socx 2.2__tar.gz → 2.3__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: socx
3
- Version: 2.2
3
+ Version: 2.3
4
4
  Summary: A set of useful tools for a security operations center
5
5
  Author-email: Enlace <enlace.aman@gmail.com>
6
6
  Classifier: Programming Language :: Python :: 3
@@ -8,7 +8,7 @@ Classifier: Operating System :: OS Independent
8
8
  Requires-Python: >=3.8
9
9
  Description-Content-Type: text/markdown
10
10
 
11
- # socx
11
+ # SOCX
12
12
  A collection of helpful tools for a SOC analyst. Easily search for IPs, domains, and find files on the system.
13
13
 
14
14
  ## Installing
@@ -30,21 +30,26 @@ or
30
30
  python socx.py [universal options] [function] [arguments]
31
31
 
32
32
  Examples:
33
+
33
34
  socx --help
34
35
 
35
36
  socx info -h
36
-
37
+
37
38
  socx info -ip 1.2.3.4
38
-
39
+
39
40
  socx -v 3 info -d google.com
40
-
41
+
41
42
  socx find -f filename.txt -i
42
-
43
+
43
44
  socx find -f fold.*name -r
44
-
45
+
45
46
  socx unwrap --url "https://urldefense.com/v3/__https:/..."
46
-
47
+
47
48
  socx combine --csvs 5
49
+
50
+ socx awake --minutes 90
51
+
52
+ socx awake --restart
48
53
 
49
54
  ## Other Information
50
55
 
@@ -1,4 +1,4 @@
1
- # socx
1
+ # SOCX
2
2
  A collection of helpful tools for a SOC analyst. Easily search for IPs, domains, and find files on the system.
3
3
 
4
4
  ## Installing
@@ -20,21 +20,26 @@ or
20
20
  python socx.py [universal options] [function] [arguments]
21
21
 
22
22
  Examples:
23
+
23
24
  socx --help
24
25
 
25
26
  socx info -h
26
-
27
+
27
28
  socx info -ip 1.2.3.4
28
-
29
+
29
30
  socx -v 3 info -d google.com
30
-
31
+
31
32
  socx find -f filename.txt -i
32
-
33
+
33
34
  socx find -f fold.*name -r
34
-
35
+
35
36
  socx unwrap --url "https://urldefense.com/v3/__https:/..."
36
-
37
+
37
38
  socx combine --csvs 5
39
+
40
+ socx awake --minutes 90
41
+
42
+ socx awake --restart
38
43
 
39
44
  ## Other Information
40
45
 
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "socx"
7
- version = "2.2"
7
+ version = "2.3"
8
8
  authors = [
9
9
  { name="Enlace", email="enlace.aman@gmail.com" },
10
10
  ]
@@ -66,6 +66,8 @@ Examples:
66
66
  {PROGRAM_NAME} find -f fold.*name -r
67
67
  {PROGRAM_NAME} unwrap --url "https://urldefense.com/v3/__https:/..."
68
68
  {PROGRAM_NAME} combine --csvs 5
69
+ {PROGRAM_NAME} awake --minutes 90
70
+ {PROGRAM_NAME} awake --restart
69
71
  """
70
72
  verbosity = 1
71
73
  environmental_variables = {
@@ -490,7 +492,7 @@ def do_command_history(user="~"):
490
492
  p("Command history gathered", v=3)
491
493
 
492
494
 
493
- def awake(minutes=60):
495
+ def awake(minutes=60, restart=False):
494
496
  interval = 10 # seconds
495
497
  iterations = (minutes * 60) / interval
496
498
 
@@ -509,6 +511,13 @@ def awake(minutes=60):
509
511
  for line in proc.stdout:
510
512
  print(line, end="")
511
513
 
514
+ if restart:
515
+ p("Restarting device...")
516
+ cmd = ["shutdown", "/r", "/t", "0"]
517
+ proc = subprocess.Popen(
518
+ cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE, close_fds=True
519
+ )
520
+
512
521
 
513
522
  #############
514
523
  # Arguments #
@@ -545,6 +554,16 @@ FUNCTIONS = [
545
554
  "required": False,
546
555
  "help": "Keeps device awake for this many minutes",
547
556
  },
557
+ {
558
+ "name": "restart",
559
+ "flag": "--restart",
560
+ "short_flag": "-r",
561
+ "type": bool,
562
+ "action": "store_true",
563
+ "default": False,
564
+ "required": False,
565
+ "help": "Restart computer once done keeping device awake",
566
+ },
548
567
  ],
549
568
  },
550
569
  {
@@ -576,6 +595,7 @@ FUNCTIONS = [
576
595
  "name": "skip_og_filename_column",
577
596
  "flag": "--skip_og_filename_column",
578
597
  "short_flag": "-sname",
598
+ "action": "store_true",
579
599
  "type": bool,
580
600
  "default": False,
581
601
  "required": False,
@@ -701,6 +721,7 @@ FUNCTIONS = [
701
721
  "short_flag": "-ss",
702
722
  "type": bool,
703
723
  "default": False,
724
+ "action": "store_true",
704
725
  "required": False,
705
726
  "help": "Do smart search (try directory then user folder then C: then D:)",
706
727
  },
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: socx
3
- Version: 2.2
3
+ Version: 2.3
4
4
  Summary: A set of useful tools for a security operations center
5
5
  Author-email: Enlace <enlace.aman@gmail.com>
6
6
  Classifier: Programming Language :: Python :: 3
@@ -8,7 +8,7 @@ Classifier: Operating System :: OS Independent
8
8
  Requires-Python: >=3.8
9
9
  Description-Content-Type: text/markdown
10
10
 
11
- # socx
11
+ # SOCX
12
12
  A collection of helpful tools for a SOC analyst. Easily search for IPs, domains, and find files on the system.
13
13
 
14
14
  ## Installing
@@ -30,21 +30,26 @@ or
30
30
  python socx.py [universal options] [function] [arguments]
31
31
 
32
32
  Examples:
33
+
33
34
  socx --help
34
35
 
35
36
  socx info -h
36
-
37
+
37
38
  socx info -ip 1.2.3.4
38
-
39
+
39
40
  socx -v 3 info -d google.com
40
-
41
+
41
42
  socx find -f filename.txt -i
42
-
43
+
43
44
  socx find -f fold.*name -r
44
-
45
+
45
46
  socx unwrap --url "https://urldefense.com/v3/__https:/..."
46
-
47
+
47
48
  socx combine --csvs 5
49
+
50
+ socx awake --minutes 90
51
+
52
+ socx awake --restart
48
53
 
49
54
  ## Other Information
50
55
 
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes