I'm working with a vendor's API and it recommends the following steps for transmitting an encrypted value:
1) Convert the encryption password to a byte array.
2) Convert the value to be encrypted to a byte array.
3) The entire length of the array is inserted as the first four bytes onto the front of the first block of the resultant byte array before encryption.
4) Encrypt value with AES
Just curious, do steps 1-3 make the encrypted values significantly more secure than if they just started with step 4? Is this a recommended practice?
It is making implementation more complicated.