socketsecurity 1.0.38__tar.gz → 1.0.40__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {socketsecurity-1.0.38/socketsecurity.egg-info → socketsecurity-1.0.40}/PKG-INFO +2 -2
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/__init__.py +1 -1
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/__init__.py +21 -19
- {socketsecurity-1.0.38 → socketsecurity-1.0.40/socketsecurity.egg-info}/PKG-INFO +2 -2
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/LICENSE +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/README.md +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/pyproject.toml +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/setup.cfg +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/classes.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/exceptions.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/git_interface.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/github.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/gitlab.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/issues.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/licenses.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/messages.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/core/scm_comments.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity/socketcli.py +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity.egg-info/SOURCES.txt +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity.egg-info/dependency_links.txt +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity.egg-info/entry_points.txt +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity.egg-info/requires.txt +0 -0
- {socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity.egg-info/top_level.txt +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
__author__ = 'socket.dev'
|
|
2
|
-
__version__ = '1.0.
|
|
2
|
+
__version__ = '1.0.40'
|
|
@@ -437,25 +437,17 @@ class Core:
|
|
|
437
437
|
for ecosystem in socket_globs:
|
|
438
438
|
patterns = socket_globs[ecosystem]
|
|
439
439
|
for file_name in patterns:
|
|
440
|
-
pattern = patterns[file_name]["pattern"]
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
glob_start = time.time()
|
|
452
|
-
glob_files = glob(file_path, recursive=True)
|
|
453
|
-
for glob_file in glob_files:
|
|
454
|
-
if glob_file not in files:
|
|
455
|
-
files.add(glob_file)
|
|
456
|
-
glob_end = time.time()
|
|
457
|
-
glob_total_time = glob_end - glob_start
|
|
458
|
-
log.debug(f"Glob for pattern {file_path} took {glob_total_time:.2f} seconds")
|
|
440
|
+
pattern = Core.to_case_insensitive_regex(patterns[file_name]["pattern"])
|
|
441
|
+
file_path = f"{path}/**/{pattern}"
|
|
442
|
+
log.debug(f"Globbing {file_path}")
|
|
443
|
+
glob_start = time.time()
|
|
444
|
+
glob_files = glob(file_path, recursive=True)
|
|
445
|
+
for glob_file in glob_files:
|
|
446
|
+
if glob_file not in files:
|
|
447
|
+
files.add(glob_file)
|
|
448
|
+
glob_end = time.time()
|
|
449
|
+
glob_total_time = glob_end - glob_start
|
|
450
|
+
log.debug(f"Glob for pattern {file_path} took {glob_total_time:.2f} seconds")
|
|
459
451
|
|
|
460
452
|
log.debug("Finished Find Files")
|
|
461
453
|
end_time = time.time()
|
|
@@ -872,6 +864,16 @@ class Core:
|
|
|
872
864
|
file.write(content)
|
|
873
865
|
file.close()
|
|
874
866
|
|
|
867
|
+
@staticmethod
|
|
868
|
+
def to_case_insensitive_regex(input_string: str) -> str:
|
|
869
|
+
"""
|
|
870
|
+
Converts a string into a case-insensitive regex format.
|
|
871
|
+
Example: "pipfile" -> "[Pp][Ii][Pp][Ff][Ii][Ll][Ee]"
|
|
872
|
+
:param input_string: The input string to convert.
|
|
873
|
+
:return: A case-insensitive regex string.
|
|
874
|
+
"""
|
|
875
|
+
return ''.join(f'[{char.lower()}{char.upper()}]' if char.isalpha() else char for char in input_string)
|
|
876
|
+
|
|
875
877
|
# @staticmethod
|
|
876
878
|
# def create_license_file(diff: Diff) -> None:
|
|
877
879
|
# output = []
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{socketsecurity-1.0.38 → socketsecurity-1.0.40}/socketsecurity.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|