GithubHelp home page GithubHelp logo

feliperomero3 / contosoconference Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 57 KB

ASP.NET Core 3.1 Web API to manage the *ficticious* world-famous Contoso Conference

License: MIT License

C# 100.00%
aspnet-core-webapi microsoft-identity-platform

contosoconference's Introduction

Contoso Conference

Build Status

ASP.NET Core 3.1 Web API to manage the fictitious world-famous Contoso Conference.

Overview

Contoso Conference is held every other year and it presents speakers from all around the world to talk about the latest technologies.

Prerequisites

  • An Azure account with an active subscription
  • An Azure AD tenant
  • An Azure AD Application to represent the Web API you want to protect
  • An Azure AD Application to represent the client (e. g. Postman) you want to allow access to the protected Web API
  • Visual Studio 2019

Getting started

  1. Clone this project.

  2. Replace AzureAd configuration section in appsettings.json file with the values generated for your Azure AD registered Application that represents the Web API you want to protect.

    "AzureAd": {
      "Instance": "https://login.microsoftonline.com/",
      "Domain": "[Enter the domain of your tenant, e.g. contoso.onmicrosoft.com]",
      "ClientId": "[Enter the Client Id (obtained from the Azure portal), e.g. ba74781c2-53c2-442a-97c2-3d60re42f403]",
      "TenantId": "[Enter the Tenant Id (obtained from the Azure portal), e.g. da41245a5-11b3-996c-00a8-4d99re19f292]",
      "Audience": "Enter the Application ID URI (obtained from the Azure portal), e.g. api://ba74781c2-53c2-442a-97c2-3d60re42f403"
    }
    ...
  3. Build the solution file.

  4. Press F5 to start the debug session.

Notes

This is my attempt at building a Web API on ASP.NET Core protected with Azure Active Directory using Microsoft Identity Platform. The domain model is based on a Demo Conference API hosted in Azure used by Microsoft in an API Management tutorial.

License

MIT License

Copyright © 2022 Felipe Romero

contosoconference's People

Contributors

feliperomero3 avatar

Watchers

 avatar

contosoconference's Issues

Enable Microsoft Identity Web logging level

Microsoft Identity Web integrates with the logging available in ASP .NET Core. Starting in Microsoft Identity Web v1.4.1, the MSAL .NET logs are also enabled to assist with troubleshooting and understanding any issues that may occur during token acquisition.

To enable the MSAL .NET logs, just explicitly enable the Microsoft Identity Web logs, for example, in appsettings.json

"Logging": {
        "LogLevel": {
            "Default": "Information",
            "Microsoft": "Warning",
            "Microsoft.Identity.Web":  "Information"
        }
...

Adding this line "Microsoft.Identity.Web": "Information" will enable the MSAL .NET logs at the "information" level.

Source: https://github.com/AzureAD/microsoft-identity-web/wiki/Logging

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.