- Get the reverse shell in netcat
- check python support in the target system
which python
- If your terminal is using zsh, then you need to switch to bash
#!/bin/bash | |
# Enabling ADB over network | |
# adb kill-server && adb start-server # restart adb server | |
# adb tcpip 5555 # start adb service | |
# adb connect <phone_id> # connect to the device | |
# For enabling loudspeaker and cut the call, make sure to change it based on your phone screen | |
# Ref for getting touch coordinates: https://android.stackexchange.com/questions/164295/how-can-i-see-the-pointer-location-and-simulate-it |
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
config.vm.box = "ubuntu/xenial64" | |
config.vm.box_check_update = false | |
# Spark Jobs history | |
config.vm.network "forwarded_port", guest: 4040, host: 4040 | |
# Spark Master | |
config.vm.network "forwarded_port", guest: 8080, host: 8080 |
#!/bin/bash | |
# Global variable declarations | |
format="plain" | |
directories=() | |
current_directory=`pwd` | |
report_directory="${current_directory}/report/" | |
fresh_report_directory="0" | |
# usage |
#!/bin/bash | |
# Loops through the proc directory | |
for processId in `ls /proc/`; do | |
# Checks for the status file for a process | |
if [[ $processId =~ ^[0-9]+$ && -r "/proc/${processId}/status" ]]; then | |
# Gets the swap space usage for the process | |
swapUsage=`grep VmSwap "/proc/${processId}/status" | awk '{print $2}'` | |
if [[ ! -z $swapUsage && $swapUsage > 0 ]]; then | |
# Gets the process name |
# utility function which is used to create and change | |
# to the given directory name | |
# Add to the .bashrc file | |
# usage: | |
# mkcd directory_name | |
mkcd() { | |
local directory_name="${1}" | |
if [ -z $directory_name ] | |
then | |
echo "Pass the directory name as the argument!!!" > /dev/stderr |
#!/bin/bash | |
################################################################################# | |
# # | |
# - Removes the duplicate normal files from the given directory and makes them # | |
# as the hard link for the non removed file. # | |
# - The non removed file is the one which comes first in the lexical ordering # | |
# - Script uses fdupes utility to find out the duplicate files # | |
# # | |
# = Usage: bash script.sh duplicate_files_folder # |
#!/bin/bash | |
############################################################# | |
# | |
# Restarts the Network Manager automatically when the | |
# Network disconnects, because of wifi connectivity problem | |
# | |
############################################################# | |
# Function which checks for the root user execution |
#!/bin/bash | |
######################################################## | |
# | |
# Checks for Network connection by using Ping utility | |
# | |
######################################################## | |
# Main flow of Execution | |
main() { |
#!/bin/bash | |
#================================================ | |
# Removes the Docker images based on conditions | |
#================================================ | |
# Variable Declaration | |
declare -A image_exclusion=( ["node"]="8-alpine" ["jenkins"]="latest" ) | |
# Checks whether image has been excluded or not |