07-23-2008
Help on what? IMHO it's using a different algorithm to encrypt the pw. What's the problem with that? Need a bit more info.
10 More Discussions You Might Find Interesting
1. AIX
hi,
I have a problem with unicode chars ( chinese, japanese etc ) insertion using sqlplus prompt.
When i wrote a proc program for it i am able to create records.
But when i fore the same query on sql prompt it stores reverse ????? ..some junk.
widechar columns are mapped with NVARCHAR datatype.... (0 Replies)
Discussion started by: suman_jakkula
0 Replies
2. HP-UX
Hi all,
We are facing the following problem in our HP-UX machine: software that manipulates utf-8 encoded strings (e.g. during string cut), fails to correctly manipulate strings (all containing Greek characters) that contain special characters like @, &, # etc. Actually, in different... (3 Replies)
Discussion started by: alina
3 Replies
3. Shell Programming and Scripting
Hi All,
I have a CSV file in which some fields contains special character for ex:-
my file is file 1
cat file1
abcd,bgfht,ngbht,abvc ****
hdlld,hsgdt,bhfy,knht ****
whenever i am trying to put a 4th feild in a variable its giving me list of all the files i have in current... (6 Replies)
Discussion started by: sam25
6 Replies
4. Shell Programming and Scripting
Hello,
if I try this (in bash):
#!/bin/bash
cat leercaracter.sh | while read linea
do
# read character by character
echo $linea | while read -n 1 caracter
do
echo $caracter
done
done
New lines, spaces, tabs aren't showed by echo.
How can I 'echo' those characters?... (7 Replies)
Discussion started by: albertogarcia
7 Replies
5. Shell Programming and Scripting
Hi all,
I'm learning sed (and regular expressions) - My first little program is to replace 3 numbers in a row with 'XXX'
This is what I am trying:
echo '511' | sed 's/{3}/XXX/'
Here is the output:
defunct-macbook-pro:~ defunct$ echo '511' | sed 's/{3}/XXX/'
511For some reason, it doesnt... (2 Replies)
Discussion started by: Defunct
2 Replies
6. Solaris
Hello,
I have large xml files with chinese characters on a windows box and they need to be FTP'd to UNIX box. When I ftp the file, the chinese text converts to junk characters.
I tried changing my setting on putty to UTF-8, but still cannot view the correct text. Is there something I need to... (4 Replies)
Discussion started by: tokool420
4 Replies
7. Shell Programming and Scripting
I'm trying to figure out a problem. I echo a colored block character with this code:
echo -e '\E
It works. But the challenge is echoing two different blocks with two different colors. I tried everything. Heres what i tried:
echo -e '\E
Doesn't work. It only echoes the first block.... (2 Replies)
Discussion started by: tinman47
2 Replies
8. Shell Programming and Scripting
Hi,
I am facing a below problem. Inorder to mak sure the below file is fixed width i am using the following command
awk '{printf("%-375s\n", $0) } so as to add trailing spaces at the end for records of length less than 375.
Input file > inp.txt
1©1234
1234
123©1
The output file is... (1 Reply)
Discussion started by: marcus_kosaman
1 Replies
9. Shell Programming and Scripting
grep -i "$line,$opline" COMBO_JUNK|awk -F, '
{
C4+=$4
}
{
}
END {
print C4
}
' OFS=,`
when i run this command in the script.... it o/p all the value as 0 if $line contains any special parameters.....
but the same script if i run in command prompt... it shows... (4 Replies)
Discussion started by: nikhil jain
4 Replies
10. Shell Programming and Scripting
I am using Korn shell on Linux 2.6x platform , and I am suing the following code to capture the lines which contain CONTROL CHARACTERS in my file :
awk '/]/ {print NR}' EROLLMENT_INPUT.txt
The problem is that this code shows the file has control characters when the file is in folder A ,... (2 Replies)
Discussion started by: kumarjt
2 Replies
LEARN ABOUT LINUX
setkey_r
ENCRYPT(3) Linux Programmer's Manual ENCRYPT(3)
NAME
encrypt, setkey, encrypt_r, setkey_r - encrypt 64-bit messages
SYNOPSIS
#define _XOPEN_SOURCE
#include <unistd.h>
void encrypt(char block[64], int edflag);
#define _XOPEN_SOURCE
#include <stdlib.h>
void setkey(const char *key);
#define _GNU_SOURCE
#include <crypt.h>
void setkey_r(const char *key, struct crypt_data *data);
void encrypt_r(char *block, int edflag, struct crypt_data *data);
Each of these requires linking with -lcrypt.
DESCRIPTION
These functions encrypt and decrypt 64-bit messages. The setkey() function sets the key used by encrypt(). The key argument used here is
an array of 64 bytes, each of which has numerical value 1 or 0. The bytes key[n] where n=8*i-1 are ignored, so that the effective key
length is 56 bits.
The encrypt() function modifies the passed buffer, encoding if edflag is 0, and decoding if 1 is being passed. Like the key argument, also
block is a bit vector representation of the actual value that is encoded. The result is returned in that same vector.
These two functions are not reentrant, that is, the key data is kept in static storage. The functions setkey_r() and encrypt_r() are the
reentrant versions. They use the following structure to hold the key data:
struct crypt_data {
char keysched[16 * 8];
char sb0[32768];
char sb1[32768];
char sb2[32768];
char sb3[32768];
char crypt_3_buf[14];
char current_salt[2];
long int current_saltbits;
int direction;
int initialized;
};
Before calling setkey_r() set data->initialized to zero.
RETURN VALUE
These functions do not return any value.
ERRORS
Set errno to zero before calling the above functions. On success, it is unchanged.
ENOSYS The function is not provided. (For example because of former USA export restrictions.)
CONFORMING TO
The functions encrypt() and setkey() conform to SVr4, SUSv2, and POSIX.1-2001. The functions encrypt_r() and setkey_r() are GNU exten-
sions.
NOTES
In glibc 2.2 these functions use the DES algorithm.
EXAMPLE
You need to link with libcrypt to compile this example with glibc. To do useful work the key[] and txt[] arrays must be filled with a use-
ful bit pattern.
#define _XOPEN_SOURCE
#include <unistd.h>
#include <stdlib.h>
int
main(void)
{
char key[64]; /* bit pattern for key */
char txt[64]; /* bit pattern for messages */
setkey(key);
encrypt(txt, 0); /* encode */
encrypt(txt, 1); /* decode */
}
SEE ALSO
cbc_crypt(3), crypt(3), ecb_crypt(3), feature_test_macros(7)
COLOPHON
This page is part of release 3.27 of the Linux man-pages project. A description of the project, and information about reporting bugs, can
be found at http://www.kernel.org/doc/man-pages/.
2003-04-04 ENCRYPT(3)