Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- ClipOn 3.0 Reference - c_encrypt() http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 C_ENCRYPT()

 DESCRIPTION

 C_ENCRYPT() converts a character string of data to a non-readable
 format.  This can be used to encrypt passwords or other sensitive
 data so that the data can be stored in a file in a secured format.
 An optional password key can also be used as an added measure of
 security.

 NOTES

 C_ENCRYPT() can accept a string up to 1023 characters in length.

 C_ENCRYPT() assumes that only readable characters (ASCII 32-127)
 are in the character string to encrypt.

 C_DECRYPT() must be used to return the data to it's original form.
 If a password key is used, the same must be used to decrypt the data.

 SYNTAX

 C_ENCRYPT(string [,password])

 PARAMETERS

 string (C) is the character string to encrypt.

 password (C) is a character string to be used as a password key to
 strengthen the data encryption.  If password is not specified, the
 string will be encrypted without a password.

 RETURNS

 C_ENCRYPT() returns an encrypted, non-readable character string.

 EXAMPLES

 use userfile        && Open user/password file

 m_id = space(10)
 m_pw = space(10)

 @ 0,0 say "Enter New Userid:   " get m_id     && Get user id
 @ 1,0 say "Enter New Password: " get m_pw     && and password
 read

 && Add new record and encrypt password using the user id as a key
 append blank
 replace userfile->id with m_id, ;
         userfile->pw with c_encrypt(m_pw, m_id)


See Also: C_DECRYPT()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson