tools
Table of Contents
Multiplexers
mosh
1 | mosh jdoe@10.10.10.101 |
ss
1 | user@opsschool ~$ ss -tuln |
- means the deamon is listening on all IP addresses the server might have.
127.0.0.1 means the daemon is listening only to the loopback interface
::: is the same thing as *, but for IPv6
::1 is the same as 127.0.0.1, but for IPv6
mtr
is a program that combines the functionality of ping and traceroute into one utility
1 | mtr -r uow.edu.au |
iftop
Displays bandwith usage on a specific interface, broken down by remote host
1 | sudo iftop -i eth0 |
iperf
a bandwidth testing utility. It consists of a daemon and client, running on separate machines.
1 | sudo iperf3 -c remote-host |
Troubleshooting layer 1 problems
1 | ip -s link show eth0 |
HTTP core protocol
Request
Method | Description |
---|---|
GET | Tranfers a current representation of the target resource. |
HEAD | Same as GET, but only transfer the status line and header section. |
POST | Perform resource-specific processing on the request payload. |
PUT | Replace all current representations of the target resource with the requested payload. |
DELETE | Remove all current representations of the target resource. |
CONNECT | Establish a tunnel to the server identified by the target resource. |
OPTIONS | Describe the communication options for the target resource. |
TRACE | Perform a message loop-back test along the path to the target resource. |
Response
Code | Reason | Description |
---|---|---|
200 | OK | The request has succeeded. |
301 | Moved Permenantly | The target has moved to a new location and future references should use a new location. The server should mention the new location in the Location header in the response. |
302 | Found | The target resources been temporarily moved. As the move is temporarily, future references should still use the same location. |
400 | Bad Request | The server cannot process the request as it is perceived as invalid. |
401 | Unauthorized | The request to the target resource is not allowed due to missing or incorrect authentication credentials. |
403 | Forbidden | The request to the target resource is not allowed for reasons unrelated to authentication. |
404 | Not Found | The target resource was not found. |
500 | Internal Server Error | The server encountered an unexpected error. |
502 | Bad Gateway | The server is acting as a gateway/proxy and received an invalid response from a server it contacted to fulfill the request. |
503 | Service Unavailable | The server is currently unable to fulfill the request. |
cURL
is a tool and library for transferring data with URL syntax, capable of handling various protocols.
1 | curl http://foobar/index.html |
By default cURL does not follow HTTP redirects, and instead a 3xx redirection message is given.
The -L switch makes cURL automatically follow redirects and issue another request to the given localtion till it finds the targeted resource.
1 | curl -IL foobar.org |
netcat
a networking tool capable of reading and writing data across a network connection.
Basic client/server
1 | $ nc -l 192.168.0.1 1234 > output.log |