Networks Guru

Tag: linux

Using Dual Monitor/Dual Touch Screens on Ubuntu

When using a dual touch screens on ubuntu, the touch may not be mapped correctly to the monitor and it may span both screens as input and only 1 monitor as an output.
Or simply touching any of them will result in having the input on the same screen (Relatively).

So, In order to apply a fix for this issue, The touch input should be mapped to the correct monitor

We may use 2 linux apps to list this info.
1. xinput is used for listing the input devices
2. xrandr is used to show/set the size, orientation and/or reflection of the outputs for a screen. It can also set the screen size.

Listing Network Interfaces in C

There are various ways for listing the network interfaces while programming in C, The below code sample should be straight forward & list them all.

Apache – Mapping URL PATH to a Directory on the FileSystem

Well, Mapping a URL Path to a directory can be useful in many scenarios,

Ex:

  • As a proof of ownership, some sites may ask you to publish certain files in certain directories “Google WebSite Ownership Verification, etc…
  •  Publishing Django static files while proxying all the other URLs. Django Developers will relate 🙂
  • etc…

Patching WordPress DoS Vulnerability CVE-2018-6389 using Modsecurity

The Vulnerability as explained in https://baraktawily.blogspot.fr/2018/02/how-to-dos-29-of-world-wide-websites.html relies in executing high number of requests, So by temporarily applying rate limiting, the impact of this vulnerability maybe mitigated using various methods one of them is by using Modsecurity until a fix is released.

Other References:

https://wpvulndb.com/vulnerabilities/9021
https://baraktawily.blogspot.fr/2018/02/how-to-dos-29-of-world-wide-websites.html
https://github.com/quitten/doser.py
https://thehackernews.com/2018/02/wordpress-dos-exploit.html
https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-6389

Creating a dummy Interface on a Linux/Unix based Systems

A dummy interface maybe created for various reasons like:

  • Publishing Services
  • A 2nd loopback interface with a public IP

Verifying a route on a Linux System

With the existence of the IP package in a linux/unix system the routing table can be viewed using the below command

$ ip route

ex:

Parsing a list of IPs and/or Networks with Prefix-Length or Subnet Masks

A very simple script that uses ipcalc capabilities to parse a list of IPs or networks an outputs a list of readable Network IDs with their subnet masks.

#!/bin/bash

AUTHOR=AHMED
Blog=”Networks.Guru”

Powered by WordPress & Theme by Anders Norén