Slashdot Mirror


Cisco Confirms Regex Flaw in IOS

gattaca writes "Cisco has announced a confirmation of an unpatched denial of service vulnerability in Cisco IOS. From the NetPro Forum post: 'I have just discovered a regular expression that crashes the router. I suspect the error is because of division by zero. Since I work for the Enterprise, I do not have direct access to TAC. Please somebody report this to Cisco. I have tested it on ranges of routers (2611, 2821, 2851, 7206) and IOSes (12.0-12.4). All routers crashed with some type of BUS ERROR. Command can be issued in user mode, therefore I think it can be considered as vulnerability to potentially cause DOS.'" Of course, the command has to be entered in user mode, so while potentially a vulnerability, chances are your local IOS-based router won't be DoSed via the bug any time soon.

16 of 61 comments (clear)

  1. does it could as denial of service by Ferzerp · · Score: 2, Insightful

    if your own people have to do it?

    1. Re:does it could as denial of service by blantonl · · Score: 4, Funny

      It only if works you authenticated are router to the.

      --
      Lindsay Blanton
      RadioReference.com
    2. Re:does it could as denial of service by packetmon · · Score: 2, Funny

      so means that you're not if authenticated router to the can't it do to crash a cause?

    3. Re:does it could as denial of service by Xerxes_au · · Score: 2, Insightful

      Fair enough that you mention that it requires a valid login to trigger this bug. Once logged in there's plenty of nasty things you can do to a Cisco router (or any other) without needing to trigger random bugs.

      I've worked in the area for a number of years now supporting both Cisco and Linux based network infrastructure, and I can say with some confidence that on a large scale, bugs in various programs which can lead to total loss of service are hardly rare. DoS bugs exist, and while many will just randomly occur over time, some are able to be triggered at will.

      This is why people use strong account policies, passwords, and firewalls to control access to any network device.

      It might be mentioning that Cisco TAC is very good, and can usually help resolve such issues expediently, given that you're willing to pay for such services. ...If you don't have a Cisco contract to obtain support and IOS updates, and depending on what you're doing, maybe you're better off looking at obtaining such support for free by going with other mainstream software (ie GNU/Linux) ;-)

  2. Then don't do that by Anonymous Coward · · Score: 2, Funny

    FTA: "I have just discovered a regular expression that crashes the router. I suspect the error is because of division by zero."

    Reminds me of:

    Patient: "My arm hurts when I do this." <wiggles arm>
    Doctor: "Then don't do that."

    The solution is obvious: don't use that regex/divide by zero. Duhhhh. Problem solved. Thank you, come again.

  3. A bigger IOS flaw discovered by packetmon · · Score: 5, Funny
    A bigger vulnerability has been discovered just now as well...

    r8#sh ver | in IOS
    IOS (tm) C2600 Software (C2600-IO3-M), Version 12.2(15)T2, RELEASE SOFTWARE (fc2)
    r8#reload
    Proceed with reload? [confirm]
    Seems like anyone with admin access can reload your router.

    IOS (tm) 4500 Software (C4500-A3JK9S-M), Version 12.2(40a), RELEASE SOFTWARE (fc1)
    frSwitch#reload
    Proceed with reload? [confirm]
    Confirmed on multiple routers as well! OMFG. On another note, anyone with local access to the router can power down the router causing a massive denial of service. Our admins here at GoodyTwoShoesNetworking.com are placing epoxy across all power buttons and cables to prevent this
  4. The Enterprise by AntEater · · Score: 4, Funny

    "Since I work for the Enterprise, I do not have direct access to TAC. "

    Yes, Capt. Kirk can be very protective of the TAC.

    --
    Alex, I'll take keybindings not used by Emacs for $400....
    1. Re:The Enterprise by Anonymous Coward · · Score: 3, Interesting

      I always wonder why a company like Cisco, of which you would expect that it puts quality at a top priority, does not accept bug reports from owners of their devices who have not paid extra for a support contract.
      Even when they don't want to guarantee response times or resolution times, at the very least they could register the problems their customers have discovered.

  5. RegEx's are incredibly dangerous by mosel-saar-ruwer · · Score: 2, Informative


    Writing code that can parse for any given syntax is, well, pretty much as difficult as writing a parsing front-end to a compiler.

    I.e. it is not trivial and it is fraught with danger.

    Any time you allow the user to submit arbitrary, un-screened, un-filtered data, you're just asking for trouble.

    Of course, I guess you could argue that the job of a RegEx parser is precisely to do the screening & the filtering for you, but it is not a trivial business, and anyone who approaches the problem as though it were a mere triviality is a fool.

    I.e. from the security point of view, the RegEx parser is a firewall [and, in all likelihood, is the only firewall], hence anyone writing a RegEx parser has to assume that the user submitting the input is a blackhat, not a whitehat.

    PS: And the problem undergoes manifold [if not infinite] complexification when you're dealing with languages [or "environments"] like HTML, Javascript, and XML, which can re-write themselves on the fly.

  6. Old news (to everyone but Cisco) by OriginalArlen · · Score: 4, Insightful
    This was widely publicized (amongst the loose communities of Cisco users, anyway) back around the time the original post was made. Hey, that would have been... 18th August! :)

    To be fair, there IS a story here, which is that Cisco only just acknowledged this officially.

    Service Provider types (the operators of routers whose successful attack would actually affect anyone in the real world) have been well aware of this. But as others have pointed out, if you don't trust your admins, and you're not running proper logging and a proper audit trail of admin sessions already, you've got bigger problems than this.

    --

    Everything I needed to know about life, I learnt from Blake's Seven
  7. Re:Not a surprise by Algorithmnast · · Score: 3, Funny

    Dividing by zero screws everything up. Even Windows Calc, one of the most advanced pieces of software on the planet, can't do it.

    As it happens, I can divide by zero, but only when I try to figure out the inverse of the percentage of well-spent money from my tax dollars.

    Or perhaps, the ratio of posts to informational-posts.

    After all, Godwin needs revision - to paraphrase "A Beautiful Mind".

  8. Re:A question by bagboy · · Score: 2, Informative

    Buying Cisco equipment (typically - and through proper purchase channels) gives you access to TAC (Technical Assistance Center), worldwide support 24x7 for network emergencies and problems, as well as extensive troubleshooting support. When you buy Cisco these days, that is what you are mostly paying for. Try getting that level of assistance from Netgear, Linksys (ironically owned by Cisco), DLink, etc... You really can't - as they do not put that level of resource behind their products.

  9. Re:A question by Repossessed · · Score: 2, Insightful

    The biggest thing I see between the expensive Cisco stuff and the cheap WRT stuff (once you flash the firmware, and thank god for the GPL, cause the original stuff sucked), is that the Cisco kit will support large gigabit networks, (And you can get older Cisco branded stuff at Linksys prices that doesn't if you shop the right channels).

    Assuming you only need 100Mbit though (which is fine for lower tiered subnets), Well... there are three systems hooked up to my WRT54GL, and it's running at about 10% of capacity. I could probably squeeze a bit more out of it by turning the wireless of, but still wouldn't want to put more than 25 or so machines on it. And if those machines do anything fancy with the network, I might want to drop that even further.s-

    --
    Liberte, Egalite, Fraternite (TM)
  10. Re:A question by OriginalArlen · · Score: 3, Insightful
    At the low end, there's not a great deal of difference beyond the value of the brand (which is non-zero: how many replies do job ads for "network engineer, min 4 years experience with Linux based routers" get vs. "cisco-based routers"? )

    At pretty much anything above the branch office level, however, there's a huge difference. The two biggies are the backplane, and the ability to support proper linecards with offload routing processors. When you have a fat high-end device in your network core with 8 16-way OC3 linecards, there's just no way the standard PC architecture can keep up. The PC architecture jus isn't designed to shift massive amounts of IO, twiddle bits on a zillion and one packets per second, then route them out a different interface.

    If your cable runs look like this then you are not going to be using PC hardware, believe me.

    Juniper are a good alternative to Cisco, though. There is now finally some competition.

    --

    Everything I needed to know about life, I learnt from Blake's Seven
  11. LGs aren't a problem but public route servers are by macdaddy · · Score: 2, Informative
    I run a public route server with a web frontend (ie, a looking glass). I have yet to see a LG that allows the use of regular expressions. Some CLI-based route servers allow it but this is easily controlled when you explicitly state what commands a non-privileged user can execute with the 'privilege exec' global config mode command.

    That said, I'm on AT&T's route server right now and I can clearly see that it's been abused by the regex bug:

    route-server> sh ver
    Cisco Internetwork Operating System Software
    IOS (tm) 7200 Software (C7200-JS-M), Version 12.2(18)S12, RELEASE SOFTWARE (fc1)
    Technical Support: http://www.cisco.com/techsupport
    Copyright (c) 1986-2006 by cisco Systems, Inc.
    Compiled Thu 25-May-06 12:32 by tinhuang
    Image text-base: 0x60008FE0, data-base: 0x61A8A000

    ROM: System Bootstrap, Version 12.2(4r)B2, RELEASE SOFTWARE (fc2)
    BOOTLDR: 7200 Software (C7200-KBOOT-M), Version 12.2(18)S12, RELEASE SOFTWARE (fc1)

    route-server uptime is 59 minutes
    System returned to ROM by bus error at PC 0x6068242C, address 0x60010 at 18:21:26 UTC Sat Sep 15 2007
    System restarted at 18:22:42 UTC Sat Sep 15 2007
    System image file is "disk0:c7200-js-mz.122-18.S12.bin"

    cisco 7206VXR (NPE400) processor (revision A) with 491520K/32768K bytes of memory.
    Processor board ID 29814540
    R7000 CPU at 350Mhz, Implementation 39, Rev 3.3, 256KB L2 Cache
    6 slot VXR midplane, Version 2.7

    Last reset from power-on
    Bridging software.
    X.25 software, Version 3.0.0.
    SuperLAT software (copyright 1990 by Meridian Technology Corp).
    TN3270 Emulation software.

    PCI bus mb0_mb1 has 400 bandwidth points
    PCI bus mb2 has 0 bandwidth points

    2 FastEthernet/IEEE 802.3 interface(s)
    125K bytes of non-volatile configuration memory.

    47040K bytes of ATA PCMCIA card at slot 0 (Sector size 512 bytes).
    8192K bytes of Flash internal SIMM (Sector size 256K).
    Configuration register is 0x2102

    Note the uptime and line noting the reason for the last reboot.

    So, in short, looking glasses aren't susceptible to this bug, at least none of the dozens LG projects I've seen are susceptible to this). However publicly accessible route servers that are IOS-based and not run on Juniper routers or Quagga may very well be susceptible if the admin hasn't secured the box.

  12. I guess I'm a security researcher then by twigles · · Score: 2, Insightful

    Since I did a "show buffers all" on a 4948 and it reloaded the box. General rule I follow is that if you have to have root access to do something, it's not a vulnerability. This is just a TAC case/bug fix.