I wanted something to quickly take a bunch of images and make a gallery page. The linux binary convert and a Bash Script to create thumbnails did the trick:
Debian, Linux, Shell Stuff, Server Administration
Enable IP Forwarding
By default, Checkpoint firewalls will not let pings pass through them. However, when you first setup a network, it’s useful to be able to test wide open through the firewall to verify routing and connectivity. Here is how to enable IP forwarding.
View HTTP Headers with Wget
View HTTP Headers with WGET
There are tools like curl, fiddler2, httpwatch, and of course wireshark that will show greater details, but if you don’t have these available, or are looking for a simple way to get debug http headers – you can use wget:
Find max MTU size
- Maximum Transmission unit is how big of a fragment can be sent. TCP/IP fragments data that doesn’t fit into one window (just about everything), then reassembles it at the far end. If the MTU is wrong, networking will fail.
I was wondering what the max MTU size was from my PC to our gateway … here is how I found the max mtu size
Use Curl to See HTTP Headers
You can use curl to see the http headers from an email link, or webpage is going to send you to a known bad page. If you want to see the contents of the page, without risk of infection (look for base64 encoding is a good sign of an infected page, but common sense will prevail) – just curl the http://address without parameters. But if you want to get the headers from an http request using curl instead of your browser – perhaps to troubleshoot http response codes, ssl certificates or other website problems, then this is a technique that will help you…
SSH Tunnel Tutorial
Be warned that this ssh tunnel tutorial will deliberately bypass a firewall, and security admins will frown (at the very least) on you bypassing a corporate firewall.
How to encrypt anything over SSH tunnel using a Socks Proxy.
(How to Browse Securely from hotspots or hide from corporate firewalls/sniffers)
SSH Security Checklist
SSH Security Checklist
All of the SSH Security Tips that are listed here are done by editing /etc/ssh/sshd_config as su:
If SSH timeout is bugging you, here is how to increase the timeout for the ssh shell:
On the Server:
sudo vim /etc/sshd_config #add this line for server side keep alives every 60s: ClientAliveInterval 60
On the Client:
sudo vim /etc/ssh_config #add this line to send keep alives from client to server every 60s ServerAliveInterval 60
Don’t forget to restart the ssh daemon where appropriate:
sudo /etc/init.d/ssh restart
sudo vim AFTER you typed
Ever typed something in vi or vim and minutes later, realized you don’t have permission to save what you typed?
I was looking up how to goto a line in VIM, and found a great article that had the method of going to a line (:1322 if you wanted to go to link 1322), and I found a gem: