Hi,
I want to insert data from one file to another file. My requirement goes this way:
I have a file1 with data as:
12345
43534
56678
23545
12343
and so on...
I have a file2 with data as:
name1:abc:12:9999
name2:ght:1:9999
name3:wrt:17:9999
name3:erc:22:9999
name4:xyz:16:9999
... (1 Reply)
Hi Guys,
I am trying to write a perl script to search a string "Name" in the file "FILE" and also want to create a new file and push the searched string Name line along with 10 lines following the same.
can anyone of you please let me know how to go about it ? (8 Replies)
I am having difficulty with the following script:
#! /bin/bash
filelist=~/data/${1}*
~/./convertFile $filelist ~/temp/outputEssentially, there are a large number of files in the directory ~/data, each with a four-letter code at the beginning (eg. aaaa001 aaaa002 bbbb001 bbbb002 etc). The... (11 Replies)
Can someone tell me how I can do this?
e.g:
Say file1.txt contains:
today is monday
the 22 of
NOVEMBER
2010
and file2.txt contains:
the
11th
month
of
How do i replace the word NOVEMBER with (5 Replies)
I am having a text file which is having more than 200 lines.
EX:
001010122 12000 BIB 12000 11200 1200003
001010122 2000 AND 12000 11200 1200003
001010122 12000 KVB 12000 11200 1200003
In the above file i want to search for string KVB and add/replace... (1 Reply)
Dear All
I am having a text file which is having more than 200 lines.
EX:
001010122 12000 BIB 12000 11200 1200003
001010122 2000 AND 12000 11200 1200003
001010122 12000 KVB 12000 11200 1200003
In the above file i want to search for string KVB... (5 Replies)
Hi,
I want to achieve something similar to what described in another post:
The difference is I want to add the line if the pattern is not found.
File 1:
A123, valueA, valueB
B234, valueA, valueB
C345, valueA, valueB
D456, valueA, valueB
E567, valueA, valueB
F678, valueA, valueB
... (11 Replies)
Discussion started by: jyu3
11 Replies
LEARN ABOUT NETBSD
pwhash
PWHASH(1) BSD General Commands Manual PWHASH(1)NAME
pwhash -- hashes passwords from the command line or standard input
SYNOPSIS
pwhash [-km] [-b rounds] [-S rounds] [-s salt] [-p | string]
DESCRIPTION
pwhash prints the encrypted form of string to the standard output. This is mostly useful for encrypting passwords from within scripts.
The options are as follows:
-b rounds
Encrypt the string using Blowfish hashing with the specified rounds.
-k Run in makekey(8) compatible mode. A single combined key (eight chars) and salt (two chars) with no intermediate space are read from
standard input and the DES encrypted result is written to standard output without a terminating newline.
-m Encrypt the string using MD5.
-p Prompt for a single string with echo turned off.
-S rounds
Encrypt the salt with HMAC-SHA1 using the password as key and the specified rounds as a hint for the number of iterations.
-s salt
Encrypt the string using DES, with the specified salt.
If no string is specified, pwhash reads one string per line from standard input, encrypting each one with the chosen algorithm from above.
In the event that no specific algorithm is given as a command line option, the algorithm specified in the default class in /etc/passwd.conf
will be used.
For MD5 and Blowfish a new random salt is automatically generated for each password.
Specifying the string on the command line should be discouraged; using the standard input is more secure.
FILES
/etc/passwd.conf
SEE ALSO crypt(3), passwd.conf(5)BSD October 16, 2009 BSD