Which of the following represents a security concern of programming CGI scripts using the C programming language?
Answer(s)
- C programs must be run with setuid root.
- If the program receives more data than the amount of memory it has allocated, a buffer overflow can cause the program to exit to a shell on the server.
- Many early C compile lack the ability to dynamically alter file permissions, which results in many C program running with root permissions.
- CGI script written in C compile at runtime on the client system, which makes the client vulnerable.
- If the server and client do not have identical compiler versions, the lesser compiler is used, which may have known exploits.
Correct Answer
If the program receives more data than the amount of memory it has allocated, a buffer overflow can cause the program to exit to a shell on the server.