Skip to content

Commit

Permalink
Revert "fix: apt --fix-broken install"
Browse files Browse the repository at this point in the history
This reverts commit 4f9562f.
  • Loading branch information
elemen3 committed Aug 14, 2023
1 parent 4f9562f commit 305bcaf
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 140 deletions.
25 changes: 1 addition & 24 deletions CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -16,27 +16,4 @@ Bug Fix: Resolved an issue where certbot was generating errors during apt-update
Bug Fix: Corrected an issue where the UFW firewall was interfering with iptables rules by disabling and stopping the UFW service.
------------------------------------------------------------------------------------------------------------------------ 2023.03.06
Option to whitelist derak.cloud
------------------------------------------------------------------------------------------------------------------------ 2023.08.01
hide logo
faster iptable rules
better menu navigation (backspace key)
fix alibaba.ir
block porn
block speedtest
block specific website
block attacks from china
block attacks from russia
block individual attacks
block bittorrent
block ip scan
------------------------------------------------------------------------------------------------------------------------ 2023.08.02
update iranian ip ranges
add "allow tunneling" menu
donate in tron
fix: ipset: command not found
fix: delay on boot caused by IP Scan rules
fix: rules don't persist on reboot
------------------------------------------------------------------------------------------------------------------------ 2023.08.03
block specific website -> find all subdomains and all ip addresses even if it's behind a loadbalancer
fix: host: command not found
------------------------------------------------------------------------------------------------------------------------ 2023.08.04
------------------------------------------------------------------------------------------------------------------------ 2023.xx.xxxxxx
9 changes: 1 addition & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,8 @@


## Installation
#### Ubuntu 18.04, Ubuntu 20.04, Ubuntu 22.04, Ubuntu 22.10, Debian 10 and Debian 11

---
If `curl` is not installed, run this first:
```bash
apt update && apt install curl -y
```


#### Ubuntu 18.04, Ubuntu 20.04, Ubuntu 22.04, Ubuntu 22.10, Debian 10 and Debian 11
``` bash
bash <(curl -s https://raw.githubusercontent.com/elemen3/wepn/master/wepn.sh)
```
85 changes: 0 additions & 85 deletions speedtest/speedtest.sh

This file was deleted.

31 changes: 8 additions & 23 deletions wepn.sh
Original file line number Diff line number Diff line change
Expand Up @@ -528,18 +528,22 @@ update_upgrade_package_lists(){
fn_menu_2
fi
elif [ -n "$apt_update_error" ]; then
echo
print "[bold][yellow]The 'apt update' encountered the following error(s):"
echo
print "[bold][red]$apt_update_error"
echo
# debian 11 error
if echo "$apt_update_error" | grep -q "The repository 'http://security.debian.org/debian-security bullseye/updates Release' does not have a Release file" ; then
print "[bold][blue]Would you like to resolve it?"
confirmation_dialog y
response="$?"
clear_logs 1
if [ $response -eq 1 ]; then
# Fix error for Debian 11
print "[blue]Resolving the problem..."
sleep 1
Expand All @@ -561,11 +565,13 @@ update_upgrade_package_lists(){
fi
# certbot error
elif echo "$apt_update_error" | grep -q "certbot/certbot/ubuntu" ; then
print "[bold][blue]Would you like to resolve it?"
confirmation_dialog y
response="$?"
clear_logs 1
if [ $response -eq 1 ]; then
# Fix certbot error
print "[blue]Resolving the problem..."
sleep 1
Expand All @@ -585,7 +591,7 @@ update_upgrade_package_lists(){
else
print center "[bold][white]To address the issues, please share error messages and distribution details via [bold][green]@wepn_group. [bold][white]This will streamline fixing and aid in automating solutions for future versions."
#exit
fn_menu_2
fi
elif [ -n "$apt_upgrade_error" ]; then
echo
Expand All @@ -611,27 +617,6 @@ update_upgrade_package_lists(){
else
fn_menu_2
fi
elif [[ $apt_upgrade_error == *"apt --fix-broken install"* ]]; then
print "[bold][blue]Would you like to resolve it?"
confirmation_dialog y
response="$?"
clear_logs 1
if [ $response -eq 1 ]; then
# Fix apt --fix-broken install error
print "[blue]Resolving the problem..."
sleep 1
apt --fix-broken install -y 2>&1 >/dev/null
print "[bold][green]The issue has been resolved :)"
sleep 1
# try again
print "[blue]Trying again..."
sleep 1
show_headers
update_upgrade_package_lists
else
#exit
fn_menu_2
fi
else
fn_menu_2
fi
Expand Down Expand Up @@ -1525,7 +1510,7 @@ fn_menu_firewall_10(){
_ip_addresses=($(echo "$checkhost_json" | jq -r 'to_entries[] | select(.value != null) | .value[][] | select(.[2] != null) | .[2]' | sort -u))
for ip in "${_ip_addresses[@]}"; do
# echo "Adding $ip to the list"
# echo "Adding $ip to the list"
[[ ! " ${ip_addresses[@]} " =~ " $ip " ]] && ip_addresses+=("$ip")
done
clear_logs 2
Expand Down

0 comments on commit 305bcaf

Please sign in to comment.