I'm trying to get this working with 5.1 and the same application suffers the same fate as my homegrown solution. Both are able to authenticate and get a token but then they fail to authorize on subsequent calls.
When I run this sample against my 5.1 installation it gets logged in, but upon clicking "List Data" the call to the SF API gets a 401.
How does one correctly create an HTTP GET with the token provided?
EDIT: I've found that the token was UrlEncoded 2x, so decoding it once left me with a valid token. I'm using HttpClient in my example.