Chapter 22: Security Flashcards
1
Q
How do we prevent a field, which for example has sensitive information, to be serialized?
A
By applying the transient keyword.
// private transient int age;
Java OCP 11 > Chapter 22: Security > Flashcards
How do we prevent a field, which for example has sensitive information, to be serialized?
By applying the transient keyword.
// private transient int age;