Skip to content

Commit

Permalink
fix: add initial webauthn configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
J0 committed Sep 11, 2024
1 parent a6c1824 commit 89204b8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
3 changes: 3 additions & 0 deletions example.env
Original file line number Diff line number Diff line change
Expand Up @@ -233,3 +233,6 @@ GOTRUE_HOOK_CUSTOM_SMS_PROVIDER_SECRET=""
# Test OTP Config
GOTRUE_SMS_TEST_OTP="<phone-1>:<otp-1>, <phone-2>:<otp-2>..."
GOTRUE_SMS_TEST_OTP_VALID_UNTIL="<ISO date time>" # (e.g. 2023-09-29T08:14:06Z)

GOTRUE_MFA_WEB_AUTHN_ENROLL_ENABLED="false"
GOTRUE_MFA_WEB_AUTHN_VERIFY_ENABLED="false"
7 changes: 4 additions & 3 deletions internal/conf/configuration.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,8 @@ type JWTConfiguration struct {
}

type MFAFactorTypeConfiguration struct {
EnrollEnabled bool `json:"enroll_enabled" split_words:"true" default:"true"`
VerifyEnabled bool `json:"verify_enabled" split_words:"true" default:"true"`
EnrollEnabled bool `json:"enroll_enabled" split_words:"true" default:"false"`
VerifyEnabled bool `json:"verify_enabled" split_words:"true" default:"false"`
}

type PhoneFactorTypeConfiguration struct {
Expand All @@ -133,7 +133,8 @@ type MFAConfiguration struct {
MaxEnrolledFactors float64 `split_words:"true" default:"10"`
MaxVerifiedFactors int `split_words:"true" default:"10"`
Phone PhoneFactorTypeConfiguration `split_words:"true"`
TOTP MFAFactorTypeConfiguration `split_words:"true"`
TOTP MFAFactorTypeConfiguration `split_words:"true" default:"{\"enroll_enabled\":true,\"verify_enabled\":true}"`
WebAuthn MFAFactorTypeConfiguration `split_words:"true"`
}

type APIConfiguration struct {
Expand Down

0 comments on commit 89204b8

Please sign in to comment.