From m204wiki
Jump to navigation Jump to search

The $ENCRYPT function performs a one-way encryption of a zero to eight-character string. Longer strings are truncated at eight characters. The result of this function is an eight-byte encrypted representation of the input string.


The format of $ENCRYPT is:


$ENCRYPT accepts the second argument (parameter) so that the same source string can be encrypted to different strings in different systems.

Note: You should use a parameter value of less than 1000 for best performance; numbers significantly larger than 1000 can cause serious performance degradation.



returns one encrypted value if %PARAM equals 28 and another value if %PARAM equals 18. If no parameter is supplied, a default of 15 is used. A null string is returned and an error message is issued if a parameter of zero or a negative value is specified.