Skip to content

Commit

Permalink
fix(jans-fido2):removed superGluu, oldU2fMigrationEnabled && add meta…
Browse files Browse the repository at this point in the history
…dataServers in dynamic-conf.json and review all other config fields #10101

Signed-off-by: imran-ishaq <[email protected]>
  • Loading branch information
imran-ishaq committed Nov 20, 2024
1 parent 4acddf3 commit 0d580f5
Show file tree
Hide file tree
Showing 8 changed files with 4 additions and 23 deletions.
1 change: 0 additions & 1 deletion docker-jans-fido2/scripts/upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ def _transform_fido2_dynamic_config(conf):
# add missing config (if not exist)
for k, v in [
("superGluuEnabled", False),
("oldU2fMigrationEnabled", True),
("metadataUrlsProvider", ""),
("errorReasonEnabled", False),
("skipDownloadMdsEnabled", False),
Expand Down
1 change: 0 additions & 1 deletion jans-cli-tui/cli_tui/plugins/020_fido/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,6 @@ def create_widgets(self):
style='class:outh-scope-text'
,widget_style=cli_style.black_bg_widget
),
self.app.getTitledCheckBox(_("Enable Super Gluu"), name='superGluuEnabled', checked=self.data.get('superGluuEnabled'), jans_help=self.app.get_help_from_schema(self.schema, 'superGluuEnabled'), style=cli_style.check_box, widget_style=cli_style.black_bg_widget),
Window(height=1),
VSplit([Window(),
HSplit([Button(_("Save"), handler=self.save_config)]),
Expand Down
2 changes: 0 additions & 2 deletions jans-config-api/plugins/docs/fido2-plugin-swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -564,8 +564,6 @@ components:
type: boolean
sessionIdPersistInCache:
type: boolean
oldU2fMigrationEnabled:
type: boolean
errorReasonEnabled:
type: boolean
fido2Configuration:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,6 @@ public class AppConfiguration implements Configuration, Serializable {
@DocProperty(description = "Boolean value specifying whether to persist session_id in cache", defaultValue = "false")
private Boolean sessionIdPersistInCache = false;

@DocProperty(description = "Boolean value to enable disable old oxAuth U2F enrollments migration")
private boolean oldU2fMigrationEnabled;

@DocProperty(description = "Boolean value specifying whether to return detailed reason of the error from Fido2. Default value is false", defaultValue = "false")
private Boolean errorReasonEnabled = false;

Expand Down Expand Up @@ -205,14 +202,6 @@ public void setSessionIdPersistInCache(Boolean sessionIdPersistInCache) {
this.sessionIdPersistInCache = sessionIdPersistInCache;
}

public boolean isOldU2fMigrationEnabled() {
return oldU2fMigrationEnabled;
}

public void setOldU2fMigrationEnabled(boolean oldU2fMigrationEnabled) {
this.oldU2fMigrationEnabled = oldU2fMigrationEnabled;
}

public Boolean getErrorReasonEnabled() {
return errorReasonEnabled;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ public class Fido2Configuration {
private List<String> hints = new ArrayList<String>();
@DocProperty(description = "If authenticators have been enabled for use in a specific protected envt (enterprise authenticators)")
private boolean enterpriseAttestation = false;
@DocProperty(description = "Enum value indicating whether MDS validation should be omitted during attestation")
private String attestationMode;
@DocProperty(description = "String value indicating whether MDS validation should be omitted during attestation")
private String attestationMode = "monitor";

public String getAuthenticatorCertsFolder() {
return authenticatorCertsFolder;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,7 @@
"jansCustomPerson",
"jansPerson"
],
"superGluuEnabled": false,
"sessionIdPersistInCache": false,
"oldU2fMigrationEnabled": true,
"errorReasonEnabled": false,
"fido2Configuration":{
"authenticatorCertsFolder":"%(fido2ConfigFolder)s/authenticator_cert",
Expand All @@ -36,6 +34,7 @@
]
}
],
"metadataServers":[{"url": "https://mds.fidoalliance.org/" }],
"userAutoEnrollment":false,
"unfinishedRequestExpiration":180,
"authenticationHistoryExpiration":1296000,
Expand Down
2 changes: 0 additions & 2 deletions terraform-provider-jans/jans/fido2_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ type JansFido2DynConfiguration struct {
MetricReporterKeepDataDays int `schema:"metric_reporter_keep_data_days" json:"metricReporterKeepDataDays,omitempty"`
PersonCustomObjectClassList []string `schema:"person_custom_object_class_list" json:"personCustomObjectClassList,omitempty"`
Fido2Configuration Fido2Configuration `schema:"fido2_configuration" json:"fido2Configuration,omitempty"`
OldU2fMigrationEnabled bool `schema:"old_u2f_migration_enabled" json:"oldU2fMigrationEnabled,omitempty"`
SuperGluuEnabled bool `schema:"super_gluu_enabled" json:"superGluuEnabled,omitempty"`
}

// GetFido2Configuration returns the current Fido2 configuration.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ func TestResourceFido2Config_Mapping(t *testing.T) {
AuthenticationHistoryExpiration: 1296000,
enabledFidoAlgorithms: []string{"RS256", "ES256"},
},
SuperGluuEnabled: true,
OldU2fMigrationEnabled: true,

}

if err := toSchemaResource(data, cfg); err != nil {
Expand Down

0 comments on commit 0d580f5

Please sign in to comment.