diff options
author | Tar Committer <tar@ocjtech.us> | 2006-12-05 16:52:12 +0000 |
---|---|---|
committer | Tar Committer <tar@ocjtech.us> | 2006-12-05 16:52:12 +0000 |
commit | 1a7c45398738cdb4eaafdc9e0962272f19d54816 (patch) | |
tree | 6863882585a40ef9f65a9bab880a22fdb02c06ab /bin/alogin.in | |
parent | a0be206eb419f63eeb436631cc91b3456dff006f (diff) | |
download | rancid-1a7c45398738cdb4eaafdc9e0962272f19d54816.tar.gz rancid-1a7c45398738cdb4eaafdc9e0962272f19d54816.tar.xz rancid-1a7c45398738cdb4eaafdc9e0962272f19d54816.zip |
Imported from rancid-2.3.2a6.tar.gz.rancid-2.3.2a6
Diffstat (limited to 'bin/alogin.in')
-rw-r--r-- | bin/alogin.in | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/bin/alogin.in b/bin/alogin.in index ae3ddee..27286d7 100644 --- a/bin/alogin.in +++ b/bin/alogin.in @@ -1,7 +1,8 @@ #! @EXPECT_PATH@ -- ## -## $Id: alogin.in,v 1.33 2006/08/10 07:00:30 heas Exp $ +## $Id: alogin.in,v 1.35 2006/12/05 16:50:52 heas Exp $ ## +## @PACKAGE@ @VERSION@ ## Copyright (C) 1997-2006 by Terrapin Communications, Inc. ## All rights reserved. ## @@ -68,6 +69,9 @@ if {[ info exists env(CISCO_USER) ]} { } regexp {\(([^)]*)} "$reason" junk default_user } +if {[ info exists env(CLOGINRC) ]} { + set password_file $env(CLOGINRC) +} # Sometimes routers take awhile to answer (the default is 10 sec) set timeout 45 @@ -85,13 +89,16 @@ for {set i 0} {$i < $argc} {incr i} { set username [ lindex $argv $i ] } # VTY Password - } -v* - - -v* { + } -v* { if {! [ regexp .\[vV\](.+) $arg ignore passwd]} { incr i set passwd [ lindex $argv $i ] } set do_passwd 0 + # Version string + } -V* { + send_user "@PACKAGE@ @VERSION@\n" + exit 0 # Enable Username } -w* - -W* { |