HP/H3C and Huawei SNMP Weak Access to Critical Data

简介: http://grutztopia.jingojango.net/2012/10/hph3c-and-huawei-snmp-weak-access-to.

http://grutztopia.jingojango.net/2012/10/hph3c-and-huawei-snmp-weak-access-to.html

/H3C and Huawei SNMP Weak Access to Critical Data

Overview

HP/H3C and Huawei networking equipment suffers from a serious weakness in regards to their handling of Systems Network Management Protocol (SNMP) requests for protected h3c-user.mib and hh3c-user.mib objects.

Identifiers


 

Vendor releases


Researcher

 Kurt Grutzmacher
 grutz <at> jingojango dot net
 twitter: @grutz

Details

Huawei/H3C have two OIDs, 'old' and 'new':
  •   old: 1.3.6.1.4.1.2011.10
  •   new: 1.3.6.1.4.1.25506
Most devices support both formats.

The MIBs h3c-user.mib and hh3c-user.mib, for the purpose of this document, will be referred to as (h)h3c-user.mib. This MIB defines the internal table and objects to "Manage configuration and Monitor running state for userlog feature."

This means there are some cool objects with data in this MIB penetration testers or malicious actors would want to get their dirty little hands on. Most objects are only accessible with the read/write community string.

In the revision history of (h)h3c-user.mib, version 2.0 modified the MAX-ACCESS from read-only to read-create the following objects within the (h)h3cUserInfoEntry sequence:
  •   (h)h3cUserName
  •   (h)h3cUserPassword
  •   (h)h3cAuthMode
  •   (h)h3cUserLevel
The purpose of these objects are to provide the locally configured users to those with a valid SNMP community. After the change only those with the read-write community string should have access, however this was not the case and the code still retained the earlier access of read-only.

So if you have the SNMP public community string then you have the ability to view these entries.

Why this is impactful

The (h)h3cUserPassword is presented in one of three formats as defined in the (h)h3cAuthMode object and mirrors how passwords are stored in the device configuration:
  •   0 -- password simple, meaning cleartext
  •   7 -- password cipher, meaning ciphertext
  •   9 -- password sha-256, meaning one-way sha-256 hash
SHA-256 is a recent addition and is not supported on all devices yet.

On top of this the (h)h3cUserLevel can be 0 to 3 where 0 is limited access and 3 is full access.

Globbing some users

You must have an SNMP read-only or read-write string and access to the
SNMP port (udp/161) for this to work:
 $ snmpwalk –c public –v 1 $IP 1.3.6.1.4.1.2011.10.2.12.1.1.1
or
 $ snmpwalk –c public –v 1 $IP 1.3.6.1.4.1.25506.2.12.1.1.1

Weaponizing

Files relevant to this disclosure:
  •   hh3c-localuser-enum.rb - Metasploit auxiliary scanner module
  •   snmp-h3c-login.nse - Nmap Scripting Engine module
These will soon be posted to https://github.com/grutz/h3c-pt-tools and requested to be added to each tool.

Mitigation

By itself this is already bad but most users who do any of the following may already be protected:
  • Use complex SNMP community strings or disable SNMPv1
  • Have disabled the mib entries for (h)h3c-user
  • Block SNMP using access controls or firewalls
  • Do not define local users, use RADIUS or TACACS+
More specific routines can be found in the vendor's release.

Why this is a bigger problem

People make poor choices. They like to think their equipment won't rat them out so they use cleartext passwords on networking equipment.

The cipher is an interesting one because it's basically an unknown... What, you think the only thing I had to share at Toorcon was SNMP and some cleartext credentials?

Timeline

June-ish 2012: Research begins after seeing something cool on a penetration test

August 6, 2012: Contacted US-CERT to coordinate vendor disclosure, VU#225404

September 5, 2012: No response from H3C, contacted US-CERT again

September 6, 2012: H3C (through US-CERT) requests more time, I state intention to present findings at Toorcon (Oct 19/20, 2012) or disclose if talk not accepted.

