Files
test/app/core/__pycache__/security.cpython-313.pyc
T

16 lines
2.7 KiB
Plaintext
Raw Normal View History

2026-09-21 19:03:31 +08:00
ó
¬†ªjƒãóˆ•SrSSKJr SSKJrJrJr SSKJr SSKrSSK r SSK
J r SSK J
r
S SjrS
S jrSSS
jjrSS jrg)u$密ç �哈希与 JWT ç­¾å�‘/校验。é)Ú annotations)ÚdatetimeÚ timedeltaÚtimezone)ÚAnyN)Úsettings)Ú AuthErrorcó’•[R"URS5[R"55R S5$)Núutf-8)ÚbcryptÚhashpwÚencodeÚgensaltÚdecode)Úraws Úapp\core\security.pyÚ
hash_passwordrs.€Ü �=Š=˜Ÿ™ GÓ,¬f¯nªnÓ.>Ó ?× FÑ FÀwÓ OÐOócó¬•U(aU(dg[R"URS5URS55$![a gf=f)NFr )r ÚcheckpwrÚ
ValueError)rÚhasheds rÚverify_passwordrsD€Þ –fØðÜ�~Š~˜cŸj™j¨Ó1°6·=±=ÀÓ3IÓJÐJøÜ óÙðús‘4AÁ
AÁAcó^•U=(d [Rn[U5n[R"[
R 5[US9-US'[R"[
R 5US'[R"U[R[RS9$)N)ÚminutesÚexpÚiat)Ú algorithm) rÚJWT_EXPIRE_MINUTESÚdictrÚnowrÚutcrÚjwtrÚ
JWT_SECRETÚ
JWT_ALGORITHM)ÚpayloadÚexpires_minutesrÚbodys rÚcreate_access_tokenr)!sp€Ø×<¤×!<Ñ!<€GÜ �‹=€DÜ—,’,œxŸ|™|Ó,¬yÀÑ/IÑI€Dˆ�KÜ—,’,œxŸ|™|Ó,€Dˆ�KÜ �:Š:�dœH×/Ñ/¼8×;QÑ;QÑ RÐRrcó•[R"U[R[R/S9$![R
an[
S5UeSnAf[Ran[