Gokapi icon indicating copy to clipboard operation
Gokapi copied to clipboard

Feature Request: Add 2FA / MFA support

Open zwimer opened this issue 6 months ago • 2 comments

It'd be useful to have 2FA / MFA support for users. This could be done in many ways, but likely the easiest would be TOTP authentication.

zwimer avatar Aug 09 '25 04:08 zwimer

There seems to already be a TOTP library written in go: https://github.com/pquerna/otp Based on their README, you'd likely only need to add a few lines of code, using the functions key,_ := totp.Generate(...), key.Secret()/key.Image(...), and totp.Validate(...). Though of course, any other MFA methods are also fine.

zwimer avatar Aug 09 '25 04:08 zwimer

Thanks for the input. Although this was already on my todo list, it does not have a high priority, as you can use an OIDC provider that supports 2FA

Forceu avatar Aug 09 '25 08:08 Forceu