diff --git a/CHANGELOG.md b/CHANGELOG.md index e4885bf84..77d705f71 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,11 @@ +###6.01 + - Shebang changed to a more portable one `#!/usr/bin/env bash` + - New extra-verbose debug mode added + - README.md major modifications + - Added CONTRIBUTING.md + - Unexpected errors on wash scanning are controlled now + - Improved distro detection for some arm Linux + ###6.0 - New system for possible tool aliases checking the requirements - Evil Twin attack added: Bettercap-Sslstrip2 and BeEF browser exploitation framework @@ -257,7 +265,7 @@ ###2.21 - Wifislax 64bits compatibility bug fixed - - Removed version from Readme file + - Removed version from README.md file ###2.2 - Changes to manage Wifislax airmon command in a better way diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 000000000..420a7b02a --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,154 @@ +# Contributing + +Hi there! We are thrilled that you would like to contribute to this project. Your help is essential for keeping it great. + +When contributing to this repository, please first discuss the change you wish to make via issue, +email, or any other method with the owners of this repository before making a change. + +Please note we have a code of conduct, please follow it in all your interactions with the project. + +--- + +## Collaborating Translators + +1. Translate the strings located in `language_strings()` function. +2. Ask by mail [v1s1t0r.1s.h3r3@gmail.com] if you have any doubt. You'll be informed about how to proceed. +3. You can be added as a collaborator on the project. + +## Collaborating Developers + +1. Tweak *"debug_mode"* variable to "1" for faster development skipping intro and initial checks or to "2" for extra verbosity and the skips mentioned before. +2. Respect the **tab indentation**, code style and the **UTF-8** format. +3. Use **LF** (Unix) line break type (not CR or CRLF). +4. Use [Shellcheck] to search for errors and warnings on code. (Thanks [xtonousou] for the tip :wink:) +5. Increase the version numbers in `airgeddon.sh` and in [Readme] to the new version that the script represents. The versioning scheme we use is *X.YZ*. Where: + - *X* is a major release with a new menu (e.g. WPS menu) + - *Y* is a minor release with a new feature for an existing menu or a new submenu for an existing feature + - *Z* is a minor release with new bug fixes, small modifications or code improvements +6. Update the date on `airgeddon.sh` under shebang, if appropriate. +7. Direct push to [Master] is not allowed. +8. Pull Requests to [Master] are not allowed. Should be done over `dev` or any other branch. They require revision and approvement. +9. All the development and coding must be in English. + +*Be sure to merge the latest from "upstream" before making a pull request!* + +We also have a private Telegram group for *trusted collaborators* for more agile discussion about developments, improvements, etc. +To be added on it you must prove first you are a *trusted collaborator* with your contributions. + +## WPS PIN Database Collaborators + +1. Add PINs ordered by the key in the associative array. (Keys are the first 6 BSSID digits). +2. Update the `known_pins.db` file. +3. Update the `pindb_checksum.txt` file with the calculated checksum of the database file using `md5sum` tool. + +*PINs should be from devices that generate generic ones* + +## Beta Testers + +1. Download the master version or the beta testing version from the development branch called [Dev]. Temporary branches may be existing for specific features that can be tested too. +2. Report any issues or bugs by mail [v1s1t0r.1s.h3r3@gmail.com] or submit issues requests [Here]. + +--- + +## Code of Conduct + +### Our Pledge + +In the interest of fostering an open and welcoming environment, we as +contributors and maintainers pledge to making participation in our project and +our community a harassment-free experience for everyone, regardless of age, body +size, disability, ethnicity, gender identity and expression, level of experience, +nationality, personal appearance, race, religion, or sexual identity and +orientation. + +### Our Standards + +Examples of behavior that contributes to creating a positive environment +include: + +* Using welcoming and inclusive language +* Being respectful of differing viewpoints and experiences +* Gracefully accepting constructive criticism +* Focusing on what is best for the community +* Showing empathy towards other community members + +Examples of unacceptable behavior by participants include: + +* The use of sexualized language or imagery and unwelcome sexual attention or +advances +* Trolling, insulting/derogatory comments, and personal or political attacks +* Public or private harassment +* Publishing others' private information, such as a physical or electronic + address, without explicit permission +* Other conduct which could reasonably be considered inappropriate in a + professional setting + +### Our Responsibilities + +Project maintainers are responsible for clarifying the standards of acceptable +behavior and are expected to take appropriate and fair corrective action in +response to any instances of unacceptable behavior. + +Project maintainers have the right and responsibility to remove, edit, or +reject comments, commits, code, wiki edits, issues, and other contributions +that are not aligned to this Code of Conduct, or to ban temporarily or +permanently any contributor for other behaviors that they deem inappropriate, +threatening, offensive, or harmful. + +### Scope + +This Code of Conduct applies both within project spaces and in public spaces +when an individual is representing the project or its community. Examples of +representing a project or community include using an official project e-mail +address, posting via an official social media account, or acting as an appointed +representative at an online or offline event. Representation of a project may be +further defined and clarified by project maintainers. + +### Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be +reported by contacting us at [v1s1t0r.1s.h3r3@gmail.com]. All +complaints will be reviewed and investigated and will result in a response that +is deemed necessary and appropriate to the circumstances. The project team is +obligated to maintain confidentiality with regard to the reporter of an incident. +Further details of specific enforcement policies may be posted separately. + +Project maintainers who do not follow or enforce the Code of Conduct in good +faith may face temporary or permanent repercussions as determined by other +members of the project's leadership. + +### Attribution + +This Code of Conduct is adapted from the [Contributor Covenant][Homepage], version 1.4, +available at [http://contributor-covenant.org/version/1/4][Version] + +--- + +## Donate + +If you enjoyed the script, feel free to donate. Invite me to a coffee through Paypal or send me a fraction of a bitcoin: + + + + + +
+ Paypal: v1s1t0r.1s.h3r3@gmail.com
+ Bitcoin: 1AKnTXbomtwUzrm81FRzi5acSSXxGteGTH +
+ +[![Paypal][Paypal]](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7ELM486P7XKKG) +  +[![Bitcoin][Bitcoin]](https://blockchain.info/address/1AKnTXbomtwUzrm81FRzi5acSSXxGteGTH) + + +[Homepage]: http://contributor-covenant.org +[Version]: http://contributor-covenant.org/version/1/4/ +[Shellcheck]: https://github.com/koalaman/shellcheck "shellcheck.hs" +[Here]: https://github.com/v1s1t0r1sh3r3/airgeddon/issues/new +[Master]: https://github.com/v1s1t0r1sh3r3/airgeddon/tree/master +[Dev]: https://github.com/v1s1t0r1sh3r3/airgeddon/tree/dev +[xtonousou]: https://github.com/xtonousou "xT" +[Readme]: README.md +[Paypal]: /imgs/banners/paypal_donate.png "Show me the money!" +[Bitcoin]: /imgs/banners/bitcoin_donate.png "Show me the money!" diff --git a/README.md b/README.md index 13e198621..b66dfd08b 100644 --- a/README.md +++ b/README.md @@ -1,206 +1,299 @@ -#airgeddon [![License](https://img.shields.io/badge/License-GPL%20v3%2B-blue.svg?style=flat-square)](LICENSE.md) -This is a multi-use bash script for Linux systems to audit wireless networks.
-![We'll conquer the earth!!][banner] - -#Features -- Interface mode switcher (Monitor-Managed) keeping selection even on interface name changing. -- DoS over wireless networks using different methods. -- Assisted Handshake file capturing. -- Cleaning and optimizing Handshake captured files. -- Offline password decrypting on WPA/WPA2 captured files (dictionary, bruteforce and rule based). -- Evil Twin attacks (Rogue AP): - - Only Rogue/Fake AP version to sniff using external sniffer (Hostapd + DHCP + DoS). - - Simple integrated sniffing (Hostapd + DHCP + DoS + ettercap). - - Integrated sniffing, sslstrip (Hostapd + DHCP + DoS + Ettercap + Sslstrip). - - Integrated sniffing, sslstrip2 and BeEF browser exploitation framework (Hostapd + DHCP + DoS + Bettercap + BeEF). - - Captive portal with "DNS blackhole" to capture wifi passwords (Hostapd + DHCP + DoS + Dnsspoff + Lighttpd). -- WPS features: - - WPS scanning (wash). Self parameterization to avoid "bad fcs" problem. - - Custom PIN association (bully and reaver). - - Pixie Dust attacks (bully and reaver). - - Bruteforce PIN attacks (bully and reaver). - - Parameterizable timeouts. - - Known WPS PINs attack (bully and reaver), based on online PIN database with auto-update. - - Integration of the most common PIN generation algorithms. -- Compatibility with many Linux distros (see requirements section). -- Easy targeting and selection in every section. -- Drag and drop files on console window for entering file paths. -- Dynamic screen resolution detection and windows auto-sizing for optimal viewing. -- Controlled Exit. Cleaning tasks and temp files. Option to keep monitor mode if desired. -- Multilanguage support and autodetect OS language feature (see supported languages section). -- Help hints in every zone/menu for easy use. -- Auto-update. Script checks for newer version if possible. - -#Requirements -Bash version 4.2 or later needed. - -Compatibility with any Linux which have installed the tools what script needs. The script checks for them at the beginning. - -Tested on these compatible Linux distros:
-*-Kali 2.0, 2016.1, 2016.2 and arm versions (Raspberry Pi)*
-*-Wifislax 4.11.1, 4.12 and 64-1.0*
-*-Backbox 4.5.1 and 4.6*
-*-Parrot 2.2.1 to 3.4.1 and arm versions (Raspberry Pi)*
-*-BlackArch 2016.01.10 to 2016.12.29*
-*-Cyborg Hawk 1.1*
-*-Debian 7 (Wheezy) and 8 (Jessie)*
-*-Ubuntu/Xubuntu 15.10, 16.04 and 16.04.1*
-*-OpenSUSE Leap 42.1 and 42.2*
-*-CentOS 6 and 7*
-*-Gentoo 20160514 and 20160704*
-*-Fedora 24*
-*-Red Hat 7 (Maipo)*
-*-Arch 4.6.2-1 to 4.8.13-1*
-*-Raspbian 7 (Wheezy) and 8 (Jessie) (Raspberry Pi)*
-*-OpenMandriva LX3*
- -airgeddon is already included in some Linux distros and repositories: - - Wifislax 4.12, 64-1.0 or higher. - - BlackArch first 2017 release or later. - - ArchStrike repository. - -We will enumerate the categories and tools. The command can be included in different packages depending of the distro. - -**Essential tools**: <- *the script doesn't work if you don't have installed all of them* - -| Command | Possible package name | // | Command | Possible package name | -| --- | --- | --- | --- | --- | -| ifconfig | net-tools | // | iwconfig | wireless-tools | -| iw | iw | // | awk | awk / gawk | -| airmon-ng | aircrack-ng | // | airodump-ng | aircrack-ng | -| aircrack-ng | aircrack-ng | // | xterm | xterm | - -**Optional tools**: <- *not necessary to work, only needed for some features* - -| Command | Possible package name | // | Command | Possible package name | -| --- | --- | --- | --- | --- | -| wpaclean | aircrack-ng | // | ettercap | ettercap / ettercap-text-only / ettercap-graphical | -| crunch | crunch | // | etterlog | ettercap / ettercap-text-only / ettercap-graphical | -| aireplay-ng | aircrack-ng | // | sslstrip | sslstrip | -| mdk3 | mdk3 | // | dhcpd | isc-dhcp-server / dhcp-server / dhcp | -| hashcat | hashcat | // | dnsspoof | dsniff | -| hostapd | hostapd | // | wash | reaver | -| lighttpd | lighttpd | // | reaver | reaver | -| iptables | iptables | // | bully | bully | -| bettercap | bettercap | // | pixiewps | pixiewps | -| beef | beef / beef-xss | // | unbuffer | expect / expect-dev | - -**Important tips about BeEF** - - The beef software you must install is BeEF (Browser Exploitation Framework). Be careful, don't confuse with beef (Flexible Brainfuck interpreter). This package has on some distros the same name, same executable file name and can lead into confusion. Anyway, airgeddon is able to detect this and show you a warning if needed. Here is a link to the right BeEF installation's page: [BeEF Installation](https://github.com/beefproject/beef/wiki/Installation). - - If you use a distro which already comes with BeEF installed like Kali, BlackArch or Wifislax, you will have no problems. If you install BeEF manually, airgeddon is able to manage the integration asking you for the path where it's installed, even modifying its own code in order to make updates-proof persistent changes. - -**Update tools**: <- *not necessary to work, only used for auto-update* - -| Command | Possible package name | -| --- | --- | -| curl | curl | - -**Internal tools**: <- *these are internally checked. Not necessary to work, good to have* - -| Command | Possible package name | -| --- | --- | -| xdpyinfo | x11-utils / xdpyinfo / xorg-xdpyinfo | -| ethtool | ethtool | -| lspci | pciutils | -| rfkill | rfkill | -Is highly recommended to have the internal tools installed. They improve functionality and performance. For example, xdpyinfo allow the script to detect the desktop resolution in order to print windows in a better way (size and position). - -Of course, the script also uses many standard basic commands that are understood to come with any Linux distro, so they are not checked (cp, rm, grep, pgrep, egrep, md5sum, uname, echo, hash, cat, sed, etc.). - -#Known incompatibilities -Impossible compatibility for Mac OSX at the moment. Some reasons:
-*-Bash version* <- it can be avoided upgrading to 4 or later, this is not the real problem :smile:
-*-Aircrack suite* <- this suite for OSX doesn't support airodump and aireplay
-*-Wireless tools* <- iwconfig doesn't exists for OSX, and airport command can't be used. It generates very different outputs - -Incompatible with OpenBSD and FreeBSD. They are Unix systems but they have some differences with Linux:
-*-Bash* <- They have no bash. It can be installed, this is not the real problem again :sweat_smile:
-*-Wireless tools* <- iwconfig doesn't exists for these systems, they use ifconfig instead and it generates very different outputs - -#Disclaimer & License -This script must be used only for educational purposes and pentesting.
-Use it only on your own networks or with the network's owner appropriate permission during a penstest.
-airgeddon staff is not responsible of its use in any case.
-This script is under GPLv3 (or later) [License](LICENSE.md). - -#Use -Must be launched only using bash (not sh). Example `bash /path/to/airgeddon.sh`
-If you launch the script using sh and a *"Syntax error"* appears, launch it with **bash instead of sh**. Even with no initial error, maybe you'll have it later. Use bash always! - -#Supported Languages -![English][english] English
-![Spanish][spanish] Spanish
-![French][french] French
-![Catalan][catalan] Catalan
-![Portuguese][portuguese] Portuguese
-![Russian][russian] Russian
-![Greek][greek] Greek - -#Project Collaboration -You can join the project: - - - Translations to other languages are welcome. - - More distros support compatibility. - - New features. - - More WPS pins for the database. - - Testing and feedback is needed too. - -*For collaborating translators:*
-You can take the strings to translate from the code. All the stuff to translate is in "language_strings" function. Ask by mail if you have any doubt. You'll be informed about you how to proceed, you can be added as a collaborator on the project. - -*For collaborating developers:*
-Debug mode was implemented for faster development skipping intro and initial checks. Use it setting var *"debug_mode"* to 1
-Please, respect the tab indentation, code style and the UTF-8 files format only using at the end of the lines LF (not CRLF).
-Direct push on master is not allowed, and pull requests require revision and approvement.
-airgeddon code is 100% clean of warnings. Use [Shellcheck](https://github.com/koalaman/shellcheck) to search for errors and warnings on code. <- Thanks xtonousou for the tip :wink: - -*For beta testers:*
-You can download the master version or the beta testing version from the development branch called `dev`. Sometimes there are other temporary branches for specific features that can be tested too. - -*For WPS PIN database collaborators:*
-The pins must be strictly ordered by key in the array. Keys are the first 6 bssid digits. After updating the "known_pins.db" file, you must update too "pindb_checksum.txt" with the calculated checksum of the database file. This checksum is calculated using md5sum tool. - -#Changelog -See [Changelog](CHANGELOG.md) file to review changes. - -#Credits & Special Thanks -Thank you to: - -**Kcdtv** for French translations, beta testing, suggestions about new features and support received since the beginning.
-**USUARIONUEVO** for helping me to improve the script, suggestions about new features and for the support received.
-**El padrino** and **cLn** for Catalan translations.
-**Luan** for Portuguese translations.
-**MiAl** for Russian translations.
-**xtonousou** for Greek translations, beta testing, suggestions, the help received fixing code warnings and other stuff. - -Thanks to the "Spanish pentesting crew", the Wifislax staff, the BlackArch community, the Seguridadwireless.net, Wifi-libre.com and Lampiweb.com forum people that helped me.
-Thanks to the Hackware.ru admins. Thanks to all the people who helped me building the online PIN database for WPS. Thank you to Dominique Bongard for bringing to us Pixie Dust attacks. Thanks to Zhao Chunsheng and Stefan Viehböck for their wonderful algorithms.
-I want to thank you too, to all developers who made and designed the third-party tools airgeddon uses. - -Thank you too to other authors who inspired me with their scripts:
-*vk496 -> Linset*
-*MI1 -> Airstorm*
-*MatToufoutu -> Ap-fucker*
-*Coeman76 -> Handshaker*
-*Goyfilms -> Goyscript*
-*Kcdtv -> WPSPin* - -#Donate -If you enjoyed the script, feel free to give a donation. Invite me to a coffee through Paypal or send me a fraction of a bitcoin:
-Paypal: *v1s1t0r.1s.h3r3@gmail.com*
-Bitcoin: *1AKnTXbomtwUzrm81FRzi5acSSXxGteGTH* - -[![paypal][paypal]](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7ELM486P7XKKG) -  -[![bitcoin][bitcoin]](https://blockchain.info/address/1AKnTXbomtwUzrm81FRzi5acSSXxGteGTH) - -[banner]: /imgs/airgeddon_banner.png "We'll conquer the earth!!" -[paypal]: /imgs/paypal_donate.png "Show me the money!" -[bitcoin]: /imgs/bitcoin_donate.png "Show me the money!" -[english]: /imgs/us.png "English" -[spanish]: /imgs/es.png "Spanish" -[french]: /imgs/fr.png "French" -[catalan]: /imgs/cat.png "Catalan" -[portuguese]: /imgs/pt.png "Portuguese" -[russian]: /imgs/ru.png "Russian" -[greek]: /imgs/gr.png "Greek" + + + + + + +# :satellite: airgeddon [![Version-shield]](CHANGELOG.md) [![Bash4.2-shield]](http://tldp.org/LDP/abs/html/bashver4.html#AEN21220) [![License-shield]](LICENSE.md) [![Paypal-shield]](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7ELM486P7XKKG) [![Bitcoin-shield]](https://blockchain.info/address/1AKnTXbomtwUzrm81FRzi5acSSXxGteGTH) + +> This is a multi-use bash script for Linux systems to audit wireless networks. + +![Banner] + +
+ Table Of Contents +- [Features] +- [Requirements] + - [Essential Tools] + - [Optional Tools] + - [Update Tools] + - [Internal Tools] + - [BeEF Tips] +- [Usage] +- [Supported Languages] +- [Known Incompatibilities] +- [Contributing] +- [Changelog] +- [Disclaimer & License] +- [Acknowledgments] + - [Hat Tip To] + - [Inspiration] +
+ +--- + +### Features + +- Interface mode switcher (Monitor-Managed) keeping selection even on interface name changing +- DoS over wireless networks using different methods +- Assisted Handshake file capturing +- Cleaning and optimizing Handshake captured files +- Offline password decrypting on WPA/WPA2 captured files (dictionary, bruteforce and rule based) +- Evil Twin attacks (Rogue AP) + - Only Rogue/Fake AP version to sniff using external sniffer (Hostapd + DHCP + DoS) + - Simple integrated sniffing (Hostapd + DHCP + DoS + Ettercap) + - Integrated sniffing, sslstrip (Hostapd + DHCP + DoS + Ettercap + Sslstrip) + - Integrated sniffing, sslstrip2 and BeEF browser exploitation framework (Hostapd + DHCP + DoS + Bettercap + BeEF) + - Captive portal with "DNS blackhole" to capture wifi passwords (Hostapd + DHCP + DoS + Dnsspoff + Lighttpd) +- WPS features + - WPS scanning (wash). Self parameterization to avoid *"bad fcs"* problem + - Custom PIN association (bully and reaver) + - Pixie Dust attacks (bully and reaver) + - Bruteforce PIN attacks (bully and reaver) + - Parameterizable timeouts + - Known WPS PINs attack (bully and reaver), based on online PIN database with auto-update + - Integration of the most common PIN generation algorithms +- Compatibility with many Linux distributions (see [Requirements] section) +- Easy targeting and selection in every section +- Drag and drop files on console window for entering file paths +- Dynamic screen resolution detection and windows auto-sizing for optimal viewing +- Controlled Exit. Cleaning tasks and temp files. Option to keep monitor mode if desired +- Multilanguage support and autodetect OS language feature (see [Supported Languages] section) +- Help hints in every zone/menu for easy use +- Auto-update. Script checks for newer version if possible + +--- + +### Requirements + +Bash **4.2** or later. + +Compatible with any Linux that has installed the tools needed. The script checks for them at the beginning. + +> `airgeddon` is already included in some Linux distributions and repositories: +> - [Wifislax] 4.12, 64-1.0 or higher +> - [BlackArch] 2017.01.28 or later +> - [ArchStrike] repository + + +
+ Tested on these compatible Linux distributions +- *Kali 2.0, 2016.1, 2016.2 and arm versions (Raspberry Pi)* +- *Wifislax 4.11.1, 4.12 and 64-1.0* +- *Backbox 4.5.1 and 4.6* +- *Parrot 2.2.1 to 3.4.1 and arm versions (Raspberry Pi)* +- *BlackArch 2016.01.10 to 2017.01.28* +- *Cyborg Hawk 1.1* +- *Debian 7 (Wheezy) and 8 (Jessie)* +- *Ubuntu/Xubuntu 15.10, 16.04 and 16.04.1* +- *OpenSUSE Leap 42.1 and 42.2* +- *CentOS 6 and 7* +- *Gentoo 20160514 and 20160704* +- *Fedora 24* +- *Red Hat 7 (Maipo)* +- *Arch 4.6.2-1 to 4.9.9-1* +- *Raspbian 7 (Wheezy) and 8 (Jessie) (Raspberry Pi)* +- *OpenMandriva LX3* +
+ +#### Essential tools ← The script does not work if you don't have installed all of them + + + + Command | Possible package name | • | Command | Possible package name +:------------|:----------------------|:-------:|:------------|:---------------------- + ifconfig | net-tools | │ | iwconfig | wireless-tools + iw | iw | │ | awk | awk \| gawk + airmon-ng | aircrack-ng | │ | airodump-ng | aircrack-ng + aircrack-ng | aircrack-ng | │ | xterm | xterm + +#### Optional tools ← Not necessary to work, only needed for some features + + Command | Possible package name | • | Command | Possible package name +:------------|:-------------------------|:-------:|:---------|:----------------------------------------------------- + wpaclean | aircrack-ng | │ | ettercap | ettercap \| ettercap-text-only \| ettercap-graphical + crunch | crunch | │ | etterlog | ettercap \| ettercap-text-only \| ettercap-graphical + aireplay-ng | aircrack-ng | │ | sslstrip | sslstrip + mdk3 | mdk3 | │ | dhcpd | isc-dhcp-server \| dhcp-server \| dhcp + hashcat | hashcat | │ | dnsspoof | dsniff + hostapd | hostapd | │ | wash | reaver + lighttpd | lighttpd | │ | reaver | reaver + iptables | iptables | │ | bully | bully + bettercap | bettercap | │ | pixiewps | pixiewps + beef | beef-xss \| beef-project | │ | unbuffer | expect \| expect-dev + +##### Important tips about BeEF + + - The right software you must install is BeEF (Browser Exploitation Framework). Be careful, do not mistake it with beef (Flexible Brainfuck Interpreter). This package has the same name and executable file name on some distributions and can lead into confusion. Anyway, `airgeddon` is able to detect the issue and displays a warning if needed. Here is a link to the right [BeEF installation's page]. + - If you use a distribution which already has BeEF installed like Kali, BlackArch or Wifislax, there will be no problems. If you have manually installed BeEF, `airgeddon` is able to manage the integration asking for the path where it's installed, even modifying its own code in order to make updates-proof persistent changes. + +#### Update tools ← Not necessary to work, only used for auto-update + + Command | Possible package name +:--------|:---------------------- + curl | curl + +#### Internal tools ← These are internally checked. Not necessary to work, good to have + + Command | Possible package name +:---------|:--------------------------------------- + xdpyinfo | x11-utils \| xdpyinfo \| xorg-xdpyinfo + ethtool | ethtool + lspci | pciutils + rfkill | rfkill + +It is highly recommended to have the internal tools installed. They improve functionality and performance. For example, `xdpyinfo` allows the script to detect the display resolution in order to print on windows in a better way (size and position). + +Of course, the script also uses many standard basic commands that are supposed to be included in any Linux distribution, so they are not checked (cp, rm, grep, pgrep, egrep, md5sum, uname, echo, hash, cat, sed, etc.). + +A command could be included in different packages, depending on the distribution. + +--- + +### Usage + +`airgeddon` should be launched with bash `bash /path/to/airgeddon.sh`.
+If you launch the script using sh and a *"Syntax error"* appears, launch it with **bash** instead of **sh**.
+Even with no initial error, it will maybe show itself later. Always use bash! + +--- + +### Supported Languages + +![English][English] English
+![Spanish][Spanish] Spanish
+![French][French] French
+![Catalan][Catalan] Catalan
+![Portuguese][Portuguese] Portuguese
+![Russian][Russian] Russian
+![Greek][Greek] Greek
+ +--- + +### Known Incompatibilities + +- Impossible compatibility for Mac OSX at the moment: + - *Bash version* ← it can be avoided upgrading to 4 or later, this is not the real problem :smile: + - *Aircrack suite* ← this suite for OSX does not support `airodump` and `aireplay` + - *Wireless tools* ← `iwconfig` does not exist for OSX, and `airport` command cannot be used. It generates different outputs +- Incompatible with OpenBSD and FreeBSD. They are Unix systems but they have some differences with Linux: + - *Bash* ← They have no bash. It can be installed, this is not the real problem again :sweat_smile: + - *Wireless tools* ← `iwconfig` does not exist on these systems, they use `ifconfig` instead and it generates different outputs + +--- + +### Contributing + +- Translations to other languages +- More distribution support compatibility +- New features +- More WPS pins for the database +- Testing and feedback + +Read [Contributing File] for more details on our code of conduct, and the process of project collaborating. + +--- + +### Changelog + +Read [Changelog File] to review changes. + +--- + +### Disclaimer & License + + + +This script must be used for educational purposes and penetration test only.
+Use it only on your own networks or with the network's owner permission.
+`airgeddon` staff is not responsible of its use in any case. + +--- + +### Acknowledgments + + +[Kcdtv] for French translations, beta testing, suggestions about new features and support received since the beginning,
+**USUARIONUEVO** for helping me to improve the script, suggestions about new features and for the support received,
+**El padrino** and [cLn] for Catalan translations,
+[Luan] for Portuguese translations,
+[MiAl] for Russian translations,
+[xtonousou] for Greek translations, beta testing, suggestions, the help received fixing code warnings and other stuff,
+[OscarAkaElvis] for allowing me to own his body when I visit the earth. + +#### Hat tip to + +- The "Spanish pentesting crew" +- The [Wifislax] staff +- The [BlackArch] community +- The forum people of [Seguridadwireless.net], [Wifi-libre.com] and [Lampiweb.com] +- The [Hackware.ru] admins +- All the people who helped building the online PIN database for WPS +- Dominique Bongard for bringing to us Pixie Dust attacks +- Zhao Chunsheng and Stefan Viehböck for their wonderful algorithms +- All developers who made and designed the third-party tools that `airgeddon` uses + +#### Inspiration + + +- [vk496] → Linset +- MI1 → Airstorm +- [MatToufoutu] → Ap-fucker +- Coeman76 → Handshaker +- Goyfilms → Goyscript +- [Kcdtv] → WPSPin + + +[Features]: #features +[Essential Tools]: #essential-tools--the-script-does-not-work-if-you-dont-have-installed-all-of-them +[Optional Tools]: #optional-tools--not-necessary-to-work-only-needed-for-some-features +[BeEF Tips]: #important-tips-about-beef +[Update Tools]: #update-tools--not-necessary-to-work-only-used-for-auto-update +[Internal Tools]: #internal-tools--these-are-internally-checked-not-necessary-to-work-good-to-have +[Requirements]: #requirements +[Usage]: #usage +[Supported Languages]: #supported-languages +[Known Incompatibilities]: #known-incompatibilities +[Contributing]: #contributing +[Changelog]: #changelog +[Disclaimer & License]: #disclaimer--license +[Acknowledgments]: #acknowledgments +[Hat Tip To]: #hat-tip-to +[Inspiration]: #inspiration + +[Banner]: /imgs/banners/airgeddon_banner.png "We will conquer the earth!!" +[English]: /imgs/flags/us.png "English" +[Spanish]: /imgs/flags/es.png "Spanish" +[French]: /imgs/flags/fr.png "French" +[Catalan]: /imgs/flags/cat.png "Catalan" +[Portuguese]: /imgs/flags/pt.png "Portuguese" +[Russian]: /imgs/flags/ru.png "Russian" +[Greek]: /imgs/flags/gr.png "Greek" + +[Changelog File]: CHANGELOG.md +[Contributing File]: CONTRIBUTING.md +[License File]: LICENSE.md + +[Wifislax]: http://www.wifislax.com +[BlackArch]: https://blackarch.org +[ArchStrike]: https://archstrike.org/wiki +[BeEF installation's page]: https://github.com/beefproject/beef/wiki/Installation +[Seguridadwireless.net]: http://foro.seguridadwireless.net +[Wifi-libre.com]: https://www.wifi-libre.com +[Lampiweb.com]: http://lampiweb.com/foro +[Hackware.ru]: https://hackware.ru + +[vk496]: https://github.com/vk496 +[MatToufoutu]: https://github.com/mattoufoutu +[Kcdtv]: https://github.com/kcdtv +[cLn]: https://github.com/cLn73 +[Luan]: https://github.com/Luan7805 +[MiAl]: https://github.com/Mi-Al +[xtonousou]: https://github.com/xtonousou "xT" +[OscarAkaElvis]: https://github.com/OscarAkaElvis + +[Version-shield]: https://img.shields.io/badge/version-6.01-blue.svg?style=flat-square&colorA=273133&colorB=0093ee "Latest version" +[Bash4.2-shield]: https://img.shields.io/badge/bash-4.2%2B-blue.svg?style=flat-square&colorA=273133&colorB=00db00 "Bash 4.2 or later" +[License-shield]: https://img.shields.io/badge/license-GPL%20v3%2B-blue.svg?style=flat-square&colorA=273133&colorB=bd0000 "GPL v3+" +[Paypal-shield]: https://img.shields.io/badge/donate-paypal-blue.svg?style=flat-square&colorA=002f86&colorB=009cde "Show me the money!" +[Bitcoin-shield]: https://img.shields.io/badge/donate-bitcoin-blue.svg?style=flat-square&colorA=273133&colorB=f7931a "Show me the money!" diff --git a/airgeddon.sh b/airgeddon.sh index 51153f68e..d88f93b15 100644 --- a/airgeddon.sh +++ b/airgeddon.sh @@ -1,8 +1,13 @@ -#!/bin/bash - -airgeddon_version="6.0" - -#Enabled 1 / Disabled 0 - Debug mode for faster development skipping intro and initial checks - Default value 0 +#!/usr/bin/env bash +#Title........: airgeddon.sh +#Description..: This is a multi-use bash script for Linux systems to audit wireless networks. +#Author.......: v1s1t0r +#Date.........: 20170220 +#Version......: 6.01 +#Usage........: bash airgeddon.sh +#Bash Version.: 4.2 or later + +#Enabled with extra-verbose mode 2 / Enabled 1 / Disabled 0 - Debug mode for faster development skipping intro and initial checks - Default value 0 debug_mode=0 #Enabled 1 / Disabled 0 - Auto update feature (it has no effect on debug mode) - Default value 1 @@ -99,6 +104,7 @@ declare -A possible_alias_names=( ) #General vars +airgeddon_version="6.01" standardhandshake_filename="handshake-01.cap" tmpdir="/tmp/" osversionfile_dir="/etc/" @@ -179,17 +185,17 @@ currentpassfile="ag.et_currentpass.txt" successfile="ag.et_success.txt" processesfile="ag.et_processes.txt" possible_dhcp_leases_files=( - "/var/lib/dhcp/dhcpd.leases" - "/var/state/dhcp/dhcpd.leases" - "/var/lib/dhcpd/dhcpd.leases" - ) -possible_beef_known_locations=( - "/usr/share/beef/" - "/usr/share/beef-xss/" - "/opt/beef/" - "/opt/beef-project/" - #Custom BeEF location (set=0) + "/var/lib/dhcp/dhcpd.leases" + "/var/state/dhcp/dhcpd.leases" + "/var/lib/dhcpd/dhcpd.leases" ) +possible_beef_known_locations=( + "/usr/share/beef/" + "/usr/share/beef-xss/" + "/opt/beef/" + "/opt/beef-project/" + #Custom BeEF location (set=0) + ) #Distros vars known_compatible_distros=( @@ -211,10 +217,10 @@ known_compatible_distros=( ) known_arm_compatible_distros=( - "Raspbian" - "Parrot arm" - "Kali arm" - ) + "Raspbian" + "Parrot arm" + "Kali arm" + ) #Hint vars declare main_hints=(128 134 163) @@ -252,6 +258,8 @@ normal_color="\e[1;0m" #Set different language text strings function language_strings() { + debug_print + declare -A unknown_chipset unknown_chipset["ENGLISH"]="Unknown" unknown_chipset["SPANISH"]="Desconocido" @@ -338,7 +346,7 @@ function language_strings() { et_misc_texts["SPANISH",4]="Con este ataque has de usar un sniffer externo para intentar obtener contraseñas de los clientes conectados a la red" et_misc_texts["FRENCH",4]="Avec cette attaque, vous devez utiliser un sniffeur pour tenter d'obtenir les mots de passe des clients connectés au réseau" et_misc_texts["CATALAN",4]="Amb aquest atac has d'utilitzar un sniffer extern per intentar obtenir contrasenyes dels clients connectats a la xarxa" - et_misc_texts["PORTUGUESE",4]="Com este ataque você tem que usar um sniffer externa para tentar obter as senhas dos clientes conectados à rede" + et_misc_texts["PORTUGUESE",4]="Com este ataque você tem que usar um sniffer externo para tentar obter as senhas dos clientes conectados à rede" et_misc_texts["RUSSIAN",4]="С этой атакой вам нужно использовать внешний сниффер для попытки получить пароли клиентов, подключённых к сети" et_misc_texts["RUSSIAN",4]="С этой атакой вам нужно использовать внешний сниффер для попытки получить пароли клиентов, подключённых к сети" et_misc_texts["GREEK",4]="Με αυτή την επίθεση θα πρέπει να χρησιμοποιήσετε έναν εξωτερικό sniffer για να μπορέσετε να υποκλέψετε κωδικούς πρόσβασης από τους χρήστες που είναι συνδεδεμένοι στο δίκτυο" @@ -426,7 +434,7 @@ function language_strings() { et_misc_texts["SPANISH",15]="Portal de Internet" et_misc_texts["FRENCH",15]="Portail Internet" et_misc_texts["CATALAN",15]="Portal d'Internet" - et_misc_texts["PORTUGUESE",15]="Portal Internet" + et_misc_texts["PORTUGUESE",15]="Portal de Internet" et_misc_texts["RUSSIAN",15]="Интернет-портал" et_misc_texts["GREEK",15]="Internet Portal" @@ -619,7 +627,7 @@ function language_strings() { arr["SPANISH",11]="Saliendo de airgeddon script v${airgeddon_version} - Nos vemos pronto! :)" arr["FRENCH",11]="Fermeture du script airgeddon v${airgeddon_version} - A bientôt! :)" arr["CATALAN",11]="Sortint de airgeddon script v${airgeddon_version} - Ens veiem aviat! :)" - arr["PORTUGUESE",11]="Saindo do script airgeddon v${airgeddon_version} - Até breve! :)" + arr["PORTUGUESE",11]="Saindo do script airgeddon v${airgeddon_version} - Até breve! :)" arr["RUSSIAN",11]="Выход из скрипта airgeddon v${airgeddon_version} - До встречи! :)" arr["GREEK",11]="Κλείσιμο του airgeddon v${airgeddon_version} - Αντίο :)" @@ -651,7 +659,7 @@ function language_strings() { arr["SPANISH",15]="Esta interfaz ha cambiado su nombre al ponerse en modo managed. Se ha seleccionado automáticamente" arr["FRENCH",15]="Le nom de l'interface a changé lors du passage en mode managed. Elle a été sélectionnée automatiquement" arr["CATALAN",15]="Aquesta interfície ha canviat de nom al posar-la en mode managed. S'ha triat automàticament" - arr["PORTUGUESE",15]="Esta interface mudou de nome, colocando em modo managed e selecionando automaticamente" + arr["PORTUGUESE",15]="Esta interface mudou de nome ao ser colocanda em modo managed. Ela foi selecionanda automaticamente" arr["RUSSIAN",15]="Интерфейс изменил имя во время перевода в управляемый режим. Выбран автоматически" arr["GREEK",15]="Η διεπάφη άλλαξε όνομα καθώς ήταν σε ετερόκλητη κατάσταση. Επιλέχθηκε αυτόματα" @@ -699,7 +707,7 @@ function language_strings() { arr["SPANISH",21]="Esta interfaz ha cambiado su nombre al ponerla en modo monitor. Se ha seleccionado automáticamente" arr["FRENCH",21]="Le nom de l'interface à changé lors de l'activation du mode moniteur. Elle a été automatiquement sélectionnée" arr["CATALAN",21]="Aquesta interfície ha canviat de nom al posar-la en mode monitor. S'ha seleccionat automàticament" - arr["PORTUGUESE",21]="Esta interface mudou de nome, colocando em modo monitor e selecionando automaticamente" + arr["PORTUGUESE",21]="Esta interface mudou de nome ao ser colocanda em modo monitor. Ela foi selecionanda automaticamente" arr["RUSSIAN",21]="Этот интерфейс изменил своё имя во время перевода в режим монитора. Выбран автоматически" arr["GREEK",21]="Η διεπαφή άλλαξε όνομα καθώς ήταν σε κατάσταση παρακολούθησης" @@ -723,7 +731,7 @@ function language_strings() { arr["SPANISH",24]="Selecciona una interfaz para trabajar con ella :" arr["FRENCH",24]="Sélectionnez l'interface pour travailler :" arr["CATALAN",24]="Seleccionar una interfície per treballar-hi :" - arr["PORTUGUESE",24]="Seleccionar uma interface para trabalhar :" + arr["PORTUGUESE",24]="Selecione uma interface para trabalhar :" arr["RUSSIAN",24]="Выберите интерфейс для работы :" arr["GREEK",24]="Επιλέξτε διεπαφή :" @@ -1091,7 +1099,7 @@ function language_strings() { arr["SPANISH",70]="Sólo un objetivo detectado. Se ha seleccionado automáticamente" arr["FRENCH",70]="Un seul réseau a été détecté. Il a été automatiquement sélectionné" arr["CATALAN",70]="Només un objectiu detectat. Seleccionat automàticament" - arr["PORTUGUESE",70]="Apenas uma rede encontrada. A rede foi selecionada automaticamente" + arr["PORTUGUESE",70]="Apenas uma rede encontrada. Ela foi selecionada automaticamente" arr["RUSSIAN",70]="Обнаружена только одна цель. Выбрана автоматически" arr["GREEK",70]="Εντοπίστηκε μόνο ένας στόχος. Επιλέχθηκε αυτόματα" @@ -1127,19 +1135,19 @@ function language_strings() { arr["RUSSIAN",74]="Этот скрипт под лицензией GPLv3 (или более поздней)" arr["GREEK",74]="Αυτό το script είναι υπό την άδεια GPLv3 (ή νεότερη)" - arr["ENGLISH",75]="Thanks to the \"Spanish pentesting crew\", to the \"Wifislax Staff\", to the forums people who help me, my collaborators, translators and specially to Kcdtv for beta testing and support received" - arr["SPANISH",75]="Gracias al \"Spanish pentesting crew\", al \"Wifislax Staff\", a la gente de los foros que me ayuda, a mis colaboradores, traductores y en especial a Kcdtv por el beta testing y el apoyo recibido" - arr["FRENCH",75]="Merci au \"Spanish pentesting crew\" , au \"Wifislax Staff\", aux gens des forums qui m'ont aidés, à mes collaborateurs, aux traducteurs et tout spécialement à Kcdtv pour les tests en phase bêta et son soutien" - arr["CATALAN",75]="Agraïments al \"Spanish pentesting crew\", al \"Wifislax Staff\", a la gent dels fòrums que m'ajuda, als meus col·laboradors, traductors i especialment al Kcdtv per les proves beta i el suport rebut" - arr["PORTUGUESE",75]="Agradecimentos a \"Spanish pentesting crew\", \"Wifislax Staff\", as pessoas dos fóruns por me ajudar, os colaboradores, tradutores e especialmente para Kcdtv por testes beta e também a todo apoio recebido" - arr["RUSSIAN",75]="Спасибо \"Spanish pentesting crew\", за \"Wifislax Staff\", людям с форумов, которые мне помогают, тем, кто принимает участие в проекте, переводчикам и особенно Kcdtv за бета тестирование и полученную поддержку" - arr["GREEK",75]="Τις ευχαριστίες μου στην \"Ισπανική ομάδα pentesting\", στο \"Wifislax Staff\", στα άτομα από το forum που με βοηθάνε, στους συνεργάτες μου, στους μεταφραστές και ειδικά στον Kcdtv για το beta testing και την υποστήριξη που λάβαμε από αυτόν" + arr["ENGLISH",75]="Thanks to the \"Spanish pentesting crew\", to the \"Wifislax Staff\", to the forums people who help me, my collaborators, translators and specially to Kcdtv and xtonousou for beta testing and support received" + arr["SPANISH",75]="Gracias al \"Spanish pentesting crew\", al \"Wifislax Staff\", a la gente de los foros que me ayuda, a mis colaboradores, traductores y en especial a Kcdtv y xtonousou por el beta testing y el apoyo recibido" + arr["FRENCH",75]="Merci au \"Spanish pentesting crew\" , au \"Wifislax Staff\", aux gens des forums qui m'ont aidés, à mes collaborateurs, aux traducteurs et tout spécialement à Kcdtv et xtonousou pour les tests en phase bêta et son soutien" + arr["CATALAN",75]="Agraïments al \"Spanish pentesting crew\", al \"Wifislax Staff\", a la gent dels fòrums que m'ajuda, als meus col·laboradors, traductors i especialment al Kcdtv i xtonousou per les proves beta i el suport rebut" + arr["PORTUGUESE",75]="Agradecimentos a \"Spanish pentesting crew\", \"Wifislax Staff\", as pessoas dos fóruns por me ajudar, os colaboradores, tradutores e especialmente para Kcdtv e xtonousou por testes beta e também a todo apoio recebido" + arr["RUSSIAN",75]="Спасибо \"Spanish pentesting crew\", за \"Wifislax Staff\", людям с форумов, которые мне помогают, тем, кто принимает участие в проекте, переводчикам и особенно Kcdtv и xtonousou за бета тестирование и полученную поддержку" + arr["GREEK",75]="Τις ευχαριστίες μου στην \"Ισπανική ομάδα pentesting\", στο \"Wifislax Staff\", στα άτομα από το forum που με βοηθάνε, στους συνεργάτες μου, στους μεταφραστές και ειδικά στον Kcdtv και xtonousou για το beta testing και την υποστήριξη που λάβαμε από αυτόν" arr["ENGLISH",76]="Invalid menu option was chosen" arr["SPANISH",76]="Opción del menú no válida" arr["FRENCH",76]="Option erronée" arr["CATALAN",76]="Opció del menú no vàlida" - arr["PORTUGUESE",76]="Opção do menu inválida" + arr["PORTUGUESE",76]="Opção inválida" arr["RUSSIAN",76]="Выбрана недействительная опция" arr["GREEK",76]="Επιλέχθηκε άκυρη επιλογή μενού" @@ -1211,7 +1219,7 @@ function language_strings() { arr["SPANISH",85]="Enviadme errores o sugerencias a ${mail}" arr["FRENCH",85]="Envoyer des erreurs ou des suggestions à ${mail}" arr["CATALAN",85]="Envieu-me errorrs o suggeriments a ${mail}" - arr["PORTUGUESE",85]="Enviar erros ou sugestões para ${mail}" + arr["PORTUGUESE",85]="Envie erros ou sugestões para ${mail}" arr["RUSSIAN",85]="Отправляйте ошибки и предложения мне на почту ${mail}" arr["GREEK",85]="Στείλτε μου αναφορές για bugs ή συστάσεις στο ${mail}" @@ -1499,7 +1507,7 @@ function language_strings() { arr["SPANISH",121]="5. Capturar Handshake" arr["FRENCH",121]="5. Capture du Handshake" arr["CATALAN",121]="5. Captura Handshake" - arr["PORTUGUESE",121]="5. Captura de Handshake" + arr["PORTUGUESE",121]="5. Capturar Handshake" arr["RUSSIAN",121]="5. Захват рукопожатия" arr["GREEK",121]="5. Καταγράψτε την Χειραψία" @@ -1523,7 +1531,7 @@ function language_strings() { arr["SPANISH",124]="modo monitor requerido en captura" arr["FRENCH",124]="modo moniteur nécessaire pour la capture" arr["CATALAN",124]="mode monitor requerit en captura" - arr["PORTUGUESE",124]="Modo de monitor necessário para captura" + arr["PORTUGUESE",124]="Modo monitor necessário para captura" arr["RUSSIAN",124]="для захвата необходим режим монитора" arr["GREEK",124]="χρειάζεται η κατάσταση παρακολούθησης για την καταγραφή" @@ -1531,7 +1539,7 @@ function language_strings() { arr["SPANISH",125]="No hay una red objetivo válida seleccionada. Serás redirigido para seleccionar una" arr["FRENCH",125]="Le choix du réseau cible est incorrect. Vous allez être redirigé vers le menu de sélection pour effectuer un nouveau choix" arr["CATALAN",125]="No hi ha una xarxa objectiu vàlida seleccionada. Seràs redirigit per seleccionar una" - arr["PORTUGUESE",125]="Nenhuma rede válida selecionada. Você será redirecionado para selecionar um" + arr["PORTUGUESE",125]="Nenhuma rede válida selecionada. Você será redirecionado para selecionar uma" arr["RUSSIAN",125]="Не выбрана подходящая целевая сеть. Вы будете перенаправлены на выбор сети" arr["GREEK",125]="Δεν έχει επιλεχθεί κάποιο έγκυρο δίκτυο-στόχος. Θα καθοδηγηθείτε ώστε να επιλέξετε ένα" @@ -1555,7 +1563,7 @@ function language_strings() { arr["SPANISH",128]="Selecciona una interfaz wifi para poder realizar más acciones que con una interfaz ethernet" arr["FRENCH",128]="Veuillez sélectionner une carte wifi au lieu d'une carte ethernet afin d'être en mesure de réaliser plus d'actions" arr["CATALAN",128]="Seleccioneu una targeta wifi per treballar amb la finalitat de ser capaç de fer més accions que amb una interfície ethernet" - arr["PORTUGUESE",128]="Selecione uma interface wifi para realizar mais ações do que com interface ethernet" + arr["PORTUGUESE",128]="Selecione uma interface wifi para realizar mais ações do que com uma interface ethernet" arr["RUSSIAN",128]="Выберите wifi карту для работы, чтобы вы могли выполнить больше действий, чем с ethernet интерфейсом" arr["GREEK",128]="Επιλέξτε κάρτα wifi ώστε να μπορείτε να έχετε περισσοτερες επιλογές από μία διεπαφή ethernet" @@ -1587,7 +1595,7 @@ function language_strings() { arr["SPANISH",132]="Limpiar un fichero de Handshake se recomienda solo para ficheros grandes. Es mejor hacer una copia de seguridad antes, a veces el fichero se puede corromper al limpiarlo" arr["FRENCH",132]="Épurer le fichier contenant le Handshake est seulement recommandable si le fichier est volumineux. Si vous décidez d'épurer le fichier il est conseillé de faire une copie de sauvegarde du fichier originel, l'opération de nettoyage comporte des risques et peut le rendre illisible" arr["CATALAN",132]="Netejar un fitxer de Handshake es recomana només per a fitxers grans. És millor fer una còpia de seguretat abans, de vegades el fitxer es pot corrompre al netejar-lo" - arr["PORTUGUESE",132]="Limpar um Handshake é recomendado apenas para arquivos grandes. Melhor fazer um backup antes de otimizar o arquivo; as vezes pode corromper o arquivo ao limpar" + arr["PORTUGUESE",132]="Limpar um Handshake é recomendado apenas para arquivos grandes. Melhor fazer um backup antes de otimizar o arquivo; as vezes o arquivo pode corromper ao limpar" arr["RUSSIAN",132]="Очистка файла рукопожатия рекомендована только для файлов больших размеров. Лучше иметь резервную копию, иногда во время очистки файл может быть повреждён" arr["GREEK",132]="Ο καθαρισμός ενός αρχείου Χειραψίας συνιστάται μόνο για μεγάλου μεγέθους αρχεία. Καλύτερα κρατήστε ένα backup, μερικές φορές το αρχείο μπορεί να καταστραφεί κατά τη διάρκεια του καθαρισμού" @@ -1603,7 +1611,7 @@ function language_strings() { arr["SPANISH",134]="Si tu Linux es una máquina virtual, es posible que las tarjetas wifi integradas sean detectadas como ethernet. Utiliza una tarjeta wifi externa usb" arr["FRENCH",134]="Si votre système d'exploitation Linux est lancé dans une machine virtuelle, il est probable que les cartes wifi internes soient détectées comme des cartes ethernet. Il vaut mieux dans ce cas utiliser un dispositif wifi usb" arr["CATALAN",134]="Si el teu Linux és a una màquina virtual, és possible que les targetes wifi integrades siguin detectades com ethernet. Utilitza una targeta wifi externa usb" - arr["PORTUGUESE",134]="Se seu Linux é uma máquina virtual, suas placas wireless integradas são detectadas como ethernet. Use uma placa usb externa" + arr["PORTUGUESE",134]="Se seu Linux for uma máquina virtual, suas placas wireless integradas são detectadas como ethernet. Use uma placa usb externa" arr["RUSSIAN",134]="Если ваш Linux в виртуально машине, то интегрированная wifi карта может определиться как Ethernet. Используйте внешнюю usb wifi карту" arr["GREEK",134]="Αν το Linux σας είναι εικονική μηχανή, είναι πιθανόν οι ενσωματωμένες κάρτες wifi να εντοπιστούν σαν ethernet. Χρησιμοποιήστε μία εξωτερική usb κάρτα wifi" @@ -1619,7 +1627,7 @@ function language_strings() { arr["SPANISH",136]="La obtención de un Handshake es solo para redes con encriptación WPA o WPA2" arr["FRENCH",136]="L'obtention d'un Handshake est seulement possible sur des réseaux protégés par chiffrement WPA ou WPA2" arr["CATALAN",136]="L'obtenció d'un Handshake és només per a xarxes amb encriptació WPA o WPA2" - arr["PORTUGUESE",136]="A obtenção de um Handshake é somente para redes com criptografia WPA ou WPA2" + arr["PORTUGUESE",136]="A obtenção de um Handshake só é possível em redes com criptografia WPA ou WPA2" arr["RUSSIAN",136]="Получение рукопожатия только для сетей с шифрованием WPA или WPA2" arr["GREEK",136]="Η απόκτηση μιας Χειραψίας ισχύει μόνο σε δίκτυα με κρυπτογράφηση WPA ή WPA2" @@ -1683,7 +1691,7 @@ function language_strings() { arr["SPANISH",144]="No cierres manualmente ninguna ventana, el script lo hará cuando proceda. En unos 20 segundos como máximo sabrás si conseguiste el Handshake" arr["FRENCH",144]="Ne pas fermer une des fenêtres manuellement: Le script va le faire automatiquement si besoin est. Vos saurez dans tout a plus 20 secondes si avez obtenu le Handshake" arr["CATALAN",144]="No tanquis manualment cap finestra, el script ho farà quan escaigui. En uns 20 segons com a màxim sabràs si vas aconseguir el Handshake" - arr["PORTUGUESE",144]="Não feche nenhuma janela manualmente, o script fechara quando necessário. Em cerca de 20 segundos no máximo você vai saber se você tem o Handshake" + arr["PORTUGUESE",144]="Não feche nenhuma janela manualmente, o script fechara quando necessário. Em cerca de 20 segundos no máximo você vai saber se tem o Handshake" arr["RUSSIAN",144]="Не закрывайте вручную какое-либо окно, скрипт сделает это когда нужно. Примерно в максимум 20 секунд вы узнаете, получили ли вы рукопожатие" arr["GREEK",144]="Μην επιχειρήσετε το κλείσιμο κάποιου παραθύρου χειροκίνητα, εάν χρειαστεί το script θα το κάνει μόνο του. Σε περίπου 20 δευτερόλεπτα το μέγιστο θα μάθετε αν αποκτήσατε την Χειραψία" @@ -1763,7 +1771,7 @@ function language_strings() { arr["SPANISH",154]="Introduce la ruta al fichero :" arr["FRENCH",154]="Entrez le chemin vers le fichier :" arr["CATALAN",154]="Introdueix la ruta al fitxer :" - arr["PORTUGUESE",154]="Digite o caminho para o arquivo :" + arr["PORTUGUESE",154]="Digite o caminho do arquivo :" arr["RUSSIAN",154]="Установить путь до файла :" arr["GREEK",154]="Θέστε μονοπάτι για το αρχείο :" @@ -1771,7 +1779,7 @@ function language_strings() { arr["SPANISH",155]="El directorio existe pero no se especificó nombre de fichero. Se autogenerará [${normal_color}${suggested_filename}${yellow_color}]" arr["FRENCH",155]="Le dossier existe mais sans qu'aucun nom pour le fichier soit précisé. Il sera donc appelé [${normal_color}${suggested_filename}${yellow_color}]" arr["CATALAN",155]="El directori existeix però no s'ha especificat nom de fitxer. Es autogenerará [${normal_color}${suggested_filename}${yellow_color}]" - arr["PORTUGUESE",155]="O diretório existe, mas o nome do arquivo não foi especificado. Será gerado automaticamente [${normal_color}${suggested_filename}${yellow_color}]" + arr["PORTUGUESE",155]="O diretório existe, mas o nome do arquivo não foi especificado. Será gerado automaticamente [${normal_color}${suggested_filename}${yellow_color}]" arr["RUSSIAN",155]="Директория существует, но вы не указали имя файла. Оно будет сгенерировано автоматически [${normal_color}${suggested_filename}${yellow_color}]" arr["GREEK",155]="Ο κατάλογος υπάρχει αλλά δεν έχετε προσδιορίσει το όνομα του αρχείου [${normal_color}${suggested_filename}${yellow_color}]" @@ -1803,7 +1811,7 @@ function language_strings() { arr["SPANISH",159]="El fichero no necesita ser limpiado/optimizado" arr["FRENCH",159]="Le fichier n'a pas besoin d'être nettoyé/optimisé" arr["CATALAN",159]="El fitxer no necessita ser netejat/optimitzat" - arr["PORTUGUESE",159]="O arquivo não precisa ser limpos/otimizado" + arr["PORTUGUESE",159]="O arquivo não precisa ser limpo/otimizado" arr["RUSSIAN",159]="Файлу не требуется очистка/оптимизация" arr["GREEK",159]="Το αρχείο δεν χρειάζεται να καθαριστεί/βελτιστοποιηθεί" @@ -1955,7 +1963,7 @@ function language_strings() { arr["SPANISH",178]="Para desencriptar la clave de una red WPA/WPA2, el fichero de captura debe contener un Handshake" arr["FRENCH",178]="Pour cracker la clé d'un réseau WPA/WPA2 le fichier de capture doit contenir un Handshake" arr["CATALAN",178]="Per desencriptar la clau d'una xarxa WPA/WPA2 el fitxer de captura ha de contenir un Handshake" - arr["PORTUGUESE",178]="Para decifrar a senha de rede WPA/WPA2, o arquivo de captura deve conter um Handshake" + arr["PORTUGUESE",178]="Para decifrar a senha de uma rede WPA/WPA2, o arquivo de captura deve conter um Handshake" arr["RUSSIAN",178]="Для расшифровки ключа сетей WPA/WPA2, файл захвата должен содержать четырёхэтапное рукопожатие" arr["GREEK",178]="Για να αποκρυπτογραφήσετε το κλειδί ενός WPA/WPA2 δικτύου, το αρχείο καταγραφής πρέπει να περιέχει μία Χειραψία" @@ -2057,7 +2065,7 @@ function language_strings() { arr["ENGLISH",191]="${blue_color}airgeddon can't find the directory path where you have BeEF installed. ${green_color}Do you want to enter it manually? ${normal_color}[y/n]" arr["SPANISH",191]="${blue_color}airgeddon no ha podido encontrar la ruta del directorio donde tienes instalado BeEF. ${green_color}¿Quieres introducirla manualmente? ${normal_color}[y/n]" - arr["FRENCH",191]="${pending_of_translation} ${blue_color}airgeddon n'a pas pu trouver le chemin vers le répertoire où vous avez installé BeEF. ${green_color}Voulez-vous entrer manuellement? ${normal_color}[y/n]" + arr["FRENCH",191]="${blue_color}airgeddon n'a pas trouvé le dossier qui contient BeEF. ${green_color}Voulez-vous l'indiquer manuellement? ${normal_color}[y/n]" arr["CATALAN",191]="${blue_color}airgeddon no ha pogut trobar la ruta del directori on tens instal·lat BeEF. ${green_color}¿Vols introduir-la manualment? ${normal_color}[y/n]" arr["PORTUGUESE",191]="${blue_color}O airgeddon não conseguiu encontrar o diretório onde você instalou o BeEF. ${green_color}Você quer inseri-lo manualmente? ${normal_color}[y/n]" arr["RUSSIAN",191]="${blue_color}airgeddon не может найти путь к каталогу, где вы установили BeEF. ${green_color}Вы хотите ввести его вручную? ${normal_color}[y/n]" @@ -2203,7 +2211,7 @@ function language_strings() { arr["SPANISH",209]="El juego de caracteres elegido es : [${normal_color}${showcharset}${blue_color}]" arr["FRENCH",209]="Le jeu de caractères définit est : [${normal_color}${showcharset}${blue_color}]" arr["CATALAN",209]="El joc de caràcters escollit és : [${normal_color}${showcharset}${blue_color}]" - arr["PORTUGUESE",209]="O conjunto de caracteres é:: [${normal_color}${showcharset}${blue_color}]" + arr["PORTUGUESE",209]="Conjunto de caracteres escolhido : [${normal_color}${showcharset}${blue_color}]" arr["RUSSIAN",209]="Символы для использования : [${normal_color}${showcharset}${blue_color}]" arr["GREEK",209]="Η συμβολοσειρά που θα χρησιμοποιηθεί είναι : [${normal_color}${showcharset}${blue_color}]" @@ -2235,7 +2243,7 @@ function language_strings() { arr["SPANISH",213]="Existe una nueva versión del script (v${airgeddon_last_version}). Será descargada" arr["FRENCH",213]="Une nouvelle version du script est disponible (v${airgeddon_last_version}). Lancement du téléchargement" arr["CATALAN",213]="Hi ha una nova versió dels script (v${airgeddon_last_version}). Serà descarregada" - arr["PORTUGUESE",213]="Uma nova versão do script (v${airgeddon_last_version}). Download será iniciado" + arr["PORTUGUESE",213]="Existe uma nova versão do script (v${airgeddon_last_version}). Download será iniciado" arr["RUSSIAN",213]="Существует новая версия скрипта (v${airgeddon_last_version}). Она будет загружена" arr["GREEK",213]="Υπάρχει νεότερη έκδοση του script (v${airgeddon_last_version}). Θα κατέβει" @@ -2251,7 +2259,7 @@ function language_strings() { arr["SPANISH",215]="Una contraseña WPA/WPA2 siempre tiene como mínimo una longitud de 8" arr["FRENCH",215]="Un mot de passe WPA/WPA2 a une longueur minimale de 8 caractères" arr["CATALAN",215]="Una contrasenya WPA/WPA2 sempre té com a mínim una longitud de 8" - arr["PORTUGUESE",215]="Uma senha WPA/WPA2 sempre tem no mínimo 8 caracteres" + arr["PORTUGUESE",215]="Uma senha WPA/WPA2 deve ter no mínimo 8 caracteres" arr["RUSSIAN",215]="WPA/WPA2 пароли всегда имеют длину минимум в 8 символов" arr["GREEK",215]="οι κωδικοί πρόσβασης WPA/WPA2 έχουν πάντα ελάχιστο μήκος 8" @@ -2259,7 +2267,7 @@ function language_strings() { arr["SPANISH",216]="No se encontraron redes con Handshake capturado en el fichero seleccionado" arr["FRENCH",216]="Aucun réseau avec son Handshake n'a été trouvé dans le fichier sélectionné" arr["CATALAN",216]="No s'han trobat xarxes amb Handshake capturat en el fitxer seleccionat" - arr["PORTUGUESE",216]="Nenhuma rede encontrada no arquivo Handshake capturado no arquivo selecionado" + arr["PORTUGUESE",216]="Nenhuma rede encontrada no arquivo Handshake selecionado " arr["RUSSIAN",216]="В выбранном файле сети с захваченным рукопожатием не найдены" arr["GREEK",216]="Δεν βρέθηκαν δίκτυα με Χειραψία στο επιλεγμένο αρχείο" @@ -2403,7 +2411,7 @@ function language_strings() { arr["SPANISH",234]="Enhorabuena!! Parece que la clave ha sido desencriptada" arr["FRENCH",234]="Félicitations!! Il semble que la clef a été décryptée" arr["CATALAN",234]="Enhorabona!! Sembla que la clau ha estat desencriptada" - arr["PORTUGUESE",234]="Parabéns!! Parece que a senha foi descriptografada" + arr["PORTUGUESE",234]="Parabéns!! Parece que a senha foi descriptografada" arr["RUSSIAN",234]="Поздравления!! Похоже на то, что ключ был расшифрован" arr["GREEK",234]="Συγχαρητήρια!! Φαίνεται πως το κλειδί αποκρυπτογραφήθηκε" @@ -2411,7 +2419,7 @@ function language_strings() { arr["SPANISH",235]="¿Quieres guardar el fichero de trofeo con la clave desencriptada? ${normal_color}[y/n]" arr["FRENCH",235]="Voulez-vous enregistrer le fichier trophée avec le mot de passe déchiffré? ${normal_color}[y/n]" arr["CATALAN",235]="¿Vols desar el fitxer de trofeu amb la clau desencriptada? ${normal_color}[y/n]" - arr["PORTUGUESE",235]="Você quer salvar arquivo com a senha descriptografado? ${normal_color}[y/n]" + arr["PORTUGUESE",235]="Você quer salvar arquivo com a senha descriptografada? ${normal_color}[y/n]" arr["RUSSIAN",235]="Вы хотите сохранить трофейный файл с расшифрованным паролем? ${normal_color}[y/n]" arr["GREEK",235]="Θέλετε να αποθηκεύσετε το αρχείο τρόπαιο με τον αποκρυπτογραφημένο κωδικό πρόσβασης; ${normal_color}[y/n]" @@ -2475,7 +2483,7 @@ function language_strings() { arr["SPANISH",243]="Fichero de reglas seleccionado: ${pink_color}${RULES}${normal_color}" arr["FRENCH",243]="Fichier règles sélectionné: ${pink_color}${RULES}${normal_color}" arr["CATALAN",243]="Fitxer de regles seleccionat: ${pink_color}${RULES}${normal_color}" - arr["PORTUGUESE",243]="Arquivo regras selecionadas: ${pink_color}${RULES}${normal_color}" + arr["PORTUGUESE",243]="Arquivo de regras selecionado: ${pink_color}${RULES}${normal_color}" arr["RUSSIAN",243]="Выбранный файл правил: ${pink_color}${RULES}${normal_color}" arr["GREEK",243]="Επιλεγμένο αρχείο κανόνων: ${pink_color}${RULES}${normal_color}" @@ -2483,7 +2491,7 @@ function language_strings() { arr["SPANISH",244]="Los ataques basados en reglas modifican las palabras de la lista del diccionario según las reglas escritas en el propio fichero de reglas. Son muy útiles. Algunas distros ya traen ficheros predefinidos de reglas (Kali: /usr/share/hashcat/rules // Wifislax: /opt/hashcat/rules)" arr["FRENCH",244]="Les attaques basées sur des règles modifient les mots du dictionnaire selon les règles établies dans le fichier règles. Ils sont très utiles. Certaines distros comportent des fichiers de règles prédéfinies (Kali: /usr/share/hashcat/rules // Wifislax: /opt/hashcat/rules)" arr["CATALAN",244]="Els atacs basats en regles modifiquen les paraules de la llista del diccionari segons les regles escrites en el propi fitxer de regles. Són molt útils. Algunes distros ja porten fitxers de regles predefinits (Kali: /usr/share/hashcat/rules // Wifislax: /opt/hashcat/rules)" - arr["PORTUGUESE",244]="Ataques baseados em regras mudaram as palavras de um dicionário de acordo com as regras escritas. Eles são muito úteis. Algumas distros já possuem regras predefinidas em (Kali: /usr/share/hashcat/rules // Wifislax: /opt/hashcat/rules)" + arr["PORTUGUESE",244]="Ataques baseados em regras mudam as palavras de um dicionário de acordo com as regras escritas. Eles são muito úteis. Algumas distros já possuem regras predefinidas em (Kali: /usr/share/hashcat/rules // Wifislax: /opt/hashcat/rules)" arr["RUSSIAN",244]="Атака, основанная на правилах, изменяет слова из словаря в соответствии с правилами, написанными в самом файле правил. Они очень полезны. Некоторые дистрибутивы имеют предустановленные правила (Kali: /usr/share/hashcat/rules // Wifislax: /opt/hashcat/rules)" arr["GREEK",244]="Οι επιθέσεις κανόνων αλλάζουν τις λέξεις του λεξικού ανάλογα με τους κανόνες που έχουν γραφτεί στο αρχείο κανόνων. Είναι πολύ χρήσιμοι. Κάποιες διανομές έχουν προκαθορισμένα αρχεία κανόνων (Kali: /usr/share/hashcat/rules // Wifislax: /opt/hashcat/rules)" @@ -2499,7 +2507,7 @@ function language_strings() { arr["SPANISH",246]="Cada vez que veas un texto con el prefijo ${cyan_color}${pending_of_translation}${pink_color} acrónimo de \"Pending of Translation\", significa que su traducción ha sido generada automáticamente y que aún está pendiente de revisión" arr["FRENCH",246]="Chaque fois que vous voyez un texte précédé par ${cyan_color}${pending_of_translation}${pink_color} acronyme de \"Pending of Translation\" cela signifie que la traduction a été faite automatiquement et est en attente de correction" arr["CATALAN",246]="Cada vegada que vegis un text amb el prefix ${cyan_color}${pending_of_translation}${pink_color} acrònim de \"Pending of Translation\", vol dir que la traducció ha estat generada automàticament i encara està pendent de revisió" - arr["PORTUGUESE",246]="Cada vez que você vê um texto com o prefixo ${cyan_color}${pending_of_translation}${pink_color} acrônimo para \"Pending of Translation\" significa que a tradução foi gerado automaticamente e ainda está pendente de revisão" + arr["PORTUGUESE",246]="Cada vez que você ver um texto com o prefixo ${cyan_color}${pending_of_translation}${pink_color} acrônimo para \"Pending of Translation\" significa que a tradução foi gerado automaticamente e ainda está pendente de revisão" arr["RUSSIAN",246]="Каждый раз, когда вы видите текст с префиксом ${cyan_color}${pending_of_translation}${pink_color} (акроним для \"Ожидает перевода\"), это означает, что перевод был сгенерирован автоматически и ещё ожидает проверки" arr["GREEK",246]="Κάθε φορά που θα βλέπετε κείμενο με πρόθεμα ${cyan_color}${pending_of_translation}${pink_color} ακρωνύμιο για \"Pending of Translation\", σημαίνει πως η μετάφραση δημιουργήθηκε αυτόματα και αναμένεται κριτική" @@ -2529,7 +2537,7 @@ function language_strings() { arr["ENGLISH",250]="If you see any bad translation or just want ${cyan_color}${pending_of_translation}${pink_color} marks to dissapear, write me to ${mail} to collaborate with translations" arr["SPANISH",250]="Si ves alguna traducción incorrecta o quieres que desparezcan las marcas ${cyan_color}${pending_of_translation}${pink_color}, escríbeme a ${mail} para colaborar con las traducciones" - arr["FRENCH",250]="Si vous voyez des erreurs contresens ou voulez voir les marques ${cyan_color}${pending_of_translation}${pink_color} disparaitre, écrivez à ${mail} pour collaborer avec les traductions" + arr["FRENCH",250]="Si vous voyez des erreurs et contresens ou si vous voulez voir les marques ${cyan_color}${pending_of_translation}${pink_color} disparaitre, écrivez à ${mail} pour collaborer avec les traductions" arr["CATALAN",250]="Si veus alguna traducció incorrecta o vols que desapareguin les marques ${cyan_color}${pending_of_translation}${pink_color}, escriu-me a ${mail} per col·laborar amb les traduccions" arr["PORTUGUESE",250]="Se você ver qualquer erro de tradução ou quer que as marcas ${cyan_color}${pending_of_translation}${pink_color} sejam retiradas, escreva para ${mail} para colaborar com as traduções" arr["RUSSIAN",250]="Если вы видите плохой перевод или просто хотите снять пометку ${cyan_color}${pending_of_translation}${pink_color} напишите мне на ${mail} для сотрудничества с переводчиками" @@ -2643,7 +2651,7 @@ function language_strings() { arr["SPANISH",264]="El ataque del portal cautivo intentará conseguir que uno de los clientes de la red nos proporcione la contraseña de la red wifi introduciéndola en nuestro portal" arr["FRENCH",264]="Le portail captif d'attaque tente d'obtenir l'un des clients du réseau nous fournir le mot de passe pour le réseau sans fil en entrant sur notre site" arr["CATALAN",264]="L'atac de portal captiu intenta aconseguir que un dels clients de la xarxa ens proporcioni la contrasenya de la xarxa wifi introduint-la al nostre portal" - arr["PORTUGUESE",264]="O ataque com portal cativo tenta fazer com que um dos clientes da rede nos forneça a senha da rede sem fio digitando-o em nosso site" + arr["PORTUGUESE",264]="O ataque com portal cativo tenta fazer com que um dos clientes da rede nos forneça a senha da rede sem fio digitando-o em nosso site" arr["RUSSIAN",264]="Атака с перехватывающим порталом заключается в том, что мы ждём когда кто-то из пользователей введёт верный пароль от Wi-Fi на веб-странице, которую мы ему показываем" arr["GREEK",264]="Η επίθεση captive portal κάνει έναν από τους χρήστες του δικτύου να μας παρέχει τον κωδικό πρόσβασης του δικτύου wifi βάζοντάς τον στο portal μας" @@ -2684,7 +2692,7 @@ function language_strings() { arr["FRENCH",269]="Pour mener à bien une attaque Evil Twin il vous faut être dans de bonnes conditions d'émission et de réception tantôt avec le point d'accès qu'avec le(s) client(s)" arr["CATALAN",269]="Per realitzar un atac Evil Twin et caldrà estar molt a prop de l'AP objectiu o tenir una antena wifi molt potent. El teu senyal ha d'arribar als clients igual de fort o més que la de l'AP legítim" arr["PORTUGUESE",269]="Para fazer um ataque Evil Twin você precisa estar perto do alvo ou ter uma antena wifi muito poderosa. Seu sinal deve atingir os clientes igualmente forte ou mais do que o AP legítimo" - arr["RUSSIAN",269]="Для выполнения атаки злой двойник, вы должны быть очень близко к целевой ТД или иметь очень мощную wifi антенну. Ваш сигнал должен достигать клиентов с такой же силой, или даже сильнее, чем легитимная ТД" + arr["RUSSIAN",269]="Для выполнения атаки злой двойник, вы должны быть очень близко к целевой ТД или иметь очень мощную wifi антенну. Ваш сигнал должен достигать клиентов с такой же силой, или даже сильнее, чем легитимная ТД" arr["GREEK",269]="Για να πραγματοποιηθεί μία επίθεση Evil Twin θα πρέπει να είστε αρκετά κοντά στο AP-στόχο ή να έχετε μία πολύ ισχυρή κεραία. Το σήμα πρέπει να φτάνει στους χρήστες το ίδιο ή περισσότερο από το αρχικό AP" arr["ENGLISH",270]="Evil Twin attack just AP" @@ -3677,7 +3685,7 @@ function language_strings() { arr["CATALAN",393]="Escriu un valor en segons (10-100) per al temps d'espera o prem [Enter] per acceptar el valor proposat [${normal_color}${timeout_secs_per_pin}${green_color}] :" arr["PORTUGUESE",393]="Insira um valor em segundos (10-100) para o timeout ou pressione [Enter] para aceitar o valor padrão [${normal_color}${timeout_secs_per_pin}${green_color}] :" arr["RUSSIAN",393]="Введите значение в секундах (10-100) для тайм-аута или нажмите [Enter], чтобы оставить по умолчанию [${normal_color}${timeout_secs_per_pin}${green_color}] :" - arr["GREEK",393]="Εισάγετε μια τιμή σε δευτερόλεπτα (10-100) για το timeout ή πατήστε [Enter] για να τεθεί η προεπιλεγμένη τιμή [${normal_color}${timeout_secs_per_pin}${green_color}] :" + arr["GREEK",393]="Εισάγετε μια τιμή σε δευτερόλεπτα (10-100) για το timeout ή πατήστε [Enter] για να τεθεί η προεπιλεγμένη τιμή [${normal_color}${timeout_secs_per_pin}${green_color}] :" arr["ENGLISH",394]="Type value in seconds (25-2400) for Pixie Dust timeout or press [Enter] to accept the proposal [${normal_color}${timeout_secs_per_pixiedust}${green_color}] :" arr["SPANISH",394]="Escribe un valor en segundos (25-2400) para el timeout de Pixie Dust o pulsa [Enter] para aceptar el valor propuesto [${normal_color}${timeout_secs_per_pixiedust}${green_color}] :" @@ -3777,7 +3785,7 @@ function language_strings() { arr["ENGLISH",406]="No BeEF executable was detected in given directory" arr["SPANISH",406]="No se ha detectado un ejecutable de BeEF en el directorio indicado" - arr["FRENCH",406]="BeEF n'est pas présent dans le dossierque vous avez indiqué" + arr["FRENCH",406]="BeEF n'est pas présent dans le dossier que vous avez indiqué" arr["CATALAN",406]="No s'ha detectat un executable de BeEF al directori indicat" arr["PORTUGUESE",406]="O executável do BeEF não foi detectado no diretório especificado" arr["RUSSIAN",406]="Ни один исполняемый файл BeEF не был обнаружен в заданной директории" @@ -3785,7 +3793,7 @@ function language_strings() { arr["ENGLISH",407]="BeEF preparation" arr["SPANISH",407]="Preparación BeEF" - arr["FRENCH",407]="${pending_of_translation} Préparation BeEF" + arr["FRENCH",407]="Mise en place de BeEF" arr["CATALAN",407]="Preparació BeEF" arr["PORTUGUESE",407]="Preparando BeEF" arr["RUSSIAN",407]="Подготовка BeEF" @@ -3795,7 +3803,7 @@ function language_strings() { arr["SPANISH",408]="Si instalaste BeEF manualmente, puede que airgeddon no sea capaz de encontrarlo y la opción del ataque te aparezca restringida. Puedes intentar solucionarlo usando la opción del menú especial para ello. Esto sólo funcionará si BeEF ya está instalado correctamente y el único problema que tienes es que el script no lo detecta" arr["FRENCH",408]="Si BeEF a été installé manuellement, il se peut qu'airgeddon ne soit pas en mesure de le trouver. L'option dédiée ne sera pas accessible. Vous pouvez essayer de la réparer en utilisant l'option consacrée à cette tâche depuis le menu spécial. Ça ne marchera que si BeEf est correctement instalé et c'est le script qui n'est pas capable de le détecter" arr["CATALAN",408]="Si vas instal·lar BeEF manualment, pot ser que airgeddon no sigui capaç de trobar-lo i l'opció de l'atac t'aparegui restringida. Pots intentar solucionar usant l'opció del menú especial per a això. Això només funcionarà si BeEF ja està instal·lat correctament i l'únic problema que tens és que el script no el detecta" - arr["PORTUGUESE",408]="Se BeEF foi instalado manualmente, o airgeddon não pode encontrá-lo automaticamente e a opção de ataque aparecerá bloqueada. Você pode tentar corrigi-lo usando a opção de menu especial para isso. Isso só vai funcionar se BeEF já está instalado com êxito e o único problema que você tem é que o script não o detecta" + arr["PORTUGUESE",408]="Se BeEF foi instalado manualmente, o airgeddon não pode encontrá-lo automaticamente e a opção de ataque aparecerá bloqueada. Você pode tentar corrigi-lo usando a opção de menu especial para isso. Isso só vai funcionar se BeEF já está instalado com êxito e o único problema que você tem é que o script não o detecta" arr["RUSSIAN",408]="Если вы установили BeEF вручную, airgeddon может быть не в состоянии найти его, и опция атаки в меню может быть ограничена. Для исправления этого, вы можете попытаться решить эту проблему с помощью специального пункта меню. Это сработает только если BeEF уже правильно установлен, и ваша единственная проблема в том, что скрипт не обнаруживает его" arr["GREEK",408]="Εάν έχετε εγκαταστήσει χειροκίνητα το BeEF, το airgeddon μπορεί να μην μπορέσει να το βρεί και η επιλογή της επίθεσης μπορεί να φανεί σαν περιορισμένη. Μπορείτε να προσπαθήσετε να διορθώσετε το πρόβλημα κάνοντας χρήση της ειδικής επιλογής στο μενού. Θα λειτουργήσει μόνο αν το BeEF έχει ήδη εγκατασταθεί σωστά και το μόνο πρόβλημα είναι ότι το script δεν το εντοπίζει" @@ -3809,7 +3817,7 @@ function language_strings() { arr["ENGLISH",410]="2. Try to troubleshoot manually installed BeEF dependency problem" arr["SPANISH",410]="2. Intentar solucionar problema de dependencia BeEF instalado manualmente" - arr["FRENCH",410]="2. Essayez de résoudre le problème BeEF installé manuellement" + arr["FRENCH",410]="2. Essayer de résoudre les problèmes de dépendances avec BeEF installé manuellement" arr["CATALAN",410]="2. Intentar solucionar problema de dependència BeEF instal·lat manualment" arr["PORTUGUESE",410]="2. Tente resolver o problema de dependência do BeEF instalado manualmente" arr["RUSSIAN",410]="2. Попробуйте устранить проблему вручную установив зависимости BeEF" @@ -3849,7 +3857,7 @@ function language_strings() { arr["ENGLISH",415]="${blue_color}airgeddon knows you have BeEF installed and you pass the validation, but it was unable to locate the right directory path where you have BeEF installed. Knowing the location gives some advantages for the execution because its configuration file can be customized instead of generic. ${green_color}Do you want to enter it manually? ${normal_color}[y/n]" arr["SPANISH",415]="${blue_color}airgeddon sabe que tienes BeEF instalado y pasas la validación, pero no ha podido concretar la ruta del directorio exacto donde tienes instalado BeEF. Conocer la localización exacta tiene algunas ventajas a la hora de ejecutarlo ya que la configuración será personalizada en lugar de ser una configuración genérica. ${green_color}¿Quieres introducirla manualmente? ${normal_color}[y/n]" - arr["FRENCH",415]="${pending_of_translation} ${blue_color}airgeddon sait que vous avez installé BeEF et les raisins secs validation, mais n'a pas pu indiquer le chemin exact du répertoire où vous avez installé BeEF. Connaître l'emplacement exact a certains avantages lors de l'exécution depuis la configuration sera personnalisée plutôt qu'une configuration générique. ${green_color}Voulez-vous entrer manuellement? ${normal_color}[y/n]" + arr["FRENCH",415]="${blue_color}airgeddon a bien détecté que BeEF est installé mais il n'est malheuruesement pas possible de trouver le dossier le contenant. En l'état actuel des choses il ne sera pas possible de personaliser les parmétres d'éxécution de BeEF. ${green_color}Voulez-vous saisir l'emplacement du dossier? ${normal_color}[y/n]" arr["CATALAN",415]="${blue_color}airgeddon sap que tens BeEF instal·lat i passes la validació, però no ha pogut concretar la ruta del directori exacte on has instal·lat BeEF. Conèixer la localització exacta té alguns avantatges a l'hora d'executar ja que la configuració serà personalitzada en lloc de ser una configuració genèrica. ${green_color}¿Vols introduir-la manualment? ${normal_color}[y/n]" arr["PORTUGUESE",415]="${blue_color}O airgeddon sabe que você instalou o BeEF e validou a instalacão, mas não pôde encontrar o caminho exato do diretório onde você instalou BeEF. Sabendo a localização exata tem algumas vantagens quando executá-lo a configuração será personalizada em vez de uma configuração genérica. ${green_color}Você quer inseri-lo manualmente? ${normal_color}[y/n]" arr["RUSSIAN",415]="${blue_color}airgeddon знает, что у вас установлен BeEF и вы успешно прошли проверку, но скрипт оказался не в состоянии найти правильный путь к каталогу, где вы установили BeEF. Знание расположения даёт некоторые преимущества при выполнении, поскольку появляется возможность настроить его конфигурационный файл, а не использовать настройки по умолчанию. ${green_color}Вы хотите ввести расположение вручную? ${normal_color}[y/n]" @@ -3857,11 +3865,19 @@ function language_strings() { arr["ENGLISH",416]=" You can run BeEF, but it is better if you run the second option before" arr["SPANISH",416]=" Puedes ejecutar BeEF, pero es recomendable ejecutar la segunda opción antes" - arr["FRENCH",416]="${pending_of_translation} Vous pouvez exécuter BeEF, mais il est recommandé d'exécuter la deuxième option de menu avant" + arr["FRENCH",416]=" Vous pouvez exécuter BeEF mais il est recommandé d'exécuter préalablement la deuxième option" arr["CATALAN",416]=" Pots executar BeEF, però és recomanable executar la segona opció del menú abans" arr["PORTUGUESE",416]=" Você pode executar BeEF, mas é recomendado executar a segunda opção de menu antes" arr["RUSSIAN",416]=" Вы можете запустить BeEF, но лучше, если вы сначала запустите вторую опцию" - arr["GREEK",416]=" Μπορείτε να εκτελέσετε το BeEF, αλλά είναι καλύτερα να διαλέξετε τη δεύτερη επιλογή από πριν" + arr["GREEK",416]=" Μπορείτε να εκτελέσετε το BeEF, αλλά είναι καλύτερα να διαλέξετε τη δεύτερη επιλογή από πρίν" + + arr["ENGLISH",417]="An unexpected error occurred, redirecting to the menu" + arr["SPANISH",417]="Ocurrió un error inesperado. Volviendo al menú" + arr["FRENCH",417]="${pending_of_translation} Une erreur inattendue s'est produite, retour au menu" + arr["CATALAN",417]="${pending_of_translation} Hi ha hagut un error inesperat, redirigint al menú" + arr["PORTUGUESE",417]="Ocorreu um erro inesperado, retornando ao menu" + arr["RUSSIAN",417]="${pending_of_translation} Непредвиденная ошибка, перенаправляя в меню" + arr["GREEK",417]="Παρουσιάστηκε μη αναμενόμενο σφάλμα, γίνεται ανακατεύθυνση στο μενού" case "${3}" in "yellow") @@ -3918,9 +3934,53 @@ function language_strings() { esac } +#Print the current line of where this was called and the function's name. Applies to some (which are useful) functions +function debug_print() { + + if [ ${debug_mode} -eq 2 ]; then + + declare excluded_functions=( + "ask_yesno" + "check_pending_of_translation" + "contains_element" + "echo_blue" + "echo_brown" + "echo_cyan" + "echo_green" + "echo_green_title" + "echo_pink" + "echo_red" + "echo_red_slim" + "echo_white" + "echo_yellow" + "generate_dynamic_line" + "interrupt_checkpoint" + "language_strings" + "last_echo" + "print_hint" + "print_large_separator" + "print_simple_separator" + "read_yesno" + "remove_warnings" + "special_text_missed_optional_tool" + "store_array" + "under_construction_message" + ) + + if (IFS=$'\n'; echo "${excluded_functions[*]}") | grep -qFx "${FUNCNAME[1]}"; then + return 1 + fi + + echo "Line:${BASH_LINENO[1]}" "${FUNCNAME[1]}" #TODO "${@}" to print parameters + return 0 + fi +} + #Set the message to show again after an interrupt ([Ctrl+C] or [Ctrl+Z]) without exiting function interrupt_checkpoint() { + debug_print + if [ -z "${last_buffered_type1}" ]; then last_buffered_message1=${1} last_buffered_message2=${1} @@ -3939,6 +3999,8 @@ function interrupt_checkpoint() { #Add the text on a menu when you miss an optional tool function special_text_missed_optional_tool() { + debug_print + declare -a required_tools=("${!3}") allowed_menu_option=1 @@ -3964,6 +4026,8 @@ function special_text_missed_optional_tool() { #Generate the chars in front of and behind a text for titles and separators function generate_dynamic_line() { + debug_print + local type=${2} if [ "${type}" = "title" ]; then ncharstitle=78 @@ -4005,6 +4069,8 @@ function generate_dynamic_line() { #Wrapper to check managed mode on an interface function check_to_set_managed() { + debug_print + check_interface_mode case "${ifacemode}" in "Managed") @@ -4026,6 +4092,8 @@ function check_to_set_managed() { #Wrapper to check monitor mode on an interface function check_to_set_monitor() { + debug_print + check_interface_mode case "${ifacemode}" in "Monitor") @@ -4047,6 +4115,8 @@ function check_to_set_monitor() { #Check for monitor mode on an interface function check_monitor_enabled() { + debug_print + mode=$(iwconfig "${interface}" 2> /dev/null | grep Mode: | awk '{print $4}' | cut -d ':' -f 2) if [[ ${mode} != "Monitor" ]]; then @@ -4061,6 +4131,8 @@ function check_monitor_enabled() { #Check if an interface is a wifi card or not function check_interface_wifi() { + debug_print + execute_iwconfig_fix return $? } @@ -4068,6 +4140,8 @@ function check_interface_wifi() { #Execute the iwconfig fix to know if an interface is a wifi card or not function execute_iwconfig_fix() { + debug_print + iwconfig_fix iwcmd="iwconfig ${interface} ${iwcmdfix} > /dev/null 2> /dev/null" eval "${iwcmd}" @@ -4078,6 +4152,8 @@ function execute_iwconfig_fix() { #Create a list of interfaces associated to its macs function renew_ifaces_and_macs_list() { + debug_print + readarray -t IFACES_AND_MACS < <(ip link | egrep "^[0-9]+" | cut -d ':' -f 2 | awk '{print $1}' | grep lo -v | grep "${interface}" -v) declare -gA ifaces_and_macs for iface_name in "${IFACES_AND_MACS[@]}"; do @@ -4096,6 +4172,8 @@ function renew_ifaces_and_macs_list() { #Check the interface coherence between interface names and macs function check_interface_coherence() { + debug_print + renew_ifaces_and_macs_list interface_auto_change=0 @@ -4126,6 +4204,8 @@ function check_interface_coherence() { #Prepare the vars to be used on wps pin database attacks function set_wps_mac_parameters() { + debug_print + six_wpsbssid_first_digits=${wps_bssid:0:8} six_wpsbssid_first_digits_clean=${six_wpsbssid_first_digits//:} six_wpsbssid_last_digits=${wps_bssid: -8} @@ -4137,6 +4217,8 @@ function set_wps_mac_parameters() { #Calculate pin based on Zhao Chunsheng algorithm (computepin), step 1 function calculate_computepin_algorithm_step1() { + debug_print + hex_to_dec=$(printf '%d\n' 0x"${six_wpsbssid_last_digits_clean}") 2> /dev/null computepin_pin=$((hex_to_dec % 10000000)) } @@ -4144,12 +4226,16 @@ function calculate_computepin_algorithm_step1() { #Calculate pin based on Zhao Chunsheng algorithm (computepin), step 2 function calculate_computepin_algorithm_step2() { + debug_print + computepin_pin=$(printf '%08d\n' $((10#${computepin_pin} * 10 + checksum_digit))) } #Calculate pin based on Stefan Viehböck algorithm (easybox) function calculate_easybox_algorithm() { + debug_print + hex_to_dec=($(printf "%04d" "0x${four_wpsbssid_last_digits_clean}" | sed 's/.*\(....\)/\1/;s/./& /g')) [[ ${four_wpsbssid_last_digits_clean} =~ ${four_wpsbssid_last_digits_clean//?/(.)} ]] && hexi=($(printf '%s\n' "${BASH_REMATCH[*]:1}")) @@ -4172,6 +4258,8 @@ function calculate_easybox_algorithm() { #Calculate the last digit on pin following the checksum rule function pin_checksum_rule() { + debug_print + current_calculated_pin=$((10#${1} * 10)) accum=0 @@ -4191,6 +4279,8 @@ function pin_checksum_rule() { #Manage the calls to check common wps pin algorithms function check_and_set_common_algorithms() { + debug_print + echo language_strings "${language}" 388 "blue" declare -g calculated_pins=("${wps_default_generic_pin}") @@ -4215,6 +4305,8 @@ function check_and_set_common_algorithms() { #Integrate calculated pins from algorithms into pins array function integrate_algorithms_pins() { + debug_print + some_calculated_pin_included=0 for pin in "${calculated_pins[@]}"; do this_pin_already_included=0 @@ -4241,6 +4333,8 @@ function integrate_algorithms_pins() { #Include the code of the pin database file function include_pin_dbfile() { + debug_print + dbfile_to_include="source \"${scriptfolder}${known_pins_dbfile}\"" eval "${dbfile_to_include}" } @@ -4248,6 +4342,8 @@ function include_pin_dbfile() { #Search for target wps bssid mac in pin database and set the vars to be used function search_in_pin_database() { + debug_print + bssid_found_in_db=0 counter_pins_found=0 declare -g pins_found=() @@ -4267,6 +4363,8 @@ function search_in_pin_database() { #Prepare monitor mode avoiding the use of airmon-ng or airmon-zc generating two interfaces from one function prepare_et_monitor() { + debug_print + disable_rfkill phy_iface=$(basename "$(readlink "/sys/class/net/${interface}/phy80211")") @@ -4281,6 +4379,8 @@ function prepare_et_monitor() { #Assure the mode of the interface before the Evil Twin process function prepare_et_interface() { + debug_print + et_initial_state=${ifacemode} if [ "${ifacemode}" != "Managed" ]; then @@ -4301,6 +4401,8 @@ function prepare_et_interface() { #Restore the state of the interfaces after Evil Twin process function restore_et_interface() { + debug_print + echo language_strings "${language}" 299 "blue" @@ -4326,6 +4428,8 @@ function restore_et_interface() { #Unblock if possible the interface if blocked function disable_rfkill() { + debug_print + if hash rfkill 2> /dev/null; then rfkill unblock all > /dev/null 2>&1 fi @@ -4334,6 +4438,8 @@ function disable_rfkill() { #Put the interface on managed mode and manage the possible name change function managed_option() { + debug_print + check_to_set_managed if [ "$?" != "0" ]; then @@ -4366,6 +4472,8 @@ function managed_option() { #Put the interface on monitor mode and manage the possible name change function monitor_option() { + debug_print + check_to_set_monitor if [ "$?" != "0" ]; then @@ -4413,6 +4521,8 @@ function monitor_option() { #Check the interface mode function check_interface_mode() { + debug_print + execute_iwconfig_fix if [ "$?" != "0" ]; then ifacemode="(Non wifi card)" @@ -4442,6 +4552,8 @@ function check_interface_mode() { #Language change menu function language_menu() { + debug_print + clear language_strings "${language}" 87 "title" current_menu="language_menu" @@ -4533,6 +4645,8 @@ function language_menu() { #Read the chipset for an interface function set_chipset() { + debug_print + chipset="" sedrule1="s/^....//" sedrule2="s/ Network Connection//g" @@ -4551,10 +4665,10 @@ function set_chipset() { if [ -f "/sys/class/net/${1}/device/modalias" ]; then - bus_type=$(cat < "/sys/class/net/${1}/device/modalias" | cut -d ":" -f 1) + bus_type=$(cut -d ":" -f 1 < "/sys/class/net/${1}/device/modalias") if [ "${bus_type}" = "usb" ]; then - vendor_and_device=$(cat < "/sys/class/net/${1}/device/modalias" | cut -d ":" -f 2 | cut -b 1-10 | sed 's/^.//;s/p/:/') + vendor_and_device=$(cut -b 6-14 < "/sys/class/net/${1}/device/modalias" | sed 's/^.//;s/p/:/') chipset=$(lsusb | grep -i "${vendor_and_device}" | head -n1 - | cut -f3- -d ":" | sed "${sedrulewifi}") elif [[ "${bus_type}" =~ pci|ssb|bcma|pcmcia ]]; then @@ -4579,6 +4693,8 @@ function set_chipset() { #Internet interface selection menu function select_internet_interface() { + debug_print + if [ "${return_to_et_main_menu}" -eq 1 ]; then return 1 fi @@ -4670,6 +4786,8 @@ function select_internet_interface() { #Interface selection menu function select_interface() { + debug_print + clear language_strings "${language}" 88 "title" current_menu="select_interface_menu" @@ -4715,6 +4833,8 @@ function select_interface() { #Read the user input on yes/no questions function read_yesno() { + debug_print + echo language_strings "${language}" "${1}" "green" read -r yesno @@ -4723,6 +4843,8 @@ function read_yesno() { #Validate the input on yes/no questions function ask_yesno() { + debug_print + yesno="" while [[ ! ${yesno} =~ ^[YyNn]$ ]]; do read_yesno "${1}" @@ -4739,6 +4861,8 @@ function ask_yesno() { #Read the user input on channel questions function read_channel() { + debug_print + echo language_strings "${language}" 25 "green" if [ "${1}" = "wps" ]; then @@ -4751,6 +4875,8 @@ function read_channel() { #Validate the input on channel questions function ask_channel() { + debug_print + local regexp="^([1-9]|1[0-4])$" if [ "${1}" = "wps" ]; then @@ -4771,6 +4897,8 @@ function ask_channel() { #Read the user input on bssid questions function read_bssid() { + debug_print + echo language_strings "${language}" 27 "green" if [ "${1}" = "wps" ]; then @@ -4783,6 +4911,8 @@ function read_bssid() { #Validate the input on bssid questions function ask_bssid() { + debug_print + local regexp="^([a-fA-F0-9]{2}:){5}[a-zA-Z0-9]{2}$" if [ "${1}" = "wps" ]; then @@ -4803,6 +4933,8 @@ function ask_bssid() { #Read the user input on essid questions function read_essid() { + debug_print + echo language_strings "${language}" 29 "green" read -r essid @@ -4811,6 +4943,8 @@ function read_essid() { #Validate the input on essid questions function ask_essid() { + debug_print + if [ -z "${essid}" ]; then while [[ -z "${essid}" ]]; do read_essid @@ -4828,6 +4962,8 @@ function ask_essid() { #Read the user input on custom pin questions function read_custom_pin() { + debug_print + echo language_strings "${language}" 363 "green" read -r custom_pin @@ -4836,6 +4972,8 @@ function read_custom_pin() { #Validate the input on custom pin questions function ask_custom_pin() { + debug_print + local regexp="^[0-9]{8}$" custom_pin="" while [[ ! ${custom_pin} =~ ${regexp} ]]; do @@ -4849,6 +4987,8 @@ function ask_custom_pin() { #Read the user input on timeout questions function read_timeout() { + debug_print + echo case ${1} in "standard") @@ -4864,6 +5004,8 @@ function read_timeout() { #Validate the user input for timeouts function ask_wps_timeout() { + debug_print + case ${1} in "standard") local regexp="^[1-9][0-9]$|^100$|^$" @@ -4905,6 +5047,8 @@ function ask_wps_timeout() { #Execute wps custom pin bully attack function exec_wps_custom_pin_bully_attack() { + debug_print + echo language_strings "${language}" 32 "green" @@ -4921,6 +5065,8 @@ function exec_wps_custom_pin_bully_attack() { #Execute wps custom pin reaver attack function exec_wps_custom_pin_reaver_attack() { + debug_print + echo language_strings "${language}" 32 "green" @@ -4937,6 +5083,8 @@ function exec_wps_custom_pin_reaver_attack() { #Execute bully pixie dust attack function exec_bully_pixiewps_attack() { + debug_print + echo language_strings "${language}" 32 "green" @@ -4953,6 +5101,8 @@ function exec_bully_pixiewps_attack() { #Execute reaver pixie dust attack function exec_reaver_pixiewps_attack() { + debug_print + echo language_strings "${language}" 32 "green" @@ -4969,6 +5119,8 @@ function exec_reaver_pixiewps_attack() { #Execute wps bruteforce pin bully attack function exec_wps_bruteforce_pin_bully_attack() { + debug_print + echo language_strings "${language}" 32 "green" @@ -4985,6 +5137,8 @@ function exec_wps_bruteforce_pin_bully_attack() { #Execute wps bruteforce pin reaver attack function exec_wps_bruteforce_pin_reaver_attack() { + debug_print + echo language_strings "${language}" 32 "green" @@ -5001,6 +5155,8 @@ function exec_wps_bruteforce_pin_reaver_attack() { #Execute wps pin database bully attack function exec_wps_pin_database_bully_attack() { + debug_print + wps_pin_database_prerequisites set_wps_attack_script "bully" "pindb" @@ -5012,6 +5168,8 @@ function exec_wps_pin_database_bully_attack() { #Execute wps pin database reaver attack function exec_wps_pin_database_reaver_attack() { + debug_print + wps_pin_database_prerequisites set_wps_attack_script "reaver" "pindb" @@ -5023,6 +5181,8 @@ function exec_wps_pin_database_reaver_attack() { #Execute mdk3 deauth DoS attack function exec_mdk3deauth() { + debug_print + echo language_strings "${language}" 89 "title" language_strings "${language}" 32 "green" @@ -5041,6 +5201,8 @@ function exec_mdk3deauth() { #Execute aireplay DoS attack function exec_aireplaydeauth() { + debug_print + echo language_strings "${language}" 90 "title" language_strings "${language}" 32 "green" @@ -5057,6 +5219,8 @@ function exec_aireplaydeauth() { #Execute WDS confusion DoS attack function exec_wdsconfusion() { + debug_print + echo language_strings "${language}" 91 "title" language_strings "${language}" 32 "green" @@ -5071,6 +5235,8 @@ function exec_wdsconfusion() { #Execute Beacon flood DoS attack function exec_beaconflood() { + debug_print + echo language_strings "${language}" 92 "title" language_strings "${language}" 32 "green" @@ -5085,6 +5251,8 @@ function exec_beaconflood() { #Execute Auth DoS attack function exec_authdos() { + debug_print + echo language_strings "${language}" 93 "title" language_strings "${language}" 32 "green" @@ -5099,6 +5267,8 @@ function exec_authdos() { #Execute Michael Shutdown DoS attack function exec_michaelshutdown() { + debug_print + echo language_strings "${language}" 94 "title" language_strings "${language}" 32 "green" @@ -5113,6 +5283,8 @@ function exec_michaelshutdown() { #Validate Mdk3 parameters function mdk3_deauth_option() { + debug_print + echo language_strings "${language}" 95 "title" language_strings "${language}" 35 "green" @@ -5133,6 +5305,8 @@ function mdk3_deauth_option() { #Validate Aireplay parameters function aireplay_deauth_option() { + debug_print + echo language_strings "${language}" 96 "title" language_strings "${language}" 36 "green" @@ -5153,6 +5327,8 @@ function aireplay_deauth_option() { #Validate WDS confusion parameters function wds_confusion_option() { + debug_print + echo language_strings "${language}" 97 "title" language_strings "${language}" 37 "green" @@ -5173,6 +5349,8 @@ function wds_confusion_option() { #Validate Beacon flood parameters function beacon_flood_option() { + debug_print + echo language_strings "${language}" 98 "title" language_strings "${language}" 38 "green" @@ -5193,6 +5371,8 @@ function beacon_flood_option() { #Validate Auth DoS parameters function auth_dos_option() { + debug_print + echo language_strings "${language}" 99 "title" language_strings "${language}" 39 "green" @@ -5212,6 +5392,8 @@ function auth_dos_option() { #Validate Michael Shutdown parameters function michael_shutdown_option() { + debug_print + echo language_strings "${language}" 100 "title" language_strings "${language}" 40 "green" @@ -5231,6 +5413,8 @@ function michael_shutdown_option() { #Validate wps parameters for custom pin, pixie dust, bruteforce and pin database attacks function wps_attacks_parameters() { + debug_print + check_monitor_enabled if [ "$?" != "0" ]; then return 1 @@ -5261,6 +5445,8 @@ function wps_attacks_parameters() { #Print selected interface function print_iface_selected() { + debug_print + if [ -z "${interface}" ]; then language_strings "${language}" 41 "red" echo @@ -5275,6 +5461,8 @@ function print_iface_selected() { #Print selected internet interface function print_iface_internet_selected() { + debug_print + if [[ "${et_mode}" != "et_captive_portal" ]] || [[ ${captive_portal_mode} = "internet" ]]; then if [ -z "${internet_interface}" ]; then language_strings "${language}" 283 "blue" @@ -5287,6 +5475,8 @@ function print_iface_internet_selected() { #Print selected target parameters (bssid, channel, essid and type of encryption) function print_all_target_vars() { + debug_print + if [ -n "${bssid}" ]; then language_strings "${language}" 43 "blue" if [ -n "${channel}" ]; then @@ -5308,6 +5498,8 @@ function print_all_target_vars() { #Print selected target parameters on evil twin menu (bssid, channel and essid) function print_all_target_vars_et() { + debug_print + if [ -n "${bssid}" ]; then language_strings "${language}" 43 "blue" else @@ -5334,6 +5526,8 @@ function print_all_target_vars_et() { #Print selected target parameters on evil twin submenus (bssid, channel, essid, DoS type and Handshake file) function print_et_target_vars() { + debug_print + if [ -n "${bssid}" ]; then language_strings "${language}" 43 "blue" else @@ -5380,6 +5574,8 @@ function print_et_target_vars() { #Print selected target parameters on wps attacks menu (bssid, channel and essid) function print_all_target_vars_wps() { + debug_print + if [ -n "${wps_bssid}" ]; then language_strings "${language}" 335 "blue" else @@ -5412,6 +5608,8 @@ function print_all_target_vars_wps() { #Print selected target parameters on decrypt menu (bssid, Handshake file, dictionary file and rules file) function print_decrypt_vars() { + debug_print + if [ -n "${bssid}" ]; then language_strings "${language}" 43 "blue" else @@ -5436,6 +5634,8 @@ function print_decrypt_vars() { #Create the dependencies arrays function initialize_menu_options_dependencies() { + debug_print + clean_handshake_dependencies=(${optional_tools_names[0]}) aircrack_attacks_dependencies=(${optional_tools_names[1]}) aireplay_attack_dependencies=(${optional_tools_names[2]}) @@ -5456,6 +5656,8 @@ function initialize_menu_options_dependencies() { #Set possible changes for some commands that can be found in different ways depending of the O.S. function set_possible_aliases() { + debug_print + for item in "${!possible_alias_names[@]}"; do if ! hash "${item}" 2> /dev/null || [[ "${item}" = "beef" ]]; then arraliases=(${possible_alias_names[${item//[[:space:]]/ }]}) @@ -5472,6 +5674,8 @@ function set_possible_aliases() { #Initialize optional_tools values function initialize_optional_tools_values() { + debug_print + declare -gA optional_tools=() for item in "${optional_tools_names[@]}"; do @@ -5482,6 +5686,8 @@ function initialize_optional_tools_values() { #Set some vars depending of the menu and invoke the printing of target vars function initialize_menu_and_print_selections() { + debug_print + forbidden_options=() case ${current_menu} in @@ -5545,6 +5751,8 @@ function initialize_menu_and_print_selections() { #Clean temporary files function clean_tmpfiles() { + debug_print + rm -rf "${tmpdir}bl.txt" > /dev/null 2>&1 rm -rf "${tmpdir}handshake"* > /dev/null 2>&1 rm -rf "${tmpdir}nws"* > /dev/null 2>&1 @@ -5575,6 +5783,8 @@ function clean_tmpfiles() { #Manage cleaning firewall rules and restore orginal routing state function clean_routing_rules() { + debug_print + if [ -n "${original_routing_state}" ]; then echo "${original_routing_state}" > /proc/sys/net/ipv4/ip_forward fi @@ -5585,6 +5795,8 @@ function clean_routing_rules() { #Clean iptables rules function clean_iptables() { + debug_print + iptables -F iptables -t nat -F iptables -X @@ -5594,6 +5806,8 @@ function clean_iptables() { #Create an array from parameters function store_array() { + debug_print + local values=("${@:3}") for i in "${!values[@]}"; do eval "${1}[\$2|${i}]=\${values[i]}" @@ -5603,6 +5817,8 @@ function store_array() { #Check if something (first parameter) is inside an array (second parameter) contains_element() { + debug_print + local e for e in "${@:2}"; do [[ "${e}" = "${1}" ]] && return 0 @@ -5613,6 +5829,8 @@ contains_element() { #Print hints from the different hint pools depending of the menu function print_hint() { + debug_print + declare -A hints case ${1} in @@ -5703,6 +5921,8 @@ function print_hint() { #airgeddon main menu function main_menu() { + debug_print + clear language_strings "${language}" 101 "title" current_menu="main_menu" @@ -5771,6 +5991,8 @@ function main_menu() { #Evil Twin attacks menu function evil_twin_attacks_menu() { + debug_print + clear language_strings "${language}" 253 "title" current_menu="evil_twin_attacks_menu" @@ -5896,6 +6118,8 @@ function evil_twin_attacks_menu() { #beef pre attack menu function beef_pre_menu() { + debug_print + if [ ${return_to_et_main_menu_from_beef} -eq 1 ]; then return fi @@ -5969,6 +6193,8 @@ function beef_pre_menu() { #WPS attacks menu function wps_attacks_menu() { + debug_print + clear language_strings "${language}" 334 "title" current_menu="wps_attacks_menu" @@ -6194,6 +6420,8 @@ function wps_attacks_menu() { #Offline decryption attacks menu function decrypt_menu() { + debug_print + clear language_strings "${language}" 170 "title" current_menu="decrypt_menu" @@ -6273,6 +6501,8 @@ function decrypt_menu() { #Read the user input on rules file questions function ask_rules() { + debug_print + validpath=1 while [[ "${validpath}" != "0" ]]; do read_path "rules" @@ -6283,6 +6513,8 @@ function ask_rules() { #Read the user input on dictionary file questions function ask_dictionary() { + debug_print + validpath=1 while [[ "${validpath}" != "0" ]]; do read_path "dictionary" @@ -6293,6 +6525,8 @@ function ask_dictionary() { #Read the user input on Handshake file questions function ask_capture_file() { + debug_print + validpath=1 while [[ "${validpath}" != "0" ]]; do read_path "targetfilefordecrypt" @@ -6303,6 +6537,8 @@ function ask_capture_file() { #Manage the questions on Handshake file questions function manage_asking_for_captured_file() { + debug_print + if [ -n "${enteredpath}" ]; then echo language_strings "${language}" 186 "blue" @@ -6318,6 +6554,8 @@ function manage_asking_for_captured_file() { #Manage the questions on dictionary file questions function manage_asking_for_dictionary_file() { + debug_print + if [ -n "${DICTIONARY}" ]; then echo language_strings "${language}" 183 "blue" @@ -6333,6 +6571,8 @@ function manage_asking_for_dictionary_file() { #Manage the questions on rules file questions function manage_asking_for_rule_file() { + debug_print + if [ -n "${RULES}" ]; then echo language_strings "${language}" 239 "blue" @@ -6348,6 +6588,8 @@ function manage_asking_for_rule_file() { #Validate the file to be cleaned function check_valid_file_to_clean() { + debug_print + nets_from_file=$(echo "1" | aircrack-ng "${1}" 2> /dev/null | egrep "WPA|WEP" | awk '{ saved = $1; $1 = ""; print substr($0, 2) }') if [ "${nets_from_file}" = "" ]; then @@ -6381,6 +6623,8 @@ function check_valid_file_to_clean() { #Check if a bssid is present on a capture file to know if there is a Handshake with that bssid function check_bssid_in_captured_file() { + debug_print + nets_from_file=$(echo "1" | aircrack-ng "${1}" 2> /dev/null | egrep "WPA \([1-9][0-9]? handshake" | awk '{ saved = $1; $1 = ""; print substr($0, 2) }') echo @@ -6419,6 +6663,8 @@ function check_bssid_in_captured_file() { #Set the target vars to a bssid selecting them from a capture file which has a Handshake function select_wpa_bssid_target_from_captured_file() { + debug_print + nets_from_file=$(echo "1" | aircrack-ng "${1}" 2> /dev/null | egrep "WPA \([1-9][0-9]? handshake" | awk '{ saved = $1; $1 = ""; print substr($0, 2) }') echo @@ -6497,6 +6743,8 @@ function select_wpa_bssid_target_from_captured_file() { #Validate and ask for the different parameters used in an aircrack dictionary based attack function aircrack_dictionary_attack_option() { + debug_print + manage_asking_for_captured_file select_wpa_bssid_target_from_captured_file "${enteredpath}" @@ -6515,6 +6763,8 @@ function aircrack_dictionary_attack_option() { #Validate and ask for the different parameters used in an aircrack bruteforce based attack function aircrack_bruteforce_attack_option() { + debug_print + manage_asking_for_captured_file select_wpa_bssid_target_from_captured_file "${enteredpath}" @@ -6540,6 +6790,8 @@ function aircrack_bruteforce_attack_option() { #Validate and ask for the different parameters used in a hashcat dictionary based attack function hashcat_dictionary_attack_option() { + debug_print + manage_asking_for_captured_file select_wpa_bssid_target_from_captured_file "${enteredpath}" @@ -6559,6 +6811,8 @@ function hashcat_dictionary_attack_option() { #Validate and ask for the different parameters used in a hashcat bruteforce based attack function hashcat_bruteforce_attack_option() { + debug_print + manage_asking_for_captured_file select_wpa_bssid_target_from_captured_file "${enteredpath}" @@ -6585,6 +6839,8 @@ function hashcat_bruteforce_attack_option() { #Validate and ask for the different parameters used in a hashcat rule based attack function hashcat_rulebased_attack_option() { + debug_print + manage_asking_for_captured_file select_wpa_bssid_target_from_captured_file "${enteredpath}" @@ -6606,6 +6862,8 @@ function hashcat_rulebased_attack_option() { #Check if the password was decrypted using hashcat and manage to save it on a file function manage_hashcat_pot() { + debug_print + local regexp="All hashes have been recovered" if [ -n "${hashcat_fix}" ]; then local regexp="Status\.{1,9}:[[:space:]]Cracked" @@ -6642,6 +6900,8 @@ function manage_hashcat_pot() { #Check if the passwords were captured using ettercap and manage to save them on a file function manage_ettercap_log() { + debug_print + ettercap_log=0 ask_yesno 302 if [ ${yesno} = "y" ]; then @@ -6665,6 +6925,8 @@ function manage_ettercap_log() { #Check if the passwords were captured using bettercap and manage to save them on a file function manage_bettercap_log() { + debug_print + bettercap_log=0 ask_yesno 302 if [ ${yesno} = "y" ]; then @@ -6688,6 +6950,8 @@ function manage_bettercap_log() { #Check if the passwords were captured using the captive portal Evil Twin attack and manage to save them on a file function manage_captive_portal_log() { + debug_print + default_et_captive_portal_logpath=$(env | grep ^HOME | awk -F = '{print $2}') lastcharetcaptiveportallogpath=${default_et_captive_portal_logpath: -1} if [ "${lastcharetcaptiveportallogpath}" != "/" ]; then @@ -6704,6 +6968,8 @@ function manage_captive_portal_log() { #Captive portal language menu function set_captive_portal_language() { + debug_print + clear language_strings "${language}" 293 "title" print_iface_selected @@ -6754,6 +7020,8 @@ function set_captive_portal_language() { #Read and validate the minlength var function set_minlength() { + debug_print + minlength=0 while [[ ! ${minlength} =~ ^[8-9]$|^[1-5][0-9]$|^6[0-3]$ ]]; do echo @@ -6765,6 +7033,8 @@ function set_minlength() { #Read and validate the maxlength var function set_maxlength() { + debug_print + maxlength=0 while [[ ! ${maxlength} =~ ^[8-9]$|^[1-5][0-9]$|^6[0-3]$ ]]; do echo @@ -6776,6 +7046,8 @@ function set_maxlength() { #Manage the minlength and maxlength vars on bruteforce attacks function set_minlength_and_maxlength() { + debug_print + set_minlength maxlength=0 while [[ ${maxlength} -lt ${minlength} ]]; do @@ -6786,6 +7058,8 @@ function set_minlength_and_maxlength() { #Charset selection menu function set_charset() { + debug_print + clear language_strings "${language}" 238 "title" language_strings "${language}" 196 "green" @@ -6877,6 +7151,8 @@ function set_charset() { #Set a var to show the chosen charset function set_show_charset() { + debug_print + showcharset="" case ${1} in @@ -6909,6 +7185,8 @@ function set_show_charset() { #Execute aircrack+crunch bruteforce attack function exec_aircrack_bruteforce_attack() { + debug_print + crunch "${minlength}" "${maxlength}" "${charset}" | aircrack-ng -a 2 -b "${bssid}" -w - "${enteredpath}" language_strings "${language}" 115 "read" } @@ -6916,6 +7194,8 @@ function exec_aircrack_bruteforce_attack() { #Execute aircrack dictionary attack function exec_aircrack_dictionary_attack() { + debug_print + aircrack-ng -a 2 -b "${bssid}" -w "${DICTIONARY}" "${enteredpath}" language_strings "${language}" 115 "read" } @@ -6923,6 +7203,8 @@ function exec_aircrack_dictionary_attack() { #Execute hashcat dictionary attack function exec_hashcat_dictionary_attack() { + debug_print + convert_cap_to_hashcat_format hashcat_cmd="hashcat -m 2500 -a 0 \"${tmpdir}hctmp.hccap\" \"${DICTIONARY}\" --potfile-disable -o \"${tmpdir}hctmp.pot\" ${hashcat_fix} | tee /dev/fd/5" exec 5>&1 @@ -6933,6 +7215,8 @@ function exec_hashcat_dictionary_attack() { #Execute hashcat bruteforce attack function exec_hashcat_bruteforce_attack() { + debug_print + convert_cap_to_hashcat_format hashcat_cmd="hashcat -m 2500 -a 3 \"${tmpdir}hctmp.hccap\" \"${charset}\" --potfile-disable -o \"${tmpdir}hctmp.pot\" ${hashcat_fix} | tee /dev/fd/5" exec 5>&1 @@ -6943,6 +7227,8 @@ function exec_hashcat_bruteforce_attack() { #Execute hashcat rule based attack function exec_hashcat_rulebased_attack() { + debug_print + convert_cap_to_hashcat_format hashcat_cmd="hashcat -m 2500 -a 0 \"${tmpdir}hctmp.hccap\" \"${DICTIONARY}\" -r \"${RULES}\" --potfile-disable -o \"${tmpdir}hctmp.pot\" ${hashcat_fix} | tee /dev/fd/5" exec 5>&1 @@ -6953,6 +7239,8 @@ function exec_hashcat_rulebased_attack() { #Execute Evil Twin only Access Point attack function exec_et_onlyap_attack() { + debug_print + set_hostapd_config launch_fake_ap set_dhcp_config @@ -6974,6 +7262,8 @@ function exec_et_onlyap_attack() { #Execute Evil Twin with sniffing attack function exec_et_sniffing_attack() { + debug_print + set_hostapd_config launch_fake_ap set_dhcp_config @@ -6999,6 +7289,8 @@ function exec_et_sniffing_attack() { #Execute Evil Twin with sniffing+sslstrip attack function exec_et_sniffing_sslstrip_attack() { + debug_print + set_hostapd_config launch_fake_ap set_dhcp_config @@ -7025,6 +7317,8 @@ function exec_et_sniffing_sslstrip_attack() { #Execute Evil Twin with sniffing+bettercap-sslstrip2/beef attack function exec_et_sniffing_sslstrip2_attack() { + debug_print + set_hostapd_config launch_fake_ap set_dhcp_config @@ -7061,6 +7355,8 @@ function exec_et_sniffing_sslstrip2_attack() { #Execute captive portal Evil Twin attack function exec_et_captive_portal_attack() { + debug_print + set_hostapd_config launch_fake_ap set_dhcp_config @@ -7089,6 +7385,8 @@ function exec_et_captive_portal_attack() { #Create configuration file for hostapd function set_hostapd_config() { + debug_print + tmpfiles_toclean=1 rm -rf "${tmpdir}${hostapd_file}" > /dev/null 2>&1 @@ -7107,6 +7405,8 @@ function set_hostapd_config() { #Launch hostapd fake Access Point function launch_fake_ap() { + debug_print + killall hostapd > /dev/null 2>&1 ${airmon} check kill > /dev/null 2>&1 nm_processes_killed=1 @@ -7131,6 +7431,8 @@ function launch_fake_ap() { #Create configuration file for dhcpd function set_dhcp_config() { + debug_print + route | grep ${ip_range} > /dev/null if [ "$?" != "0" ]; then et_ip_range=${ip_range} @@ -7212,6 +7514,8 @@ function set_dhcp_config() { #Set routing state and firewall rules for Evil Twin attacks function set_std_internet_routing_rules() { + debug_print + routing_toclean=1 original_routing_state=$(cat /proc/sys/net/ipv4/ip_forward) ifconfig "${interface}" ${et_ip_router} netmask ${std_c_mask} > /dev/null 2>&1 @@ -7256,6 +7560,8 @@ function set_std_internet_routing_rules() { #Launch dhcpd server function launch_dhcp_server() { + debug_print + killall dhcpd > /dev/null 2>&1 recalculate_windows_sizes @@ -7278,6 +7584,8 @@ function launch_dhcp_server() { #Execute DoS for Evil Twin attacks function exec_et_deauth() { + debug_print + prepare_et_monitor case ${et_dos_attack} in @@ -7317,6 +7625,8 @@ function exec_et_deauth() { #Create here-doc bash script used for wps pin attacks function set_wps_attack_script() { + debug_print + tmpfiles_toclean=1 rm -rf "${tmpdir}${wps_attack_script_file}" > /dev/null 2>&1 rm -rf "${tmpdir}${wps_out_file}" > /dev/null 2>&1 @@ -7676,6 +7986,8 @@ function set_wps_attack_script() { #Create here-doc bash script used for control windows on Evil Twin attacks function set_control_script() { + debug_print + rm -rf "${tmpdir}${control_file}" > /dev/null 2>&1 exec 7>"${tmpdir}${control_file}" @@ -7857,7 +8169,7 @@ function set_control_script() { cat >&7 <<-EOF echo -e "\t${green_color}${et_misc_texts[${language},3]}${normal_color}" - readarray -t DHCPCLIENTS < <(cat < "${tmpdir}clts.txt" 2> /dev/null | grep DHCPACK) + readarray -t DHCPCLIENTS < <(grep DHCPACK < "${tmpdir}clts.txt") client_ips=() EOF @@ -7897,6 +8209,8 @@ function set_control_script() { #Launch dnsspoof dns black hole for captive portal Evil Twin attack function launch_dns_blackhole() { + debug_print + recalculate_windows_sizes xterm -hold -bg black -fg green -geometry "${g4_middleright_window}" -T "DNS" -e "${optional_tools_names[12]} -i ${interface}" > /dev/null 2>&1 & et_processes+=($!) @@ -7905,6 +8219,8 @@ function launch_dns_blackhole() { #Launch control window for Evil Twin attacks function launch_control_window() { + debug_print + recalculate_windows_sizes case ${et_mode} in "et_onlyap") @@ -7934,6 +8250,8 @@ function launch_control_window() { #Create configuration file for lighttpd function set_webserver_config() { + debug_print + rm -rf "${tmpdir}${webserver_file}" > /dev/null 2>&1 { @@ -7957,6 +8275,8 @@ function set_webserver_config() { #Create captive portal files. Cgi bash scripts, css and js file function set_captive_portal_page() { + debug_print + rm -rf -R "${tmpdir}${webdir}" > /dev/null 2>&1 mkdir "${tmpdir}${webdir}" > /dev/null 2>&1 @@ -8161,6 +8481,8 @@ function set_captive_portal_page() { #Launch lighttpd webserver for captive portal Evil Twin attack function launch_webserver() { + debug_print + killall lighttpd > /dev/null 2>&1 recalculate_windows_sizes if [ ${captive_portal_mode} = "internet" ]; then @@ -8175,6 +8497,8 @@ function launch_webserver() { #Launch sslstrip for sslstrip sniffing Evil Twin attack function launch_sslstrip() { + debug_print + rm -rf "${tmpdir}${sslstrip_file}" > /dev/null 2>&1 recalculate_windows_sizes xterm -hold -bg black -fg green -geometry "${g4_middleright_window}" -T "Sslstrip" -e "sslstrip -w \"${tmpdir}${sslstrip_file}\" -p -l ${sslstrip_port} -f -k" > /dev/null 2>&1 & @@ -8184,6 +8508,8 @@ function launch_sslstrip() { #Launch ettercap sniffer function launch_ettercap_sniffing() { + debug_print + recalculate_windows_sizes case ${et_mode} in "et_sniffing") @@ -8205,6 +8531,8 @@ function launch_ettercap_sniffing() { #Create configuration file for beef function set_beef_config() { + debug_print + tmpfiles_toclean=1 rm -rf "${tmpdir}${beef_file}" > /dev/null 2>&1 @@ -8282,6 +8610,8 @@ function set_beef_config() { #Kill beef process function kill_beef() { + debug_print + killall "${optional_tools_names[19]}" > /dev/null 2>&1 if [ "$?" != "0" ]; then beef_pid=$(ps uax | pgrep -f "${optional_tools_names[19]}") @@ -8296,6 +8626,8 @@ function kill_beef() { #Detects if your beef is Flexible Brainfuck interpreter instead of BeEF function detect_fake_beef() { + debug_print + readarray -t BEEF_OUTPUT < <(timeout -s SIGTERM 0.5 beef -h 2> /dev/null) for item in "${BEEF_OUTPUT[@]}"; do @@ -8309,6 +8641,8 @@ function detect_fake_beef() { #Search for beef path function search_for_beef() { + debug_print + if [ "${beef_found}" -eq 0 ]; then for item in "${possible_beef_known_locations[@]}"; do if [ -f "${item}beef" ]; then @@ -8323,6 +8657,8 @@ function search_for_beef() { #Prepare system to work with beef function prepare_beef_start() { + debug_print + valid_possible_beef_path=0 if [[ ${beef_found} -eq 0 ]] && [[ ${optional_tools[${optional_tools_names[19]}]} -eq 0 ]]; then language_strings "${language}" 405 "blue" @@ -8365,6 +8701,8 @@ function prepare_beef_start() { #Set beef path manually function manual_beef_set() { + debug_print + while [[ "${valid_possible_beef_path}" != "1" ]]; do echo language_strings "${language}" 402 "green" @@ -8402,6 +8740,8 @@ function manual_beef_set() { #Fix for not found beef executable function fix_beef_executable() { + debug_print + rm -rf "/usr/bin/beef" > /dev/null 2>&1 { echo -e "#!/bin/bash\n" @@ -8417,6 +8757,8 @@ function fix_beef_executable() { #Rewrite airgeddon script in a polymorphic way adding custom beef location to array to get persistence function rewrite_script_with_custom_beef() { + debug_print + set_script_folder_and_name case ${1} in @@ -8425,7 +8767,7 @@ function rewrite_script_with_custom_beef() { chmod +x "${scriptfolder}${scriptname}" > /dev/null 2>&1 ;; "search") - beef_custom_path_line=$(cat < "${scriptfolder}${scriptname}" 2> /dev/null | grep "#[C]ustom BeEF location (set=1)" 2> /dev/null) + beef_custom_path_line=$(grep "#[C]ustom BeEF location (set=1)" < "${scriptfolder}${scriptname}" 2> /dev/null) if [ -n "${beef_custom_path_line}" ]; then [[ ${beef_custom_path_line} =~ \"(.*)\" ]] && beef_custom_path="${BASH_REMATCH[1]}" fi @@ -8436,6 +8778,8 @@ function rewrite_script_with_custom_beef() { #Start beef process as a service function start_beef_service() { + debug_print + service "${optional_tools_names[19]}" restart > /dev/null 2>&1 if [ "$?" != "0" ]; then systemctl restart "${optional_tools_names[19]}.service" > /dev/null 2>&1 @@ -8445,6 +8789,8 @@ function start_beef_service() { #Launch beef browser exploitation framework function launch_beef() { + debug_print + kill_beef if [ "${beef_found}" -eq 0 ]; then @@ -8466,6 +8812,8 @@ function launch_beef() { #Launch bettercap sniffer function launch_bettercap_sniffing() { + debug_print + recalculate_windows_sizes sniffing_scr_window_position=${g4_bottomright_window} @@ -8486,6 +8834,8 @@ function launch_bettercap_sniffing() { #Parse ettercap log searching for captured passwords function parse_ettercap_log() { + debug_print + echo language_strings "${language}" 304 "blue" @@ -8524,6 +8874,8 @@ function parse_ettercap_log() { #Parse bettercap log searching for captured passwords function parse_bettercap_log() { + debug_print + echo language_strings "${language}" 304 "blue" @@ -8580,6 +8932,8 @@ function parse_bettercap_log() { #Write on a file the id of the captive portal Evil Twin attack processes function write_et_processes() { + debug_print + for item in "${et_processes[@]}"; do echo "${item}" >> "${tmpdir}${webdir}${processesfile}" done @@ -8588,6 +8942,8 @@ function write_et_processes() { #Kill the Evil Twin processes function kill_et_windows() { + debug_print + for item in "${et_processes[@]}"; do kill "${item}" &> /dev/null done @@ -8597,6 +8953,8 @@ function kill_et_windows() { #Convert capture file to hashcat format function convert_cap_to_hashcat_format() { + debug_print + tmpfiles_toclean=1 rm -rf "${tmpdir}hctmp"* > /dev/null 2>&1 echo "1" | aircrack-ng "${enteredpath}" -J "${tmpdir}hctmp" -b "${bssid}" > /dev/null 2>&1 @@ -8605,6 +8963,8 @@ function convert_cap_to_hashcat_format() { #Handshake tools menu function handshake_tools_menu() { + debug_print + clear language_strings "${language}" 120 "title" current_menu="handshake_tools_menu" @@ -8663,6 +9023,8 @@ function handshake_tools_menu() { #Execute the cleaning of a Handshake file function exec_clean_handshake_file() { + debug_print + echo check_valid_file_to_clean "${filetoclean}" if [ "$?" != "0" ]; then @@ -8677,6 +9039,8 @@ function exec_clean_handshake_file() { #Validate and ask for the parameters used to clean a Handshake file function clean_handshake_file_option() { + debug_print + echo readpath=0 @@ -8706,6 +9070,8 @@ function clean_handshake_file_option() { #DoS attacks menu function dos_attacks_menu() { + debug_print + clear language_strings "${language}" 102 "title" current_menu="dos_attacks_menu" @@ -8805,6 +9171,8 @@ function dos_attacks_menu() { #Capture Handshake on Evil Twin attack function capture_handshake_evil_twin() { + debug_print + if [[ ${enc} != "WPA" ]] && [[ ${enc} != "WPA2" ]]; then echo language_strings "${language}" 137 "red" @@ -8873,6 +9241,8 @@ function capture_handshake_evil_twin() { #Capture Handshake on Handshake tools function capture_handshake() { + debug_print + if [[ -z ${bssid} ]] || [[ -z ${essid} ]] || [[ -z ${channel} ]] || [[ "${essid}" = "(Hidden Network)" ]]; then echo language_strings "${language}" 125 "yellow" @@ -8900,6 +9270,8 @@ function capture_handshake() { #Check if file exists function check_file_exists() { + debug_print + if [[ ! -f "${1}" || -z "${1}" ]]; then language_strings "${language}" 161 "red" return 1 @@ -8910,6 +9282,8 @@ function check_file_exists() { #Validate path function validate_path() { + debug_print + dirname=${1%/*} if [[ ! -d "${dirname}" ]] || [[ "${dirname}" = "." ]]; then @@ -8967,6 +9341,8 @@ function validate_path() { #Check for write permissions on a given path function check_write_permissions() { + debug_print + if [ -w "${1}" ]; then return 0 fi @@ -8976,6 +9352,8 @@ function check_write_permissions() { #Create a var with the name passed to the function and reading the value from the user input function read_and_clean_path() { + debug_print + settings="$(shopt -p extglob)" shopt -s extglob @@ -8990,6 +9368,8 @@ function read_and_clean_path() { #Read and validate a path function read_path() { + debug_print + echo case ${1} in "handshake") @@ -9074,6 +9454,8 @@ function read_path() { #Launch the DoS selection menu before capture a Handshake and process the captured file function attack_handshake_menu() { + debug_print + if [ "${1}" = "handshake" ]; then ask_yesno 145 handshake_captured=${yesno} @@ -9179,6 +9561,8 @@ function attack_handshake_menu() { #Launch the Handshake capture window function capture_handshake_window() { + debug_print + language_strings "${language}" 143 "blue" echo language_strings "${language}" 144 "yellow" @@ -9195,6 +9579,8 @@ function capture_handshake_window() { #Manage target exploration and parse the output files function explore_for_targets_option() { + debug_print + echo language_strings "${language}" 103 "title" language_strings "${language}" 65 "green" @@ -9215,7 +9601,7 @@ function explore_for_targets_option() { rm -rf "${tmpdir}clts.csv" > /dev/null 2>&1 recalculate_windows_sizes xterm +j -bg black -fg white -geometry "${g1_topright_window}" -T "Exploring for targets" -e airodump-ng -w "${tmpdir}nws" "${interface}" > /dev/null 2>&1 - targetline=$(cat < "${tmpdir}nws-01.csv" | egrep -a -n '(Station|Cliente)' | awk -F : '{print $1}') + targetline=$(awk '/(Station|Client[es])/{print NR}' < "${tmpdir}nws-01.csv") targetline=$((targetline - 1)) head -n "${targetline}" "${tmpdir}nws-01.csv" &> "${tmpdir}nws.csv" @@ -9269,6 +9655,8 @@ function explore_for_targets_option() { #Manage target exploration only for Access Points with WPS activated. Parse output files and print menu with results function explore_for_wps_targets_option() { + debug_print + echo language_strings "${language}" 103 "title" language_strings "${language}" 65 "green" @@ -9283,7 +9671,7 @@ function explore_for_wps_targets_option() { echo if ! grep -qe "${interface}" <(echo "${!wash_ifaces_already_set[@]}"); then language_strings "${language}" 353 "blue" - set_wash_parametrization + set_wash_parameterization language_strings "${language}" 354 "yellow" else language_strings "${language}" 355 "blue" @@ -9299,16 +9687,25 @@ function explore_for_wps_targets_option() { readarray -t WASH_PREVIEW < <(cat < "${tmpdir}wps.txt" 2> /dev/null) + wash_header_found=0 wash_line_counter=1 for item in "${WASH_PREVIEW[@]}"; do if [[ ${item} =~ -{20} ]]; then wash_start_data_line="${wash_line_counter}" + wash_header_found=1 break else wash_line_counter=$((wash_line_counter+1)) fi done + if [ "${wash_header_found}" -eq 0 ]; then + echo + language_strings "${language}" 417 "red" + language_strings "${language}" 115 "read" + return 1 + fi + washlines=$(wc -l "${tmpdir}wps.txt" 2> /dev/null | awk '{print $1}') if [ "${washlines}" -le ${wash_start_data_line} ]; then echo @@ -9436,6 +9833,8 @@ function explore_for_wps_targets_option() { #Create a menu to select target from the parsed data function select_target() { + debug_print + clear language_strings "${language}" 104 "title" echo @@ -9471,7 +9870,7 @@ function select_target() { sp4="" fi - client=$(cat < "${tmpdir}clts.csv" | grep "${exp_mac}") + client=$(grep "${exp_mac}" < "${tmpdir}clts.csv") if [ "${client}" != "" ]; then client="*" sp5="" @@ -9522,7 +9921,9 @@ function select_target() { } #Perform a test to determine if fcs parameter is needed on wash scanning -function set_wash_parametrization() { +function set_wash_parameterization() { + + debug_print fcs="" declare -gA wash_ifaces_already_set @@ -9541,6 +9942,8 @@ function set_wash_parametrization() { #Manage and validate the prerequisites for wps pin database attacks function wps_pin_database_prerequisites() { + debug_print + set_wps_mac_parameters include_pin_dbfile echo @@ -9566,6 +9969,8 @@ function wps_pin_database_prerequisites() { #Manage and validate the prerequisites for Evil Twin attacks function et_prerequisites() { + debug_print + if [ ${retry_handshake_capture} -eq 1 ]; then return fi @@ -9699,6 +10104,8 @@ function et_prerequisites() { #Manage the Handshake file requirement for captive portal Evil Twin attack function ask_et_handshake_file() { + debug_print + echo readpath=0 @@ -9738,6 +10145,8 @@ function ask_et_handshake_file() { #DoS Evil Twin attacks menu function et_dos_menu() { + debug_print + if [ ${return_to_et_main_menu} -eq 1 ]; then return fi @@ -9914,6 +10323,8 @@ function et_dos_menu() { #Selected internet interface detection function detect_internet_interface() { + debug_print + if [ ${internet_interface_selected} -eq 1 ]; then return 0 fi @@ -9940,6 +10351,8 @@ function detect_internet_interface() { #Show about and credits function credits_option() { + debug_print + clear language_strings "${language}" 105 "title" language_strings "${language}" 74 "pink" @@ -9967,6 +10380,8 @@ function credits_option() { #Show message for invalid selected language function invalid_language_selected() { + debug_print + echo language_strings "${language}" 82 "red" echo @@ -9978,6 +10393,8 @@ function invalid_language_selected() { #Show message for captive portal invalid selected language function invalid_captive_portal_language_selected() { + debug_print + language_strings "${language}" 82 "red" echo language_strings "${language}" 115 "read" @@ -9987,6 +10404,8 @@ function invalid_captive_portal_language_selected() { #Show message for forbidden selected option function forbidden_menu_option() { + debug_print + echo language_strings "${language}" 220 "red" language_strings "${language}" 115 "read" @@ -9995,6 +10414,8 @@ function forbidden_menu_option() { #Show message for invalid selected option function invalid_menu_option() { + debug_print + echo language_strings "${language}" 76 "red" language_strings "${language}" 115 "read" @@ -10003,6 +10424,8 @@ function invalid_menu_option() { #Show message for invalid selected interface function invalid_iface_selected() { + debug_print + echo language_strings "${language}" 77 "red" echo @@ -10014,6 +10437,8 @@ function invalid_iface_selected() { #Show message for invalid selected internet interface function invalid_internet_iface_selected() { + debug_print + echo language_strings "${language}" 77 "red" echo @@ -10025,6 +10450,8 @@ function invalid_internet_iface_selected() { #Manage behavior of captured traps function capture_traps() { + debug_print + case "${1}" in INT|SIGTSTP) case ${current_menu} in @@ -10057,6 +10484,8 @@ function capture_traps() { #Exit the script managing possible pending tasks function exit_script_option() { + debug_print + action_on_exit_taken=0 echo language_strings "${language}" 106 "title" @@ -10115,6 +10544,8 @@ function exit_script_option() { #Exit the script managing possible pending tasks but not showing anything function hardcore_exit() { + debug_print + exit_code=2 if [ "${ifacemode}" = "Monitor" ]; then ${airmon} stop "${interface}" > /dev/null 2>&1 @@ -10142,6 +10573,8 @@ function hardcore_exit() { #Generate a small time loop printing some dots function time_loop() { + debug_print + echo -ne " " for (( j=1; j<=4; j++ )); do echo -ne "." @@ -10152,6 +10585,8 @@ function time_loop() { #Determine which version of airmon to use function airmon_fix() { + debug_print + airmon="airmon-ng" if hash airmon-zc 2> /dev/null; then @@ -10162,6 +10597,8 @@ function airmon_fix() { #Prepare the fix for iwconfig command depending of the wireless tools version function iwconfig_fix() { + debug_print + iwversion=$(iwconfig --version | grep version | awk '{print $4}') iwcmdfix="" if [ "${iwversion}" -lt 30 ]; then @@ -10172,6 +10609,8 @@ function iwconfig_fix() { #Set hashcat parameters based on version function set_hashcat_parameters() { + debug_print + hashcat_fix="" hashcat_charset_fix_needed=0 if compare_floats_greater_or_equal "${hashcat_version}" "${hashcat3_version}"; then @@ -10183,6 +10622,8 @@ function set_hashcat_parameters() { #Determine hashcat version function get_hashcat_version() { + debug_print + hashcat_version=$(hashcat -V 2> /dev/null) hashcat_version=${hashcat_version#"v"} } @@ -10190,12 +10631,16 @@ function get_hashcat_version() { #Determine bettercap version function get_bettercap_version() { + debug_print + bettercap_version=$(bettercap -v 2> /dev/null | egrep "^bettercap [0-9]" | awk '{print $2}') } #Determine bully version function get_bully_version() { + debug_print + bully_version=$(bully -V 2> /dev/null) bully_version=${bully_version#"v"} } @@ -10203,6 +10648,8 @@ function get_bully_version() { #Determine reaver version function get_reaver_version() { + debug_print + reaver_version=$(reaver -h 2>&1 > /dev/null | egrep "^Reaver v[0-9]" | awk '{print $2}') if [ -z "${reaver_version}" ]; then reaver_version=$(reaver -h 2> /dev/null | egrep "^Reaver v[0-9]" | awk '{print $2}') @@ -10213,6 +10660,8 @@ function get_reaver_version() { #Set verbosity for bully based on version function set_bully_verbosity() { + debug_print + if compare_floats_greater_or_equal "${bully_version}" "${minimum_bully_verbosity4_version}"; then bully_verbosity="4" else @@ -10223,6 +10672,8 @@ function set_bully_verbosity() { #Validate if bully version is able to perform integrated pixiewps attack function validate_bully_pixiewps_version() { + debug_print + if compare_floats_greater_or_equal "${bully_version}" "${minimum_bully_pixiewps_version}"; then return 0 fi @@ -10232,6 +10683,8 @@ function validate_bully_pixiewps_version() { #Validate if reaver version is able to perform integrated pixiewps attack function validate_reaver_pixiewps_version() { + debug_print + if compare_floats_greater_or_equal "${reaver_version}" "${minimum_reaver_pixiewps_version}"; then return 0 fi @@ -10241,6 +10694,8 @@ function validate_reaver_pixiewps_version() { #Set the script folder var if necessary function set_script_folder_and_name() { + debug_print + if [ -z "${scriptfolder}" ]; then scriptfolder=${0} @@ -10257,6 +10712,8 @@ function set_script_folder_and_name() { #Check if pins database file exist and try to download the new one if proceed function check_pins_database_file() { + debug_print + if [ -f "${scriptfolder}${known_pins_dbfile}" ]; then language_strings "${language}" 376 "yellow" echo @@ -10323,6 +10780,8 @@ function check_pins_database_file() { #Download the pins database file function download_pins_database_file() { + debug_print + remote_pindb_file=$(timeout -s SIGTERM 15 curl -L ${urlscript_pins_dbfile} 2> /dev/null) if [ "${remote_pindb_file}" != "${curl_404_error}" ]; then @@ -10336,6 +10795,8 @@ function download_pins_database_file() { #Ask for try to download pin db file again and set the var to skip it function ask_for_pin_dbfile_download_retry() { + debug_print + ask_yesno 380 if [ ${yesno} = "n" ]; then pin_dbfile_checked=1 @@ -10345,12 +10806,16 @@ function ask_for_pin_dbfile_download_retry() { #Get the checksum for local pin database file function get_local_pin_dbfile_checksum() { + debug_print + local_pin_dbfile_checksum=$(md5sum "${1}" | awk '{print $1}') } #Get the checksum for remote pin database file function get_remote_pin_dbfile_checksum() { + debug_print + remote_pin_dbfile_checksum=$(timeout -s SIGTERM 15 curl -L ${urlscript_pins_dbfile_checksum} 2> /dev/null | head -n 1) if [ "${remote_pin_dbfile_checksum}" != "${curl_404_error}" ]; then @@ -10362,6 +10827,8 @@ function get_remote_pin_dbfile_checksum() { #Check for possible non Linux operating systems function non_linux_os_check() { + debug_print + case "${OSTYPE}" in solaris*) distro="Solaris" @@ -10378,6 +10845,8 @@ function non_linux_os_check() { #First phase of Linux distro detection based on uname output function detect_distro_phase1() { + debug_print + for i in "${known_compatible_distros[@]}"; do uname -a | grep "${i}" -i > /dev/null if [ "$?" = "0" ]; then @@ -10390,6 +10859,8 @@ function detect_distro_phase1() { #Second phase of Linux distro detection based on architecture and version file function detect_distro_phase2() { + debug_print + if [ "${distro}" = "Unknown Linux" ]; then if [ -f ${osversionfile_dir}"centos-release" ]; then distro="CentOS" @@ -10406,7 +10877,7 @@ function detect_distro_phase2() { elif [ -f ${osversionfile_dir}"debian_version" ]; then distro="Debian" if [ -f ${osversionfile_dir}"os-release" ]; then - extra_os_info=$(cat < ${osversionfile_dir}"os-release" | grep "PRETTY_NAME") + extra_os_info=$(grep "PRETTY_NAME" < ${osversionfile_dir}"os-release") if [[ "${extra_os_info}" =~ Raspbian ]]; then distro="Raspbian" is_arm=1 @@ -10418,9 +10889,13 @@ function detect_distro_phase2() { fi elif [ "${distro}" = "Arch" ]; then if [ -f ${osversionfile_dir}"os-release" ]; then - extra_os_info=$(cat < ${osversionfile_dir}"os-release" | grep "PRETTY_NAME") + extra_os_info=$(grep "PRETTY_NAME" < ${osversionfile_dir}"os-release") if [[ "${extra_os_info}" =~ BlackArch ]]; then distro="BlackArch" + elif [[ "${extra_os_info}" =~ Kali ]]; then + #Kali is intentionally here too to avoid some Kali arm distro bad detection + distro="Kali" + is_arm=1 fi fi fi @@ -10431,6 +10906,8 @@ function detect_distro_phase2() { #Detect if arm architecture is present on system function detect_arm_architecture() { + debug_print + distro_already_known=0 uname -m | grep -i "arm" > /dev/null @@ -10446,12 +10923,16 @@ function detect_arm_architecture() { distro="${distro} arm" is_arm=1 fi + elif [[ "${distro}" != "Unknown Linux" ]] && [[ "${is_arm}" -eq 1 ]]; then + distro="${distro} arm" fi } #Set some useful vars based on Linux distro function special_distro_features() { + debug_print + case ${distro} in "Wifislax") networkmanager_cmd="service restart networkmanager" @@ -10571,6 +11052,8 @@ function special_distro_features() { #Determine if NetworkManager must be killed on your system. Only needed for previous versions of 1.0.12 function check_if_kill_needed() { + debug_print + nm_min_main_version="1" nm_min_subversion="0" nm_min_subversion2="12" @@ -10606,6 +11089,8 @@ function check_if_kill_needed() { #Do some checks for some general configuration function general_checkings() { + debug_print + compatible=0 distro="Unknown Linux" @@ -10636,6 +11121,8 @@ function general_checkings() { #Check if the user is root function check_root_permissions() { + debug_print + user=$(whoami) if [ "${user}" != "root" ]; then @@ -10646,6 +11133,8 @@ function check_root_permissions() { #Print Linux known distros function print_known_distros() { + debug_print + all_known_compatible_distros=("${known_compatible_distros[@]}" "${known_arm_compatible_distros[@]}") IFS=$'\n' all_known_compatible_distros=($(printf "%s\n" "${all_known_compatible_distros[@]}" | sort)) @@ -10660,6 +11149,8 @@ function print_known_distros() { #Check if you have installed the tools (essential and optional) that the script uses function check_compatibility() { + debug_print + echo language_strings "${language}" 108 "blue" language_strings "${language}" 115 "read" @@ -10759,6 +11250,8 @@ function check_compatibility() { #Check for the minimum bash version requirement function check_bash_version() { + debug_print + echo bashversion="${BASH_VERSINFO[0]}.${BASH_VERSINFO[1]}" if compare_floats_greater_or_equal "${bashversion}" ${minimum_bash_version_required}; then @@ -10773,6 +11266,8 @@ function check_bash_version() { #Check if you have installed the tools required to update the script function check_update_tools() { + debug_print + if [ ${auto_update} -eq 1 ]; then if [ ${update_toolsok} -eq 1 ]; then autoupdate_check @@ -10787,6 +11282,8 @@ function check_update_tools() { #Check if window size is enough for intro function check_window_size_for_intro() { + debug_print + window_width=$(tput cols) window_height=$(tput lines) @@ -10808,6 +11305,8 @@ function check_window_size_for_intro() { #Print the script intro function print_intro() { + debug_print + echo -e "${yellow_color} .__ .___ .___" sleep 0.15 && echo -e " _____ |__|______ ____ ____ __| _/__| _/____ ____" sleep 0.15 && echo -e " \__ \ | \_ __ \/ ___\_/ __ \ / __ |/ __ |/ _ \ / \\" @@ -10823,6 +11322,8 @@ function print_intro() { #Generate the frames of the animated ascii art flying saucer function flying_saucer() { + debug_print + case ${1} in 1) echo " " @@ -10863,6 +11364,8 @@ function flying_saucer() { #Print animated ascii art flying saucer function print_animated_flying_saucer() { + debug_print + echo -e "\033[s" for i in $(seq 1 8); do @@ -10879,6 +11382,8 @@ function print_animated_flying_saucer() { #Initialize script settings function initialize_script_settings() { + debug_print + exit_code=0 check_kill_needed=0 nm_processes_killed=0 @@ -10901,6 +11406,8 @@ function initialize_script_settings() { #Detect screen resolution if possible function detect_screen_resolution() { + debug_print + resolution_detected=0 if hash xdpyinfo 2> /dev/null; then resolution=$(xdpyinfo 2> /dev/null | grep -A 3 "screen #0" | grep "dimensions" | tr -s " " | cut -d " " -f 3 | grep "x") @@ -10920,6 +11427,8 @@ function detect_screen_resolution() { #Set windows sizes and positions function set_windows_sizes() { + debug_print + set_xsizes set_ysizes set_ypositions @@ -10949,6 +11458,8 @@ function set_windows_sizes() { #Set sizes for x axis function set_xsizes() { + debug_print + xtotal=$(awk -v n1="${resolution_x}" "BEGIN{print n1 / ${xratio}}") xtotaltmp=$(printf "%.0f" "${xtotal}" 2> /dev/null) @@ -10968,6 +11479,8 @@ function set_xsizes() { #Set sizes for y axis function set_ysizes() { + debug_print + ytotal=$(awk -v n1="${resolution_y}" "BEGIN{print n1 / ${yratio}}") ytotaltmp=$(printf "%.0f" "${ytotal}" 2> /dev/null) if [ "$?" != "0" ]; then @@ -10986,12 +11499,16 @@ function set_ysizes() { #Set positions for y axis function set_ypositions() { + debug_print + middle_position=$((resolution_y / 3 + ywindow_edge_pixels)) } #Recalculate windows sizes and positions function recalculate_windows_sizes() { + debug_print + detect_screen_resolution set_windows_sizes } @@ -10999,6 +11516,8 @@ function recalculate_windows_sizes() { #Script starting point function welcome() { + debug_print + clear current_menu="pre_main_menu" initialize_script_settings @@ -11068,6 +11587,8 @@ function welcome() { #Avoid the problem of using airmon-zc without ethtool or lspci installed function airmonzc_security_check() { + debug_print + if [ "${airmon}" = "airmon-zc" ]; then if ! hash ethtool 2> /dev/null; then echo @@ -11090,18 +11611,24 @@ function airmonzc_security_check() { #Compare if first float argument is greater than float second argument function compare_floats_greater_than() { + debug_print + awk -v n1="${1}" -v n2="${2}" 'BEGIN{if (n1>n2) exit 0; exit 1}' } #Compare if first float argument is greater or equal than float second argument function compare_floats_greater_or_equal() { + debug_print + awk -v n1="${1}" -v n2="${2}" 'BEGIN{if (n1>=n2) exit 0; exit 1}' } #Update and relaunch the script function download_last_version() { + debug_print + rewrite_script_with_custom_beef "search" timeout -s SIGTERM 15 curl -L ${urlscript_directlink} -s -o "${0}" @@ -11122,6 +11649,8 @@ function download_last_version() { #Validate if the selected internet interface has internet access function validate_et_internet_interface() { + debug_print + echo language_strings "${language}" 287 "blue" check_internet_access "${host_to_check_internet}" @@ -11151,6 +11680,8 @@ function validate_et_internet_interface() { #Check for active internet connection function check_internet_access() { + debug_print + ping -c 1 ${host_to_check_internet} -W 1 > /dev/null 2>&1 return $? } @@ -11158,6 +11689,8 @@ function check_internet_access() { #Check for default route on an interface function check_default_route() { + debug_print + route | grep "${1}" | grep "default" > /dev/null return $? } @@ -11165,6 +11698,8 @@ function check_default_route() { #Update the script if your version is lower than the cloud version function autoupdate_check() { + debug_print + echo language_strings "${language}" 210 "blue" echo @@ -11199,6 +11734,8 @@ function autoupdate_check() { #Check if you can launch captive portal Evil Twin attack function check_et_without_internet_compatibility() { + debug_print + if ! hash "${optional_tools_names[12]}" 2> /dev/null; then return 1 fi @@ -11208,6 +11745,8 @@ function check_et_without_internet_compatibility() { #Change script language automatically if OS language is supported by the script and different from current language function autodetect_language() { + debug_print + [[ $(locale | grep LANG) =~ ^(.*)=\"?([a-zA-Z]+)_(.*)$ ]] && lang="${BASH_REMATCH[2]}" for lgkey in "${!lang_association[@]}"; do @@ -11222,6 +11761,8 @@ function autodetect_language() { #Clean some known and controlled warnings for shellcheck tool function remove_warnings() { + debug_print + echo "${clean_handshake_dependencies[@]}" > /dev/null 2>&1 echo "${aircrack_attacks_dependencies[@]}" > /dev/null 2>&1 echo "${aireplay_attack_dependencies[@]}" > /dev/null 2>&1 @@ -11243,18 +11784,24 @@ function remove_warnings() { #Print a simple separator function print_simple_separator() { + debug_print + echo_blue "---------" } #Print a large separator function print_large_separator() { + debug_print + echo_blue "-------------------------------------------------------" } #Add the PoT prefix on printed strings if PoT mark is found function check_pending_of_translation() { + debug_print + if [[ "${1}" =~ ^${escaped_pending_of_translation}([[:space:]])(.*)$ ]]; then text="${cyan_color}${pending_of_translation} ${2}${BASH_REMATCH[2]}" return 1 @@ -11275,6 +11822,8 @@ function check_pending_of_translation() { #Print under construction message used on some menu entries function under_construction_message() { + debug_print + local var_uc="${under_constructionvar^}" echo echo_yellow "${var_uc}..." @@ -11284,6 +11833,8 @@ function under_construction_message() { #Canalize the echo functions function last_echo() { + debug_print + check_pending_of_translation "${1}" "${2}" if [ "$?" != "0" ]; then echo -e "${2}${text}${normal_color}" @@ -11295,60 +11846,80 @@ function last_echo() { #Print green messages function echo_green() { + debug_print + last_echo "${1}" "${green_color}" } #Print blue messages function echo_blue() { + debug_print + last_echo "${1}" "${blue_color}" } #Print yellow messages function echo_yellow() { + debug_print + last_echo "${1}" "${yellow_color}" } #Print red messages function echo_red() { + debug_print + last_echo "${1}" "${red_color}" } #Print red messages using a slimmer thickness function echo_red_slim() { + debug_print + last_echo "${1}" "${red_color_slim}" } #Print black messages with background for titles function echo_green_title() { + debug_print + last_echo "${1}" "${green_color_title}" } #Print pink messages function echo_pink() { + debug_print + last_echo "${1}" "${pink_color}" } #Print cyan messages function echo_cyan() { + debug_print + last_echo "${1}" "${cyan_color}" } #Print brown messages function echo_brown() { + debug_print + last_echo "${1}" "${brown_color}" } #Print white messages function echo_white() { + debug_print + last_echo "${1}" "${white_color}" } diff --git a/imgs/airgeddon_banner.png b/imgs/banners/airgeddon_banner.png similarity index 100% rename from imgs/airgeddon_banner.png rename to imgs/banners/airgeddon_banner.png diff --git a/imgs/bitcoin_donate.png b/imgs/banners/bitcoin_donate.png similarity index 100% rename from imgs/bitcoin_donate.png rename to imgs/banners/bitcoin_donate.png diff --git a/imgs/paypal_donate.png b/imgs/banners/paypal_donate.png similarity index 100% rename from imgs/paypal_donate.png rename to imgs/banners/paypal_donate.png diff --git a/imgs/cat.png b/imgs/flags/cat.png similarity index 100% rename from imgs/cat.png rename to imgs/flags/cat.png diff --git a/imgs/es.png b/imgs/flags/es.png similarity index 100% rename from imgs/es.png rename to imgs/flags/es.png diff --git a/imgs/fr.png b/imgs/flags/fr.png similarity index 100% rename from imgs/fr.png rename to imgs/flags/fr.png diff --git a/imgs/gr.png b/imgs/flags/gr.png similarity index 100% rename from imgs/gr.png rename to imgs/flags/gr.png diff --git a/imgs/pt.png b/imgs/flags/pt.png similarity index 100% rename from imgs/pt.png rename to imgs/flags/pt.png diff --git a/imgs/ru.png b/imgs/flags/ru.png similarity index 100% rename from imgs/ru.png rename to imgs/flags/ru.png diff --git a/imgs/us.png b/imgs/flags/us.png similarity index 100% rename from imgs/us.png rename to imgs/flags/us.png diff --git a/imgs/airgeddon_icon.png b/imgs/icons/airgeddon_icon.png similarity index 100% rename from imgs/airgeddon_icon.png rename to imgs/icons/airgeddon_icon.png