Change enable password via SNMP

Discussion in 'Cisco' started by Craig B., Oct 5, 2004.

  1. Craig B.

    Craig B. Guest

    I'm trying to write a VB app that changes our admin passwords on our
    Cisco switches and routers. I initially tried writing a telnet script
    tool to do this but ran into some problems with that. I've considered
    using "expect" to do this and run it as a shell from within the VB
    app. I find that a bit chesey, but will do it as a last resort.

    Can you chang the enable and enable secret password via SNMP?

    If so, what is the SNMP string to get there?

    Thanks in adavance.

    Craig
     
    Craig B., Oct 5, 2004
    #1
    1. Advertising

  2. Craig B.

    Andrej Brkic Guest

    On 2004-10-05, Craig B. <> wrote:
    > I'm trying to write a VB app that changes our admin passwords on our
    > Cisco switches and routers. I initially tried writing a telnet script
    > tool to do this but ran into some problems with that. I've considered
    > using "expect" to do this and run it as a shell from within the VB
    > app. I find that a bit chesey, but will do it as a last resort.
    >
    > Can you chang the enable and enable secret password via SNMP?
    >
    > If so, what is the SNMP string to get there?
    >


    Well the easy way would be to have the new enable (or enable secret)
    as config item in plaintext file and just do 'conf net' via snmp
    pointing to your tftp server containg a file with a new password.

    For example:

    snmpset <router> <community> .iso.org.dod.internet.private.enterprises.cisco.local.lsystem.hostConfigSet.192.168.0.1 s <filename>

    Replace 192.168.0.1 with your tftp servers address and the filename with the
    file containing the new enable password.

    After that you can do 'write mem' via snmp to save the new config

    snmpset <router> <community> .iso.org.dod.internet.private.enterprises.cisco.local.lsystem.writeMem.0 i 1

    Examples above are for UCD SNMP. You could put it all in a small script
    and feed the IP's of your routers/switches to it.

    --
    Andrej Brkic
    Fakultet Prometnih Znanosti, Zagreb, Croatia
    E-mail:
     
    Andrej Brkic, Oct 15, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. news.easynews.com

    SNMP - Cisco - SNMP

    news.easynews.com, Mar 4, 2004, in forum: Cisco
    Replies:
    0
    Views:
    835
    news.easynews.com
    Mar 4, 2004
  2. Deepak K
    Replies:
    2
    Views:
    12,373
    Deepak K
    Apr 19, 2005
  3. John Oliver

    Enable SNMP on PIX 515?

    John Oliver, May 17, 2006, in forum: Cisco
    Replies:
    5
    Views:
    14,622
    John Oliver
    May 17, 2006
  4. Tony Neville
    Replies:
    7
    Views:
    1,668
    steve
    Sep 22, 2006
  5. Replies:
    8
    Views:
    1,364
    bod43
    Mar 23, 2009
Loading...

Share This Page