| 1: | <?php |
| 2: | |
| 3: | |
| 4: | |
| 5: | |
| 6: | |
| 7: | |
| 8: | namespace Aurora\Modules\TwoFactorAuth; |
| 9: | |
| 10: | use Aurora\System\SettingsProperty; |
| 11: | |
| 12: | |
| 13: | |
| 14: | |
| 15: | |
| 16: | |
| 17: | |
| 18: | |
| 19: | |
| 20: | |
| 21: | |
| 22: | |
| 23: | |
| 24: | |
| 25: | |
| 26: | |
| 27: | class Settings extends \Aurora\System\Module\Settings |
| 28: | { |
| 29: | protected function initDefaults() |
| 30: | { |
| 31: | $this->aContainer = [ |
| 32: | "Disabled" => new SettingsProperty( |
| 33: | false, |
| 34: | "bool", |
| 35: | null, |
| 36: | "Setting to true disables the module", |
| 37: | ), |
| 38: | "ShowRecommendationToConfigure" => new SettingsProperty( |
| 39: | false, |
| 40: | "bool", |
| 41: | null, |
| 42: | "If true, users will get a message suggesting to enable 2FA if it's not enabled in their accounts yet", |
| 43: | ), |
| 44: | "AllowSecurityKeys" => new SettingsProperty( |
| 45: | false, |
| 46: | "bool", |
| 47: | null, |
| 48: | "Enables support for security keys", |
| 49: | ), |
| 50: | "FacetIds" => new SettingsProperty( |
| 51: | [], |
| 52: | "array", |
| 53: | null, |
| 54: | "List of app-key-hashes of mobile apps", |
| 55: | ), |
| 56: | "AllowAuthenticatorApp" => new SettingsProperty( |
| 57: | true, |
| 58: | "bool", |
| 59: | null, |
| 60: | "Enables use of authenticator app", |
| 61: | ), |
| 62: | "ClockTolerance" => new SettingsProperty( |
| 63: | 2, |
| 64: | "int", |
| 65: | null, |
| 66: | "Value set to N means that codes starting from N * 30sec ago to N * 30sec from now are accepted", |
| 67: | ), |
| 68: | "AllowBackupCodes" => new SettingsProperty( |
| 69: | true, |
| 70: | "bool", |
| 71: | null, |
| 72: | "If set to true, and if authenticator app or security key configured, users are able to use backup codes", |
| 73: | ), |
| 74: | "AllowUsedDevices" => new SettingsProperty( |
| 75: | false, |
| 76: | "bool", |
| 77: | null, |
| 78: | "Enables managing trusted devices", |
| 79: | ), |
| 80: | "TrustDevicesForDays" => new SettingsProperty( |
| 81: | 0, |
| 82: | "int", |
| 83: | null, |
| 84: | "Allows for expiry of trusted device list entries after certain amount of days; if set to 0, managing trusted devices is disabled.", |
| 85: | ), |
| 86: | "IncludeInMobile" => new SettingsProperty( |
| 87: | true, |
| 88: | "bool", |
| 89: | null, |
| 90: | "If true, the module is used in mobile version of the interface", |
| 91: | ), |
| 92: | "IncludeInDesktop" => new SettingsProperty( |
| 93: | true, |
| 94: | "bool", |
| 95: | null, |
| 96: | "If true, the module is used in desktop version of the interface", |
| 97: | ), |
| 98: | "RequireInMobile" => new SettingsProperty( |
| 99: | [ |
| 100: | "StandardLoginFormWebclient" |
| 101: | ], |
| 102: | "array", |
| 103: | null, |
| 104: | "List of other modules required by this module", |
| 105: | ), |
| 106: | ]; |
| 107: | } |
| 108: | } |
| 109: | |