hackerbrother

Learn Penetration Testing And Ethical Hacking Online.

facebook

  • Facebook
  • Popular Posts

    Showing posts with label kali linux. Show all posts
    Showing posts with label kali linux. Show all posts



    What's more pleasant when you change distribution to have available his configuration files carefully preserved?

    When you spend time tweaking the configuration of the display server or its favourite text editor, the idea of ​​losing these famous files gives cold sweats.

    Only when we want to make a backup of these files we must do everything by hand and especially we always tend to forget some.

    This for this reason that I tinkered a little script Bash that collects your conf files and makes a nice tar.bz2 archive ready to be copied away from crashes.

    You can download the script in question here: saveconfig.sh

    This script is very easily customisation. It is divided into two sections: the first contains the commands (the script itself) and the second part is a list of files to save.


    You can add filenames as well as directories. In all cases we must give the full path from the root (/). If you indicate a directory, all its content will be copied ... so think about what you add! It may be best to give filenames belonging to the same directory rather than giving the entire directory (I am thinking in particular of the hidden directories used by browsers which contain the cache of your navigation).

    Launched as a lambda user, saveconfig.sh saves the system configuration files (in / etc, / usr ...).

    Launched in root, the script will additionally record the configuration of each "human" user (whose uid is greater than or equal to 500)


    User configuration files must be indicated using the keyword _USER_ which will be replaced when using the script by the home directory of this user (nothing very complicated, you will easily understand by looking at the list of files by default).

    Small note: saveconfig.sh does not keep the file permissions in memory ... but it is easily modifiable by modifying the arguments passed to tar and cp.

    The script needs bash, awk, tar and bzip2 to work.

    Continue Reading
    Kali Linux 2020: news and download of this distribution of ethical hacking


    When we talk about Kali Linux, we mean one of the most important and best known ethical hacking suits worldwide. It offers a wide range of possibilities to users and that makes each new version make many are attentive to their news. In this article we echo thenews of Kali Linux 2020, as well as explain how we can download this Linux distribution.










    As often happens with each new update, whatever the type of program or system, they bring improvements. These improvements translate into new functions or tools that make the day-to-day life of users benefit. But you also have to keep in mind that with each new version, present problems are corrected.

    Kali Linux allows users to perform different ethical hacking tests. Now they have a series of novelties that make this Linux distribution even more attractive. We are facing the third update of this current version. We will comment on the most important changes.

    What's new in Kali Linux 2020

    One of the novelties of Kali Linux 2020 that we can mention is that they have started usingCloudflare CDN to host the repository and distribute content to users. This they do to improve the quality and speed of downloads.

    There are also changes regardingmetapackages. Now there is an additional and unique image called kali-linux-large-2020-amd64.iso.

    Kali Linux 2020 is not a great update that brings very significant changes, however ithas improved certain applications. For example we talk about tools like Burp Suite, HostAPd-WPE, Hyperion, Kismet andNmap. All of them have been updated to a new version and have included improvements.

    One of the significant changes in relation to applications is that it now includesAmass. It is a tool that security professionals can use to map the network and discover possible external threats. Now this tool comes standard with Kali Linux.

    For the rest, it should also be mentioned that improvements have been made in terms of failures and security errors. Corrections that, in short, make this new version safer.





    How to get Kali Linux 2020

    It should be mentioned that for those users who already have this distribution installed and have it updated they will not have much to do. They would simply have to run the root @ kali command: ~ # apt update && apt-and full-upgrade to make sure they have the most current version.
    For those users who do not have it installed or want to obtain the ISO for some reason, it is best to go to the official website . There you just have to go to the download section and download the version you want (64 bits, 32 bits ...).

    As we always say, it is important to download software from official and reliable sites. We must avoid doing it from third-party links that we don't really know who it belongs to and what could be behind it.

    In addition, having updated systems can bring important benefits. On the one hand we will have the most updated tools and thus obtain improvements in performance. However, security is also very important. Security vulnerabilities are corrected with each new update . Faults that can be exploited by cyber criminals and that have been patched.
    Continue Reading



    android-file-transfer-linux
    Hello today I teach you how to install Android file transfer for linux in debian 9, it is a tool to transfer files, photos, etc. to our pc or vice versa.

    Open the terminal or bash, install as root or sudo:
    apt-get install build-essential cmake libqt4-dev ninja-build libfuse-dev libreadline-dev
    We hope you install the bookstores ...
    In another terminal or bash as a user we download from https://github.com/whoozle/android-file-transfer-linux the tool for this we must have git installed.
    git clone https://github.com/whoozle/android-file-transfer-linux
    Once the repository is cloned, we open the directory in the downloaded route.
    cd android-file-transfer-linux

    We have compiled ...
    cmake install.cmake
    make
    ./android-file-transfer
    Or we can also create a small scritp with privileges that makes it easier for us to open the tool from any part of the terminal:

    To create this script we open the terminal as root and place:



    cd /usr/local/bin

    We created a directory with name android-file-transfer
    nano android-file-transfer

    We put our script inside that directory ...
     
    #!/bin/bash
    echo Abriendo el IDE de android-file-transfer-linux
    cd /home/jesseshl/android-file-transfer-linux/qt/
    ./android-file-transfer
    Briefly explain this script which you can change, in the path cd / home / jesseshl / android-file-transfer-linux / qt / I'm giving you order to open that directory you must change to the path that has the tool installed ""

    Then we give you privileges with:
     
    chmod +x android-file-transfer
    With this we can open the tool just by placing android-file-transfer from our terminal. You can also create a launcher in my case with xfce, adding a new element in the panel as we can see in the following image.
    pitcher

    Continue Reading

    Bonding
    Good morning, today I will comment on something that many people do not know, others are not clear, but that ultimately is too useful: the union of network interfaces or bonding.

    · What is it?

    According to wikipedia:
     
    In computer networks, the term link aggregation applies to several methods of combining (aggregating) multiple network connections in parallel to increase performance beyond what a single connection could support and provide redundancy in case one of the links fail. A link aggregation group (LAG) combines a series of physical ports to create a single high-bandwidth data path, in order to implement the shared load of traffic between the member ports of the group and improve the reliability of the connection .
     
    The definition is quite clear, this technique provides parallel network connections to maximize performance, or to allow redundant network connections and maximize network availability. for example, to maximize availability, it allows network connections to "fail over" between a primary network device and any number of secondary devices, or alternatively, by selecting the highest available connection speed. This approach provides automatic configuration of wireless and wired networks with support of removable devices. The above is done using the active-backup mode  (I'll explain the available modes later).

    · Operation and advantages

    To explain the operation, we can build on the definition and also clarify some additional things that will allow and things that do not, the use of this technology:
    • It will not double your connection speed .
    • It allows you, among other things, to have in your computer the possibility of connecting to two different networks by wired and wireless connection, using one of them in a primary way and in case it fails, using the secondary network without suffering disconnections, interruption in the downloads, reconnections in services that require an uninterrupted connection (IRC, XMPP, etc), streaming interruption, among many other things using the active-backup mode that is what we are going to configure in this article.

    · Bonding modes

    This technology, has different modes of operation or bonding, each one of them does a different thing and I will explain them to cotinuación:
    0 (balance-rr) Round-robin policy : Transmit packets in sequential order from the first slave (slave) until the last. This mode provides load balancing and fault tolerance. 

    1 (active-backup) Active-backup policy : only one slave in the link is active. A different slave is activated if, and only if, the active slave fails. The MAC address of the link is externally visible on a single port (network adapter) to avoid confusing the switch. This mode provides fault tolerance. 

    2 (balance-xor) XOR policy :Transmission based on [(MAC address of origin XOR with destination MAC address) slave count in module]. This selects the same slave for each destination MAC address. This mode provides load balancing and fault tolerance. 

    3 (broadcast) Broadcast policy : transmits everything on all slave type interfaces. This mode provides fault tolerance. 

    4 (802.3ad) IEEE 802.3ad Dynamic link aggregation : Creates aggregation groups that share the same speed and duplex configurations. It uses all the slaves in the active aggregator according to the 802.3ad specification.
    (Prerequisites: compatibility with Ethtool in the basic controllers to recover the speed and duplex of each slave) A switch that supports the dynamic aggregation of IEEE 802.3ad links Most of the switches will require some type of configuration to enable the 802.3 mode ad). 


    5 (balance-tlb) Adaptive transmit load balancing : channel link that does not require any special switch support. The outgoing traffic is distributed according to the current load (calculated in relation to the speed) in each slave. Incoming traffic is received by the current slave. If the receiving slave fails, another slave assumes the MAC address of the failed slave slave.
    (Prerequisite: Ethtool support in the base controllers to recover the speed of each slave). 


    6 (balance-alb) Adaptive load balancing : includes balance-tlb plus load balancing (rlb) for IPV4 traffic, and does not require any special switch support. The load balancing received is achieved through the ARP negotiation. The link controller intercepts the ARP Responses sent by the local system when it leaves and overwrites the source hardware address with the unique hardware address of one of the slaves in the link, so that different pairs use different hardware addresses for the server.

    · Requirements for bonding

    For this article we will use systemd-networkd and two network cards, if you are not using this network administrator, you can do the migration in a simple way (in case you already use it, you can continue to the section " Configuring the union of interfaces. "). 
    1. Disable your current network manager (NetworkManager, wicd, etc) using the systemctl command, for NetworkManager it would be:
      $ sudo systemctl disable NetworkManager.service NetworkManager-wait-online.service # Para Network Manager
      
      $ sudo systemctl disable wicd.service # Para wicd
    2. The next step is to configure our network interfaces, to know what they are, we will execute:
      $ ls /sys/class/net/
      enp2s0  lo  wlp3s0
    3. In this case we have enp2s0 and wlp3s0 (the interface 'lo' is excluded when the loopback is). Now we proceed to configure them: 

      For the wired interface: we create the file '/etc/systemd/network/20-wired.network' for the wired connection with the following content:
      [Match]
      Name=enp2s0
      
      [Network]
      DHCP=ipv4
      DNS=9.9.9.9 # Esta línea te permite usar los servidores DNS seguros y privados de https://www.quad9.net/, si no desea usarlos, elimine esta línea.

      For the wireless network: first we will configure wpa_supplicant for wifi authentication and then we will create the .network file. 

      Configuration of wpa_supplicant:
      # Los siguientes comandos requieren privilegios root (no sudo).
      
      $ wpa_passphrase "Nombre de la red" 'Contraseña de la red' > /etc/wpa_supplicant/wpa_supplicant-wlp3s0.conf
      $ systemctl enable --now wpa_supplicant@wlp3s0

      We created a file called '/etc/systemd/network/25-wireless.network' with the following content:
      [Match]
      Name=wlp3s0
      
      [Network]
      DHCP=ipv4
      DNS=9.9.9.9 # Esta línea te permite usar los servidores DNS seguros y privados de https://www.quad9.net/, si no desea usarlos, elimine esta línea.
    4. We stop our previous network services using:
      $ sudo systemctl stop NetworkManager.service NetworkManager-wait-online.service # Para Network Manager
      
      $ sudo systemctl stop wicd.service # Para wicd
    5. We initiate systemd-network and we enable it to start automatically when the system starts:
      $ sudo systemctl enable --now systemd-networkd.service systemd-resolved.service systemd-networkd-wait-online
    With this we have finished the migration to the systemd network administrator, make sure you have access to the internet with the two interfaces before continuing.

    · Configuring the union of interfaces.

    Once we have systemd-networkd configured and running, we will configure the bonding.
    1. Configuring bonding: the first step is to create a virtual network device for our bond connection. 
      - We create a file called '/etc/systemd/network/10-bond1.netdev' with the following content:
      [NetDev]
      Name=bond1
      Kind=bond
      
      [Bond]
      Mode=active-backup
      PrimaryReselectPolicy=always
      TransmitHashPolicy=layer3+4
      MIIMonitorSec=1s
      LACPTransmitRate=fast
      - We configure the bond interface by creating a file called '/etc/systemd/network/10-bond1.network' with the following content:
      [Match]
      Name=bond1
      
      [Network]
      DHCP=ipv4
      DNS=9.9.9.9 # Esta línea te permite usar los servidores DNS seguros y privados de https://www.quad9.net/, si no desea usarlos, elimine esta línea.
      With this we finalize this step.
    2. The next thing is to go back to the files '/etc/systemd/network/20-wired.network' and '/etc/systemd/network/25-wireless.network' and edit them in this way so that they point to our bond interface: 

      '/etc/systemd/network/20-wired.network'
      [Match]
      Name=enp2s0
      
      [Network]
      Bond=bond1
      LinkLocalAddressing=no
      PrimarySlave=true
      Note: with the option PrimarySlave = true, we establish the priority of our network interface, this means that if it is connected, the interface in bonding mode will use this as primary and the secondary ones will only be activated in case it fails. Also once it is available again, the bond interface will make the change automatically to use the primary again. 

      '/etc/systemd/network/25-wireless.network'
      [Match]
      Name=wlp3s0
      
      [Network]
      LinkLocalAddressing=no
      Bond=bond1
    3. Now we re-start our network services with:
      $ sudo systemctl restart systemd-networkd.service systemd-resolved.service
    Once this is done, we will have finished, to verify it we execute:
    ➤➤ $ networkctl 
    IDX LINK             TYPE               OPERATIONAL SETUP     
      1 lo               loopback           carrier     unmanaged 
      2 enp2s0           ether              carrier     configured
      3 wlp3s0           wlan               carrier     configured
     66 bond1            bond               routable    configured
    
    4 links listed.
    We check the status of our bond interface with:
     ➤➤ $ cat /proc/net/bonding/bond1
    Ethernet Channel Bonding Driver: v3.7.1 (April 27, 2011)
    
    Bonding Mode: fault-tolerance (active-backup)
    Primary Slave: enp2s0 (primary_reselect always)
    Currently Active Slave: enp2s0
    MII Status: up
    MII Polling Interval (ms): 1000
    Up Delay (ms): 0
    Down Delay (ms): 0
    
    Slave Interface: wlp3s0
    MII Status: up
    Speed: Unknown
    Duplex: Unknown
    Link Failure Count: 1
    Permanent HW addr: xx:xx:xx:xx:xx:xx
    Slave queue ID: 0
    
    Slave Interface: enp2s0
    MII Status: up
    Speed: 1000 Mbps
    Duplex: full
    Link Failure Count: 4
    Permanent HW addr: xx:xx:xx:xx:xx:xx
    Slave queue ID: 0
    We can see that the Bonding Mode is correct according to our configurations ( active-backup ) and that our network interface enp2s0 is the primary one.
    Continue Reading