September 18, 2012: Approved for Toorcon! Information goes up not long after on Toorcon website.

September 18-October 16, 2012: Build slides, work on tools, no contact with US-CERT or vendors.

October 16, 2012: HP contacts me directly asking that I not present  this information at Toorcon

October 18, 2012: Publicly state agreement to cancel the Toorcon talk

October 22, 2012: HP discloses! What what? Why bother putting any pressure not to give the talk if you're gonna give everything out 2 days later?

October 23, 2012: So I publish.

 

目录
相关文章
|
测试技术 API 网络架构
利用百度云盘API上传文件至百度云盘
一、获取Access Token示例 1. 请您将以下HTTP请求直接粘贴到浏览器地址栏内,并按下回车键。 https://openapi.baidu.com/oauth/2.0/authorize?response_type=token&client_id=L6g70tBRRIXLsY0Z3...
3922 0
|
12月前
|
机器学习/深度学习 人工智能 自然语言处理
师资研修|AI赋能教师教学能力转型-德阳某教育主管部门
近日,德阳市教育主管部门,面向全市中职院校的骨干教师,开展AIGC赋能教育教学师资培训。TsingtaoAI参与负责本次师资研修的教学。本次师资研修通过系统化、专业化的培训,帮助教师深入掌握AI大模型及生成技术在教学中的应用。课程以实践为核心,以案例为载体,涵盖AI提示词优化、教案与题库生成、PPT高效设计及AI数字人应用等核心内容,全面提升教师的教学效率与创新能力。
532 5
|
Java API
Java一分钟之-Java日期与时间API:LocalDate, LocalDateTime
【5月更文挑战第13天】Java 8引入`java.time`包,改进日期时间API。`LocalDate`代表日期,`LocalDateTime`包含日期和时间。本文概述两者的基本用法、常见问题及解决策略。创建日期时间使用`of()`和`parse()`,操作日期时间有`plusDays()`、`minusMonths()`等。注意点包括:设置正确的`DateTimeFormatter`,考虑闰年影响,以及在需要时区信息时使用`ZonedDateTime`。正确使用这些类能提升代码质量。
568 3
|
JavaScript Java 测试技术
基于springboot+vue.js+uniapp的网上手机销售系统附带文章源码部署视频讲解等
基于springboot+vue.js+uniapp的网上手机销售系统附带文章源码部署视频讲解等
164 0
|
传感器 物联网 数据处理
MQTT 和 EMQX到底有啥区别?
MQTT 和 EMQX到底有啥区别?
3591 3
MQTT 和 EMQX到底有啥区别?
|
安全
致远OA ajax.do 任意文件上传 (CNVD-2021-01627) 漏洞复现
致远OA ajax.do 任意文件上传 (CNVD-2021-01627) 漏洞复现
2548 0
|
Java 测试技术 Maven
Java 反编译工具的使用与对比分析(一)
Java 反编译工具的使用与对比分析
964 0
Java 反编译工具的使用与对比分析(一)
|
Web App开发 网络协议 网络安全
启用ECH的配置
开启 Encrypted Client Hello (Secure SNI)
7032 0
|
缓存 前端开发 JavaScript
大开眼界:CSS指纹
大家好,我是零一。之前我发过一篇文章,是关于浏览器指纹的:浏览器隐身模式下的你,仍然没有任何隐私,里面介绍了各种各样的指纹生成方式,今天讨论另一个比较新奇的思路:CSS指纹
544 0
大开眼界:CSS指纹
|
存储 缓存 算法
ZIP 也能边下载边解压?流式解压技术揭秘!
对于一个 ZIP 文件,由于标准的解压方式总是从读取文件的末尾开始的,因此必须下载完整个 ZIP 解压后才能访问。当用户通过网络访问 ZIP 文件时,下载解压所带来的耗时将大大降低用户体验。那么能不能边下载边解压呢?阿里巴巴文娱技术 喻远将介绍 ZIP 流式解压的原理和技术实现路径。
6919 0
ZIP 也能边下载边解压?流式解压技术揭秘!