Unit 3: Disassembly and Malware Debugging - Practice Quiz

INT251 — Malware Analysis And Cyber Defence 60 Questions
0 Correct 0 Wrong 60 Left
0/60

1 What is static code analysis in malware analysis?

Static code analysis Easy
A. Running code inside a debugger
B. Examining code without executing it
C. Restoring files from a backup
D. Monitoring live network traffic

2 Which tool converts machine-code instructions into assembly language?

Static code analysis Easy
A. Disassembler
B. Packet analyzer
C. File compressor
D. Text editor

3 Which information can commonly be found by extracting strings from a suspicious binary?

Static code analysis Easy
A. Current processor temperature
B. Active network bandwidth
C. Live keyboard input
D. Embedded URLs and file paths

4 What is the main purpose of calculating a cryptographic hash of a malware sample?

Static code analysis Easy
A. To repair the file automatically
B. To identify the file uniquely
C. To execute the file safely
D. To increase the file size

5 Which part of a Windows Portable Executable (PE) file lists external functions used by the program?

Static code analysis Easy
A. Import table
B. Audio stream
C. Recycle Bin
D. Bitmap header

6 What does a Windows API call allow a program to do?

Disassembling Windows API Easy
A. Request services from Windows
B. Replace the processor firmware
C. Disable all hardware interrupts
D. Rewrite assembly as source code

7 Which Windows API function is commonly associated with opening or creating a file?

Disassembling Windows API Easy
A. CreateFile
B. CreateThread
C. RegOpenKey
D. VirtualAlloc

8 Which Windows API function is commonly used to allocate virtual memory?

Disassembling Windows API Easy
A. CloseHandle
B. VirtualAlloc
C. DeleteFile
D. OpenProcess

9 What is the purpose of GetProcAddress in Windows?

Disassembling Windows API Easy
A. Create a new user account
B. Read data from a network socket
C. Find an exported function address
D. Calculate a file checksum

10 In disassembled code, which instruction commonly transfers control to a Windows API function?

Disassembling Windows API Easy
A. CALL
B. INC
C. NOP
D. CMP

11 What is debugging?

General concepts of debugging Easy
A. Designing and installing network cables
B. Observing and controlling program execution
C. Encrypting and archiving program files
D. Deleting and restoring system accounts

12 What is a breakpoint?

General concepts of debugging Easy
A. A location where execution pauses
B. A file that stores source code
C. A protocol for sending email
D. A method for compressing binaries

13 What does single-stepping allow an analyst to do?

General concepts of debugging Easy
A. Scan every file for signatures
B. Execute one instruction at a time
C. Run several programs in parallel
D. Download multiple updates together

14 Which processor component stores temporary values such as addresses and calculation results?

General concepts of debugging Easy
A. Sectors
B. Packets
C. Directories
D. Registers

15 What does the instruction pointer normally identify?

General concepts of debugging Easy
A. The size of the system disk
B. The current network gateway
C. The next instruction to execute
D. The last file opened by Windows

16 Why should a suspicious binary be debugged in an isolated environment?

Debugging binaries Easy
A. To reduce risk to other systems
B. To improve the monitor resolution
C. To simplify the binary's license
D. To increase the processor clock rate

17 What does stepping into a function do in a debugger?

Debugging binaries Easy
A. Deletes the called function
B. Skips the entire called function
C. Pauses inside the called function
D. Renames the called function

18 What does stepping over a function call usually do?

Debugging binaries Easy
A. Displays only the function's source file
B. Executes the function without entering it
C. Stops the function from ever running
D. Copies the function into another process

19 Which debugger feature can pause execution when a selected memory location is accessed?

Debugging binaries Easy
A. Import table
B. Checksum
C. File signature
D. Watchpoint

20 What is the purpose of viewing the call stack while debugging a binary?

Debugging binaries Easy
A. To display the installed device drivers
B. To list the available disk partitions
C. To measure the current network speed
D. To inspect the active function calls

21 A suspicious Windows executable has very high entropy in its .text section and contains only a few readable strings. What is the most likely explanation?

Static code analysis Medium
A. The executable was compiled without optimization
B. The executable uses position-independent code
C. The executable contains only debug symbols
D. The executable is packed or encrypted

22 During static analysis, a function repeatedly references the strings cmd.exe, /c, and CreateProcessW. What behavior should an analyst investigate first?

Static code analysis Medium
A. Credential collection through browser databases
B. Registry persistence through a service
C. Command execution through a child process
D. Network communication through a socket

23 A disassembler incorrectly treats embedded data as executable instructions. Which action is most useful for correcting the analysis?

Static code analysis Medium
A. Rename every function using its virtual address
B. Redefine the region as data and reanalyze references
C. Convert the entire section into writable executable memory before continuing the static examination
D. Disable all cross-reference generation in the disassembler

24 Why is examining cross-references to a suspicious string such as Software\\Microsoft\\Windows\\CurrentVersion\\Run useful?

Static code analysis Medium
A. It calculates the executable's cryptographic file hash
B. It identifies code that may configure registry persistence
C. It reveals every process that has loaded the executable
D. It determines the compiler's exact optimization level

25 An executable imports VirtualAlloc, WriteProcessMemory, and CreateRemoteThread. Which capability is most strongly suggested by this combination?

Static code analysis Medium
A. Encrypting files with a symmetric cipher
B. Creating a scheduled task for persistence
C. Capturing packets from a network adapter
D. Injecting code into another process

26 In 32-bit x86 code using stdcall, several values are pushed immediately before a Windows API call. In what order are the function arguments normally pushed?

Disassembling Windows API Medium
A. In register order followed by stack order
B. From leftmost argument to rightmost argument
C. From rightmost argument to leftmost argument
D. In alphabetical order by parameter name

27 A binary imports only LoadLibraryA and GetProcAddress, but later performs network operations. Why might the network APIs be absent from its import table?

Disassembling Windows API Medium
A. The APIs are resolved dynamically at runtime
B. The APIs are automatically inserted by the debugger
C. The APIs execute entirely inside the processor firmware
D. The loader converts network instructions into API calls and records them only after the process terminates

28 A call to CreateFileW returns 0xFFFFFFFF in the EAX register on a 32-bit system. How should this result usually be interpreted?

Disassembling Windows API Medium
A. The function returned a valid kernel object address
B. The file operation failed with INVALID_HANDLE_VALUE
C. The file was created with maximum access rights
D. The call succeeded but produced an empty file

29 While analyzing a call to RegSetValueExW, which argument is most important for determining the actual data written to the registry value?

Disassembling Windows API Medium
A. The return address stored by the call instruction
B. The pointer passed through the lpData parameter
C. The handle passed through the hKey parameter
D. The reserved value passed through the third parameter

30 A disassembly shows calls to InternetOpenW, InternetConnectW, and HttpOpenRequestW. What behavior is most directly indicated?

Disassembling Windows API Medium
A. Installing a kernel driver for packet filtering
B. Enumerating local user account information
C. Opening a named pipe for local communication
D. Preparing an HTTP request to a remote server

31 Why might an analyst prefer a hardware execution breakpoint over a software breakpoint when examining self-checking malware?

General concepts of debugging Medium
A. It avoids replacing the target instruction with INT 3
B. It allows unlimited breakpoints without processor support
C. It permanently disables all anti-debugging checks
D. It automatically reconstructs imports and repairs the executable's PE headers after every breakpoint event

32 What is the practical difference between stepping into and stepping over a CALL instruction?

General concepts of debugging Medium
A. Stepping into changes the stack; stepping over preserves every register
B. Stepping into ends the process; stepping over restarts the process
C. Stepping into enters the function; stepping over pauses after it returns
D. Stepping into skips the function; stepping over enters the function

33 A breakpoint set at a hard-coded virtual address works during one run but fails after restarting the program. Which Windows security feature most likely caused this?

General concepts of debugging Medium
A. Address Space Layout Randomization
B. User Account Control
C. Data Execution Prevention
D. Structured Exception Handling

34 A debugger reports a first-chance access violation, but the program continues normally after the exception is passed to it. What does this indicate?

General concepts of debugging Medium
A. The executable was rebuilt with valid relocation entries
B. The program handled the exception internally
C. The debugger repaired the invalid memory automatically
D. The operating system silently removed the failing instruction

35 Which breakpoint is most appropriate when an analyst wants execution to stop only when a buffer at a particular address is modified?

General concepts of debugging Medium
A. A temporary breakpoint on the process exit routine
B. A conditional breakpoint on every imported API
C. A hardware write breakpoint on the buffer
D. A software execution breakpoint at program entry

36 A packed binary decrypts its original code and then jumps into a newly readable code region. What should the analyst do near this transition?

Debugging binaries Medium
A. Terminate the process before the unpacked code executes
B. Clear every breakpoint and disable memory map monitoring for the remainder of the analysis
C. Break at the jump and inspect the possible original entry point
D. Replace the jump with a return instruction and save the file

37 After dumping an unpacked process from memory, the resulting executable does not run because its imported functions cannot be resolved. What is the likely next step?

Debugging binaries Medium
A. Reconstruct the import address table
B. Convert every writable section into a resource section
C. Replace all API calls with no-operation instructions
D. Delete the executable's relocation section

38 A sample exits when IsDebuggerPresent returns a nonzero value. Which debugging action best allows analysis to continue while preserving the surrounding control flow?

Debugging binaries Medium
A. Force the process to restart after every API call
B. Change all conditional branches in the program into unconditional jumps
C. Remove the executable's entire import directory
D. Modify the return value to zero before the comparison

39 A malware sample creates a child process and then terminates its original process. How should the analyst continue debugging the active behavior?

Debugging binaries Medium
A. Set a breakpoint only on the terminated parent's entry point
B. Configure the debugger to follow or attach to the child process
C. Disable process creation so the parent remains permanently active
D. Dump the parent's static resources and assume they contain all code executed by the child

40 A loop executes thousands of times, but the analyst only wants to stop when register ECX becomes 0x20. What is the most efficient debugging technique?

Debugging binaries Medium
A. Patch the loop condition into an unconditional branch
B. Set breakpoints on every instruction in the containing module
C. Set a conditional breakpoint based on ECX
D. Single-step through every loop iteration

41 A PE32+ sample is loaded at 0x00007FF700000000. A disassembler reports an instruction at RVA 0x2A3C0 containing call qword ptr [rip+0x195A]. The instruction is 6 bytes long. Which virtual address contains the 8-byte call target pointer?

Static code analysis Hard
A. 0x00007FF70002BD20
B. 0x00007FF70002BD1A
C. 0x00007FF700044D20
D. 0x00007FF7000195A0

42 A recursive-traversal disassembler misses a region that later executes, while a linear-sweep disassembler decodes many nonsensical instructions in the same region. Which code pattern best explains both observations?

Static code analysis Hard
A. A sequence of ordinary functions separated by compiler alignment bytes and complete unwind metadata
B. A jump table reached through a register-indirect branch
C. An imported function referenced through the PE import table
D. A direct call followed by a standard function epilogue

43 In a 32-bit malware function, the sequence call next; next: pop esi; sub esi, 0x1050 is observed. The call instruction begins at RVA 0x2050 and is 5 bytes long. What value does ESI hold after the sub, assuming normal call semantics?

Static code analysis Hard
A. The module image base
B. The current stack pointer
C. The preferred entry-point VA
D. The import-directory RVA

44 Static inspection shows a small import table, a writable and executable section with high entropy, and an entry point that repeatedly writes bytes into that section before branching there. Which conclusion is most defensible?

Static code analysis Hard
A. The missing imports prove the binary invokes every service through direct system calls
B. The high-entropy section must contain an encrypted configuration only
C. The sample is certainly compressed with a specific commercial packer
D. The sample likely reconstructs or decrypts executable code at runtime

45 A PE file's declared entry point appears benign, but malicious initialization occurs before it. Which static structure should be examined first for code that the Windows loader may execute before the entry point?

Static code analysis Hard
A. The bound import table
B. The debug directory
C. The TLS callback array
D. The base relocation table

46 Immediately before a Windows x64 call, the disassembly sets RCX to a process handle, RDX to a base address, R8 to a buffer, and R9 to a size. It stores a pointer at [rsp+0x20]. If the target is WriteProcessMemory, what does [rsp+0x20] represent?

Disassembling Windows API Hard
A. The fifth argument, lpNumberOfBytesWritten
B. The first slot of the callee's local-variable area
C. A mandatory pointer to the caller's saved nonvolatile registers and exception-unwind metadata
D. The return address for WriteProcessMemory

47 A 32-bit call site pushes five arguments, executes call eax, and then immediately continues without adjusting ESP. Runtime inspection identifies EAX as CreateFileW. Which calling-convention inference is correct?

Disassembling Windows API Hard
A. The caller omitted required cleanup for a normal cdecl API
B. The absence of cleanup proves the function never returns normally
C. The callee normally removes its arguments using stdcall semantics
D. The arguments were passed using the x64 register convention

48 A sample walks loaded modules, parses export directories, hashes each exported name, and compares the result with embedded constants before calling the matched address. What is the primary analytical consequence?

Disassembling Windows API Hard
A. API usage can be read directly from the normal import-name table
B. Every resolved address necessarily points to a kernel system-call stub
C. The export ordinal alone uniquely reveals each requested API across all Windows versions
D. API usage must be recovered by resolving the hash algorithm and constants

49 While resolving an exported function manually, the export address-table entry points inside the export directory and contains the ASCII text KERNELBASE.CreateFileW. How should this entry be interpreted?

Disassembling Windows API Hard
A. It is a forwarded export that must be resolved in KERNELBASE
B. It is executable code whose bytes happen to form an ASCII string
C. It is an API-set contract that must always be converted into a system-call number
D. It is a malformed relocation record that should be added to the current module base

50 Disassembly shows calls to VirtualAllocEx, WriteProcessMemory, and CreateRemoteThread, all using the same process handle. Which interpretation best synthesizes the API sequence?

Disassembling Windows API Hard
A. It proves that a reflective DLL was injected without any intermediate loader code
B. It is consistent with allocating, writing, and executing code in another process
C. It exclusively implements local heap management for the current process
D. It only changes the target process's access token before resuming an existing suspended thread

51 A debugger implements a software breakpoint by replacing the first byte of an instruction with 0xCC. After the breakpoint exception is reported on x86, what sequence is required to execute the original instruction exactly once and then restore the breakpoint?

General concepts of debugging Hard
A. Restore the byte, leave EIP unchanged, set a hardware write breakpoint, then resume
B. Restore the byte, decrement EIP, set the trap flag, resume, then reinsert 0xCC
C. Increment EIP, retain 0xCC, clear the trap flag, then resume execution
D. Decrement ESP, replace the return address, clear all debug registers, and continue until the function returns

52 A debugger receives a first-chance access-violation notification from a program that uses structured exception handling as normal control flow. What is the correct default interpretation?

General concepts of debugging Hard
A. The debugger may pass it to the program's exception handlers before treating it as unhandled
B. The exception has already bypassed every user-mode and kernel-mode handler
C. The process has necessarily crashed and must be terminated immediately
D. The faulting instruction must be patched because first-chance exceptions cannot be intentional

53 You need to detect writes to a four-byte variable without modifying code or making its entire memory page read-only. Which mechanism is most appropriate on x86/x64?

General concepts of debugging Hard
A. A data hardware breakpoint configured through debug registers
B. A guard page applied only to the variable's four-byte storage range
C. A software execution breakpoint placed at the variable's address
D. A trap flag left enabled continuously on the process's initial thread and inherited automatically by all future threads

54 A multithreaded sample intermittently bypasses a breakpoint because another thread restores the patched byte while the debugger is single-stepping the first thread. Which debugger strategy most directly prevents this race?

General concepts of debugging Hard
A. Suspend the other threads during breakpoint restoration and single-step completion
B. Convert the software breakpoint into a conditional source-level breakpoint evaluated only after every thread reaches a synchronization barrier
C. Disable ASLR so all threads execute at fixed virtual addresses
D. Clear the process's PE checksum before resuming the faulting thread

55 Single-stepping changes a malware sample's behavior because it compares timestamps around a short code region. Which response provides the strongest evidence that the timing check is anti-debugging rather than legitimate timeout logic?

General concepts of debugging Hard
A. Set additional software breakpoints throughout the timed region so that every instruction and API transition can be inspected in greater detail
B. Disable network access and infer that any subsequent delay is caused by debugger detection
C. Rename the debugger executable and observe whether the sample's window title changes
D. Patch or normalize the timing source and observe whether the hidden path becomes stable

56 A breakpoint was recorded at 0x0042F130 when a module loaded at 0x00400000. On the next run, ASLR loads the module at 0x6A100000. At what address should the breakpoint be placed?

Debugging binaries Hard
A. 0x6A52F130
B. 0x6A12F130
C. 0x6A0D0ED0
D. 0x0042F130

57 A packed process has decrypted its original code, transferred control to a stable original entry point, and resolved APIs dynamically. To create a useful reconstructed PE, which action remains essential after dumping the process image?

Debugging binaries Hard
A. Replace every indirect branch with a direct branch to its current runtime target
B. Remove all relocation entries because the dump already contains absolute addresses
C. Rebuild or repair imports and align dumped sections with valid PE metadata
D. Preserve the packer's original entry point and discard the unpacked entry-point address

58 A debugger stops on an execute access violation at a heap address. The bytes there form valid code that the sample just decoded, but the page protection is PAGE_READWRITE. What is the most likely immediate cause?

Debugging binaries Hard
A. Control-flow guard rejected the page because it lacks an import-table entry
B. DEP or NX blocked instruction fetch from a non-executable page
C. The CPU requires all dynamically generated code to reside in the module's original .text section
D. ASLR relocated the heap allocation without applying PE base relocations

59 A 64-bit debugger attached to a WOW64 process reports transitions through both 32-bit user code and 64-bit system components. Why can register and breakpoint handling become misleading?

Debugging binaries Hard
A. WOW64 maintains distinct 32-bit and 64-bit execution contexts during mode transitions
B. The processor disables debug registers whenever a thread enters a 64-bit system DLL
C. All 32-bit addresses are automatically sign-extended and therefore refer to kernel memory after each API call
D. WOW64 converts every 32-bit instruction into a permanent 64-bit replacement in memory

60 A self-modifying routine overwrites instructions that currently contain software breakpoints, causing missed events and corrupted decoded code. Which breakpoint strategy is most robust for the rewritten region?

Debugging binaries Hard
A. Mark the region permanently non-writable and ignore resulting write exceptions
B. Set breakpoints only on imported APIs because self-modifying code cannot invoke them indirectly
C. Insert additional INT3 bytes before the routine begins rewriting the region
D. Use hardware execution breakpoints on selected addresses after the final rewrite