This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
#Set up Linux and oracle | |
echo "Deploying Oracle..." | |
if [[ "$1" != "" ]] ; then | |
DEFAULT_PWD=$1 | |
echo "Using user specified default password" | |
else | |
DEFAULT_PWD=passW0RD |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Open firewall for port | |
FW_PORT=9877 | |
iptables -I INPUT 1 -p tcp -m tcp --dport $FW_PORT -j ACCEPT | |
iptables -I INPUT 1 -p tcp -m tcp --sport $FW_PORT -j ACCEPT | |
iptables -I OUTPUT 1 -p tcp -m tcp --sport $FW_PORT -j ACCEPT | |
iptables -I OUTPUT 1 -p tcp -m tcp --dport $FW_PORT -j ACCEPT | |
#save firewall rules | |
/sbin/service iptables save | |
/sbin/service iptables restart |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import hashlib | |
h = hashlib.new('sha256') | |
h.update(str) | |
print h.hexdigest() |
NewerOlder