PRIMARY CATEGORY → ZSH

In this Setup environment, all the following Shell Functions are declared in the custom.zsh script

Then, the custom.zsh script is sourced from the .zshrc file as follows →

# ~/.zshrc - Custom Functions
if [[ -f /home/al3xbb/.config/zsh/src/custom.zsh ]] ; then
    source /home/al3xbb/.config/zsh/src/custom.zsh
fi

Custom.zsh Source File → See here

Terminal/Screen

Shell Functions related to the Terminal and Screen actions →

clearScreenAndScrollback

Reference

It clears the Screen Content and Scrollback Buffer through the C-l keybind

More info here

Pentesting

Shell Functions related to the Pentesting Process

Most of the functions are Non-POSIX-Compliant as ZSH is the Targeted Shell

mkt

It creates a Pentesting Folder Structure to store all documentation related to the target 🎯

validateIP

This function simply checks if the IP Address entered as an argument is valid

It is used by the setTarget function

setTarget

It sets the Target’s IP Address and Hostname as one of the Polybar Bar’s Modules

This function prints the above data into the /home/al3xbb/.config/bin/target file

Then the Polybar Module carries out an action based on that File’s Content as follows →

  • If Empty“No target” as Polybar’s Bar Content
  • If not EmptyFile’s Content as the Polybar’s Bar Content, i.e. the IP Address and Hostame

clearTarget

This functions empties the /home/al3xbb/.config/bin/target file

Therefore, as mentioned in the setTarget function, the Polybar Module sets “No Target” as Polybar Bar’s Content