WGU D385: Logging and Security
Issues Questions With Complete Answers.What are some common debugging techniques? Answer- - printing out values of variables
- changing the state ("path") of the program to make it do different things
- stepping through the execution of a program line by line
- breakpoints
- trace points
- stopping the program at certain events
- viewing the output of a program in a debugger window
What are some Python debugging tools? Answer- - pdb: most commonly used
- Web-PDB
- wdb
- Pyflame
- objgraph
- when attackers exploit an XML parser to read arbitrary files on your server
- attackers might also be able to read config files, retrieve user information
- DEserialization is when a serialized object is read from a file or the network and
- INSECURE DESERIALIZATION occurs when an attacker can manipulate the
- typically allows for arbitrary code execution
- validate the entry before accessing or opening
XML External Entity Attacks Answer- - XXE
Insecure Deserialization Answer- - serialization is the conversion of an object in a programming language is saved into a format that can be saved to a database
converted back into an object
serialized object and achieve authentication bypass, DOS, or arbitrary code execution Injection Attacks Answer- - when an application cannot properly distinguish between untrusted user data and code
SQL Injection Attack Mitigation Answer- - use parameterized statements Log Injection Attack Mitigation Answer- - prefixing log entries with meta-data (i.e.timestamp)
Sensitive Data Leaks Answer- - occurs when an application fails to properly protect sensitive information 1 / 2
- this typically occurs through descriptive response headers, descriptive error
- attackers send HTTP requests that pretend to come from the victim
- attackers then carry out unwanted actions such as changing a password or
- SameSite cookies
- avoid using GET requests for state-changing actions
- attacker us able to send requests on behalf of the server
- allows attackers to forge the request signature and assume a privileged position on
- validate external addresses before initiating any outbound requests
- code step throughs
- stack tracing
- breakpoints
- code step through
messages with stack traces or database error messages, or revealing comments in HTML files Cross-site Request Forgery Answer- - client-side technique used to attack other users of a web application
transferring money from a bank account CSRF Mitigation Answer- - CSRF tokens
SSRF Answer- - Server-side Request Forgery
a network, bypassing firewall controls, and gaining access to internal services SSRF Mitigation Answer- - never make outbound requests based on user input
PDB Answer- - debugger built into the Python standard library Which three actions are supported by the Python Debugger (PDB)? (Choose 3 answers.) Answer- - establishing breakpoints
Which three debugging techniques require the use of a debugger? (Choose 3 answers.) Answer- - trace points
What do system monitoring and review of audit trails provide? Answer- - Accountability What are the logging levels and values? Answer- - DEBUG = 10
- INFO = 20
- WARNING = 30
- ERROR = 40
- CRITICAL = 50
Which logging function may indicate an impending full disk? Answer- - WARNING
- indicates that there could be a problem in the immediate future
- / 2
What does DEBUG indicate? Answer- - only used when diagnosing software problems What does CRITICAL indicate? Answer- - indicates catastrophic code malfunction