mirror of
https://huihui.cat/mirrors/MikroTikPatch.git
synced 2026-01-28 01:07:18 +01:00
Update patch.py
Signed-off-by: elseif <elseif@live.cn>
This commit is contained in:
parent
a8dd672a66
commit
c657f2e736
1 changed files with 3 additions and 0 deletions
3
patch.py
3
patch.py
|
|
@ -269,6 +269,9 @@ def patch_squashfs(path,key_dict):
|
|||
for file in files:
|
||||
file = os.path.join(root,file)
|
||||
if os.path.isfile(file):
|
||||
if 'sys2' in file:
|
||||
os.remove(file)
|
||||
continue
|
||||
data = open(file,'rb').read()
|
||||
for old_public_key,new_public_key in key_dict.items():
|
||||
_data = replace_key(old_public_key,new_public_key,data,file)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue