1.
What is the attack technique used to exploit websites by altering backend database queries through inputting manipulated queries?
Correct Answer
C. SQL Injection
Explanation
SQL Injection is the correct answer because it is a technique used to exploit websites by altering backend database queries through inputting manipulated queries. It involves inserting malicious SQL code into an application's database query, allowing an attacker to gain unauthorized access to the database, modify or retrieve sensitive data, and even execute arbitrary commands on the server.
2.
What happens when an application takes user-inputted data and sends it to a web browser without proper validation and escaping?
Correct Answer
B. XSS
Explanation
When an application takes user-inputted data and sends it to a web browser without proper validation and escaping, it can lead to a vulnerability known as XSS (Cross-Site Scripting). XSS occurs when an attacker is able to inject malicious scripts or code into a website, which then gets executed by unsuspecting users. This can result in the attacker stealing sensitive information, manipulating website content, or even gaining unauthorized access to user accounts. Therefore, the correct answer is XSS.
3.
What flaw arises from session tokens having poor randomness across a range of values?
Correct Answer
B. Session Hijacking
Explanation
Session hijacking is the flaw that arises from session tokens having poor randomness across a range of values. Session hijacking occurs when an attacker is able to intercept and steal a valid session token, allowing them to impersonate the user and gain unauthorized access to their account. If session tokens have poor randomness, it becomes easier for an attacker to guess or predict valid tokens, increasing the likelihood of successful session hijacking attacks.
4.
An attack technique that forces a user’s session credential or session ID to an explicit value.
Correct Answer
D. Session Fixation
Explanation
Session fixation is an attack technique where an attacker forces a user's session credential or session ID to a specific value. This is typically done by tricking the user into using a predetermined session ID, allowing the attacker to hijack the session and gain unauthorized access to the user's account. Unlike brute force or dictionary attacks, session fixation focuses on manipulating the session ID rather than attempting to guess or crack passwords.
5.
What threat arises from not flagging HTTP cookies with tokens as secure?
Correct Answer
A. Session Hijacking
Explanation
Not flagging HTTP cookies with tokens as secure can lead to session hijacking. When a cookie is not marked as secure, it can be intercepted by attackers who can then use the stolen cookie to impersonate the user and gain unauthorized access to their session. This allows the attacker to take control of the user's session and perform actions on their behalf without their knowledge or consent.
6.
Which attack can execute scripts in the user’s browser and is capable of hijacking user sessions, defacing websites or redirecting the user to malicious sites.
Correct Answer
B. XSS
Explanation
XSS (Cross-Site Scripting) is the correct answer. XSS is an attack that allows an attacker to inject malicious scripts into web pages viewed by users. These scripts can then be executed in the user's browser, giving the attacker the ability to hijack user sessions, deface websites, or redirect users to malicious sites. XSS attacks can occur when a website does not properly validate or sanitize user input, allowing the injection of malicious code.
7.
What flaw can lead to exposure of resources or functionality to unintended actors?
Correct Answer
B. Improper Authentication
Explanation
Improper authentication is a flaw that can lead to exposure of resources or functionality to unintended actors. This means that if a system does not properly verify and authenticate users, it can allow unauthorized individuals to gain access to sensitive information or perform actions that they should not be able to. This flaw can occur when authentication mechanisms are weak, improperly implemented, or not enforced consistently throughout the system.
8.
Which threat can be prevented by having unique usernames generated with a high degree of entropy?
Correct Answer
B. Authentication bypass
Explanation
Having unique usernames generated with a high degree of entropy can prevent authentication bypass. This is because authentication bypass occurs when an attacker is able to bypass the login process and gain unauthorized access to a system or application. By using unique usernames with high entropy, it becomes more difficult for attackers to guess or brute force their way into an account, increasing the overall security of the authentication process.
9.
What threat are you vulnerable to if you do not validate authorization of user for direct references to restricted resources?
Correct Answer
D. Insecure Direct object references
Explanation
If you do not validate authorization of a user for direct references to restricted resources, you are vulnerable to Insecure Direct Object References. This means that an attacker can directly access and manipulate restricted resources without proper authorization, potentially leading to unauthorized access, data breaches, or other security issues.
10.
Role-Based Access Control helps prevent this OWASP Top 10 weakness:
Correct Answer
C. Authorization bypass
Explanation
Role-Based Access Control (RBAC) helps prevent C. Authorization Bypass. RBAC is a method where permissions are associated with roles, and users are assigned to these roles, thereby obtaining the permissions to perform particular functions within the system. This helps in preventing unauthorized access to resources, thereby mitigating the risk of authorization bypass. It’s a key part of securing sensitive information within a system.
11.
What is the type of flaw that occurs when untrusted user-entered data is sent to the interpreter as part of a query or command?
Correct Answer
B. Injection
Explanation
Injection is the correct answer because it refers to the type of flaw that occurs when untrusted user-entered data is sent to the interpreter as part of a query or command. This can happen in various contexts, such as SQL injection, where malicious code is injected into a SQL query, or command injection, where malicious commands are injected into a system command. In both cases, the attacker is able to manipulate the interpreter and potentially gain unauthorized access or perform malicious actions.
12.
For every link or form which invoke state-changing functions with an unpredictable token for each user what attack can be prevented
Correct Answer
C. Cross Site Request Forgery
Explanation
Cross Site Request Forgery (CSRF) is an attack that occurs when a malicious website tricks a user's browser into making a request to another website where the user is authenticated. This attack is prevented by using unpredictable tokens for each user, which are included in links or forms that invoke state-changing functions. These tokens ensure that the request originated from the legitimate website and not from a malicious source, thus protecting against CSRF attacks.
13.
For a connection that changes from HTTP to HTTPS, what flaw arises if you do not change the session identifier?
Correct Answer
D. Session Hijacking
Explanation
The flaw that arises if you do not change the session identifier when a connection changes from HTTP to HTTPS is D. Session Hijacking. This is because an attacker might have already intercepted the HTTP traffic and obtained the session identifier. If the session identifier is not changed when switching to HTTPS, the attacker can continue to use the intercepted session identifier to hijack the session. This is a serious security flaw as it can lead to unauthorized access to sensitive information. Always ensure that the session identifier is changed when switching from HTTP to HTTPS to prevent this type of attack.
14.
Attack that exploits the trust that a site has in a user's browser is called ____________.
Correct Answer
B. Cross Site Request Forgery
Explanation
Cross Site Request Forgery is an attack that takes advantage of the trust that a website has in a user's browser. In this type of attack, the attacker tricks the user's browser into making unauthorized requests on their behalf, exploiting the fact that the website trusts the user's browser to send legitimate requests. This can lead to various security vulnerabilities, such as unauthorized actions being performed on the user's behalf or sensitive information being accessed by the attacker.
15.
For an an indirect reference, what happens if there’s no list of limited values authorized for a user in the direct reference?
Correct Answer
D. Access to sensitive data possible
Explanation
If there is no list of limited values authorized for a user in the direct reference, it means that there are no restrictions on the data that the user can access. This can lead to access to sensitive data possible, as the user can potentially retrieve or modify any data in the system without any limitations or restrictions.
16.
We can allow client-side scripts to execute in the browsers for needed operations. State true or false.
Correct Answer
A. True
Explanation
The statement is True. We can allow client-side scripts to execute in the browsers for needed operations. However, it’s important to note that this should be done with caution due to the potential security risks associated with client-side scripting, such as Cross-Site Scripting (XSS) attacks. Proper input validation and output encoding practices should be implemented to mitigate these risks.
17.
Which of these are categorized as 'session-related vulnerabilities'?
Correct Answer(s)
A. Session Fixation
B. Session Spoofing
C. Session Hijacking
Explanation
Session-related vulnerabilities in the context of cybersecurity involve risks associated with the management and security of user sessions. Session Fixation occurs when an attacker sets a user's session identifier, potentially gaining unauthorized access. Session Spoofing involves impersonating a legitimate user by exploiting session information, while Session Hijacking refers to intercepting or taking over an active session.
18.
What is phishing?
Correct Answer
B. Email Scam
Explanation
Phishing refers to a type of online scam where individuals or organizations attempt to deceive others by posing as a trustworthy entity in order to obtain sensitive information such as passwords, credit card details, or personal data. This is commonly done through fraudulent emails that appear to be from legitimate sources, tricking recipients into clicking on malicious links or providing their confidential information.
19.
Define Cookie.
Correct Answer
B. A file that makes it easier to access a Web site and browse.
Explanation
A cookie is a file that is created by a website and stored on the user's computer. It contains information about the user's preferences and browsing habits, allowing the website to remember the user and provide a personalized experience. Cookies make it easier to access a website and browse by storing relevant information and settings, such as login credentials and language preferences. They do not have anything to do with computer viruses, stealing identities, or being a web application file.
20.
You receive an e-mail from Desjardins saying that you have won a contest. What should you do?
Correct Answer
D. Contact your caisse to confirm the information
Explanation
Contacting your caisse to confirm the information is the correct answer because it is important to verify the legitimacy of the email before providing any personal information or taking any further action. This will help ensure that the contest is genuine and not a scam.
21.
An IP Address is the Internet equivalent of ______________.
Correct Answer
A. Your mailing address
Explanation
An IP address is similar to a mailing address because it is a unique identifier that allows devices to communicate with each other over the internet. Just like how a mailing address tells the postal service where to deliver a package, an IP address tells the internet where to send data packets. It helps in routing information between different devices and networks, ensuring that data reaches its intended destination.
22.
Network permissions should be established so that users can accomplish their tasks, but cannot access any system resources that are not necessary so that ____________________________.
Correct Answer
C. Only the resources authorized for that user will be at risk.
Explanation
Establishing network permissions ensures that users can only access the resources that are necessary for them to perform their tasks. By limiting their access to only authorized resources, the risk of unauthorized access and misuse of system resources is minimized. This prevents hackers from posing as legitimate users and reduces the likelihood of a legitimate user's identity being stolen. Therefore, by establishing network permissions, the only resources that will be at risk are the ones that have been specifically authorized for that user.
23.
Statistics show that many companies connected to the Internet are not sufficiently secure. Why not?
Correct Answer(s)
A. Many companies do not have a written security policy in place
C. Many companies have insufficient protection between the Internet and company networks
D. Many companies have insufficient information about the traffic over the company networks
Explanation
Many companies connected to the Internet are not sufficiently secure due to various reasons. One reason is that many companies do not have a written security policy in place, which means they lack clear guidelines and protocols to protect their systems and data. Additionally, many companies have insufficient protection between the Internet and their company networks, leaving them vulnerable to cyber attacks. Furthermore, many companies lack sufficient information about the traffic over their networks, making it difficult for them to identify and address potential security threats. Therefore, the combination of these factors contributes to the lack of security in many companies connected to the Internet.
24.
The use of proper security techniques can _______________.
Correct Answer(s)
A. Minimize the threat of attackers
C. Prevent most hackers from accessing your system
Explanation
The use of proper security techniques can minimize the threat of attackers and prevent most hackers from accessing your system. By implementing strong security measures such as firewalls, encryption, and regular updates, the chances of unauthorized access to your system are significantly reduced. While it cannot provide 100 percent security, using proper security techniques greatly enhances the overall security posture and reduces the risk of successful attacks.
25.
The characteristics of an effective security system are that the system is _______________.
Correct Answer
B. Highly secure, easy to use, flexible, and scalable
Explanation
An effective security system is one that combines high-security measures with ease of use, flexibility to adapt to changing needs, and scalability for future growth. While comprehensive alarming and reporting are important features, the overall effectiveness of a security system requires a balance of these characteristics.
26.
What is the attack technique used to exploit websites by altering backend database queries through inputting manipulated queries?
Correct Answer
C. SQL Injection
Explanation
SQL Injection is the correct answer because it is a common attack technique where an attacker alters backend database queries by inputting manipulated queries. This allows the attacker to execute unauthorized actions on the database, such as retrieving sensitive information, modifying data, or even deleting the entire database. By exploiting vulnerabilities in the input validation process, the attacker can inject malicious SQL code that is executed by the database, bypassing normal security measures. This can have serious consequences for the targeted web application and its users.