From a9844cef60f640cbefb5355f0bd701e8aa0c7a3f Mon Sep 17 00:00:00 2001 From: infinition <37984399+infinition@users.noreply.github.com> Date: Thu, 7 Nov 2024 20:27:55 +0100 Subject: [PATCH 1/5] Update README.md changed wget target link --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e1a734a..11c71b8 100644 --- a/README.md +++ b/README.md @@ -306,7 +306,7 @@ The fastest way to install Bjorn is using the automatic installation script : ```bash # Download and run the installer -wget https://github.com/infinition/Bjorn/install_bjorn.sh +wget https://raw.githubusercontent.com/infinition/Bjorn/refs/heads/main/install_bjorn.sh sudo chmod +x install_bjorn.sh sudo ./install_bjorn.sh # Choose the choice 1 for automatic installation. It may take a while as a lot of packages and modules will be installed. You must reboot at the end. From 5ab87eaf18259a6b8561bfa3774705f15ba59bf7 Mon Sep 17 00:00:00 2001 From: Ikko Eltociear Ashimine Date: Fri, 8 Nov 2024 08:31:13 +0900 Subject: [PATCH 2/5] docs: update README.md alogorithm -> algorithm --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 11c71b8..fd6ab09 100644 --- a/README.md +++ b/README.md @@ -855,7 +855,7 @@ Currently hardcoded for the 2.13-inch V2 & V4 e-Paper HAT. My program automatically detect the screen model and adapt the python expressions into my code. For other versions: -- As i dont have the v1 and v3 to validate my alogorithm, i just hope it will work properly. +- As i dont have the v1 and v3 to validate my algorithm, i just hope it will work properly. ### Ghosting removed ! 🍾 In my journey to make Bjorn work with the different screen versions, I struggled, hacking several parameters and found out that it was possible to remove the ghosting of screens! I let you see this, I think this method will be very useful for all other projects with the e-paper screen! From 1e48fc2d85f904dc6ce9f09f3fb739b24dbe386f Mon Sep 17 00:00:00 2001 From: Fabien POLLY Date: Fri, 8 Nov 2024 00:38:40 +0100 Subject: [PATCH 3/5] Solved missing folders and added screen choice in the installation script --- backup/backups/.gitkeep | 0 backup/uploads/.gitkeep | 0 config/.gitkeep | 0 config/shared_config.json | 107 +++++++++++++++++++++++++++ data/logs/.gitkeep | 0 data/output/.gitkeep | 0 data/output/crackedpwd/.gitkeep | 0 data/output/data_stolen/.gitkeep | 0 data/output/scan_results/.gitkeep | 0 data/output/vulnerabilities/.gitkeep | 0 data/output/zombies/.gitkeep | 0 install_bjorn.sh | 30 ++++++++ 12 files changed, 137 insertions(+) create mode 100644 backup/backups/.gitkeep create mode 100644 backup/uploads/.gitkeep create mode 100644 config/.gitkeep create mode 100644 config/shared_config.json create mode 100644 data/logs/.gitkeep create mode 100644 data/output/.gitkeep create mode 100644 data/output/crackedpwd/.gitkeep create mode 100644 data/output/data_stolen/.gitkeep create mode 100644 data/output/scan_results/.gitkeep create mode 100644 data/output/vulnerabilities/.gitkeep create mode 100644 data/output/zombies/.gitkeep diff --git a/backup/backups/.gitkeep b/backup/backups/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/backup/uploads/.gitkeep b/backup/uploads/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/config/.gitkeep b/config/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/config/shared_config.json b/config/shared_config.json new file mode 100644 index 0000000..9278659 --- /dev/null +++ b/config/shared_config.json @@ -0,0 +1,107 @@ +{ + "__title_Bjorn__": "Settings", + "manual_mode": false, + "websrv": true, + "web_increment ": false, + "debug_mode": true, + "scan_vuln_running": false, + "retry_success_actions": false, + "retry_failed_actions": true, + "blacklistcheck": true, + "displaying_csv": true, + "log_debug": true, + "log_info": true, + "log_warning": true, + "log_error": true, + "log_critical": true, + "startup_delay": 10, + "web_delay": 2, + "screen_delay": 1, + "comment_delaymin": 15, + "comment_delaymax": 30, + "livestatus_delay": 8, + "image_display_delaymin": 2, + "image_display_delaymax": 8, + "scan_interval": 180, + "scan_vuln_interval": 900, + "failed_retry_delay": 600, + "success_retry_delay": 900, + "ref_width": 122, + "ref_height": 250, + "epd_type": "epd2in13_V4", + "__title_lists__": "List Settings", + "portlist": [ + 20, + 21, + 22, + 23, + 25, + 53, + 69, + 80, + 110, + 111, + 135, + 137, + 139, + 143, + 161, + 162, + 389, + 443, + 445, + 512, + 513, + 514, + 587, + 636, + 993, + 995, + 1080, + 1433, + 1521, + 2049, + 3306, + 3389, + 5000, + 5001, + 5432, + 5900, + 8080, + 8443, + 9090, + 10000 + ], + "mac_scan_blacklist": [ + "00:11:32:c4:71:9b", + "00:11:32:c4:71:9a" + ], + "ip_scan_blacklist": [ + "192.168.1.1", + "192.168.1.12", + "192.168.1.38", + "192.168.1.53", + "192.168.1.40", + "192.168.1.29" + ], + "steal_file_names": [ + "ssh.csv", + "hack.txt" + ], + "steal_file_extensions": [ + ".bjorn", + ".hack", + ".flag" + ], + "__title_network__": "Network", + "nmap_scan_aggressivity": "-T2", + "portstart": 1, + "portend": 2, + "__title_timewaits__": "Time Wait Settings", + "timewait_smb": 0, + "timewait_ssh": 0, + "timewait_telnet": 0, + "timewait_ftp": 0, + "timewait_sql": 0, + "timewait_rdp": 0 +} diff --git a/data/logs/.gitkeep b/data/logs/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/data/output/.gitkeep b/data/output/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/data/output/crackedpwd/.gitkeep b/data/output/crackedpwd/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/data/output/data_stolen/.gitkeep b/data/output/data_stolen/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/data/output/scan_results/.gitkeep b/data/output/scan_results/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/data/output/vulnerabilities/.gitkeep b/data/output/vulnerabilities/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/data/output/zombies/.gitkeep b/data/output/zombies/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/install_bjorn.sh b/install_bjorn.sh index 8285451..4ca2702 100644 --- a/install_bjorn.sh +++ b/install_bjorn.sh @@ -306,6 +306,16 @@ setup_bjorn() { cd Bjorn + # Update the shared_config.json file with the selected EPD version + log "INFO" "Updating E-Paper display configuration..." + if [ -f "config/shared_config.json" ]; then + sed -i "s/\"epd_type\": \"[^\"]*\"/\"epd_type\": \"$EPD_VERSION\"/" config/shared_config.json + check_success "Updated E-Paper display configuration to $EPD_VERSION" + else + log "ERROR" "Configuration file not found: config/shared_config.json" + handle_error "E-Paper display configuration update" + fi + # Install requirements with --break-system-packages flag log "INFO" "Installing Python requirements..." @@ -515,6 +525,26 @@ main() { echo "2. Custom installation" read -p "Choose an option (1/2): " install_option + # E-Paper Display Selection + echo -e "\n${BLUE}Please select your E-Paper Display version:${NC}" + echo "1. epd2in13" + echo "2. epd2in13_V2" + echo "3. epd2in13_V3" + echo "4. epd2in13_V4" + + while true; do + read -p "Enter your choice (1-4): " epd_choice + case $epd_choice in + 1) EPD_VERSION="epd2in13"; break;; + 2) EPD_VERSION="epd2in13_V2"; break;; + 3) EPD_VERSION="epd2in13_V3"; break;; + 4) EPD_VERSION="epd2in13_V4"; break;; + *) echo -e "${RED}Invalid choice. Please select 1-4.${NC}";; + esac + done + + log "INFO" "Selected E-Paper Display version: $EPD_VERSION" + case $install_option in 1) CURRENT_STEP=1; show_progress "Checking system compatibility" From cb11afd5d18d943ef83341876f1ce19bf8c7bde4 Mon Sep 17 00:00:00 2001 From: infinition <37984399+infinition@users.noreply.github.com> Date: Fri, 8 Nov 2024 00:48:24 +0100 Subject: [PATCH 4/5] Update README.md Added the choice to choose epd screen type --- README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/README.md b/README.md index 11c71b8..1c9948c 100644 --- a/README.md +++ b/README.md @@ -379,6 +379,24 @@ sudo pip install -r requirements.txt --break-system-packages # As i did not succeed "for now" to get a stable installation with a virtual environment, i installed the dependencies system wide (with --break-system-packages), it did not cause any issue so far. You can try to install them in a virtual environment if you want. ``` +##### 3.1: Configure E-Paper Display Type +Choose your e-Paper HAT version by modifying the configuration file: + +1. Open the configuration file: +```bash +sudo vi /home/bjorn/Bjorn/config/shared_config.json +``` +Press i to enter insert mode +Locate the line containing "epd_type": +Change the value according to your screen model: + +- For 2.13 V1: "epd_type": "epd2in13", +- For 2.13 V2: "epd_type": "epd2in13_V2", +- For 2.13 V3: "epd_type": "epd2in13_V3", +- For 2.13 V4: "epd_type": "epd2in13_V4", + +Press Esc to exit insert mode +Type :wq and press Enter to save and quit #### Step 4: Configure File Descriptor Limits From 1981e0672280a05666424c490bf6269011e481d4 Mon Sep 17 00:00:00 2001 From: infinition <37984399+infinition@users.noreply.github.com> Date: Fri, 8 Nov 2024 18:34:22 +0100 Subject: [PATCH 5/5] Delete data/output/zombies/.gitkeep --- data/output/zombies/.gitkeep | 0 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 data/output/zombies/.gitkeep diff --git a/data/output/zombies/.gitkeep b/data/output/zombies/.gitkeep deleted file mode 100644 index e69de29..0000000