File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ def __init__(self, sandbox=False):
2828 self .sandbox_so_path = f'{ self .sandbox_path } /sandbox.so'
2929 try :
3030 if os .path .exists (self .sandbox_so_path ):
31- os .chmod (self .sandbox_so_path , 0o644 )
31+ os .chmod (self .sandbox_so_path , 0o444 )
3232 # 初始化host黑名单
3333 banned_hosts_file_path = f'{ self .sandbox_path } /.SANDBOX_BANNED_HOSTS'
3434 if os .path .exists (banned_hosts_file_path ):
@@ -40,7 +40,7 @@ def __init__(self, sandbox=False):
4040 banned_hosts = f"{ banned_hosts } ,{ hostname } ,{ local_ip } "
4141 with open (banned_hosts_file_path , "w" ) as f :
4242 f .write (banned_hosts )
43- os .chmod (banned_hosts_file_path , 0o644 )
43+ os .chmod (banned_hosts_file_path , 0o444 )
4444 except Exception as e :
4545 maxkb_logger .error (f'Failed to init SANDBOX_BANNED_HOSTS due to exception: { e } ' , exc_info = True )
4646 pass
You can’t perform that action at this time.
0 commit comments