C/c ++ ---- websites and Their backdoors (CGI applications)
C/C ++ has learned how to build a CGI program! First, let's take a look at what is CGI: CGI stands for "Common Gateway Interface ), a tool used by the HTTP server to "talk" with programs on your or other machines. The program must run on the network server. ---- From Baidu encyclopedia 1. first of all, we need Apache server2.0 (to learn the web, you must know this, Xi). After the software is installed, there may be many problems that may not be opened. After meow, I used to work for half a day, but finally, I got it done! (1). In fact, there are two main situations I have encountered. The first one is to disable IIS to save the boot time, or some chivalrous people directly uninstall it! So it cannot be opened! ----------------------- In the face of this problem, the next one will be ready! Apache server2.0 requires IIS cooperation. (2). The second is that port 80 is occupied, which is one of the most common scenarios. There are many solutions, but I prefer this. Cmd -- "net-ano ---> check the PID that occupies port 80 (usually a browser or something) and close it in process management! After the above Apache server is running, it will be typed into localhost in the browser, and one will be displayed and then modified, http. the cof file has two locations: the first location: # AddHandler cgi-script. cgi removes the first # annotator of this statement from the second position: <Directory "D: /Program Files/Apache Software Foundation/Apache2.2/cgi-bin "> AllowOverride NoneOptions None ----- replace this location with: Options Indexes ExecCGIOrder allow, after configuring the denyAllow from all </Directory> locations. You can use C/C ++ for programming! Step 1: compile a file such as 1 # include <stdio. h> 2 int main (int args, char * argv []) {3 4 printf ("Content-type: text/html \ n "); 5 printf ("hello world! I'm cgi "); 6 getchar (); 7 return 0; 8} compile and generate a hello.exefile named" hello. cgi is then placed in the cgi-binfile in the Self-installed Apache server2.0 file in the browser, and then enter localhost/cgi-bin/hello. cgi can see this picture 2. so after talking about this, we should use c/c ++ to write a cgi for the background and operate the data behind it! First of all, we need to write an html and make it web. Of course, this is easy! To save time, write a simple html !! Look! 1