def corruptDLL():
 createAssembly('CORRUPT', 'CORRUPT', (-1))
 file = open('fooCORRUPT.dll', 'rb')
 joe = file.readlines()
 file.close()
 joe.insert((len(joe) / 2), 'File is now corrupted...\n')
 file = open('fooCORRUPT.dll', 'wb')
 file.writelines(joe)
 file.close()

def corruptDLL ( ) : createAssembly ( 'CORRUPT' , 'CORRUPT' , ( - 1 ) ) file = open ( 'fooCORRUPT.dll' , 'rb' ) joe = file . readlines ( ) file . close ( ) joe . insert ( ( len ( joe ) / 2 ) , 'File is now corrupted...\n' ) file = open ( 'fooCORRUPT.dll' , 'wb' ) file . writelines ( joe ) file . close ( )
places a corrupt copy of ironpython .