Skip to content

Commit f9ce781

Browse files
committed
update
1 parent 0bdfc8e commit f9ce781

File tree

90 files changed

+1362
-229
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+1362
-229
lines changed

Pipfile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ pdfrw = "*"
1919
scapy = "*"
2020
stegano = "*"
2121
qrcode = "*"
22-
pygraphviz = "*"
2322
passlib = "*"
2423
python-slugify = "*"
2524
Pillow = "*"

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ chalgen generates challenges and evidence for CTFs using a tree based format
1313
## Prerequisites
1414
Note: This is **not required** for Github Codespaces. Everything will be installed automatically.
1515

16-
- Follow the documentation [here](https://pygraphviz.github.io/documentation/stable/install.html) to install `pygraphviz` for your system
1716
- Install ffmpeg from [here](https://ffmpeg.org/download.html)
1817
- Install Docker from [here](https://docs.docker.com/engine/install/)
1918
- Install kubectl from [here](https://kubernetes.io/docs/tasks/tools/)

chal_types/crypto.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ def gen(self, chal_dir):
246246
# if config_text is not None:
247247
#text = config_text + "\n\n" + self.flag
248248

249-
chal_txt = encryptDecrypt(text + self.get_value("text"), key)
249+
chal_txt = hex_text(xor_text(text + self.get_value("text"), key))
250250
f.write(chal_txt)
251251
self.display = chal_txt
252252

chal_types/docker_builder.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ def build(self, docker_context):
9393
def __enter__(self):
9494
with FixMinikube(), tempfile.TemporaryDirectory() as temp_dir, console.status("[bold green]Creating Docker Environment", spinner_style="green"):
9595
self.build(temp_dir)
96-
subprocess.check_output(f"docker build -q {temp_dir} -t {self.name}".split())
96+
subprocess.check_output(f"docker build --platform linux/amd64 -q {temp_dir} -t {self.name}".split())
9797
subprocess.check_output(f'docker run -d --name {self.name} {self.name}'.split())
9898
proc = Process(f'docker exec -it {self.name} /bin/sh', "container", self.color)
9999
stat.start()

chal_types/forensics/networking.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
import random
1313
from ..text_transforms import text_transforms
1414

15-
from scapy.all import rdpcap, wrpcap
15+
#from scapy.all import rdpcap, wrpcap
1616

1717
class PCAPLogin(GeneratedChallenge):
1818
yaml_tag = u'!pcap_login'

chal_types/templates/docker_make/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
build:
2-
@docker build . -t {chal_name}
2+
@docker build --platform linux/amd64 . -t {chal_name}
33

44
run: build
55
@docker run {chal_run_options} {chal_name}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
django==1.6.2
22
Pillow
3-
pyyaml
3+
pyyaml==5.3.1

chal_types/templates/twitter_flask/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,4 @@ SQLAlchemy==1.0.13 # via flask-sqlalchemy
3232
Werkzeug==0.11.10 # via flask, flask-wtf
3333
WTForms==2.1 # via flask-wtf
3434

35-
pyyaml
35+
pyyaml==5.3.1

chal_types/text_transforms.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ def encryptDecrypt(inpString, xorKey):
171171

172172

173173
def xor_text(string, key):
174-
return "".join([chr(ord(c1) ^ ord(c2)) for c1, c2 in zip(string, key*(len(string) / len(key) + 1))])
174+
return "".join([chr(ord(c1) ^ ord(c2)) for c1, c2 in zip(string, key*int(len(string) / len(key) + 1))])
175175

176176
def pad(s, block_size):
177177
return s + (block_size - len(s) % block_size) * chr(block_size - len(s) % block_size)

chal_types/utils.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
from rich.logging import RichHandler
1212
from dirhash import dirhash
1313
import random
14-
import openpyxl
1514

1615
from chal_types.text_transforms import SHA256
1716

0 commit comments

Comments
 (0)