New answers tagged c++
The way I made it work is by copying SSL_write implementation and manually modifying padding after encryption. SSL_write uses other non-public functions (from a couple of files) and few macros, those must be copied as well. Correct implementation of TLS protocol must check padding size and all bytes must be set to the same value (by default it's zeros in ...
A harmless executable that copies (at least part of it) would be a zipper tool that creates an self-unzipping executable archive. These tools are not so much en vogue today as the have been for obvious reasons.
Metasploit has ways to embed executables in other files. You can use it to launch calc.exe, for your example. The full detailed manual is here, but it might take a while for you to get the hang of it.
Top 50 recent answers are included