mirror of
				https://github.com/rofl0r/proxychains-ng.git
				synced 2025-11-04 09:06:05 +00:00 
			
		
		
		
	proxy_getaddrinfo: fix case when func was used in lieu of inet_aton
This commit is contained in:
		@@ -827,6 +827,9 @@ int proxy_getaddrinfo(const char *node, const char *service, const struct addrin
 | 
			
		||||
	if(!space) goto err1;
 | 
			
		||||
 | 
			
		||||
	if(node && !inet_aton(node, &((struct sockaddr_in *) &space->sockaddr_space)->sin_addr)) {
 | 
			
		||||
		/* some folks (nmap) use getaddrinfo() with AI_NUMERICHOST to check whether a string
 | 
			
		||||
		   containing a numeric ip was passed. we must return failure in that case. */
 | 
			
		||||
		if(hints && (hints->ai_flags & AI_NUMERICHOST)) return EAI_NONAME;
 | 
			
		||||
		hp = proxy_gethostbyname(node, &ghdata);
 | 
			
		||||
		if(hp)
 | 
			
		||||
			memcpy(&((struct sockaddr_in *) &space->sockaddr_space)->sin_addr,
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user