What does the 'HttpOnly' attribute flag instruct a web browser to do when handling a specific session cookie? MCQ with Answer and Explanation

What does the 'HttpOnly' attribute flag instruct a web browser to do when handling a specific session cookie?
A. To prevent client-side scripts (like JavaScript) from accessing the cookie, reducing the risk of data theft via Cross-Site Scripting (XSS)
B. To ensure the cookie only operates when accessing local intranet platforms
C. To force the web page content layout into a text-only presentation mode
D. To delete the cookie instantly when the network switches to an alternative port path
Answer: Option A
Solution (By JKSSB Mock Tests)
The 'HttpOnly' security flag prevents client-side scripts from reading cookie strings via properties like 'document.cookie', protecting session tokens from malicious script injection exploits.

Discuss this Question (0)

No comments yet. Be the first to start the discussion!

Practice More Internet and Web Technologies Questions

Question #1
Which specific protocol operates inside network environments to enable secure communication tunnels, replacing legacy unencrypted routing options for terminal management?
A. POP3 server paths
B. HTTP plain text standards
C. SSH (Secure Shell)
D. SMTP protocol loops

Correct Answer: Option C


Explanation:
SSH utilizes public-key cryptography to authenticate remote systems and encrypt communications, providing a secure alternative to unencrypted protocols like Telnet.

This question belongs to: Computer Internet and Web Technologies
Question #2
What does the term 'Hypertext' mean in the context of the World Wide Web environment?
A. Encrypted secure string text used inside user database units
B. Text that is transmitted at speeds faster than fiber networks
C. Text that contains embedded links pointing to other documents or media files
D. Text written using machine language binary code values

Correct Answer: Option C


Explanation:
Hypertext is text that contains embedded electronic cross-references (hyperlinks), allowing users to easily jump from one piece of text to another related node.

This question belongs to: Computer Internet and Web Technologies
Question #3
Which protocol is utilized by network administrators to dynamically assign local IP addresses automatically to devices joining a network?
A. SMTP
B. FTP
C. DHCP
D. DNS

Correct Answer: Option C


Explanation:
DHCP (Dynamic Host Configuration Protocol) automatically assigns IP addresses and network configuration parameters to client devices dynamically.

This question belongs to: Computer Internet and Web Technologies