Basic Authentication in DOT NET Core Web API using VS Code | .NET CORE 6.0 Tutorial

Поделиться
HTML-код
  • Опубликовано: 10 сен 2024
  • #dotnetcore #webapi #basicauthentication #vscode #nihiratechiees
    This video explains how to implement Basic Authentication in DOT NET Core Web API using VS Code
    Steps followed
    ============
    1, Enable Authentication adding “useAuthentication”
    2, Create Authentication handler
    3, Implement AuthenticationSchemeoptions
    4, Get Authorization Header using Authorizationheadervalue
    5, Based on the data validate against database
    6, If data is valid create authentication ticket
    7, Return the response with ticket
    Link for Web API using VS Code
    ==========================
    • .NET Core 6.0 Web API ...
    Link for Base 64 Encode
    =====================
    www.base64enco...
    Source Code GitHub Link
    =====================
    github.com/nih...

Комментарии • 49

  • @martinoluccarelli6233
    @martinoluccarelli6233 Год назад

    Very very clear explanation

  • @VijayKumar-fq4ie
    @VijayKumar-fq4ie 2 года назад

    oh good. thank you so much for regular upload. pls keep continue it

  • @spiderwaui
    @spiderwaui Год назад

    Thank you Sir! I learned alot!

  • @Proviper666
    @Proviper666 Год назад

    It worked for me. I was using storage as list. Still worked.

  • @pradeepsamaniya1448
    @pradeepsamaniya1448 7 месяцев назад

    Hi sir, I am getting exception while posting data from postman. error is "The format of value '' is invalid"

    • @NihiraTechiees
      @NihiraTechiees  7 месяцев назад

      Can you send me the data used in postman

  • @romanmatran
    @romanmatran Год назад

    good one, thanks

  • @sportzzz2081
    @sportzzz2081 Год назад

    Thank you.

  • @ashishnayak2666
    @ashishnayak2666 2 года назад

    Very clear explanation 👌

  • @twinwalks
    @twinwalks 2 года назад

    Thanks! Very well explained :)

  • @pokerlife7564
    @pokerlife7564 Год назад

    Very good explanation.
    But I'm facing one problem. Everytime I add [Authorize] and send a request from Postman, it throws a 404 error. Works fine without the authorisation.

    • @NihiraTechiees
      @NihiraTechiees  Год назад

      Looks like You have issue with your authorize implementation

  • @saipavan3915
    @saipavan3915 2 года назад +1

    In this u used encoding in one line but iam getting error there

    • @NihiraTechiees
      @NihiraTechiees  2 года назад

      Can you share the error

    • @saipavan3915
      @saipavan3915 2 года назад

      @@NihiraTechiees now it got resolved as we need to add one using statement in the code

    • @saipavan3915
      @saipavan3915 2 года назад

      @@NihiraTechiees thank you for replying

    • @NihiraTechiees
      @NihiraTechiees  2 года назад

      @@saipavan3915 you can cross check with source code, I provided github link in description

  • @user-pc2ge5km9s
    @user-pc2ge5km9s Год назад

    WOW! Thx

  • @S3Kglitches
    @S3Kglitches Год назад

    how to use the "claims" thing in the REST API Controller later?

    • @NihiraTechiees
      @NihiraTechiees  Год назад +1

      Check next videos in the same playlist jwt authentication it will cover everything

  • @rizmolpg1609
    @rizmolpg1609 2 года назад

    Thank you for the video. Can pls explain to get 401 message in the postman response

  • @sandeepjadhav2608
    @sandeepjadhav2608 2 года назад

    Why there is no startup class. usually we do all our settings in Startup class.

    • @NihiraTechiees
      @NihiraTechiees  2 года назад

      Upto. Net core version 3.1 we have startup.cs. after that start up file changes moved to program.cs

    • @sandeepjadhav2608
      @sandeepjadhav2608 2 года назад

      @@NihiraTechiees okay, Thanks for the update.

  • @pramodanachimath5081
    @pramodanachimath5081 Год назад

    This video is good and helping lot, but where you are giving username and password in the code?

  • @martaruano157
    @martaruano157 Год назад

    Can you show how to connect to the database? :)

    • @NihiraTechiees
      @NihiraTechiees  Год назад

      Follow this tutorial ruclips.net/p/PLfyWdpsiUiPDcTp8SucoyN4nX1JW_Hgcm
      Here the first video explains the database connectivity

  • @66_surajprajapati70
    @66_surajprajapati70 Год назад

    In item.userId what is userId

  • @poojaswain4722
    @poojaswain4722 2 года назад

    Can you give me the data base file

  • @jeffrdrama7984
    @jeffrdrama7984 Год назад

    Any tip for azure key vault to save and check password