mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 17:22:49 +01:00
Merge pull request #9254 from Security-Onion-Solutions/TOoSmOotH-patch-3
Update filecheck
This commit is contained in:
@@ -6,6 +6,7 @@
|
|||||||
# Elastic License 2.0.
|
# Elastic License 2.0.
|
||||||
|
|
||||||
import os
|
import os
|
||||||
|
import shutil
|
||||||
import time
|
import time
|
||||||
import hashlib
|
import hashlib
|
||||||
import logging
|
import logging
|
||||||
@@ -51,7 +52,7 @@ def process(filename, hizash):
|
|||||||
head, tail = os.path.split(filename)
|
head, tail = os.path.split(filename)
|
||||||
|
|
||||||
# Move the file
|
# Move the file
|
||||||
os.rename(filename, strelkapath + tail)
|
shutil.move(filename, strelkapath + tail)
|
||||||
|
|
||||||
class CreatedEventHandler(FileSystemEventHandler):
|
class CreatedEventHandler(FileSystemEventHandler):
|
||||||
def on_created(self, event):
|
def on_created(self, event):
|
||||||
@@ -76,4 +77,4 @@ if __name__ == "__main__":
|
|||||||
observer.stop()
|
observer.stop()
|
||||||
observer.join()
|
observer.join()
|
||||||
|
|
||||||
logging.info("Exiting filecheck")
|
logging.info("Exiting filecheck")
|
||||||
|
|||||||
Reference in New Issue
Block a user