Regarding the IPv6 thread last month, rather than force the use of IPv4,
could we fix the IIS filter to support IPv6? I believe this patch to
ConenctionList.cpp could do that (untested):
105c105,114
< int err = GetAddrInfo( server.c_str(), NULL, NULL, &aiList );
---
> ADDRINFOW aiHints;
> WCHAR service[5];
>
> memset(&aiHints, 0, sizeof(ADDRINFOW));
> aiHints.ai_flags = AI_ADDRCONFIG;
> aiHints.ai_socktype = SOCK_STREAM;
>
> (void)_itow_s( port, service, 5, 10 );
>
> int err = GetAddrInfoW( server.c_str(), service, &aiHints, &aiList );
113,116d121
< struct sockaddr_in sin;
< memset( &sin, 0, sizeof( struct sockaddr_in ) );
< sin.sin_port = htons( port );
< sin.sin_family = AF_INET;
120,121c125,130
< CosignTrace1( "aiCur->ai_addr: %s\n", inet_ntoa( ((struct
sockaddr_in*)(aiCur->ai_addr))->sin_addr ) );
< if ( (s = socket( AF_INET, SOCK_STREAM, NULL )) == INVALID_SOCKET ) {
---
>
> WCHAR hostname[ NI_MAXHOST ];
> int r = GetNameInfoW( (struct sockaddr *) aiCur->ai_addr, sizeof( struct
sockaddr ), hostname, NI_MAXHOST, NULL, 0, NI_NUMERICHOST);
> CosignTrace1( "aiCur->ai_addr: %s\n", hostname );
>
> if ( (s = socket( aiCur->ai_family, aiCur->ai_socktype,
aiCur->ai_protocol )) == INVALID_SOCKET ) {
124,125c133
< sin.sin_addr.S_un = ((struct
sockaddr_in*)(aiCur->ai_addr))->sin_addr.S_un;
< if ( connect( s, (struct sockaddr*)&sin, sizeof(struct sockaddr_in) ) ==
SOCKET_ERROR ) {
---
> if ( connect( s, aiCur->ai_addr, aiCur->ai_addrlen ) == SOCKET_ERROR ) {
133a142,143
>
> FreeAddrInfoW(aiList);
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Cosign-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/cosign-discuss