Chapter 4 - Application Security Flashcards

1
Q

Which of the following is one way of preventing spyware from being downloaded?
A. Use firewall exceptions.
B. Adjust Internet Explorer security settings.
C. Adjust the Internet Explorer home page.
D. Remove the spyware from Add/Remove Programs.

A

B. Adjust the Internet Explorer security settings so that security is at a higher level, and add trusted and restricted websites.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q
What key combination should be used to close a pop-up window?
A. Windows+R
B. Ctrl+Shift+Esc
C. Ctrl+Alt+Del
D. Alt+F4
A

D. Alt+F4 is the key combination that is used to close an active window. Sometimes it is okay to click the X, but malware creators are getting smarter all the time; the X could be a ruse.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q
Which protocol can be used to secure the e-mail login from an Outlook client
using POP3 and SMTP?
A. SMTP
B. SPA
C. SAP
D. Exchange
A

B. SPA (Secure Password Authentication) is a Microsoft protocol used to authenticate e-mail clients. S/MIME and PGP can be used to secure the actual e-mail transmissions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are two ways to secure Internet Explorer? (Select the two best answers.)
A. Set the Internet zone’s security level to High.
B. Disable the pop-up blocker.
C. Disable ActiveX controls.
D. Add malicious sites to the Trusted Sites zone.

A

A and C. By increasing the Internet zone security level to high, you employ the maximum safeguards for that zone. ActiveX controls can be used for malicious purposes; disabling them makes it so that they do not show up in the
browser. Disabling a pop-up blocker and adding malicious sites to the Trusted Sites zone would make Internet Explorer less secure.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q
Heaps and stacks can be affected by which of the following attacks?
A. Buffer overflows
B. Rootkits
C. SQL injection
D. Cross-site scripting
A

A. Stacks and heaps are data structures that can be affected by buffer overflows. Value types are stored in a stack, whereas reference types are stored in a heap. An ethical coder will try to keep these running efficiently. An unethical coder will attempt to use a buffer overflow to affect heaps and stacks that in turn could affect the application in question or the operating system. The
buffer overflow might be initiated by certain inputs and can be prevented by bounds checking.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q
As part of your user awareness training, you recommend that users remove which of the following when they finish accessing the Internet?
A. Instant messaging
B. Cookies
C. Group policies
D. Temporary files
A

B. The best answer is cookies, which can be used for authentication and session tracking and can be read as plain text. They can be used by spyware and can track people without their permission. It is also wise to delete temporary
Internet files as opposed to temporary files.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Which statement best applies to the term Java applet?
A. It decreases the usability of web-enabled systems.
B. It is a programming language.
C. A web browser must have the capability to run Java applets.
D. It uses digital signatures for authentication.

A

C. To run Java applets, a web browser must have that option enabled. Java increases the usability of web-enabled systems, and Java is a programming language. It does not use digital signatures for authentication.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q
Which of the following concepts can ease administration but can be the victim of malicious attack?
A. Zombies
B. Backdoors
C. Buffer overflow
D. Group policy
A

B. Backdoors were originally created to ease administration. However, hackers quickly found that they could use these backdoors for a malicious attack.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q
In an attempt to collect information about a user’s activities, which of the following will be used by spyware?
A. Tracking cookie
B. Session cookie
C. Shopping cart
D. Persistent cookie
A

A. A tracking cookie will be used, or misused, by spyware in an attempt to access a user’s activities. Tracking cookies are also known as browser cookies or HTTP cookies, or simply a cookie. Shopping carts take advantage of cookies to keep the shopping cart reliable.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q
What is it known as when a web script runs in its own environment and does not interfere with other processes?
A. Quarantine
B. Honeynet
C. Sandbox
D. VPN
A

C. When a web script runs in its own environment for the express purpose of not interfering with other processes, it is known as running in a sandbox. Often, the sandbox will be used to create sample scripts before they are actually implemented. Quarantining is a method used to isolate viruses. A honeynet is a collection of servers used to attract hackers and isolate them in an area where they can do no damage. VPN is short for virtual private network, which enables the connection of two hosts from remote networks.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

How can you train a user to easily determine whether a web page has a valid security certificate? (Select the best answer.)
A. Have the user contact the webmaster.
B. Have the user check for HTTPS://.
C. Have the user click the padlock in the browser and verify the certificate.
D. Have the user called the ISP.

A

C. In Internet Explorer, the user should click the padlock in the browser; this will show the certificate information. Often, the address bar will have different colors as the background; for example, blue or green means that the certificate is valid, whereas red or pink indicates a problem. In Firefox, click the name of the website listed in the address bar just before where it says HTTPS to find out the validity of the certificate. Contacting the webmaster and calling the ISP are time-consuming, not easily done, and not something that an end user should do. Although HTTPS:// can tell a person that the browser is now using the hypertext transfer protocol secure, it does not necessarily determine whether the certificate is valid.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q
To code applications in a secure manner, what is the best practice to use?
A. Cross-site scripting
B. Flash version 3
C. Input validation
D. HTML version 5
A

