#!/bin/bash # $1: IP, $2: Port RES=$(ssh -p $2 -i id_rsa joske@$1 "cat flag.txt") echo $RES if [[ "$RES" == *"IGCTF"* ]]; then exit 0 else exit 1 fi