need encrypt form


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting need encrypt form
# 1  
Old 03-08-2008
need encrypt form

Hi,
i need to encrypt and decrypt of a string. pls provide me some syntax or any method available using shell script.

i know one method i.e.,
perl -e 'print pack "H*","message"'
so if perl command doesnt work then what is the other method to encrypt and decrypt.

Thanks in advance.
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Encrypt script

Hi, I have to encrypt my ash scripts on a distribution of linux with Armv5tejl Buildroot , I tried a lot of solutions but none works . Someone can help me? Thanks, Nicola (7 Replies)
Discussion started by: n.rito
7 Replies

2. Shell Programming and Scripting

Remove x lines form top and y lines form bottom using AWK?

How to remove x lines form top and y lines form bottom. This works, but like awk only cat file | head -n-y | awk 'NR>(x-1)' so remove last 3 lines and 5 firstcat file | head -n-3 | awk 'NR>4' (5 Replies)
Discussion started by: Jotne
5 Replies

3. Shell Programming and Scripting

Transpose Data form Different form

HI Guys, I have data in File A.txt RL03 RL03_A_1 RL03_B_1 RL03_C_1 RL03 -119.8 -119.5 -119.5 RL07 RL07_A_1 RL07_B_1 RL07_C_1 RL07 -119.3 -119.5 -119.5 RL15 RL15_A_1 RL15_C_1 RL15 -120.5 -119.4 RL16... (2 Replies)
Discussion started by: asavaliya
2 Replies

4. Shell Programming and Scripting

Encrypt and Decrypt

I have script for all oracle prod db. I have hard coded the username / password. I need a mechanism to encode and decode the username / password in a shell script. Another challenge is I use the username and password in a Select command for oracle DB. How can call the decrypted... (2 Replies)
Discussion started by: ilugopal
2 Replies

5. Shell Programming and Scripting

Need help with file encrypt

Hi I need to encrypt the below file using the translate command to shift each letter five characters to the end of the character set. ALPHABETICAL FACTS. THE FIRST THREE LETTERS ARE ABC. THE MEDIAN LETTERS ARE MN. THE LAST THREE LETTERS ARE XYZ. THE FIRST WORD IN MY DISCTIONARY IS AAL. THE... (1 Reply)
Discussion started by: drew211
1 Replies

6. Shell Programming and Scripting

How to Encrypt password

Hello, I have a paramter file, In which I store all the user-ids and passwords for the project. So if a user just invokes the paramter file he has access to all the variables, which i have exported in the parmatere file. Now if a user echo's the variable which stores the databse password.... (1 Reply)
Discussion started by: DSDexter
1 Replies

7. Shell Programming and Scripting

Tr utility to Encrypt

I need some help.. I would like to make a script that uses the tr utility to "encrypt" a selected file. I need to know how to set up the script so that if i type encrypt(script name) the letter that i want to start the encryption and then the file name, that it starts with the entered letter, and... (1 Reply)
Discussion started by: frankthetank115
1 Replies

8. Programming

Help with encrypt function

Hi there, I need to include a simple encryption function in a C program and I came across this function void encrypt(char block, int edflag) whic is defined in #include des_crypt.h. According the man "the block argument to encrypt() is a character array of length 64 containing only the... (1 Reply)
Discussion started by: giggi
1 Replies

9. UNIX for Advanced & Expert Users

Changing Unix form to Microsoft Word form to be able to email it to someone.

Please someone I need information on how to change a Unix form/document into a microsoft word document in order to be emailed to another company. Please help ASAP. Thankyou :confused: (8 Replies)
Discussion started by: Cheraunm
8 Replies
Login or Register to Ask a Question
crypt(3)						     Library Functions Manual							  crypt(3)

Name
       crypt, crypt16, setkey, encrypt - DES encryption

Syntax
       char *crypt(key, salt)
       char *key, *salt;

       char *crypt16(key, salt)
       char *key, *salt;

       void setkey(key)
       char *key;

Description
       The  subroutine is the password encryption routine.  It is based on the NBS Data Encryption Standard, with variations intended to frustrate
       use of hardware implementations of the DES for key search.

       The first argument to is normally a user's typed password.  The second is a 2-character string chosen from the set [a-zA-Z0-9./].  The salt
       string  is  used to perturb the DES algorithm in one of 4096 different ways, after which the password is used as the key to encrypt repeat-
       edly a constant string.	The returned value points to the encrypted password, in the same alphabet as the salt.	The first  two	characters
       are the salt itself.

       The subroutine is identical to the function except that it will accept a password up to sixteen characters in length. It generates a longer
       encrypted password for use with enhanced security features.

       The other entries provide primitive access to the actual DES algorithm.	The argument of is a character array of length 64 containing  only
       the characters with numerical value 0 and 1.  If this string is divided into groups of 8, the low-order bit in each group is ignored, lead-
       ing to a 56-bit key which is set into the machine.

       The argument to the entry is likewise a character array of length 64 containing 0s and 1s.  The argument array is modified in  place  to  a
       similar	array  representing the bits of the argument after having been subjected to the DES algorithm using the key set by If edflag is 0,
       the argument is encrypted; if non-zero, it is decrypted.

Restrictions
       The return values from and point to static data areas whose content is overwritten by each call.

Environment
   Default Environment
       In the default environment on systems that do not have the optional encryption software installed the function expects  exactly	one  argu-
       ment,  the data to be encrypted. The edflag argument is not supplied and there is no way to decrypt data.  If the optional encryption soft-
       ware is installed the function behaves as it does in the POSIX environment.  The syntax for the default environment follows:
	    void encrypt(block)
	    char *block;

   POSIX Environment
       In the POSIX environment the encrypt function always expects two arguments.  The function will set errno to ENOSYS and return if edflag	is
       non-zero and the optional encryption software is not present.  The syntax for the POSIX environment follows:
	    void encrypt(block, edflag)
	    char *block;
	    int edflag;

       In all cases the function will set errno to ENOSYS and return if the optional encryption software is not present.

See Also
       login(1), passwd(1), yppasswd(1yp), getpass(3), auth(5), passwd(5), passwd(5yp)
       ULTRIX Security Guide for Users and Programmers

																	  crypt(3)