diff --git a/src/fr/anssi/smartpgp/Constants.java b/src/fr/anssi/smartpgp/Constants.java index 6a66b73..d03618a 100644 --- a/src/fr/anssi/smartpgp/Constants.java +++ b/src/fr/anssi/smartpgp/Constants.java @@ -67,9 +67,10 @@ public final class Constants { protected static final byte LANG_MAX_LENGTH = 8; protected static final byte[] LANG_DEFAULT = { (byte)0x65, (byte)0x6e }; + protected static final byte SEX_NOT_KNOWN = (byte)0x30; protected static final byte SEX_MALE = (byte)0x31; protected static final byte SEX_FEMALE = (byte)0x32; - protected static final byte SEX_NOT_ANNOUNCED = (byte)0x39; + protected static final byte SEX_NOT_APPLICABLE = (byte)0x39; protected static final short TAG_AID = (short)0x004f; protected static final short TAG_LOGIN = (short)0x005e; diff --git a/src/fr/anssi/smartpgp/Persistent.java b/src/fr/anssi/smartpgp/Persistent.java index 3c42c71..e267366 100644 --- a/src/fr/anssi/smartpgp/Persistent.java +++ b/src/fr/anssi/smartpgp/Persistent.java @@ -179,7 +179,7 @@ public final class Persistent { lang_length = (byte)Constants.LANG_DEFAULT.length; Common.commitTransaction(isRegistering); - sex = Constants.SEX_NOT_ANNOUNCED; + sex = Constants.SEX_NOT_KNOWN; Util.arrayFillNonAtomic(digital_signature_counter, (short)0, (short)digital_signature_counter.length, (byte)0); diff --git a/src/fr/anssi/smartpgp/SmartPGPApplet.java b/src/fr/anssi/smartpgp/SmartPGPApplet.java index 0b5f85e..3e9961e 100644 --- a/src/fr/anssi/smartpgp/SmartPGPApplet.java +++ b/src/fr/anssi/smartpgp/SmartPGPApplet.java @@ -946,9 +946,10 @@ public final class SmartPGPApplet extends Applet { } switch(buf[0]) { + case Constants.SEX_NOT_KNOWN: case Constants.SEX_MALE: case Constants.SEX_FEMALE: - case Constants.SEX_NOT_ANNOUNCED: + case Constants.SEX_NOT_APPLICABLE: data.sex = buf[0]; break;