Now do the same again, but instead of just implementing your algorithm directly, use a few hundred npm packages to achieve the same. Don't forget to convert to/from base64 a bunch, and obviously make sure the famous leftPad is involved every step of the way.
For fairness you can use a heavy sprinkling of inappropriate boost in the C++ side.