wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

Lesson 2 - Passing Data to Subsystems

Total questions: 10

Worksheet time: 20mins

Name
Class
Date
1.

What is the main security problem with meta-characters, when a dynamic web applications pass data to a subsystem?

a)

The parser may switch context from normal text to control command.

b)

They may contain names, addresses, passwords, and some private information.

c)

They contain raw data, instead of encrypted data.

d)

The programmer is not able to handle them.

2.

Any database server based on SQL will need to have quotes escaped in string constants.

a)

True

b)

False

3.

The hyphens are not the main root of problem in SQL injection attack.

a)

True

b)

False

4.

If a program run an external command using operating system, the risk of which attack is more probably increased?

a)

SQL injection

b)

Shell command injection

c)

Session Hijacking

d)

All the above answers

5.

All the following methods are useful to reduce the risk of Shell Command Injection, except:

a)

Managing without the shell

b)

Avoiding user input in the command arguments

c)

Avoiding 'Finger' and 'Sendmail' commands

d)

Handling shell metacharacters

6.

An attacker entered this input as email address when registering in a system. What attack he intend to perform?

a)

Shell command injection

b)

SQL injection

c)

Session hijacking

d)

Metacharacter injection

7.

An attacker can modify queries that are sent to a database by playing with input to the web application. It describes ...

a)

Shell Command Injection

b)

SQL Injection

c)

Cross-site Scripting

d)

Session Hijacking

8.

If we do not handle metacharacters, our SQL-based database application will be vulnerable to SQL injection attacks.

a)

True

b)

False

9.

A good measure against SQL injection attack is to pass query parameters separately from the SQL statement itself.

a)

True

b)

False

10.

Which statement is incorrect about blacklisting of metacharacters in Shell Command Injection?

a)

We handle only the characters we know are unsafe.

b)

It is not a good measure because we may easily miss some metacharacters.

c)

Escaping shell metacharacters is easy with blacklisting.

d)

Blacklist must contains all metacharacters of different shells, if we are not quite sure what kind of shell will be used.