Enforcing 2FA
Two-Factor Authentication (2FA), also known as Multi-Factor Authentication (MFA), adds an extra layer of security to user accounts by requiring a second form of verification beyond just a password. This significantly reduces the risk of unauthorized access even if passwords are compromised.
Enforcing 2FA Settings
Section titled “Enforcing 2FA Settings”- Log in to PentestPad with an administrator account
- Navigate to the sidebar menu
- Click on Administration
- Select General tag
- Locate Enforce users to set up multi factor authentication settings
Enabling System-Wide 2FA
Section titled “Enabling System-Wide 2FA”To require 2FA for users:
- Navigate to Administration > General tag
- Toggle Enforce users to set up multi factor authentication to enabled
- Click Save Settings
User’s next login
Section titled “User’s next login”- Users can log in normally without 2FA
- System forces user to set 2FA before proceeding
How Users Enable 2FA
Section titled “How Users Enable 2FA”When 2FA is required or enabled by choice, users follow these steps:
- Log in with username and password
- System displays prompt: “Two-Factor Authentication Required”
- User sees QR code and setup instructions
- User opens authenticator app on their mobile device
- User scans QR code with authenticator app
- App generates a 6-digit verification code
- User enters verification code in PentestPad
- System displays backup codes (10 one-time codes)
- User saves backup codes in secure location
- Setup complete - 2FA is now active
Alternative Setup: Manual Entry
Section titled “Alternative Setup: Manual Entry”If users cannot scan the QR code:
- Click “Can’t scan the QR code?”
- System displays secret key (e.g.,
JBSWY3DPEHPK3PXP) - User manually enters this key in authenticator app
- Complete verification as normal
Supported Authenticator Apps
Section titled “Supported Authenticator Apps”PentestPad supports TOTP (Time-based One-Time Password) compatible applications:
Recommended Apps
Section titled “Recommended Apps”Google Authenticator
- Platforms: iOS, Android
- Features: Simple, reliable, free
- Best for: Basic 2FA needs
Microsoft Authenticator
- Platforms: iOS, Android
- Features: Backup, multi-device sync, passwordless login
- Best for: Microsoft ecosystem users
Authy
- Platforms: iOS, Android, Desktop, Chrome
- Features: Cloud backup, multi-device sync, encrypted backups
- Best for: Users who want desktop access
1Password
- Platforms: Cross-platform
- Features: Integrated password + TOTP management, secure sharing
- Best for: Teams using password managers
LastPass Authenticator
- Platforms: iOS, Android
- Features: One-tap verification, backup
- Best for: LastPass users
Any TOTP App Works
Section titled “Any TOTP App Works”PentestPad uses the standard TOTP protocol (RFC 6238), so any compatible authenticator application will work.
Backup Codes
Section titled “Backup Codes”Understanding Backup Codes
Section titled “Understanding Backup Codes”Backup codes are one-time use recovery codes generated during 2FA setup:
Characteristics:
- Typically 10 codes provided at setup
- Each code can only be used once
- 8-10 characters long
- Can be used instead of authenticator app
- Remain valid until used or regenerated
When to Use Backup Codes
Section titled “When to Use Backup Codes”Use backup codes when:
- Lost or broken phone with authenticator app
- Authenticator app not working or corrupted
- Device not available (traveling, etc.)
- Need emergency access to account
- Switching to a new phone
How to Use a Backup Code
Section titled “How to Use a Backup Code”- Navigate to PentestPad login page
- Enter username and password
- When prompted for 2FA code, click “Use backup code”
- Enter one of your saved backup codes
- Log in successfully
- Immediately reconfigure 2FA in account settings
User Self-Service Reset
Section titled “User Self-Service Reset”Users can reset their own 2FA using backup codes (see Backup Codes section above).
Troubleshooting Common Issues
Section titled “Troubleshooting Common Issues”User Cannot Scan QR Code
Section titled “User Cannot Scan QR Code”Solutions:
- Provide manual entry option - show secret key
- Check camera permissions on mobile device
- Try different authenticator app
- Ensure good lighting when scanning
- Move phone closer/farther from screen
Time Sync Issues
Section titled “Time Sync Issues”Problem: Codes not working even though entered correctly
Solution:
- Verify device time is accurate (not off by minutes)
- Enable automatic time sync on device:
- iOS: Settings > General > Date & Time > Set Automatically
- Android: Settings > System > Date & time > Automatic
- Check timezone is correct
- Try waiting for next code cycle (codes refresh every 30 seconds)
Codes Not Accepted
Section titled “Codes Not Accepted”Troubleshooting steps:
- Verify correct time on device
- Check for typos - codes are case-sensitive
- Ensure using code from correct account in authenticator
- Wait for code to refresh (they expire quickly)
- Check if Caps Lock is on
- Try backup codes if codes consistently fail