Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Document preview thumbnail
Preview 4 out of 42 pages
Exam (elaborations)

WGU D385 Pre-Assessment 2026/2027 | Software Security & Testing | Questions & Answers | Exam Prep

Document preview thumbnail
Preview 4 out of 42 pages

Prepare for the WGU D385 Pre-Assessment with focused practice questions and answers covering Software Security and Testing. Review software vulnerabilities, secure coding, logging, error handling, assertions, static and dynamic analysis, testing, authentication, authorization, REST API security, vulnerability remediation, encryption, and security testing concepts. Use the questions and explanations to test your understanding, reinforce key concepts, identify areas needing additional review, and prepare effectively for D385 assessments and performance tasks. Ideal for structured review and focused exam preparation.

Content preview

WGU D385 PRE-ASSESSMENT 2026/2027 | ALL CORRECT
ANSWERS | HIGH-YIELD PRACTICE QUESTIONS | COMPLETE
EXAM PREP STUDY GUIDE | VERIFIED ANSWERS | LATEST
UPDATE
1. What does the os.R_OK constant represent in the context of the os.access
function in Python?

Delete permission

Read permission

Execute permission

Write permission

2. Assume x and y are String variables with x = "Hello" and y = null. The result of
(x = = y) is

a syntax error

x being set to the value null

false

true

a run-time error

3. What does the 403 Forbidden status code imply?

The client's request is malformed.

The client does not have the necessary permissions to access the
requested resource.

The server refuses to authorize the request.

The requested resource is temporarily unavailable.

,4. Describe how input validation helps in defending against log injection
attacks.

Input validation ensures that only properly formatted data is
accepted, preventing malicious input from being logged.

Input validation is used only for user authentication.

Input validation allows all data but filters it after logging.

Input validation is irrelevant to log security.

5. If a web application is vulnerable to session hijacking, what defensive coding
technique could be implemented to mitigate this risk?

Using only client-side validation for user inputs.

Disabling logging to prevent information leakage.

Allowing unrestricted access to API endpoints.

Implementing secure session management practices.

6. Describe the significance of returning the old value in the safe_deserialize
function when the keys match.

Returning the old value prevents data loss and maintains
consistency in the deserialization process.

Returning the old value allows for easier debugging of the function.

Returning the old value indicates a successful operation.

Returning the old value is irrelevant to the function's purpose.

7. You call a secured API with an expired token. What HTTP status code should
you expect?

404 Not Found

, 401 Unauthorized

400 Bad Request

403 Forbidden

8. Which HTTP response status code indicates that the user is not authenticated
to access the site?

404

400

401

403

201

9. What is the primary purpose of cross-origin resource sharing (CORS)?

To enable file sharing between different web applications.

To restrict web applications from accessing external resources.

To enhance the security of web applications by blocking all cross-
origin requests.

To allow web applications to make requests to domains other than
their own.

10. If a Python program uses os.access(filename, os.W_OK) and returns False,
what should the programmer infer about the file?

The file does not exist.

The file is not writable by the program.

The file is readable by the program.

The file is executable by the program.

, 11. What is the primary purpose of the function check_null_string in
programming?

To concatenate two strings.

To check if a string is null.

To convert a string to uppercase.

To count the number of characters in a string.

12. If a web application is vulnerable to SQL injection, what defensive coding
technique should be implemented to mitigate this risk?

Disabling error messages

Using prepared statements

Implementing cross-site scripting protection

Increasing server response time

13. What is the meaning of the HTTP status code 405?

Bad Request

Internal Server Error

Method Not Allowed

Not Found

14. In a scenario where a user attempts to access a resource without proper
authorization, what defensive coding technique could be implemented to
handle this situation effectively?

Implement input validation and return an appropriate HTTP status
code.

Display a message indicating the resource is unavailable.

Document information

Uploaded on
September 17, 2026
Number of pages
42
Written in
2026/2027
Type
Exam (elaborations)
Contains
Questions & answers
$21.99

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Sold
12
Followers
0
Items
1251
Last sold
3 days ago



Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions