Question 313 of 513
1Z0-829 Java I/O API and Securing Applications Practice Question
Which three actions help secure a Java application that uses serialization? (Select three.)
⚠ Common exam trap
Test-takers frequently confuse versioning best practices (like declaring `serialVersionUID`) with security controls, or think that using `SecureRandom` for `serialVersionUID` adds security, when in fact it only breaks compatibility and does nothing to prevent deserialization attacks.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Overriding resolveClass() in ObjectInputStream to validate class names.
Overriding `resolveClass()` in `ObjectInputStream` allows you to validate the class name before it is deserialized. This prevents deserialization attacks where an attacker sends a malicious class that could execute arbitrary code. By checking the class name against a whitelist, you can block untrusted classes from being loaded.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
Overriding resolveClass() in ObjectInputStream to validate class names.
Why this is correct
Allows filtering of classes during deserialization.
- ✓
Implementing ObjectInputFilter to set a deserialization filter.
Why this is correct
Standard way to restrict deserialization in Java 9+.
- ✓
Using transient keyword for sensitive fields.
Why this is correct
Prevents sensitive data from being serialized.
- ✗
Using SecureRandom to generate serialVersionUID.
Why it's wrong here
serialVersionUID is a long constant, not generated with SecureRandom.
- ✗
Declaring serialVersionUID explicitly as a long constant.
Why it's wrong here
Helps with version compatibility but does not prevent attacks.
Visual reference
About these practice questions
Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →
Last reviewed: Jun 25, 2026
This 1Z0-829 practice question is part of Courseiva's free Oracle certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the 1Z0-829 exam.
Question Discussion
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
Sign in to join the discussion.