Skip to content

Commit 0391e81

Browse files
committed
Linting
1 parent 6cf11e8 commit 0391e81

2 files changed

Lines changed: 3 additions & 6 deletions

File tree

nxc/modules/recyclebin.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
from io import BytesIO
21
from os import makedirs
32
from nxc.paths import NXC_PATH
43
from os.path import join, abspath
@@ -27,7 +26,7 @@ def on_admin_login(self, context, connection):
2726
remote_ops = RemoteOperations(connection.conn, connection.kerberos)
2827
remote_ops.enableRegistry()
2928

30-
for sid_directory in connection.conn.listPath("C$", "$Recycle.Bin\\*"):
29+
for sid_directory in connection.conn.listPath("C$", "$Recycle.Bin\\*"):
3130
try:
3231
if sid_directory.get_longname() and sid_directory.get_longname() not in false_positive_users:
3332

@@ -99,4 +98,4 @@ def on_admin_login(self, context, connection):
9998
context.log.exception(e)
10099
context.log.fail(f"Error connecting to RemoteRegistry {e} on host {connection.host}")
101100
finally:
102-
remote_ops.finish()
101+
remote_ops.finish()

nxc/protocols/smb/smbspider.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def spider(
3131
depth=None,
3232
content=False,
3333
onlyfiles=True,
34-
silent = False
34+
silent=False
3535
):
3636
if exclude_dirs is None:
3737
exclude_dirs = []
@@ -153,7 +153,6 @@ def dir_list(self, files, path):
153153
if self.content and not result.is_directory():
154154
self.search_content(path, result)
155155

156-
157156
def search_content(self, path, result):
158157
path = path.replace("*", "")
159158
try:
@@ -225,4 +224,3 @@ def search_content(self, path, result):
225224
def get_lastm_time(self, result_obj):
226225
with contextlib.suppress(Exception):
227226
return strftime("%Y-%m-%d %H:%M", localtime(result_obj.get_mtime_epoch()))
228-

0 commit comments

Comments
 (0)