rand(1openssl) OpenSSL rand(1openssl)NAME
rand - generate pseudo-random bytes
SYNOPSIS
openssl rand [-out file] [-rand file(s)] [-base64] num
DESCRIPTION
The rand command outputs num pseudo-random bytes after seeding the random number generator once. As in other openssl command line tools,
PRNG seeding uses the file $HOME/.rnd or .rnd in addition to the files given in the -rand option. A new $HOME/.rnd or .rnd file will be
written back if enough seeding was obtained from these sources.
OPTIONS -out file
Write to file instead of standard output.
-rand file(s)
Use specified file or files or EGD socket (see RAND_egd(3)) for seeding the random number generator. Multiple files can be specified
separated by a OS-dependent character. The separator is ; for MS-Windows, , for OpenVMS, and : for all others.
-base64
Perform base64 encoding on the output.
SEE ALSO RAND_bytes(3)OpenSSL-0.9.8 Oct 11 2005 rand(1openssl)
Check Out this Related Man Page
gendsa(1openssl) OpenSSL gendsa(1openssl)NAME
gendsa - generate a DSA private key from a set of parameters
SYNOPSIS
openssl gendsa [-out filename] [-des] [-des3] [-idea] [-rand file(s)] [-engine id] [paramfile]
DESCRIPTION
The gendsa command generates a DSA private key from a DSA parameter file (which will be typically generated by the openssl dsaparam com-
mand).
OPTIONS
-des|-des3|-idea
These options encrypt the private key with the DES, triple DES, or the IDEA ciphers respectively before outputting it. A pass phrase is
prompted for. If none of these options is specified no encryption is used.
-rand file(s)
a file or files containing random data used to seed the random number generator, or an EGD socket (see RAND_egd(3)). Multiple files
can be specified separated by a OS-dependent character. The separator is ; for MS-Windows, , for OpenVMS, and : for all others.
-engine id
specifying an engine (by it's unique id string) will cause req to attempt to obtain a functional reference to the specified engine,
thus initialising it if needed. The engine will then be set as the default for all available algorithms.
paramfile
This option specifies the DSA parameter file to use. The parameters in this file determine the size of the private key. DSA parameters
can be generated and examined using the openssl dsaparam command.
NOTES
DSA key generation is little more than random number generation so it is much quicker that RSA key generation for example.
SEE ALSO dsaparam(1), dsa(1), genrsa(1), rsa(1)OpenSSL-0.9.8 Oct 11 2005 gendsa(1openssl)
Hi folks
I'm coding on Ubuntu 9.04 standard shell.
I'm writing a script that needs to generate a random number at some point of its execution.
When I do
echo $RANDOMas a command inside shell, I clearly get some randomly generated number
However when I do
i=`$RANDOM`
echo $ior even... (14 Replies)
Hi,
Following is the trimmed down version of the code I'm using to generate a set of random numbers using erand48
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
main()
{
unsigned short xsubi;
xsubi=10;
double r;
int x;
int i=0,... (14 Replies)
Hi I'm trying to remove blank spaces in expressions and function calls..
Consider the following example
printf ("Hello");
a = a + b;
I'm trying to eliminate space in between the function name and the opening brace. And also eliminate space between operators and operands..
That is, I'm... (19 Replies)
Hi, im trying to make a shell script that basically runs a random shell script form a list of shell scripts i specify. Im not very good at writing shell scripts, and am new to linux.
Thanks in advance :) (15 Replies)
Hi,
Is there a tool somewhat parallel to rev, but which randomizes instead of reverses?
I've tried rl, but I can only get it to randomize words.
I was hoping for something like this
echo "hello" | ran
leolh
less simpler solutions are also welcome.
Sorry if the question is... (21 Replies)
Hello,
This is my code:
nb_lignes=`wc -l $1 | cut -d " " -f1`
for i in $(seq $nb_lignes)
do
m=`head $1 -n $i | tail -1`
//command
done
Please how can i change it to get Get 20% of lines in File randomly to apply "command" on each line ? 20% or 40% or 60 % (it's a parameter)
Thank you. (15 Replies)
I have two files containing hundreds of different sequences with the same Identifiers (ID-001, ID-002, etc.,), something like this:
Infile1:
ID-001 ATGGGAGCGGGGGCGTCTGCCTTGAGGGGAGAGAAGCTAGATACA
ID-002 ATGGGAGCGGGGGCGTCTGTTTTGAGGGGAGAGAAGCTAGATACA
ID-003... (18 Replies)
Hi,
I've been attempting to create a script that downloads web pages at random intervals to mimic typical user usage. However I'm struggling to link $url to the URL list and thus wget complains of a missing URL. Any ideas?
Thanks
#!/bin/sh
#URL List
url1="http://www.bbc.co.uk"... (14 Replies)
Hello,
I have a column which have 7200 numbers and I am deciding to pick up 1440 numbers randomly without any reputation? Could any one let me know which script in unix will be work for my case?
Regards
Sajjad (17 Replies)
Hi,
I am in a terrible emergency. I have multiple cdr files with line count >6000.
I need to append |0| | | | | | | |random| to end of each line. The random number should never repeat.
Please help with a shell script to process all cdr's in a directory with above requirement. (23 Replies)
Hi there,
first of all this is not homework...this is a new type of exercise for practicing vocabulary with my students.
I have a file consisting of two columns, separated by a tab, each line consisting of a word and its definition, separated by a line break.
What i need is to replace a... (15 Replies)
So I started with following the example on the omnios page for bhyve (sorry, I can't provide the link because I'm a post shy of the 5 to give a URL):
And found that in the end I was able to create a running bhyve zone, but accessing it via zlogin results in a blank console. I've tried Debian 9... (14 Replies)
Hello. I am installing Kali Linux on a laptop with no monitor. The installation goes fine through the external monitor and I can see the GRUB menu on boot, but once it comes time to log in it acts like my non existant laptop screen is my main monitor to type my login info on while my external is... (14 Replies)