-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat(jans-fido): refactor mds3 codebase and server config Signed-off-by: shekhar16 <shekharlaad1609@gmail.com> * feat(jans-fido): revert rename from docker file #9111 Signed-off-by: shekhar16 <shekharlaad1609@gmail.com> * feat(jans-fido): add metadatarefreshinterval #9111 Signed-off-by: shekhar16 <shekharlaad1609@gmail.com> * feat(jans-fido): changes to refactor metadataservers #9111 Signed-off-by: shekhar16 <shekharlaad1609@gmail.com> --------- Signed-off-by: shekhar16 <shekharlaad1609@gmail.com>
- Loading branch information
Showing
23 changed files
with
363 additions
and
174 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
70 changes: 70 additions & 0 deletions
70
jans-fido2/model/src/main/java/io/jans/fido2/model/conf/AttestationMode.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
package io.jans.fido2.model.conf; | ||
|
||
import com.fasterxml.jackson.annotation.JsonCreator; | ||
import io.jans.orm.annotation.AttributeEnum; | ||
import jakarta.xml.bind.annotation.XmlEnum; | ||
|
||
import java.util.HashMap; | ||
import java.util.Map; | ||
|
||
/** | ||
* @author Shekhar L. on 06/08/2024 | ||
*/ | ||
|
||
@XmlEnum(String.class) | ||
public enum AttestationMode implements AttributeEnum { | ||
|
||
DISABLED("disabled", "none"), MONITOR("monitor", "direct"), ENFORCED("enforced", "direct"); | ||
|
||
private String value; | ||
private String displayName; | ||
|
||
private AttestationMode(String value, String displayName) { | ||
this.setValue(value); | ||
this.setDisplayName(displayName); | ||
} | ||
|
||
private static final Map<String, AttestationMode> mapByValues = new HashMap<>(); | ||
|
||
static { | ||
for (AttestationMode enumType : values()) { | ||
mapByValues.put(enumType.getValue(), enumType); | ||
} | ||
} | ||
|
||
@JsonCreator | ||
public static AttestationMode forValues(String value) { | ||
return getByValue(value); | ||
} | ||
|
||
public static AttestationMode getByValue(String value) { | ||
return mapByValues.get(value); | ||
} | ||
|
||
@Override | ||
public Enum<? extends AttributeEnum> resolveByValue(String value) { | ||
return getByValue(value); | ||
} | ||
|
||
|
||
public String getValue() { | ||
return value; | ||
} | ||
|
||
public void setValue(String value) { | ||
this.value = value; | ||
} | ||
|
||
public String getDisplayName() { | ||
return displayName; | ||
} | ||
|
||
public void setDisplayName(String displayName) { | ||
this.displayName = displayName; | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return value; | ||
} | ||
} |
Oops, something went wrong.