CWE-941 通信信道中错误指定的目的地

Incorrectly Specified Destination in a Communication Channel

结构: Simple

Abstraction: Base

状态: Incomplete

被利用可能性: unkown

基本描述

The software creates a communication channel to initiate an outgoing request to an actor, but it does not correctly specify the intended destination for that actor.

扩展描述

Attackers at the destination may be able to spoof trusted servers to steal data or cause a denial of service.

There are at least two distinct weaknesses that can cause the software to communicate with an unintended destination:

相关缺陷

  • cwe_Nature: ChildOf cwe_CWE_ID: 923 cwe_View_ID: 1000 cwe_Ordinal: Primary

  • cwe_Nature: ChildOf cwe_CWE_ID: 923 cwe_View_ID: 699 cwe_Ordinal: Primary

  • cwe_Nature: CanPrecede cwe_CWE_ID: 406 cwe_View_ID: 1000

适用平台

Language: {'cwe_Class': 'Language-Independent', 'cwe_Prevalence': 'Undetermined'}

Paradigm: {'cwe_Name': 'Mobile', 'cwe_Prevalence': 'Undetermined'}

示例代码

This code listens on a port for DNS requests and sends the result to the requesting address.

bad Python

sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
sock.bind( (UDP_IP,UDP_PORT) )
while true:
data = sock.recvfrom(1024)
if not data:
break

(requestIP, nameToResolve) = parseUDPpacket(data)
record = resolveName(nameToResolve)
sendResponse(requestIP,record)

This code sends a DNS record to a requesting IP address. UDP allows the source IP address to be easily changed ('spoofed'), thus allowing an attacker to redirect responses to a target, which may be then be overwhelmed by the network traffic.

分析过的案例

标识 说明 链接
CVE-2013-5211 composite: NTP feature generates large responses (high amplification factor) with spoofed UDP source addresses. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2013-5211
CVE-1999-0513 Classic "Smurf" attack, using spoofed ICMP packets to broadcast addresses. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-1999-0513
CVE-1999-1379 DNS query with spoofed source address causes more traffic to be returned to spoofed address than was sent by the attacker. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-1999-1379

Notes

引用