Cheap and insurmountable TCP tunnel Encryption
I haven't written anything for a long time, so I plan to write something. I used to perform penetration tests for a customer, so I have been planning to publish some of my findings. On an application server platform website, I found a very interesting vulnerability. Through this influential vulnerability, I can gain root permissions on the server in a short period of time, or have absolute permissions on the server (all directories are readable and writable ). We have been using this vulnerability for a long time. Many people have detected the vulnerability, but none of them have found this vulnerability. But don't be so excited. My boss won't allow me to leak this vulnerability. There is no suggestion. Right, there is nothing.
So I cannot discuss this project with you or my findings. I decided to check my script inventory and share a tool with you. I have been using this tool for a while. I like this tool very much. I have never planned to share it before, because I am using this powerful encryption tool and cannot even decrypt it from my password system, so this encryption tool is my secret and I like it very much. However, if I feel very confident about my system, I should share it. So I will release this encryption tool.
This story is related to a network access server. I know many excellent stories are related to the network access server, but this is definitely a special one. I bought a network access server for a while. I use it to do anything, such as saving code, home photos, documents, copies of ID cards, bills, printing documents, scanning documents, statement documents, and so on. This is not an exaggeration. I use it to do anything.
Of course, all data on my network access server is encrypted. I just bought a server and added the encryption function. This is not complicated. When your documents are not encrypted, you have to think about how to allow legal users to access these files. This encryption system can effectively organize thieves or hackers to steal your hard disk data, because your server runs 24 hours a day. In this way, the decryption code is changing at any time. (A bit like the security commands in the QQ token)
I believe that the network access server is very easy to receive attacks. There are several vulnerabilities that affect all network access servers. All my data is in the network access server, so I will not enable the remote access protocol when I am killed, even with SSL encryption. Right, I just don't believe that the current technology can ensure the security of my data. Of course, you can also say that I'm paranoid. I only use the server locally and do not allow it to connect to the Internet.
However, I cannot live like this for a long time. This situation has deteriorated over the past few days. Several times, when I was outside, I needed files on the server, but I was unable to connect to my server (the author worried that the data was stolen, so the server was disconnected from the network ). I have many years of experience in network security, and I am very good at encryption and can write multiple computer languages. I should be able to solve this problem with my own hands.
I think some encryption algorithms can achieve my dream, such as using SSL/SSH encryption. I need this method to ensure data security and it is difficult to crack. I put my encryption program on the server, and once connected, it was hard for me to fall asleep all night. I often wondered late at night whether any super hacker was intruding my server with a 0-day attack.
I don't remember that the flynham password can be used for reverse cracking. Yes, my encryption algorithm is the same as that of the fynham password. There is no way to reverse crack it, but it will be very difficult for ordinary people to use it. You need a time-type data package loader. Secondly, it is large enough to accommodate encrypted files. Therefore, for fvenham encryption, the principle of this encryption is unbreakable, and you do not even need to use OTP data again. I call this encryption "one time pad )". If you want to send or accept 1 GB of data, you must first have a 1 GB key.
Through this theory, I have designed a channel called the fynham tunnel. This is a cross-platform, multi-thread TCP tunnel software. It is encrypted and decrypted through the flynham algorithm. You can build a flynham tunnel on all mainstream operating systems. It has enough threads to support a large number of concurrent online clients. Of course, there is a question about the key. Everyone has their own encryption algorithms, but let's look at my methods first.
-Generate a huge file: You can copy, compress, or generate a huge file at will. Then, you need to use a more reliable encryption method to encrypt the file and generate a large string of keys. You do not need to remember this key. You only need to enter a password. Then use AES to encrypt your file. Here you can use the openssl command "openssl enc-aes-256-cbc ". Then, use a hard disk encryption tool such as Truecrypt to create an encrypted storage solution. Then... You can use the encryption method you want.
In this way, when I am out, and need to teach a lot of files, I don't have to expect to transfer more than 1 GB of files, as long as I have 2 GB of keys locally. It only needs to transmit a small piece of code, and then the file that I want to transmit will be generated on my local machine.
Similarly, you can use this key once or for a whole month. You only need to purchase a mobile hard drive of about GB and then encrypt the entire disk. Then, put the encrypted file into your network access server or computer. Then, when you need to run the fynham tunnel, specify the start command as -- start-pos. In the next day, it will change its own start-pos code ). There is only one thing you need to write down, that is, the starting code of its change every day.
If you can change the initial code every day, your files are absolutely safe.
-Run some commands of the fynham tunnel on your computer
Vernamtunnel -- local-port = 443 -- remote-host = NASServer -- remote-port = 443 -- key-file =/media/Encrypted -- start-pos = 6482691749
If one day I want to re-run the fanham tunnel, I just need to redefine the start-pos parameter. I only need to write down the start code of each day and have my USB command card (after encrypting the entire mobile hard disk with his tool, then the hard disk becomes a USB command card ). Then, set the sending port to port 443. Of course, I seldom use port 443. Generally, I set the sending port to port 18734 that is rarely used.
Next, you need to use my software to set your mobile hard disk. Below are the parameters
Vernamtunnel.exe -- local-port = 443 -- remote-host = MYINTERNETIP -- remote-port = 18734 -- key-file = F: \ Encrypted -- start-pos = 6482691749
Now, enter https: // localhost in the browser, then I will see the https interface of my server.
Compile:
In the system, you can do the following:
make cleanmake
If you want to compile in linux, run the following command on windows:
Apt-get install wine mingw32 mingw32-binutils mingw32-runtimemake cleanmake-f Makefile. WinInLinux If You Want To compile and run it on Windows, you need to install Mingw or Cygwin
make cleanmake -f Makefile.MinGW32