C. Input validation is the best practice to use when coding applications. This is important when creating web applications or web pages that require information to be inputted by the user.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q
An organization hires you to test an application that you have limited knowledge of.  You are given a login to the application, but do not have access to source code.  What type of test are you running?
A. White box
B. Gray box
C. Black box
D. SDLC
A

B. A gray box test is when you are given limited information about the system you are testing. Black box testers are not given logins, source code, or anything else, though they may know the functionality of the system. White box testers are given logins, source code, documentation, and more. SDLC stands for Systems Development Life Cycle of which these types of tests are just a part.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q
You check the application log of your web server and see that someone attempted unsuccessfully to enter the text “test; etc/passwd” into an HTML form field. Which attack was attempted?
A. SQL injection
B. Code injection
C. Command injection
D. Buffer overflow
A

C. In this case a command was entered, and the attacker was attempting to gain access to the password file within the /etc directory. If the attacker tried to inject code, he would not use commands, but rather PHP, ASP, or another language. SQL injections are usually run on databases, not web servers’ HTML forms. Buffer overflows have to do with memory and how applications utilize it.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q
An attacker takes advantage of vulnerability in programming, which allows the attacker to copy more than 16 bytes to a standard 16-byte variable.  Which attack is being initiated?
A. Directory traversal
B. Command injection
C. XSS
D. Buffer overflow
A

D. A buffer overflow can be initiated when a string variable is not programmed correctly—for example, if the variable allows for more than the standard amount of bytes. Directory traversal is when an attacker uses commands and code to access unauthorized parent directories. Command injection is when commands and command syntax are entered into an application or OS. XSS or cross-site scripting is when code is injected into a website form to obtain information and unauthorized access.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q
What’s the best way to prevent SQL injection attacks on web applications?
A. Input validation
B. Host-based firewall
C. Add HTTPS pages
D. Update the web server
A

A. Input validation is the best way to prevent SQL injection attacks on web servers and database servers (or combinations of the two). Host-based firewalls aid in preventing network attacks but not necessarily coded attacks of this type. HTTPS pages initiate a secure transfer of data, but they don’t necessarily lock out attackers that plan on using SQL injection. Updating the web server is a good idea, but will have little if any effect on the forms that are written by the web programmer.

17
Q
Which of the following attacks uses a JavaScript image tag in an e-mail?
A. SQL injection
B. Cross-site scripting
C. Cross-site request forgery
D. Directory traversal
A

B. Cross-site scripting (XSS) can be initiated on web forms or through e-mail. It often uses JavaScript to accomplish its means. SQL injection is when code (SQL-based) is inserted into forms or databases. Cross-site request forgery (XSRF) is when a user’s browser sends unauthorized commands to a website, without the user’s consent. Directory traversal is when an attacker attempts to gain access to higher directories in an OS.

18
Q
Which of the following should occur first when developing software?
A. Fuzzing
B. Penetration testing
C. Secure code review
D. Patch management
A

C. Of the listed answers, secure code review should happen first in the SDLC. It should be followed by fuzzing and penetration testing in that order. Patch management is a recurring theme until the software meets the end of its life cycle.

19
Q
You are the security administrator for a multimedia development company.  Users are constantly searching the Internet for media, information, graphics, and so on. You receive complaints from several users about unwanted windows appearing on their displays.  What should you do?
A. Install antivirus software
B. Install pop-up blockers
C. Install screensavers
D. Install a host-based firewall
A

B. The windows that are being displayed are most likely pop-ups. Standard pop-up blockers will prevent most of these. Antivirus software of itself does not have pop-up blocking technology but might be combined in a suite of antimalware software that does have pop-up blocking capability. Screensavers won’t affect the users’ web sessions. Host-based firewalls are a good idea and
will prevent attacks, but since a firewall will allow the connections that users make to websites, it cannot stop pop-ups.

20
Q
You have analyzed what you expect to be malicious code. The results show that JavaScript is being utilized to send random data to a separate service on the same computer.  What attack has occurred?
A. DoS
B. SQL injection
C. LDAP injection
D. Buffer overflow
A

D. Buffer overflows can be initiated by sending random data to other services on a computer. While JavaScript is commonly used in XSS attacks, it can also be used to create a buffer overflow. DoS stands for denial of service, which is when a computer sends many packets to a server or other important system in the hope of making that system fail. SQL and LDAP injection will not use JavaScript.