<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Windows Core Networking : System.Net</title><link>http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx</link><description>Tags: System.Net</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Creating IP Agnostic Applications - Part 2 (Dual Mode Sockets)</title><link>http://blogs.msdn.com/wndp/archive/2006/10/24/creating-ip-agnostic-applications-part-2-dual-mode-sockets.aspx</link><pubDate>Tue, 24 Oct 2006 20:59:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:869873</guid><dc:creator>wndpteam</dc:creator><slash:comments>16</slash:comments><comments>http://blogs.msdn.com/wndp/comments/869873.aspx</comments><wfw:commentRss>http://blogs.msdn.com/wndp/commentrss.aspx?PostID=869873</wfw:commentRss><description>&lt;P&gt;In a previous post I wrote about how on Windows Vista and Windows Server "Longhorn," IPv6 is installed and enabled by default and that&amp;nbsp;when both IPv4 and IPv6 are enabled, the TCP/IP stack prefers to use IPv6 over IPv4.&amp;nbsp; With the growth of IPv6, applications must now&amp;nbsp;work seamlessly over both protocols (IPv4 &amp;amp; IPv6).&amp;nbsp; The remainder of this post discusses one way to make handling both protocols easier by using a single socket that works with IPv4 &amp;amp; IPv6.&amp;nbsp; No longer do you need to create two sockets to make your application IPv4 &amp;amp; IPv6 aware :).&lt;/P&gt;
&lt;P&gt;Windows Vista and Windows Server Longhorn includes a new TCP/IP stack which&amp;nbsp;includes common TCP &amp;amp; UDP layers on top of the IPv4 and IPv6 layers.&amp;nbsp; This new architecture has made it possible for a single IPv6 socket to work with both IPv6 and IPv4.&amp;nbsp; For example, using a single IPv6 socket one can now accept BOTH IPv4 and IPv6 traffic.&amp;nbsp; Such a socket is typically dubbed a "dual mode" socket.&amp;nbsp; Dual mode sockets are usable by managed code sockets (ie. &lt;A href="http://search.msdn.microsoft.com/search/Redirect.aspx?title=Socket+Class+(System.Net.Sockets)+&amp;amp;url=http://msdn2.microsoft.com/en-us/library/system.net.sockets.socket.aspx" mce_href="http://search.msdn.microsoft.com/search/Redirect.aspx?title=Socket+Class+(System.Net.Sockets)+&amp;amp;url=http://msdn2.microsoft.com/en-us/library/system.net.sockets.socket.aspx"&gt;System.Net.Sockets.Socket&lt;/A&gt;), native &lt;A href="http://search.msdn.microsoft.com/search/Redirect.aspx?title=Winsock+Reference+%5bWinsock%5d&amp;amp;url=http://msdn.microsoft.com/library/en-us/winsock/winsock/winsock_reference.asp" mce_href="http://search.msdn.microsoft.com/search/Redirect.aspx?title=Winsock+Reference+%5bWinsock%5d&amp;amp;url=http://msdn.microsoft.com/library/en-us/winsock/winsock/winsock_reference.asp"&gt;Winsock&lt;/A&gt; sockets as well as &lt;A href="http://blogs.msdn.com/wndp/archive/2006/02/24/538746.aspx" mce_href="http://blogs.msdn.com/wndp/archive/2006/02/24/538746.aspx"&gt;Winsock Kernel (WSK)&lt;/A&gt;&amp;nbsp;sockets.&amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To create a "dual mode" socket, the following steps are&amp;nbsp;needed:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Create an IPv6 socket 
&lt;LI&gt;Set the IPV6_V6ONLY socket option to false&lt;/LI&gt;&lt;/OL&gt;
&lt;P&gt;Once you have created the socket and set the appropriate option,&amp;nbsp;the socket can be used to accept&amp;nbsp;incoming IPv4/v6 connections or connect to an IPv4/v6 destination.&amp;nbsp; The snippets below outline&amp;nbsp;accepting incoming connections over both protocols&amp;nbsp;in native and managed code:&lt;/P&gt;
&lt;P&gt;Note: The code is meant as demonstration code; error code checking and exception handling have been left off the&amp;nbsp;code&amp;nbsp;snippets to keep them as concise as possible.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;.NET (C#)&lt;/STRONG&gt;&lt;/P&gt;&lt;PRE&gt;&lt;P&gt;Socket sock = new Socket(AddressFamily.InterNetworkV6, SocketType.Stream, ProtocolType.Tcp);&lt;/P&gt;
&lt;P&gt;// 27 is equivalent to IPV6_V6ONLY socket option in the winsock snippet below&lt;BR&gt;sock.SetSocketOption(SocketOptionLevel.IPv6, (SocketOptionName)27, 0);&lt;BR&gt;sock.Bind(new IPEndPoint(IPAddress.IPv6Any, 8000));&lt;BR&gt;sock.Listen(5);&lt;BR&gt;Socket client = sock.Accept();&lt;BR&gt;// send / receive data on 'client' socket 
&lt;/P&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;STRONG&gt;Winsock&lt;/STRONG&gt;&lt;/P&gt;&lt;PRE&gt;&lt;P&gt;WSADATA wsaData;&lt;BR&gt;SOCKET lsock = INVALID_SOCKET;&lt;BR&gt;SOCKET csock = INVALID_SOCKET;&lt;BR&gt;SOCKADDR_STORAGE serverAddr = {0};&lt;BR&gt;SOCKADDR_STORAGE clientAddr = {0};&lt;BR&gt;int off = 0;&lt;BR&gt;int port = 8000;&lt;BR&gt;int clientAddrLen = sizeof(clientAddr);&lt;BR&gt;WSAStartup(MAKEWORD(2,2), &amp;amp;wsaData); 
&lt;P&gt;serverAddr.ss_family = AF_INET6;&lt;BR&gt;INETADDR_SETANY((SOCKADDR *)&amp;amp;serverAddr);&lt;BR&gt;SS_PORT(&amp;amp;serverAddr) = htons(port);&lt;BR&gt;lsock = socket(AF_INET6, SOCK_STREAM, IPPROTO_TCP)&lt;BR&gt;&lt;/P&gt;
&lt;P&gt;//make the socket a dual mode socket&lt;BR&gt;setsockopt(lsock,IPPROTO_IPV6,IPV6_V6ONLY,(char *)&amp;amp;off, sizeof(off));&lt;BR&gt;bind(lsock, (SOCKADDR *)&amp;amp;serverAddr, (int)INET_SOCKADDR_LENGTH(serverAddr.ss_family));&lt;BR&gt;listen(lsock, 5);&lt;BR&gt;csock = accept(lsock, (SOCKADDR *)&amp;amp;clientAddr, &amp;amp;clientAddrLen); &lt;/P&gt;
&lt;P&gt;... 
&lt;P&gt;... 
&lt;P&gt;WSACleanup(); 
&lt;/P&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;STRONG&gt;When using a dual mode socket, it is important to remember the socket is&amp;nbsp;at&amp;nbsp;root an IPv6 socket.&lt;/STRONG&gt;&amp;nbsp; Since this is the case, when specifying an IPv4 address to such a socket (ie. connect to IPv4 endpoint using a dual mode socket) one must format the IPv4 address as an &lt;A href="http://en.wikipedia.org/wiki/IPv4_mapped_address" mce_href="http://en.wikipedia.org/wiki/IPv4_mapped_address"&gt;IPv4 mapped address&lt;/A&gt; prior to passing the address to a socket function.&amp;nbsp; Fortunately,&amp;nbsp;one can use IN6ADDR_SETV4MAPPED(...), defined in mstcpip.h to simplify this task. 
&lt;P&gt;The following shows&amp;nbsp;an example of what this looks like in Winsock: &lt;PRE&gt;&lt;P&gt;WSADATA wsaData;&lt;BR&gt;SOCKET csock = INVALID_SOCKET;&lt;BR&gt;SOCKADDR_STORAGE addrLoopback4 = {0}; 
&lt;P&gt;int port = 8000;&lt;BR&gt;int off = 0; 
&lt;P&gt;addrLoopback4.ss_family = AF_INET;&lt;BR&gt;INETADDR_SETLOOPBACK((SOCKADDR*)&amp;amp;addrLoopback4);&lt;BR&gt;SS_PORT(&amp;amp;addrLoopback4) = htons(port); 
&lt;P&gt;WSAStartup(MAKEWORD(2,2), &amp;amp;wsaData);&lt;BR&gt;if((csock = socket(AF_INET6, SOCK_STREAM, IPPROTO_TCP)) == INVALID_SOCKET)&lt;/P&gt;&lt;P&gt;{&lt;BR&gt;     //error creating the listening socket&lt;BR&gt;     WSACleanup();&lt;BR&gt;     return 1;&lt;BR&gt;} &lt;/P&gt;
&lt;P&gt;//make the socket a dual mode socket&lt;BR&gt;setsockopt(csock,IPPROTO_IPV6,IPV6_V6ONLY,(char *)&amp;amp;off, sizeof(off)); 
&lt;P&gt;// format the address as a v4 mapped address if needed&lt;BR&gt;ConvertToV4MappedAddressIfNeeded((SOCKADDR *) &amp;amp;addrLoopback4);&lt;BR&gt;// connect&lt;BR&gt;connect(csock, (SOCKADDR *)&amp;amp;addrLoopback4, sizeof(addrLoopback4)); &lt;BR&gt;printf("Connect complete"); 
&lt;P&gt;closesocket(csock); 
&lt;P&gt;WSACleanup();&lt;BR&gt;return 0; 
&lt;P&gt;&amp;nbsp; 
&lt;P&gt;
&lt;P&gt;
&lt;P&gt;void ConvertToV4MappedAddressIfNeeded(PSOCKADDR pAddr)&lt;BR&gt;{&lt;BR&gt;    // if v4 address, convert to v4 mapped v6 address&lt;BR&gt;    if (AF_INET == pAddr-&amp;gt;sa_family)&lt;BR&gt;    {&lt;BR&gt;        IN_ADDR In4addr;    &lt;BR&gt;        SCOPE_ID scope = INETADDR_SCOPE_ID(pAddr);&lt;BR&gt;        USHORT port = INETADDR_PORT(pAddr);&lt;BR&gt;        In4addr = *(IN_ADDR*)INETADDR_ADDRESS(pAddr);&lt;BR&gt;        ZeroMemory(pAddr, sizeof(SOCKADDR_STORAGE));&lt;BR&gt;        IN6ADDR_SETV4MAPPED(&lt;BR&gt;             (PSOCKADDR_IN6)pAddr,&lt;BR&gt;             &amp;amp;In4addr,&lt;BR&gt;             scope,&lt;BR&gt;             port&lt;BR&gt;             ); 
&lt;P&gt;    }&lt;BR&gt;} 
&lt;/P&gt;&lt;/PRE&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cheers, 
&lt;P&gt;-- Mike Flasko&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=869873" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/wndp/archive/tags/Winsock/default.aspx">Winsock</category><category domain="http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx">System.Net</category><category domain="http://blogs.msdn.com/wndp/archive/tags/networking/default.aspx">networking</category><category domain="http://blogs.msdn.com/wndp/archive/tags/WSK/default.aspx">WSK</category></item><item><title>Creating IP Agnostic Applications - Part  1</title><link>http://blogs.msdn.com/wndp/archive/2006/08/29/Creating-IP-Agnostic-Applications--Part--1.aspx</link><pubDate>Tue, 29 Aug 2006 18:00:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:729108</guid><dc:creator>wndpteam</dc:creator><slash:comments>5</slash:comments><comments>http://blogs.msdn.com/wndp/comments/729108.aspx</comments><wfw:commentRss>http://blogs.msdn.com/wndp/commentrss.aspx?PostID=729108</wfw:commentRss><description>&lt;P&gt;&lt;/P&gt;
&lt;P&gt;In Windows Vista and Windows Server "Longhorn," IPv6 is installed and enabled by default.&amp;nbsp; When both IPv4 and IPv6 are enabled on these OSs, the TCP/IP stack prefers to use IPv6 over IPv4.&amp;nbsp; For example, APIs such as &lt;A href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock/winsock/wsaconnectbyname_2.asp" target=_blank&gt;ConnectByName&lt;/A&gt;&amp;nbsp;will attempt to connect first via IPv6.&amp;nbsp; See &lt;A href="http://www.microsoft.com/technet/community/columns/cableguy/cg0206.mspx" target=_blank&gt;this&lt;/A&gt; post for a detailed discussion of address sorting. 
&lt;P&gt;Since the &lt;A href="http://www.microsoft.com/technet/community/columns/cableguy/cg1005.mspx" target=_blank&gt;IPv6 stack has been enhanced, is installed by default and the preferred network layer&lt;/A&gt;, it is important when writing network code to ensure your application is IP agnostic.&amp;nbsp; That is, your application should be able to function well when: 
&lt;UL&gt;
&lt;LI&gt;IPv4 and IPv6 are installed 
&lt;LI&gt;IPv4 is the only network layer protocol installed 
&lt;LI&gt;IPv6 is the only network layer protocol installed&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;At first glance this requirement may seem like significant added complexity for an application developer, but there is good news :).&amp;nbsp; We have been actively working on ways to&amp;nbsp;make writing IP agnostic applications simple.&amp;nbsp; The remainder of this post will&amp;nbsp;talk about how to get started making your apps IPv6 aware.&amp;nbsp; In a subsequent post, I hope to drill down into specific topics.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Check Out the Porting Guide&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;When writing such applications, I suggest reading&amp;nbsp;the &lt;A href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock/winsock/ipv6_guide_for_windows_sockets_applications_2.asp" target=_blank&gt;Winsock IPv6 Porting Guide&lt;/A&gt;.&amp;nbsp; This document&amp;nbsp;is applicable to Windows Vista and&amp;nbsp;Windows Server Longhorn as well as many prior OSs&amp;nbsp;such as Windows XP and Window Server 2003.&amp;nbsp; While the document&amp;nbsp;speaks directly to the use of native code Winsock APIs, the concepts presented are&amp;nbsp;directly applicable to&amp;nbsp;both native and managed code (ie.&amp;nbsp;.Net Framework).&amp;nbsp;&amp;nbsp;Would a&amp;nbsp;version of this document targeted&amp;nbsp;at managed code development&amp;nbsp;be useful?&amp;nbsp; Are there areas of the porting guide you would like expanded?&amp;nbsp; If so,&amp;nbsp;please let us know.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;How to Check if IPv4 or IPv6&amp;nbsp;is Installed&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;
&lt;P&gt;One of the first tasks you may need to do is determine if IPv4 and/or IPv6 are installed&amp;nbsp;on the machine.&amp;nbsp;&amp;nbsp;I believe there a number of suggested methods&amp;nbsp;out there, but the recommended method which&amp;nbsp;will reliably tell you if&amp;nbsp;a protocol is installed is to attempt to create a socket&amp;nbsp;for the address family in question.&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&lt;FONT color=#800000&gt;For Winsock developers, this is accomplished by calling the socket or WSASocket&amp;nbsp;function with the address family parameter set to AF_INET to test IPv4 availability and AF_INET6 for IPv6.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color=#800000&gt;For .Net Framework applications, use the Socket.SupportsIPv4 property to test IPv4 availability and Socket.OSSupportsIPv6 for IPv6.&lt;/FONT&gt;&amp;nbsp; &lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;STRONG&gt;Note&lt;/STRONG&gt;: There is a Socket.SupportsIPv6 property, but this is &lt;EM&gt;NOT&lt;/EM&gt; the one you want in this case.&amp;nbsp; For compat reasons we could not change the meaning of this property which does not tell you whether the machine has IPv6 installed, but instead gives back the value of a legacy configuration switch.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;STRONG&gt;Previous Posts&lt;/STRONG&gt; &lt;/P&gt;
&lt;P&gt;Brad Williamson has posted already on a couple of the APIs available on Windows Vista &amp;amp; Windows Server "Longhorn" which &lt;A href="http://blogs.msdn.com/wndp/archive/2006/07/25/WSAConnectByName_and_WSAConnectByList.aspx" target=_blank&gt;simplify connection establishment for IP agnostic apps&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;-Mike Flasko&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=729108" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/wndp/archive/tags/Winsock/default.aspx">Winsock</category><category domain="http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx">System.Net</category><category domain="http://blogs.msdn.com/wndp/archive/tags/IPV6/default.aspx">IPV6</category></item><item><title>Recent System.Net Related Postings</title><link>http://blogs.msdn.com/wndp/archive/2006/07/17/669305.aspx</link><pubDate>Tue, 18 Jul 2006 08:41:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:669305</guid><dc:creator>wndpteam</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/wndp/comments/669305.aspx</comments><wfw:commentRss>http://blogs.msdn.com/wndp/commentrss.aspx?PostID=669305</wfw:commentRss><description>&lt;P&gt;Recently, a number of current and former System.Net team members have posted about various managed code&amp;nbsp;network programming&amp;nbsp;topics:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://blogs.msdn.com/joncole/archive/2006/06/13/629988.aspx"&gt;Proxy configuration with HttpWebRequest&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://blogs.msdn.com/malarch/archive/2006/06/26/647993.aspx"&gt;Socket programming considerations&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://blogs.msdn.com/mflasko/archive/2006/07/17/669293.aspx"&gt;HttpWebRequst &amp;amp; Pipelining&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Know of other System.Net related blogs?&amp;nbsp; If so, we eagerly await the URL(leave&amp;nbsp;a comment with the URL)&lt;/P&gt;
&lt;P&gt;-Mike Flasko&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=669305" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx">System.Net</category></item><item><title>Simple .NET TCP Framing Example</title><link>http://blogs.msdn.com/wndp/archive/2006/04/06/570370.aspx</link><pubDate>Fri, 07 Apr 2006 01:45:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:570370</guid><dc:creator>wndpteam</dc:creator><slash:comments>2</slash:comments><comments>http://blogs.msdn.com/wndp/comments/570370.aspx</comments><wfw:commentRss>http://blogs.msdn.com/wndp/commentrss.aspx?PostID=570370</wfw:commentRss><description>&lt;P&gt;Recently, Jon Cole from the System.Net&amp;nbsp;QA team posted a great article in response to&amp;nbsp;questions we've received on our .Net Networking Forum (&lt;A href="http://forums.microsoft.com/MSDN/ShowForum.aspx?ForumID=40&amp;amp;SiteID=1"&gt;http://forums.microsoft.com/MSDN/ShowForum.aspx?ForumID=40&amp;amp;SiteID=1&lt;/A&gt;).&amp;nbsp; His post can be found here: &amp;nbsp;&lt;A href="/joncole/archive/2006/03/20/555721.aspx"&gt;http://blogs.msdn.com/joncole/archive/2006/03/20/555721.aspx&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Excerpt from the article:&lt;/P&gt;
&lt;P&gt;A common misunderstanding for developers new to network programming over TCP sockets is how messages are sent and received.&amp;nbsp; I frequently hear the statement that "my data is not arriving on the other side of the socket in the same format that I sent it."&amp;nbsp; The most common cause of this is because the TCP protocol does not guarantee that it will keep message boundaries.&amp;nbsp; In other words, you could send "Hello World" in a single call to Send(), but the other side of the socket stream may have to do multiple Receive() calls on the socket to get all of the data (the first Receive might return "he" and the second "llo world").&amp;nbsp; ........&lt;/P&gt;
&lt;P&gt;-- Mike Flasko&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=570370" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx">System.Net</category></item><item><title>.Net Framework 2.0 - What's new </title><link>http://blogs.msdn.com/wndp/archive/2005/11/01/488015.aspx</link><pubDate>Wed, 02 Nov 2005 06:53:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:488015</guid><dc:creator>wndpteam</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/wndp/comments/488015.aspx</comments><wfw:commentRss>http://blogs.msdn.com/wndp/commentrss.aspx?PostID=488015</wfw:commentRss><description>&lt;P&gt;On October 27th the .Net Framework 2.0 was made available to MSDN subscribers and launch events will be start in early November.&amp;nbsp; To see an overview of whats new in the .Net Framework and the System.Net name space please see:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://msdn2.microsoft.com/en-us/library/t357fb32"&gt;http://msdn2.microsoft.com/en-us/library/t357fb32&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Mike Flasko&lt;BR&gt;Program Manager - WNDP &lt;BR&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=488015" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx">System.Net</category></item><item><title>System .NET features and future </title><link>http://blogs.msdn.com/wndp/archive/2005/09/06/461533.aspx</link><pubDate>Tue, 06 Sep 2005 19:43:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:461533</guid><dc:creator>wndpteam</dc:creator><slash:comments>3</slash:comments><comments>http://blogs.msdn.com/wndp/comments/461533.aspx</comments><wfw:commentRss>http://blogs.msdn.com/wndp/commentrss.aspx?PostID=461533</wfw:commentRss><description>&lt;P&gt;&lt;FONT face=Verdana size=2&gt;As many of you may already know, the release of Visual Studio .NET 2005 is right around the corner… hooray! As we put the final touches on “Whidbey” for the November 7th launch we are starting a parallel effort focused on planning for our next major release of Visual Studio, codenamed “Orcas”. &lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;As we switch hats from ”Whidbey” release to “Orcas” planning, the System.Net team would like to hear directly from networking application developers on what they would like to see from System.Net in the future. &lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Some questions that we have been asking ourselves that you may also want to consider … &lt;/FONT&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;What features would you like to see enhanced in the System.Net namespace?&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;What functionality would you like to see from the Visual Studio .Net IDE as it relates to creating rich networking applications?&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Do you find yourself always writing the same lines of code to accomplish a networking-related task that we should consider simplifying? An example of this is the work that we did with the WebClient class that allows applications to easily send/receive data to an URI with just a few lines of code.&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Is there anything that you believe we have missed the mark on with System .Net?&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Have you went down the path designing and/or developing an application with System .Net that you later could not finish due to a limitation with the classes?&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Are there features in other platforms that you would to see in System.Net?&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;How would you rate the overall experience of creating network applications in .Net?&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Are you using the HttpListener classes? And if so, what type of functionality would you like to see added?&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Are there any HTTP-based protocols that you would like see added or expanded-on in the System.Net classes?&lt;/FONT&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Beyond the features and functionality of the classes, we also would like to learn about network applications, past, present and future that are being built by .NET developers! So please let us know about the applications that you have created or are in the process of creating by replying to this post in the .NET Framework and Communication &lt;A href="http://forums.microsoft.com/msdn/ShowForum.aspx?ForumID=40"&gt;forum&lt;/A&gt;, as a comment to this post on our &lt;a href="http://blogs.msdn.com/wndp/"&gt;WNDP team blog&lt;/A&gt;, or simply by sending the System.NET team an &lt;A href="mailto:nclasks@microsoft.com"&gt;email&lt;/A&gt;. &lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;The System.Net classes are about enabling developers to write robust, secure networking applications for the client and the server. And as we begin planning for the future of the networking classes we want to be sure that we hear about what you would like to see. We look forward to hearing from you. &lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Thanks!&lt;BR&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Billy Anders&lt;BR&gt;Group Program Manager&lt;BR&gt;Windows Networking Developer Platform&lt;BR&gt;&lt;A href="mailto:billy.anders@microsoft.com"&gt;billy.anders@microsoft.com&lt;/A&gt;&lt;BR&gt;&lt;a href="http://blogs.msdn.com/wndp/"&gt;http://blogs.msdn.com/wndp/&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;This has been cross-posted on the WNDP blog and the System .Net forum.&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=461533" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/wndp/archive/tags/Http.sys/default.aspx">Http.sys</category><category domain="http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx">System.Net</category></item><item><title>Automatic Proxy Configuration in System.NET</title><link>http://blogs.msdn.com/wndp/archive/2005/08/02/447041.aspx</link><pubDate>Wed, 03 Aug 2005 08:28:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:447041</guid><dc:creator>wndpteam</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/wndp/comments/447041.aspx</comments><wfw:commentRss>http://blogs.msdn.com/wndp/commentrss.aspx?PostID=447041</wfw:commentRss><description>&lt;DIV&gt;&lt;A href="http://msdn.microsoft.com/msdnmag/default.aspx"&gt;MSDN Magazine &lt;/A&gt;recently published a great read on changes to web proxy functionality in the .NET Framework 2.0.&amp;nbsp; In the article, &lt;A href="http://msdn.microsoft.com/msdnmag/issues/05/08/AutomaticProxyDetection/default.aspx"&gt;Take the Burden Off Users with Automatic Configuration in .NET&lt;/A&gt;, fellow WNDP team member and test lead for the managed network programming APIs (aka System.NET), Durgaprasad Gorti, gives new details about changes to web proxy support in System.NET such as how the System.NET classes now honor the automatic proxy configuration settings as used by Internet Explorer and connection-specific proxy settings.&amp;nbsp; &lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;In his article, Durgaprasad also provides sample code that demonstrates the new functionality and gives a&amp;nbsp;short introduction to the Web Proxy Auto-Discovery Protocol&amp;nbsp;as well.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=447041" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx">System.Net</category></item><item><title>MSDN Magazine on Winsock/System.Net </title><link>http://blogs.msdn.com/wndp/archive/2005/07/19/440711.aspx</link><pubDate>Wed, 20 Jul 2005 05:29:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:440711</guid><dc:creator>wndpteam</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/wndp/comments/440711.aspx</comments><wfw:commentRss>http://blogs.msdn.com/wndp/commentrss.aspx?PostID=440711</wfw:commentRss><description>MSDN Magazine for August 2005 has &lt;a href="http://msdn.microsoft.com/msdnmag/issues/05/08/HighPerformanceSockets/"&gt;an article about System.Net.Sockets and WinSock&lt;/a&gt; by Daryn Kiely:
&lt;blockquote&gt;
						&lt;p&gt;Sockets are the transport 
						mechanism most frequently used in high-performance 
						server applications. Fortunately, the Win32&lt;sup&gt;®&lt;/sup&gt; Windows&lt;sup &gt;®&lt;/sup&gt; 
						Sockets library (Winsock) provides mechanisms to improve 
						the performance of programs that use sockets, and the 
						Microsoft&lt;sup&gt;®&lt;/sup&gt; .NET Framework 
						provides a layer over Winsock so that managed 
						applications can communicate over sockets. So much advanced 
						socket support is great, but using all these layers to 
						write a truly high-performance socket-based application 
						requires a little background information.&lt;/p&gt;

						&lt;p&gt;I am going to write a trivial chat server app to 
						explore methods for writing a socket-based server and 
						client using the base System.Net.Sockets.Socket class. 
						Although .NET provides higher-level abstractions like 
						the TcpListener and TcpClient classes (also in 
						System.Net.Sockets), these classes are missing some of 
						the advanced features exposed by the lower-level Socket 
						class. That said, they can be useful in many situations. 
						The TcpListener class provides simple methods that 
						listen for and accept incoming connection requests in 
						blocking synchronous mode, while the TcpClient class 
						provides simple methods for connecting, sending, and 
						receiving stream data over a network in synchronous 
						blocking mode.&lt;/blockquote&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp; -- Ari Pernick (arip)&lt;/p&gt;
