This file contains hidden or 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
# Reversing container for CTFs by mcd1992 | |
# docker run -ti --rm -v `pwd`:/workdir/ --security-opt seccomp:unconfined -P mcd1992/archctf:latest | |
FROM archlinux/base:latest | |
MAINTAINER mcd1992 | |
# Make port 31337 available for listening (must use -p for publishing) | |
EXPOSE 31337 | |
# Enable pacman colors and multilib repo; add vim to editor /etc/profile; set LOCALE to en_US.UTF-8 |
This file contains hidden or 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/bash | |
# figure out the absolute path to the script being run a bit | |
# non-obvious, the ${0%/*} pulls the path out of $0, cd's into the | |
# specified directory, then uses $PWD to figure out where that | |
# directory lives - and all this in a subshell, so we don't affect | |
# $PWD | |
GAMEROOT=$(cd "${0%/*}" && echo $PWD) |
This file contains hidden or 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
function unrequire( modName ) | |
if( not modName ) then return end | |
local _R = debug.getregistry() | |
local moduleMetatable = _R["_LOADLIB"] | |
package.loaded[ modName ] = nil | |
_G[ modName ] = nil | |
for k, ud in pairs( _R ) do | |
if( (type(k) == "string") and string.find( k, "^LOADLIB: .+gm.._" .. modName .. "_.+%.dll$" ) and (type(ud) == "_LOADLIB") and (getmetatable(ud) == moduleMetatable) ) then | |
print( "Unloading: " .. k ) |