Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Salesforce Certified B2C Commerce Architect (Arch-303) Exam - Topic 1 Question 74 Discussion

Actual exam question for Salesforce's Salesforce Certified B2C Commerce Architect (Arch-303) exam
Question #: 74
Topic #: 1
[All Salesforce Certified B2C Commerce Architect (Arch-303) Questions]

A developer is checking for Cross Site Scripting (XSS) and found that the quick search is not escaped (allows inclusion of Javascript) in the following script:

How would the developer resolve this issue?

Show Suggested Answer Hide Answer
Suggested Answer: B

To resolve the issue of Cross Site Scripting (XSS) where the quick search is not escaped, the developer should use the <isprint> tag with the 'jshtml' encoding option (Answer B). This method ensures that any JavaScript included in the search phrase is properly escaped, preventing the execution of potentially malicious scripts. The 'jshtml' encoding is specifically designed to encode text for HTML contexts where JavaScript is embedded, providing a secure way to handle user input in Salesforce B2C Commerce.


Contribute your Thoughts:

0/2000 characters
Rolland
5 days ago
Wait, are we really allowing JavaScript in the search? That's risky!
upvoted 0 times
...
Amie
10 days ago
I think D is a solid option too, but not sure if it's the best.
upvoted 0 times
...
Glory
15 days ago
Option B seems like the best choice for XSS protection.
upvoted 0 times
...
Chaya
20 days ago
I recall that using is generally a good practice for escaping, but I can't remember if it's the right choice here.
upvoted 0 times
...
Wynell
25 days ago
I'm a bit confused about the difference between 'jshtmr' and 'jsblock'—I feel like I need to review those examples again.
upvoted 0 times
...
Nieves
1 month ago
I think option C sounds familiar; it might be the one we practiced that uses 'jsblock' encoding.
upvoted 0 times
...
Vallie
1 month ago
I remember we discussed XSS prevention techniques, but I'm not entirely sure which encoding method is the best for this case.
upvoted 0 times
...

Save Cancel