mirror of
https://github.com/onionshare/onionshare.git
synced 2025-05-04 07:25:10 -04:00
Checks if username is ASCII string else throw an error
This commit is contained in:
parent
97fe219e21
commit
98f6f3b7d7
2 changed files with 12 additions and 1 deletions
|
@ -51,6 +51,7 @@ class ChatModeWeb:
|
|||
username = username.strip()
|
||||
return (
|
||||
username
|
||||
and username.isascii()
|
||||
and username not in self.connected_users
|
||||
and len(username) < 128
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue