產生 TOTP

按照相應算法或格式產生 TOTP。

輸入: 文本 (UTF-8) / 檔案結果: 文本

文本輸入

工具選項

範例

A conventional six-digit authenticator

Use the public RFC test secret with 6 digits and a 30-second interval. The current answer changes with time; never use this published secret for an account.

輸入

GEZDGNBVGY3TQOJQGEZDGNBVGY3TQOJQ

Expected checks

6 digits · 30-second period
Matches native HMAC for the current counter window.
名称
RFC6238-public-test
代碼長度
6
纪元位移量(T0)
0
时間間隔(T1)
30
An eight-digit code

Use the public RFC test secret with 8 digits and a 30-second interval. The current answer changes with time; never use this published secret for an account.

輸入

GEZDGNBVGY3TQOJQGEZDGNBVGY3TQOJQ

Expected checks

8 digits · 30-second period
Matches native HMAC for the current counter window.
名称
RFC6238-public-test
代碼長度
8
纪元位移量(T0)
0
时間間隔(T1)
30
A one-minute interval

Use the public RFC test secret with 6 digits and a 60-second interval. The current answer changes with time; never use this published secret for an account.

輸入

GEZDGNBVGY3TQOJQGEZDGNBVGY3TQOJQ

Expected checks

6 digits · 60-second period
Matches native HMAC for the current counter window.
名称
RFC6238-public-test
代碼長度
6
纪元位移量(T0)
0
时間間隔(T1)
60
An eight-digit one-minute interval

Use the public RFC test secret with 8 digits and a 60-second interval. The current answer changes with time; never use this published secret for an account.

輸入

GEZDGNBVGY3TQOJQGEZDGNBVGY3TQOJQ

Expected checks

8 digits · 60-second period
Matches native HMAC for the current counter window.
名称
RFC6238-public-test
代碼長度
8
纪元位移量(T0)
0
时間間隔(T1)
60
A custom seven-digit interval

Use the public RFC test secret with 7 digits and a 45-second interval. The current answer changes with time; never use this published secret for an account.

輸入

GEZDGNBVGY3TQOJQGEZDGNBVGY3TQOJQ

Expected checks

7 digits · 45-second period
Matches native HMAC for the current counter window.
名称
RFC6238-public-test
代碼長度
7
纪元位移量(T0)
0
时間間隔(T1)
45
Generate TOTP

輸入

JBSWY3DPEHPK3PXP

Expected checks

Matches /^URI: otpauth:\/\/totp\/Account\?secret=JBSWY3DPEHPK3PXP&algorithm=SHA1&digits=6&period=30\n\nPassword: \d{6}$/
名称
Account
代碼長度
6
纪元位移量(T0)
0
时間間隔(T1)
30
invalid base32 secret rejected

輸入

not,valid|base32;input

Expected rejection

Message contains
Invalid secret. The input must be a valid base32 string (characters A–Z and 2–7).
名称
Account
代碼長度
6
纪元位移量(T0)
0
时間間隔(T1)
30

参數

参數默認值輸入與選項
名称"Account"必填
代碼長度6最小值: 6. 最大值: 8. 整數
纪元位移量(T0)0最小值: 0. 整數
时間間隔(T1)30最小值: 1. 整數

相关工具

其他

操作参考

查看原始技术文檔 (English)