0 Replies - 8448 Views - Last Post: 19 June 2012 - 11:12 AM Rate Topic: -----

#1 modi123_1  Icon User is offline

  • Suitor #2
  • member icon



Reputation: 8401
  • View blog
  • Posts: 31,265
  • Joined: 12-June 08

[link] Basic Authentication with Asp.Net WebAPI

Posted 19 June 2012 - 11:12 AM

http://stevescodingb...asp-net-webapi/

A solid walk through on a frequent topic of discussion!

Quote

On a recent project, I undertook the task of implementing a RESTful API using the new Asp.Net WebAPI framework. The aim was to support clients of all types, including a .Net desktop app and iOS and Android mobile apps. My API had to support some sort of authentication mechanism.

Since this was a basic application (to be used as a learning tool for the other developers on our team) we decided to use Basic HTTP Authentication. As the name suggests, it’s a simple protocol whereby the client sends an authorization token as a header in the HTTP request, and the server decodes that token to decide whether or not it is valid. If it is, the request continues, otherwise it (should) return a 401 Unauthorized response.


Is This A Good Question/Topic? 0
  • +

Page 1 of 1