Disclaimer:
Educational Use Only:
The website links provided are to be used strictly for educational and knowledge-gaining purposes only.
No Misuse:
Do not misuse the links or the information contained therein for any commercial, illegal, or unethical activities.
Respect for Websites and Businesses:
Respect the intellectual property and business interests of the websites and their owners. Do not attempt to alter, copy, or redistribute content without proper authorization.
Acknowledge Value of Knowledge:
Recognize and value the knowledge and resources shared by these websites. Use the information responsibly and ethically.
No Endorsement:
The provision of these links does not imply endorsement of the linked sites, their content, or their products and services. Users are responsible for evaluating the suitability and accuracy of the information.
User Responsibility:
By accessing these links, you agree to use the information at your own risk and to comply with all applicable laws and website terms of use.
- Which of the following best defines client-side execution in web security?
a. Code runs on the user’s browser or device
b. Code runs on the web server
c. Code runs on the network gateway
d. Code runs in the database
Answer: a. Code runs on the user’s browser or deviceexamradar+1 - Which is the most common language for client-side scripting in web applications?
a. Python
b. Java
c. JavaScript
d. PHP
Answer: c. JavaScriptexamradar+1 - What is a primary risk of executing code on the client side?
a. Increased server load
b. Malicious code manipulation by users
c. Reduced network bandwidth
d. Stronger encryption
Answer: b. Malicious code manipulation by usersexamradar+1 - Why should sensitive business logic never be executed only on the client side?
a. It improves user experience
b. It optimizes browser memory
c. Code can be inspected or altered by attackers
d. Faster code execution
Answer: c. Code can be inspected or altered by attackersexamradar+1 - Which attack exploits the execution of untrusted JavaScript in the user’s browser?
a. Cross Site Scripting (XSS)
b. SQL Injection
c. Command Injection
d. Man-in-the-Middle
Answer: a. Cross Site Scripting (XSS)testbook+1 - Which of the following types of validations is essential on the server, even if client-side validation is used?
a. Output validation
b. Client-side validation only
c. Input validation
d. Visual validation
Answer: c. Input validationexamradar+1 - How can a user become a victim of a drive-by download attack?
a. Downloading files from secure sources only
b. Visiting a compromised website with vulnerable software
c. Using only HTTPS sites
d. Regularly updating browsers
Answer: b. Visiting a compromised website with vulnerable softwaretestbook+1 - What role does a Content Security Policy (CSP) play in client-side security?
a. Reduces server load
b. Restricts execution of malicious scripts
c. Encrypts all data
d. Prevents brute force attacks
Answer: b. Restricts execution of malicious scriptstestbook+1 - Why is client-side validation insufficient to prevent security breaches?
a. Malicious code can bypass or disable it
b. It is invisible to users
c. It only works for static pages
d. Browsers block it automatically
Answer: a. Malicious code can bypass or disable itexamradar+1 - What is a common target for client-side attacks in web applications?
a. Database schema
b. Application logic on the client/browser
c. Operating system kernel
d. Network switches
Answer: b. Application logic on the client/browserexamradar+1 - Which of the following storage options is most vulnerable on the client side?
a. Cloud storage
b. Server database
c. Local storage or cookies
d. Encrypted backup drives
Answer: c. Local storage or cookiesexamradar+1 - A major risk of storing authentication tokens in client-side storage is:
a. Enhanced session security
b. Improved network speed
c. Easy accessibility to attackers
d. Increased server load
Answer: c. Easy accessibility to attackersexamradar+1 - What is the function of the Same-Origin Policy in browsers?
a. Block pop-up ads
b. Restrict scripts from accessing data across domains
c. Encrypt network packets
d. Optimize browser speed
Answer: b. Restrict scripts from accessing data across domainstestbook+1 - What can happen when cross-site scripting (XSS) is successful?
a. Attacker executes arbitrary code in the user’s browser
b. Server automatically shuts down
c. User’s password is changed by the browser
d. SSL certificate expires
Answer: a. Attacker executes arbitrary code in the user’s browsertestbook+1 - Which component is responsible for rendering the user interface and executing client-side scripts?
a. Server
b. Database
c. Client device/browser
d. Network switch
Answer: c. Client device/browserexamradar+1 - Which attack can intercept cookies and session data using client-side execution flaws?
a. Cross Site Scripting (XSS)
b. SQL Injection
c. DoS attack
d. DNS poisoning
Answer: a. Cross Site Scripting (XSS)testbook+1 - Why should client-side controls not be the sole method for securing sensitive data?
a. They are faster
b. Easily bypassed or manipulated by attackers
c. Make site load slower
d. Increase encryption levels
Answer: b. Easily bypassed or manipulated by attackersexamradar+1 - In which type of attack does an attacker force a user to execute unwanted actions in a web app?
a. Denial of Service attack
b. Cross Site Request Forgery (CSRF)
c. Rootkit attack
d. Buffer overflow
Answer: b. Cross Site Request Forgery (CSRF)sanfoundry+1 - Where should critical validation of form data always take place?
a. Client only
b. Server only
c. Both server and client, but server is essential
d. Database
Answer: c. Both server and client, but server is essentialexamradar+1 - Why are client-side scripts easily viewable and modifiable?
a. They are encrypted by the browser
b. Browsers interpret and expose code openly
c. Server compiles them before sending
d. They use machine code
Answer: b. Browsers interpret and expose code openlyexamradar+1 - Which of these measures can help prevent client-side script tampering?
a. Using strong server-side validation
b. Disabling SSL
c. Deleting all cookies
d. Limiting bandwidth
Answer: a. Using strong server-side validationexamradar+1 - Which is NOT a client-side scripting language?
a. JavaScript
b. HTML
c. CSS
d. PHP
Answer: d. PHPcybotech+1 - How can client-side execution contribute to phishing attacks?
a. By revealing server IP addresses
b. By rendering fake login forms in the browser
c. By blocking user input
d. By modifying the OS kernel
Answer: b. By rendering fake login forms in the browsertestbook+1 - What does a ‘defense in depth’ strategy recommend?
a. Using firewalls only
b. Layering multiple security measures, both client and server side
c. Disabling client-side execution
d. Encrypting HTML
Answer: b. Layering multiple security measures, both client and server sideexamradar+1 - Which browser feature blocks unauthorized cross-domain requests?
a. HTTP Strict Transport Security (HSTS)
b. Same-Origin Policy
c. Block All Popup Windows
d. HTML Sanitizer
Answer: b. Same-Origin Policytestbook+1 - What is the main risk of executing third-party scripts in web pages?
a. Slower site loading
b. Introduction of malicious code by attackers
c. Reduced CSS compatibility
d. Improved UI
Answer: b. Introduction of malicious code by attackersexamradar+1 - A user visits a site and malware is automatically downloaded to their machine. This is called:
a. Drive-by download
b. Man-in-the-Middle attack
c. Cookie tampering
d. Session timeout
Answer: a. Drive-by downloadtestbook+1 - Which of the following is a BEST practice for client-side security?
a. Rely only on client-side validation
b. Rely only on server-side validation
c. Use client-side security to enhance UX, but always validate server-side
d. Don’t use encryption
Answer: c. Use client-side security to enhance UX, but always validate server-sideexamradar+1 - Which web vulnerability allows attackers to inject scripts that browsers will run as legit content?
a. Cross-Site Scripting (XSS)
b. Denial of Service
c. Watering Hole attack
d. ARP Spoofing
Answer: a. Cross-Site Scripting (XSS)testbook+1 - What is a potential impact of successful client-side code injection?
a. Data breach or user impersonation
b. Faster website loading
c. Encrypted output only
d. Automatic logout
Answer: a. Data breach or user impersonationtestbook+1 - Which of the following is NOT a risk associated with client-side storage?
a. Data tampering by attackers
b. Greater network latency
c. Theft of sensitive data
d. Replay attacks
Answer: b. Greater network latencyexamradar+1 - What is one action organizations can take to protect against client-side attacks?
a. Apply security patches regularly
b. Remove all cookies
c. Disable RAM
d. Turn off the monitor
Answer: a. Apply security patches regularlytestbook+1 - What’s the best method to handle authentication in modern web apps?
a. Store tokens only in local storage
b. Store tokens securely on the server and use HTTP-only cookies
c. Print credentials in JavaScript
d. Use no authentication
Answer: b. Store tokens securely on the server and use HTTP-only cookiesexamradar+1 - Why is it dangerous to trust only client-side validation for input data?
a. Browser updates can disable it
b. Attackers can modify code and send malicious input
c. Data is always encrypted anyway
d. Hackers avoid client-side code
Answer: b. Attackers can modify code and send malicious inputexamradar+1 - Which method can help reduce the risk of XSS attacks?
a. Input sanitization and encoding output
b. Only using JavaScript frameworks
c. Removing all CSS code
d. Disabling all user interaction
Answer: a. Input sanitization and encoding outputtestbook+1 - DOM-based XSS attacks exploit vulnerabilities in:
a. Client-side scripts manipulating the DOM
b. HTTP headers
c. SSL certificates
d. SQL queries
Answer: a. Client-side scripts manipulating the DOMtestbook+1 - Which type of validation provides the best protection?
a. Only server-side validation
b. Only client-side validation
c. Both, but do not rely solely on client-side
d. Disabling validation
Answer: c. Both, but do not rely solely on client-sideexamradar+1 - What type of client-side storage should be avoided for sensitive data like tokens?
a. LocalStorage and SessionStorage
b. Server file system
c. Network switch
d. HDD
Answer: a. LocalStorage and SessionStorageexamradar+1 - Which tool can help analyze and prevent client-side script vulnerabilities?
a. Browser developer tools
b. Power supply unit
c. Server power management
d. Disk defragmenter
Answer: a. Browser developer toolsexamradar+1 - A user is tricked into clicking a malicious link that executes code in their browser. Which attack is this?
a. Cross-Site Scripting (XSS)
b. TCP SYN flood
c. Watering Hole attack
d. Sniffing
Answer: a. Cross-Site Scripting (XSS)testbook+1 - Which of the following best describes “client-side attack”?
a. Attack targeting user’s browser or client application vulnerabilities
b. Attack on data center power
c. Server hardware malfunction
d. Cloud provider misconfiguration
Answer: a. Attack targeting user’s browser or client application vulnerabilitiesexamradar+1 - How can educational programs assist in preventing client-side attacks?
a. Increase awareness of secure practices
b. Block all web traffic
c. Turn off employee computers
d. Automatically update JS code
Answer: a. Increase awareness of secure practicestestbook+1 - A script reads data from one domain and sends to another, bypassing browser restrictions. What is this called?
a. Cross-Origin Resource Sharing (CORS) misconfiguration
b. Secure HTTP transmission
c. TCP spoofing
d. Database mirroring
Answer: a. Cross-Origin Resource Sharing (CORS) misconfigurationtestbook+1 - Which of the following represents a client-side security best practice?
a. Keep browsers and plugins updated
b. Turn off browser history
c. Use public Wi-Fi always
d. Share session cookies
Answer: a. Keep browsers and plugins updatedexamradar+1 - Client-side code can be obfuscated to:
a. Make it harder for attackers to read and alter
b. Reduce server workload
c. Maximize ram usage
d. Encrypt passwords automatically
Answer: a. Make it harder for attackers to read and alterexamradar+1 - What is the primary motive behind attackers using client-side attacks?
a. To compromise client-side systems and access sensitive info
b. To speed up user browsers
c. To optimize server response times
d. To increase page load times
Answer: a. To compromise client-side systems and access sensitive infoexamradar+1 - Server-side validation is critical because:
a. Attackers cannot tamper with server logic directly from the client
b. It is slower
c. It uses less bandwidth
d. It only checks syntax
Answer: a. Attackers cannot tamper with server logic directly from the clientexamradar+1 - Which browser technology restricts cross-domain scripting by default?
a. Same-Origin Policy
b. JSON
c. WebAssembly
d. XML
Answer: a. Same-Origin Policytestbook+1 - Why is using HTTPS important for client-side security?
a. Encrypts data in transit, preventing interception and tampering
b. Decreases image quality
c. Blocks browser scripts
d. Speeds up DNS
Answer: a. Encrypts data in transit, preventing interception and tamperingexamradar+1 - If sensitive processing must occur, where should it usually be handled?
a. Always on the server side
b. In the client browser only
c. On network appliances
d. On the client’s mobile device
Answer: a. Always on the server sideexamradar+1
- https://examradar.com/client-side-vs-server-side-security-in-web-security-mcqs/
- https://examradar.com/client-side-attacks-in-web-security-mcqs/
- https://sharncommerce.org/wp-content/uploads/2024/03/B.com-V-Sem-NEP-Cyber-Security-Solved-MCQs.pdf
- https://testbook.com/objective-questions/mcq-on-owasp-top-10-vulnerabilities–5eea6a0d39140f30f369e30b
- https://testbook.com/question-answer/which-of-the-following-types-of-attack-allows-atta–63a70a5402494bbd0fb5d3c3
- https://www.sanfoundry.com/database-mcqs-application-security/
- https://cybotech.in/start-quiz/100-mcqs-client-side-vs-server-side-scripting-quiz-online-test
- https://www.sanfoundry.com/1000-cyber-security-questions-answers/
- https://www.scribd.com/document/516169743/Cyber-Security-MCQ-Set-1-5
- https://www.studocu.com/in/document/lovely-professional-university/penetration-testing/unit-v-questions-mcq/78126558
- https://forensicmcq.com/digital-forensics-mcqs-part-1-with-answer-and-explanation/
- https://www.scribd.com/document/553820157/Security-MCQ-1
- https://www.scribd.com/document/647946667/MCQ-Questions-cybersecurity
- https://www.placementpreparation.io/mcq/cyber-security/page/4/
- https://www.sanfoundry.com/tough-cyber-security-questions-answers/
- https://testbook.com/objective-questions/mcq-on-http–5eea6a0939140f30f369d901
- https://www.theknowledgeacademy.com/blog/cyber-security-mcq-and-answers/