mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-09-21 03:19:52 +00:00
fix: 修复空字符串加密报错的问题
This commit is contained in:
@@ -33,7 +33,7 @@ class EBCCipher:
|
||||
def __padding(val):
|
||||
# padding
|
||||
val = bytes(val)
|
||||
while len(val) % 16 != 0:
|
||||
while len(val) == 0 or len(val) % 16 != 0:
|
||||
val += b'\0'
|
||||
return val
|
||||
|
||||
|
Reference in New Issue
Block a user