KQOAuth – Easy and Powerful OAuth library for Qt
Article Metadata
Contents |
Introduction
kQOAuth is a powerful yet easy way to integrate OAuth authentication to your Qt application. kQOAuth handles OAuth request signing, request submitting and reply parsing for you. It also provides an easy way to retrieve user authorization to protected resources with a built in HTTP server. All this is done with Qt programming in mind, so you can use Qt's signals to react to OAuth events in your own application. This also means that the library works fully asynchronously. kQOAuth is licensed under the LGPL license.
kQOAuth is written by Johan Paul (johan.paul@gmail.com). The web site of kOQAuth is at [1]. The content on this wiki page is taken from this web page.
Main Components
The two main classes of kQOAuth are "KQOAuthManager" and "KQOAuthRequest" . KQOAuthManager executes the request and keeps track of the authorization process, while KQOAuthRequest describes the next step of the process and takes care of formatting the headers for the request.
You can find more info on it with example:here
If you are unfamiliar with "OAuth", it would be nice to checkout the tutorials below:
Beginner’s Guide to OAuth – Part II : Protocol Workflow
[https://dev.twitter.com/docs/auth#intro Authenticating Requests with OAuth]
Features
kQOAuth is written in C++ and its main features include:
- Provides easy, "automated", OAuth authentication but also more advanced detailed control of the authentication process.
- OAuth request handling (request signing, submitting and result parsing).
- No dependencies to external libraries.
- Works with signals and slots - asynchronously.
- Handles protected resource owner authentication by taking care of opening temporary token retrieval web page and parsing the reply with a built in HTTP server.
Download and source code
kQOAuth library source code is available on Gitorious.org at this page
Usage
kQOAuth can be used in two different ways. If you don't want to control the authentication process in detail, you can use the convenience APIs to get access to protected resources with a few lines of code.The only pieces of information you will need are
- your application's consumer key
- your application's secret consumer key
- URL for retrieving the temporary request tokens
- URL for the user to authenticate the application to access the protected resources
- URL for sending the authenticated request.
Disclaimer
kQOAuth is at version 0.92. Use it at your own risk. It has so far been successfully tested on Mac OS X 10.6 and Ubuntu Linux 10.10. Only Qt 4.7 and newer are supported. kQOAuth currently supports only HMAC-SHA1 signing method. kQOAuth should be Symbian compliant, but feedback regarding this is needed.


an example would have been better to show how to use it with Qt for symbian.
Geco0ol - Nice work !
Hello d_ptr team
I highly appreciate the library you released for working with twitter. Everything works smoothly, and one can easily recognize the twitter API requirements in it. There is only one thing i do not manage to achieve by using it: i cannot get the browser to close itself after getting the access tokens. Could you please point me a thing or two i should check or suggest me how could i try to close the browser. I am using the library on symbian belle currently, but i plan to use it on other symbian breeds, and meego harmattan as well.
Thx,
Geogeco0ol 17:49, 20 March 2012 (EET)
Begineer - kQOAuth not working on Ubuntu
Hi,
I am using kQOAuth Library work perfectly fine on windows. but same code does not work on Ubuntu 10.10 i am using latest Qt. it does not connect to network.
any one is with same issue. Plz. Help!
supThx.
begineer 16:06, 7 May 2012 (EEST)