&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=440711" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/wndp/archive/tags/Winsock/default.aspx">Winsock</category><category domain="http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx">System.Net</category></item><item><title>Run ASMX without IIS</title><link>http://blogs.msdn.com/wndp/archive/2005/06/23/431806.aspx</link><pubDate>Thu, 23 Jun 2005 11:02:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:431806</guid><dc:creator>wndpteam</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/wndp/comments/431806.aspx</comments><wfw:commentRss>http://blogs.msdn.com/wndp/commentrss.aspx?PostID=431806</wfw:commentRss><description>&lt;DIV&gt;Back in late 2004, Aaron Skonnard wrote an interesting article that details how a developer can create a lightweight, special-purpose web server without IIS.&amp;nbsp; In his sample, Aaron chooses to&amp;nbsp;host&amp;nbsp;ASMX web services, but one could easily create other types of specialty web servers.&amp;nbsp; Interestingly enough along with hosting&amp;nbsp;the ASP.NET Runtime&amp;nbsp;the other&amp;nbsp;enabling technologies that allow for this functionality are none other than&amp;nbsp;Microsoft's kernel-mode HTTP listener,&amp;nbsp;Http.sys and the HttpListener classes of System.Net.&amp;nbsp; Both of which are WNDP API's.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Run ASMX Without IIS&lt;/DIV&gt;
&lt;DIV&gt;&lt;A href="http://msdn.microsoft.com/msdnmag/issues/04/12/ServiceStation/"&gt;http://msdn.microsoft.com/msdnmag/issues/04/12/ServiceStation/&lt;/A&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Now you may ask "why would I want to create my own web server"?&amp;nbsp; And to that question we would have to agree that for the vast majority you would not want to for a production system.&amp;nbsp;&amp;nbsp; But the article and sample does demonstrate that it is indeed possible to create some of the basic web serving functionality with very little code and effort.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=431806" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/wndp/archive/tags/Http.sys/default.aspx">Http.sys</category><category domain="http://blogs.msdn.com/wndp/archive/tags/System.Net/default.aspx">System.Net</category></item></channel></rss>