-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
PQCLass report from my side
MacOS
- Problem :
- The collector.py wasn't create any data, so,I provide just the temporal files.
- The MacOS desktop wasn't mine, so I couldn't spend more than two days troubleshooting.
Linux- Ubuntu
-
Problem : Debian
- ydotool and pkt2Flow wasn't working on Debian
- So, I use the Ubuntu and then was okay
-
Problem : python version
-
Problem -> Python
- Error whenrun the
./runner.sh - This was due to Inconsistencies in the python libraries with Python 3.8 (default and preferred python for Ubuntu 20.4 that i use ),
[ERROR viaduct::backend::ffi] Missing HTTP status [ERROR viaduct::backend::ffi] Missing HTTP status Traceback (most recent call last): File "./collector.py", line 9, in <module> def loop_thru_all_files_in(path: str, ips: list[str]) -> tuple[int, str] | None: TypeError: 'type' object is not subscriptable
- Solution
- Change to python 3.10 in venv
- So I create a venv with python 3.10,then I download the requirements, and then IN the
runner.shbefore call thecollector.pyI activate the venv e.g.source venv/bin/activate
- Error whenrun the
-
Problem : pkt2flow
:~/Desktop/pq_second/PQClass/pkt2flow$ scons # You got binary pkt2flow scons: Reading SConscript files ... scons: done reading SConscript files. scons: Building targets ... gcc -o flow_db.o -c -I. flow_db.c gcc -o pkt2flow.o -c -I. pkt2flow.c pkt2flow.c: In function 'resemble_file_path': pkt2flow.c:150:8: warning: implicit declaration of function 'asprintf'; did you mean 'vsprintf'? [-Wimplicit-function-declaration] 150 | ret = asprintf(&outputpath, "%s/%s", outputdir, type_folder); | ^~~~~~~~ | vsprintf gcc -o utilities.o -c -I. utilities.c utilities.c: In function 'new_file_name': utilities.c:62:9: warning: implicit declaration of function 'asprintf'; did you mean 'vsprintf'? [-Wimplicit-function-declaration] 62 | ret = asprintf(&fname, "%s_%"PRIu16"_%s_%"PRIu16"_%lu.pcap", | ^~~~~~~~ | vsprintf gcc -o pkt2flow flow_db.o pkt2flow.o utilities.o -L/usr/local/lib -L/usr/lib -lpcap scons: done building targets.
-
Solution
-
nano pkt2flow.c&nano utilities.c-> Add this line at the top ->#define _GNU_SOURCE-> save& and recompile with ->scons
-
Problem : ydotoold
- Correct installation
sudo apt update sudo apt install cmake make g++ libevdev-dev libudev-dev git clone --recursive https://github.com/ReimuNotMoe/ydotool.git cd ydotool mkdir build cd build cmake .. make -j$(nproc) sudo make install sudo systemctl enable --now ydotoold ydotool key 30:1 30:0 # Simulates pressing 'a' , #SOS if ydotool fail, then do the next line sudo systemctl restart systemd-logind sudo /usr/local/bin/ydotoold & # Try running the daemon directly: ydotool key 30:1 30:0 # Simulates pressing 'a' , # If it still needs sudo, try: sudo chmod 777 /tmp/.ydotool_socket
# SOS Make ydotool , Persistent After Reboot sudo nano /etc/systemd/system/ydotoold.service # And add: [Unit] Description=ydotoold Daemon After=multi-user.target [Service] ExecStart=/usr/local/bin/ydotoold Restart=always User=pash [Install] WantedBy=default.target # Then sudo systemctl daemon-reload sudo systemctl enable --now ydotoold
-
Windows
I modify the runner.ahk in order to :
- comment/uncomment each line based on the scenario I want to run
- StartIndex
- corresponding selection of Path address for the
firefox & chrome.exe - --browser & --pqc corresponding selection
- SplitCap using correct file index
#Requires AutoHotkey v2.0
; 1: Ff + enable
;startIndex := 0 ;
; 2: Ff + disble
;startIndex := 100 ;
; 3: CH + enable
;startIndex := 200 ;
; 4: CH + disable
startIndex := 300 ;
Loop 100
{
fileIndex := startIndex + A_Index - 1
; Run sniffer.py with the correct file index
Run 'python sniffer.py ' . fileIndex ,, 'Hide'
; Open Firefox for PQC test
; 1+2
Run '"C:/Program Files/Mozilla Firefox/firefox.exe" "https://pq.cloudflareresearch.com"',, 'Max'
; 3+4
; Run '"C:\Program Files\Google\Chrome\Application\chrome.exe" "https://pq.cloudflareresearch.com"',, 'Max'
Sleep 4000
Send '^w' ; Close Firefox tab
Sleep 4000
; Process with SplitCap (using correct file index)
Run('C:/Users/kos00/Documents/Zotero/Python/PQC/PQClass/Windows/SplitCap.exe -r sniff' . fileIndex . '.pcap -o temp-' . fileIndex ,, 'Hide')
Sleep 3000
}
; Run Collector
;Run 'python collector.py --ip 2606:4700:7::a29f:8a55 2606:4700:7::a29f:8955 --browser firefox --pqc'
; 1: Ff + enable
;Run 'python collector.py --ip 2606:4700:7::a29f:8a55 2606:4700:7::a29f:8955 --browser firefox --pqc true'
; 2: Ff + disble
;Run 'python collector.py --ip 2606:4700:7::a29f:8a55 2606:4700:7::a29f:8955 --browser firefox --pqc false'
; 3: CH + enable
;Run 'python collector.py --ip 2606:4700:7::a29f:8a55 2606:4700:7::a29f:8955 --browser chrome --pqc true'
; 4: CH + disable
Run 'python collector.py --ip 2606:4700:7::a29f:8a55 2606:4700:7::a29f:8955 --browser chrome --pqc false'Metadata
Metadata
Assignees
Labels
No labels