Reviewed November 2008
xcall MIAMEX, MX_PWCRYPT, clearpw, cryptpw {,type}
MX_PWCRYPT is used for for simple password encryption. It is useful for use in GDI files to avoid revealing SMTP passwords.
You specify clearpw, the clear text version of password, and it returns cryptpw, the encrypted version. Note that this is a relatively simplistic password encryption mechanism known to A-Shell and ATE, which is recognized by the fact that the first character will be a chr(2). If you have a need to decrypt them, contact MicroSabio for details. We did not publish the decryption scheme because it would compromise what limited security it offers.
The optional type argument allows you to create the original 7-bit style password encryption used by earlier versions of ATE, in addition to the newer 8-bit style. The two types of encrypted passwords can be distinguished by the first byte: chr(1) indicates type 1 (7 bit), while chr(2) indicates type 2 (8 bit). If not specified, the routine uses type 2.
History
2010 February, A-Shell 5.1.1175: Maximum length of passwords increased from 24 to 128.
2008 November, A-Shell 5.1.1130: New type parameter allows for selection of either 7- or 8-bit encryption.
2008 April, A-Shell 5.1.1124: Routine added to A-Shell.