Utilizando un nuevo CMS, periodo de pruebas…
Ejemplo de código:
#!/usr/bin/perl
#===================================================================#
# Program => agent_pass.pl (In Perl 5.0) version 0.0.1 #
#===================================================================#
# Autor => Fernando "El Pop" Romo (pop@cofradia.org) #
# Creation date => 17/March/2006 #
#-------------------------------------------------------------------#
# Info => A Silly program to generate Agent Login Passwords #
#-------------------------------------------------------------------#
# This code are released under the GPL 1.0 License. Any change must #
# be report to the authors #
# (c) 2006 - Fernando Romo / Neocenter #
#-------------------------------------------------------------------#
# The change history is at the end of the file #
#===================================================================#
# Last update:
# $Id: agent_pass.pl,v 1.1 2006/03/17 07:52:57 pop Exp $
use strict;
srand;
# The @chars array could take other values to generate alphabetic passwords
# v.g.: @chars = ( "A" .. "Z", "a" .. "z", 0 .. 9, qw(! @ $ % ^ & *) );
# we use only numbers to generate passwords for a phone pad.
my @chars = (0 .. 9);
# Test Arguments, in $ARGV[0] is the password length and
# $ARGV[1] the number of passwords to generate
if ($ARGV[0] > 0 && $ARGV[1] > 0) {
for (my $i=1;$i<=$ARGV[1];$i++) {
my $password = join("", @chars[ map { rand @chars } ( 1 .. $ARGV[0] ) ]);
print "$password\n";
}
} else {
print "Usage: random.pl \[password length\] \[number of password's to generate\] \n";
}
#============================================================================#
# Change History #
#----------------------------------------------------------------------------#
#
# $Log: agent_pass.pl,v $
# Revision 1.1 2006/03/17 07:52:57 pop
# A simple program to generate Random Agent passwords to use in phone,
# could be use as well to generate Authorization codes for users.
#
#
#============================================================================#
y un ejemplo con video de youtube:
httpv://www.youtube.com/watch?v=PBcGdJWnK7A

Leave a Reply
You must be logged in to post a comment.