0

Hi everyone I have an issue, I have one Asp.NET Web.API application with User management functionality from example Create User manage User Permissions ect, and now I have developed another Web.API application and I need to implement authentication and authorization via first application users credentials. What is the best approach or solution to achieve this goal? Note that in first app I changed the classic Role base Authorization into Permission based.

Thanks in advance for any help.

5
  • 1
    In case possible separate authentication as a separate service and implement token based authentication. Commented Apr 6, 2017 at 20:20
  • Thanks for answer what type of service do you mean? Commented Apr 6, 2017 at 21:55
  • 1
    Another rest api service which implements token based authentication. Commented Apr 6, 2017 at 22:00
  • Do you have any example to point me? Commented Apr 6, 2017 at 22:13
  • 1
    There are several ways you can achieve token based authentication. My preference is to use OAuth using ASP.net identity server. github.com/IdentityServer Commented Apr 6, 2017 at 22:40

2 Answers 2

1

I have developed another Web.API application and I need to implement authentication and authorization via first application users credentials.

There are a lot of ways to implement the solution. One way is use to token-based authentication using Identity Server.

You could test my sample code at GitHub.

Please note that it uses InMemory Identity Database with hard-coded username and password for testing. You could replace with real Identity Database easily.

Sign up to request clarification or add additional context in comments.

Comments

0

I had a similar issue so I moved all of my authentication and authorization into an IHTTP Module. This allowed me to set the applications module in IIS 7.0. https://msdn.microsoft.com/en-us/library/ms227673.aspx

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.