SymLink – HowTo: Create a Symbolic Link – Linux

A symbolic link, also known as a symlink or a soft link, is a special kind of file (entry) that points to the actual file or directory on a disk (like a shortcut in Windows).

Symbolic links are used all the time to link libraries and often used to link files and folders on mounted NFS (Network File System) shares.

The ln command is a standard Linux utility for creation links. (more…)

HowTo: Create Patch Using Diff Command – Linux

If you have made some changes to the code and you would like to share these changes with others – the best way is to provide them as a patch file.

diff is the Linux command line tool that is used for creating patches (sometimes called diffs) and requires that you have two copies of the code: one with your changes and one without.

This article explains how to create a patch for a single file or for a whole directory using diff and how to apply this patch after. (more…)

Linux – Fake File Access, Modify and Change TimeStamps

Files in Linux have 3 types of timestamps: atime (access), mtime (modify) and ctime (change).

Someday you may have a situation when you would like to fake a timestamps of some file.

atime and mtime timestamps can be easily changed using touch command, but there is no a standard way to set a different ctime timestamp.

As a possible workaround you can set the system time to the ctime you want to impose, then touch the file and then restore the system time.

Read the below article to learn how to change a file’s timestamps and keep anonymity. (more…)

HowTo: Check and Change File Encoding In Linux

The Linux administrators that work with web hosting know how is it important to keep correct character encoding of the html documents.

From the following article you’ll learn how to check a file’s encoding from the command-line in Linux.

You will also find the best solution to convert text files between different charsets.

I’ll also show the most common examples of how to convert a file’s encoding between CP1251 (Windows-1251, Cyrillic), UTF-8, ISO-8859-1 and ASCII charsets. (more…)

OpenSSL: Check If Private Key Matches SSL Certificate & CSR

When you are dealing with lots of different SSL Certificates, it is quite easy to forget which certificate goes with which Private Key.

Or, for example, which CSR has been generated using which Private Key.

From the Linux command line, you can easily check whether an SSL Certificate or a CSR match a Private Key using the OpenSSL utility.

To make sure that the files are compatible, you can print and compare the values of the SSL Certificate modulus, the Private Key modulus and the CSR modulus. (more…)

20 Awesome Nmap Command Examples

In this tutorial you’ll fined 20 basic examples of Nmap command usage.

You’ll see how to use Nmap from the Linux command line to find active hosts on a network and scan for the opened ports.

You’ll learn how to determine a remote operation system using TCP/IP stack fingerprinting and how to discover what version of software is running on a remote host.

I’ll also show how to use Nmap for stealthy scanning, how to detect firewalls and spoof MAC address. (more…)