<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Nicolas&#039; Blog</title>
	<atom:link href="http://ndufresne.ca/feed/" rel="self" type="application/rss+xml" />
	<link>http://ndufresne.ca</link>
	<description>Yet another Open Source developer blog</description>
	<lastBuildDate>Thu, 02 Sep 2010 12:23:05 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>GLib 2.26 will gain proxy support</title>
		<link>http://ndufresne.ca/2010/08/glib-2-26-will-gain-proxy-support/</link>
		<comments>http://ndufresne.ca/2010/08/glib-2-26-will-gain-proxy-support/#comments</comments>
		<pubDate>Mon, 23 Aug 2010 16:08:49 +0000</pubDate>
		<dc:creator>Nicolas</dc:creator>
				<category><![CDATA[Planet]]></category>

		<guid isPermaLink="false">http://ndufresne.ca/?p=39</guid>
		<description><![CDATA[GLib 2.26, coming on September 10th, will finally gain proxy support. This contribution to GLib was made possible by Collabora Ltd. and reviewing efforts by Dan Winship. After three months of head scratching and rewriting, we finally came-up with a solution that blends into the GIO architecture and requires no code change for users of the [...]]]></description>
			<content:encoded><![CDATA[<p>GLib 2.26, coming on September 10th, will finally gain proxy support. This contribution to GLib was made possible by <a title="Collabora's website" href="http://www.collabora.co.uk" target="_blank">Collabora Ltd.</a> and reviewing efforts by <a title="Dan's blog" href="http://danw.mysterion.org/" target="_blank">Dan Winship</a>. After three months of head scratching and rewriting, we finally came-up with a solution that blends into the GIO architecture and requires no code change for users of the GIO library.</p>
<p><span id="more-39"></span></p>
<p><strong>Notable features are:</strong></p>
<ul>
<li>﻿﻿GLib friendly API for proxy configuration (GProxyResolver)</li>
<li>Configuration powered by <a title="LibProxy's website" href="http://code.google.com/p/libproxy/" target="_blank">LibProxy</a> (requires installation of <a title="glib-networking GIT repository" href="http://git.gnome.org/browse/glib-networking/" target="_blank">glib-networking</a>)</li>
<li>Transparent support for SOCKS version 5, 4a and 4</li>
<li>Support for application side proxy such as HTTP (﻿using g_socket_client_add_application_proxy(&#8230;))</li>
<li>Proxy information available inside the GSocket&#8217;s remote address</li>
<li>Plug-in based configuration and protocol support</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://ndufresne.ca/2010/08/glib-2-26-will-gain-proxy-support/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Toward an improved GLib network stack</title>
		<link>http://ndufresne.ca/2010/06/toward-an-improved-glib-network-stack/</link>
		<comments>http://ndufresne.ca/2010/06/toward-an-improved-glib-network-stack/#comments</comments>
		<pubDate>Mon, 14 Jun 2010 20:26:50 +0000</pubDate>
		<dc:creator>Nicolas</dc:creator>
				<category><![CDATA[Planet]]></category>
		<category><![CDATA[glib]]></category>
		<category><![CDATA[proxy]]></category>
		<category><![CDATA[telepathy]]></category>
		<category><![CDATA[tls]]></category>

		<guid isPermaLink="false">http://ndufresne.ca/?p=27</guid>
		<description><![CDATA[I recently started looking into GLib TLS implementation written by Dan Winship. As a reflex, I tried to merge it into my proxy branch. Things did not go so well, not because the branches are wrong, but because they both need similar features inside GIO. This is a good lesson for me, I should have [...]]]></description>
			<content:encoded><![CDATA[<p>I recently started looking into GLib TLS implementation written by <a title="Dan's GLib git tree" href="http://people.gnome.org/~danw/glib.git" target="_blank">Dan Winship</a>. As a reflex, I tried to merge it into my proxy branch. Things did not go so well, not because the branches are wrong, but because they both need similar features inside GIO. This is a good lesson for me, I should have been more careful to what Dan was doing.</p>
<p>So I decided to restart my analyses with both features together (Proxy and TLS).  I&#8217;m far from being done but I&#8217;d like to share my findings so far. Let&#8217;s start with a simplified representation of a &#8220;normal&#8221; network connection.</p>
<p><a href="http://ndufresne.ca/blog/wp-content/uploads/2010/06/glib-connect-timeline1.png"><img title="Glib Network Connection Timeline" src="http://ndufresne.ca/blog/wp-content/uploads/2010/06/glib-connect-timeline1.png" alt="Glib Network Connection Timeline" /></a></p>
<p>The goal with that little timeline was to prove myself that both features fits well together. Some may notice that this is exactly what would happen if you connect through SOCKSv5 to an XMPP server doing TLS auto-negotiation. This use case is important for me since I would like to remove TLS code from Wocky (Telepathy Gabble XMPP stack) and use GLib in the future.</p>
<p>That&#8217;s all very interesting but where&#8217;s the problem ? Well the thing is that both proxy and TLS handshake requires information about the original destination address. For proxy handshake, we have to send the original hostname and port to the proxy server. For proxy protocol like HTTP, you need to know the destination protocol in order to decide if you leave the connection as-is (e.g HTTP, Gopher and FTP) or if you have to use HTTP Connect method. For TLS handshake, you need to check server certificate against the original destination address (not against the proxy server address). You also need to take in consideration the scheme if an URI was used to connect.</p>
<p>On proxy side, the implementation is using the GProxyAddress (a subclass of GSocketAddress). It is used to memorize the destination hostname and port. On TLS side a method get_name() was added to GSocketConnectable interface. The first thing I told myself when I started writing this was: Why a program can&#8217;t just remember that information ? Well the answer is that in both cases this information might be acquired dynamically during the address enumeration. As an example, if you use GNetworkService class, you will never know what hostname was really used since the returned GSocketAddress does not contain it.</p>
<p>Basically, this is what I need to work on to pursue my way trough a more complete network stack in GLib (and get Proxy/TLS support from GLib in Telepathy Gabble <img src='http://ndufresne.ca/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> ).</p>
]]></content:encoded>
			<wfw:commentRss>http://ndufresne.ca/2010/06/toward-an-improved-glib-network-stack/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Transparent proxy for GLib applications</title>
		<link>http://ndufresne.ca/2010/06/transparent-proxy-for-glib-applications/</link>
		<comments>http://ndufresne.ca/2010/06/transparent-proxy-for-glib-applications/#comments</comments>
		<pubDate>Fri, 04 Jun 2010 20:41:54 +0000</pubDate>
		<dc:creator>Nicolas</dc:creator>
				<category><![CDATA[Planet]]></category>
		<category><![CDATA[glib]]></category>
		<category><![CDATA[proxy]]></category>

		<guid isPermaLink="false">http://ndufresne.ca/?p=16</guid>
		<description><![CDATA[The biggest problem with socket based proxies are their simplicity.  It&#8217;s a bigger pain to write them once for all applications than to implement them for a single application.  But that is if you don&#8217;t consider system wide and automatic configuration. So far, the result on Linux is that most desktop environments have global settings. [...]]]></description>
			<content:encoded><![CDATA[<p>The biggest problem with socket based proxies are their simplicity.  It&#8217;s a bigger pain to write them once for all applications than to implement them for a single application.  But that is if you don&#8217;t consider system wide and automatic configuration. So far, the result on Linux is that most desktop environments have global settings. Except the browsers, none of the applications use them.</p>
<p><span id="more-16"></span>A few months ago, I was asked to implement proxy support for <a title="Telepathy Gabble" href="http://http://telepathy.freedesktop.org/wiki/" target="_blank">Telepathy Gabble.</a> While reading about socket based proxies, I asked myself why should Gabble cares about proxies ? It does not change anything in the way <a title="XMPP" href="http://xmpp.org/">XMPP</a> is being used. The only difference is at connection time. As <a title="GLib" href="http://www.gtk.org/" target="_blank">GLib</a> offers an abstraction to <a title="GIO GSocketClient" href="http://library.gnome.org/devel/gio/stable/GSocketClient.html" target="_blank">socket connections</a> why GLib can&#8217;t take care of them ?</p>
<p>That&#8217;s why I started hacking on GLib to implement transparent proxies. I came up with a set of patches that can be found in my <a title="Nicolas's git for GLib Proxy" href="http://git.collabora.co.uk/?p=user/nicolas/glib.git;a=shortlog;h=refs/heads/proxy2" target="_blank">git tree.</a></p>
<p>The problem can be split in two:</p>
<ol>
<li>Which proxies should I use ?</li>
<li>How do I connect through these proxy servers ?</li>
</ol>
<p>The first problem is configuration. There is at least three types of proxy configuration. The network provided proxy WPAD (e.g. often through DHCP), the JavaScript configuration files (PAC) and the static configuration (e.g. system network configuration). This problem can be solved using <a title="Libproxy" href="http://code.google.com/p/libproxy/" target="_blank">LibProxy</a>. While its name is a little generic, LibProxy only deals with proxy configuration. You give it an URI and it gives you back one or more proxy URIs.</p>
<p>The second problem is the connection. Some proxy protocols are dialects of other protocols. As those are very specific, it&#8217;s normal to leave to specialized library the task of handling them (e.g.<a title="LibSoup an HTTP library" href="http://live.gnome.org/LibSoup" target="_self"> libsoup</a> will care of HTTP proxy). For other protocols like <a title="SOCKSv5 Specification" href="http://www.faqs.org/rfcs/rfc1928.html" target="_blank">SOCKS</a>, every application should support them. Currently, every application and library implements their own partial support for SOCKS and some just don&#8217;t. If you are lucky like me, you may end-up with Evolution not using SOCKS except when rendering emails external images because libsoup does support it.</p>
<p>Quickly the problem gets bigger and code more complicated. At some point, having this in a centralized library should help desktop applications to just work. But my idea has some limitations since we can&#8217;t force anyone from using BSD sockets directly. So far, I can only encourage maintainers to port over GIO,  basing their code on a  well tested network abstraction.</p>
]]></content:encoded>
			<wfw:commentRss>http://ndufresne.ca/2010/06/transparent-proxy-for-glib-applications/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Mail Notification in Meego</title>
		<link>http://ndufresne.ca/2010/05/mail-notification-in-meego/</link>
		<comments>http://ndufresne.ca/2010/05/mail-notification-in-meego/#comments</comments>
		<pubDate>Mon, 31 May 2010 17:19:23 +0000</pubDate>
		<dc:creator>Nicolas</dc:creator>
				<category><![CDATA[Planet]]></category>

		<guid isPermaLink="false">http://ndufresne.ca/?p=8</guid>
		<description><![CDATA[With Meego for Notebooks 1.0 users of Google and MSN can now monitor and open their online e-mails account with a single mouse click in the MyZone panel. Thanks to Intel for hiring Collabora to implement this feature. The GUI shows the number of unread messages for each of your accounts in real-time. Clicking the [...]]]></description>
			<content:encoded><![CDATA[<p>With <a title="Meego For Notebook 1.0 annoucement" href="http://meego.com/community/blogs/imad/2010/meego-v1.0-core-software-platform-netbook-user-experience-project-release" target="_blank">Meego for Notebooks 1.0</a> users of Google and MSN can now monitor and open their online e-mails account with a single mouse click in the <a title="The MyZone Panel" href="http://help.meego.com/netbook/myzone/myzone-panel" target="_blank">MyZone</a> panel. Thanks to Intel for hiring Collabora to implement this feature. The GUI shows the number of unread messages for each of your accounts in real-time. Clicking the button will open the online mailbox in your favourite browser. Have a look at the bottom left of the following screen:</p>
<p><a href="http://ndufresne.ca/blog/wp-content/uploads/2010/05/mail-notification-700x520.png"><img class="alignnone size-full wp-image-9" title="Meego Mail Notification" src="http://ndufresne.ca/blog/wp-content/uploads/2010/05/mail-notification-700x520.png" alt="Meego for Notebook 1.0 presenting Google Mail Notification" width="700" height="525" /></a></p>
<p>The feature is as been made possible by Telepathy draft API for <a title="Connectaion.MailNotification API" href="http://telepathy.freedesktop.org/spec/org.freedesktop.Telepathy.Connection.Interface.MailNotification.DRAFT.html" target="_blank">mail notification</a>. Meego provides the premiere integration of this API in a user interface. It fills a long standing gap in the Telepathy framework.</p>
]]></content:encoded>
			<wfw:commentRss>http://ndufresne.ca/2010/05/mail-notification-in-meego/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Got a blog</title>
		<link>http://ndufresne.ca/2010/05/hello-world/</link>
		<comments>http://ndufresne.ca/2010/05/hello-world/#comments</comments>
		<pubDate>Fri, 28 May 2010 22:05:06 +0000</pubDate>
		<dc:creator>Nicolas</dc:creator>
				<category><![CDATA[Other]]></category>

		<guid isPermaLink="false">http:/?p=1</guid>
		<description><![CDATA[First let me introduce myself. I&#8217;m Nicolas Dufresne also known has stormer on IRC. I&#8217;m currently occupied at adding proxy support into GLib Network IO API.  From now own, I will be posting about my current and previous work, or simply giving my ideas about Open Sources softwares in general.
Enjoy!
]]></description>
			<content:encoded><![CDATA[<p>First let me introduce myself. I&#8217;m Nicolas Dufresne also known has <em>stormer</em> on IRC. I&#8217;m currently occupied at adding proxy support into GLib Network IO API.  From now own, I will be posting about my current and previous work, or simply giving my ideas about Open Sources softwares in general.</p>
<p>Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://ndufresne.ca/2010/05/hello-world/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

