├── SecureResource ├── Movies.Client │ ├── Views │ │ ├── _ViewStart.cshtml │ │ ├── _ViewImports.cshtml │ │ ├── Home │ │ │ ├── Privacy.cshtml │ │ │ └── Index.cshtml │ │ ├── Shared │ │ │ ├── _ValidationScriptsPartial.cshtml │ │ │ ├── Error.cshtml │ │ │ └── _Layout.cshtml │ │ └── Movies │ │ │ ├── OnlyAdmin.cshtml │ │ │ ├── Details.cshtml │ │ │ ├── Delete.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── Create.cshtml │ │ │ └── Edit.cshtml │ ├── wwwroot │ │ ├── favicon.ico │ │ ├── js │ │ │ └── site.js │ │ ├── lib │ │ │ ├── jquery-validation-unobtrusive │ │ │ │ └── LICENSE.txt │ │ │ ├── jquery-validation │ │ │ │ └── LICENSE.md │ │ │ ├── bootstrap │ │ │ │ ├── LICENSE │ │ │ │ └── dist │ │ │ │ │ └── css │ │ │ │ │ └── bootstrap-reboot.min.css │ │ │ └── jquery │ │ │ │ └── LICENSE.txt │ │ └── css │ │ │ └── site.css │ ├── Properties │ │ ├── serviceDependencies.json │ │ ├── serviceDependencies.local.json │ │ └── launchSettings.json │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── Models │ │ ├── ErrorViewModel.cs │ │ ├── UserInfoViewModel.cs │ │ └── Movie.cs │ ├── Movies.Client.csproj │ ├── ApiServices │ │ └── IMovieApiService.cs │ ├── Program.cs │ ├── Controllers │ │ └── HomeController.cs │ └── HttpHandlers │ │ └── AuthenticationDelegatingHandler.cs ├── IdentityServer │ ├── Views │ │ ├── _ViewStart.cshtml │ │ ├── _ViewImports.cshtml │ │ ├── Account │ │ │ ├── AccessDenied.cshtml │ │ │ ├── Logout.cshtml │ │ │ ├── LoggedOut.cshtml │ │ │ └── Login.cshtml │ │ ├── Device │ │ │ ├── Success.cshtml │ │ │ └── UserCodeCapture.cshtml │ │ ├── Shared │ │ │ ├── _ValidationSummary.cshtml │ │ │ ├── Redirect.cshtml │ │ │ ├── _Layout.cshtml │ │ │ ├── _Nav.cshtml │ │ │ ├── _ScopeListItem.cshtml │ │ │ └── Error.cshtml │ │ ├── Home │ │ │ └── Index.cshtml │ │ ├── Diagnostics │ │ │ └── Index.cshtml │ │ └── Grants │ │ │ └── Index.cshtml │ ├── wwwroot │ │ ├── lib │ │ │ ├── bootstrap │ │ │ │ ├── scss │ │ │ │ │ ├── utilities │ │ │ │ │ │ ├── _clearfix.scss │ │ │ │ │ │ ├── _overflow.scss │ │ │ │ │ │ ├── _screenreaders.scss │ │ │ │ │ │ ├── _visibility.scss │ │ │ │ │ │ ├── _shadows.scss │ │ │ │ │ │ ├── _float.scss │ │ │ │ │ │ ├── _align.scss │ │ │ │ │ │ ├── _background.scss │ │ │ │ │ │ ├── _stretched-link.scss │ │ │ │ │ │ ├── _sizing.scss │ │ │ │ │ │ ├── _position.scss │ │ │ │ │ │ ├── _display.scss │ │ │ │ │ │ ├── _embed.scss │ │ │ │ │ │ ├── _borders.scss │ │ │ │ │ │ ├── _text.scss │ │ │ │ │ │ ├── _spacing.scss │ │ │ │ │ │ └── _flex.scss │ │ │ │ │ ├── _media.scss │ │ │ │ │ ├── mixins │ │ │ │ │ │ ├── _clearfix.scss │ │ │ │ │ │ ├── _size.scss │ │ │ │ │ │ ├── _lists.scss │ │ │ │ │ │ ├── _text-truncate.scss │ │ │ │ │ │ ├── _resize.scss │ │ │ │ │ │ ├── _visibility.scss │ │ │ │ │ │ ├── _alert.scss │ │ │ │ │ │ ├── _text-hide.scss │ │ │ │ │ │ ├── _badge.scss │ │ │ │ │ │ ├── _nav-divider.scss │ │ │ │ │ │ ├── _transition.scss │ │ │ │ │ │ ├── _float.scss │ │ │ │ │ │ ├── _list-group.scss │ │ │ │ │ │ ├── _text-emphasis.scss │ │ │ │ │ │ ├── _reset-text.scss │ │ │ │ │ │ ├── _pagination.scss │ │ │ │ │ │ ├── _box-shadow.scss │ │ │ │ │ │ ├── _deprecate.scss │ │ │ │ │ │ ├── _background-variant.scss │ │ │ │ │ │ ├── _hover.scss │ │ │ │ │ │ ├── _screen-reader.scss │ │ │ │ │ │ ├── _table-row.scss │ │ │ │ │ │ ├── _image.scss │ │ │ │ │ │ ├── _border-radius.scss │ │ │ │ │ │ ├── _caret.scss │ │ │ │ │ │ ├── _grid-framework.scss │ │ │ │ │ │ ├── _gradients.scss │ │ │ │ │ │ ├── _grid.scss │ │ │ │ │ │ └── _buttons.scss │ │ │ │ │ ├── _transitions.scss │ │ │ │ │ ├── bootstrap-reboot.scss │ │ │ │ │ ├── _jumbotron.scss │ │ │ │ │ ├── _utilities.scss │ │ │ │ │ ├── _root.scss │ │ │ │ │ ├── bootstrap-grid.scss │ │ │ │ │ ├── bootstrap.scss │ │ │ │ │ ├── _close.scss │ │ │ │ │ ├── _toasts.scss │ │ │ │ │ ├── _code.scss │ │ │ │ │ ├── _mixins.scss │ │ │ │ │ ├── _spinners.scss │ │ │ │ │ ├── _images.scss │ │ │ │ │ ├── _progress.scss │ │ │ │ │ ├── _badge.scss │ │ │ │ │ ├── _alert.scss │ │ │ │ │ ├── _breadcrumb.scss │ │ │ │ │ ├── _grid.scss │ │ │ │ │ ├── _pagination.scss │ │ │ │ │ ├── _nav.scss │ │ │ │ │ ├── _type.scss │ │ │ │ │ ├── _tooltip.scss │ │ │ │ │ ├── _buttons.scss │ │ │ │ │ └── _print.scss │ │ │ │ ├── LICENSE │ │ │ │ └── dist │ │ │ │ │ └── css │ │ │ │ │ └── bootstrap-reboot.min.css │ │ │ └── jquery │ │ │ │ ├── LICENSE.txt │ │ │ │ └── README.md │ │ ├── icon.jpg │ │ ├── icon.png │ │ ├── js │ │ │ ├── signin-redirect.js │ │ │ └── signout-redirect.js │ │ ├── favicon.ico │ │ └── css │ │ │ ├── site.min.css │ │ │ ├── site.css │ │ │ └── site.scss │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── IdentityServer.csproj │ ├── Quickstart │ │ ├── Account │ │ │ ├── LogoutInputModel.cs │ │ │ ├── RedirectViewModel.cs │ │ │ ├── LogoutViewModel.cs │ │ │ ├── ExternalProvider.cs │ │ │ ├── LoginInputModel.cs │ │ │ ├── LoggedOutViewModel.cs │ │ │ ├── AccountOptions.cs │ │ │ └── LoginViewModel.cs │ │ ├── Device │ │ │ ├── DeviceAuthorizationInputModel.cs │ │ │ └── DeviceAuthorizationViewModel.cs │ │ ├── Consent │ │ │ ├── ScopeViewModel.cs │ │ │ ├── ConsentInputModel.cs │ │ │ ├── ConsentViewModel.cs │ │ │ ├── ProcessConsentResult.cs │ │ │ └── ConsentOptions.cs │ │ ├── Home │ │ │ ├── ErrorViewModel.cs │ │ │ └── HomeController.cs │ │ ├── Grants │ │ │ ├── GrantsViewModel.cs │ │ │ └── GrantsController.cs │ │ ├── Extensions.cs │ │ ├── Diagnostics │ │ │ ├── DiagnosticsController.cs │ │ │ └── DiagnosticsViewModel.cs │ │ ├── SecurityHeadersAttribute.cs │ │ └── TestUsers.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Program.cs │ ├── tempkey.jwk │ ├── Startup.cs │ └── Config.cs ├── Movies.API │ ├── Properties │ │ ├── serviceDependencies.json │ │ ├── serviceDependencies.local.json │ │ └── launchSettings.json │ ├── appsettings.Development.json │ ├── Data │ │ └── MoviesContext.cs │ ├── appsettings.json │ ├── Models │ │ └── Movie.cs │ ├── Controllers │ │ ├── IdentityController.cs │ │ └── MoviesController.cs │ ├── Movies.API.csproj │ ├── Program.cs │ └── Startup.cs ├── ApiGateway │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── ApiGateway.csproj │ ├── ocelot.json │ ├── Properties │ │ └── launchSettings.json │ ├── Program.cs │ └── Startup.cs └── SecureResource.sln └── LICENSE /SecureResource/Movies.Client/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /SecureResource/IdentityServer/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /SecureResource/IdentityServer/wwwroot/lib/bootstrap/scss/utilities/_clearfix.scss: -------------------------------------------------------------------------------- 1 | .clearfix { 2 | @include clearfix(); 3 | } 4 | -------------------------------------------------------------------------------- /SecureResource/IdentityServer/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using IdentityServerHost.Quickstart.UI 2 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 3 | -------------------------------------------------------------------------------- /SecureResource/IdentityServer/wwwroot/icon.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nirzaf/run-aspnet-identityserver/HEAD/SecureResource/IdentityServer/wwwroot/icon.jpg -------------------------------------------------------------------------------- /SecureResource/IdentityServer/wwwroot/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nirzaf/run-aspnet-identityserver/HEAD/SecureResource/IdentityServer/wwwroot/icon.png -------------------------------------------------------------------------------- /SecureResource/IdentityServer/wwwroot/js/signin-redirect.js: -------------------------------------------------------------------------------- 1 | window.location.href = document.querySelector("meta[http-equiv=refresh]").getAttribute("data-url"); 2 | -------------------------------------------------------------------------------- /SecureResource/IdentityServer/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nirzaf/run-aspnet-identityserver/HEAD/SecureResource/IdentityServer/wwwroot/favicon.ico -------------------------------------------------------------------------------- /SecureResource/Movies.Client/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Movies.Client 2 | @using Movies.Client.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /SecureResource/Movies.Client/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nirzaf/run-aspnet-identityserver/HEAD/SecureResource/Movies.Client/wwwroot/favicon.ico -------------------------------------------------------------------------------- /SecureResource/IdentityServer/wwwroot/lib/bootstrap/scss/_media.scss: -------------------------------------------------------------------------------- 1 | .media { 2 | display: flex; 3 | align-items: flex-start; 4 | } 5 | 6 | .media-body { 7 | flex: 1; 8 | } 9 | -------------------------------------------------------------------------------- /SecureResource/IdentityServer/wwwroot/lib/bootstrap/scss/mixins/_clearfix.scss: -------------------------------------------------------------------------------- 1 | @mixin clearfix() { 2 | &::after { 3 | display: block; 4 | clear: both; 5 | content: ""; 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /SecureResource/Movies.API/Properties/serviceDependencies.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | "mssql1": { 4 | "type": "mssql", 5 | "connectionId": "MoviesAPIContext" 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /SecureResource/Movies.Client/Properties/serviceDependencies.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | "mssql1": { 4 | "type": "mssql", 5 | "connectionId": "MoviesClientContext" 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /SecureResource/Movies.Client/Views/Home/Privacy.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Privacy Policy"; 3 | } 4 |
Use this page to detail your site's privacy policy.
7 | -------------------------------------------------------------------------------- /SecureResource/Movies.API/Properties/serviceDependencies.local.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | "mssql1": { 4 | "type": "mssql.local", 5 | "connectionId": "MoviesAPIContext" 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /SecureResource/Movies.Client/Properties/serviceDependencies.local.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | "mssql1": { 4 | "type": "mssql.local", 5 | "connectionId": "MoviesClientContext" 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /SecureResource/IdentityServer/wwwroot/lib/bootstrap/scss/utilities/_overflow.scss: -------------------------------------------------------------------------------- 1 | // stylelint-disable declaration-no-important 2 | 3 | @each $value in $overflows { 4 | .overflow-#{$value} { overflow: $value !important; } 5 | } 6 | -------------------------------------------------------------------------------- /SecureResource/IdentityServer/Views/Account/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | 2 |You do not have access to that resource.
6 |You have successfully authorized the device
6 |Learn about building Web apps with ASP.NET Core.
8 |Once complete, you may close this tab.
7 |Would you like to logut of IdentityServer?
7 |Please enter the code displayed on your device.
7 || 13 | Claim Type 14 | | 15 |16 | Claim Value 17 | | 18 |
|---|---|
| 25 | @Html.DisplayFor(modelItem => item.Key) 26 | | 27 |28 | @Html.DisplayFor(modelItem => item.Value) 29 | | 30 |
12 | Request ID: @Model.RequestId
13 |
18 | Swapping to Development environment will display more detailed information about the error that occurred. 19 |
20 |21 | The Development environment shouldn't be enabled for deployed applications. 22 | It can result in displaying sensitive information from exceptions to end users. 23 | For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT environment variable to Development 24 | and restarting the app. 25 |
26 | -------------------------------------------------------------------------------- /SecureResource/ApiGateway/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Microsoft.AspNetCore.Hosting; 6 | using Microsoft.Extensions.Configuration; 7 | using Microsoft.Extensions.Hosting; 8 | using Microsoft.Extensions.Logging; 9 | 10 | namespace ApiGateway 11 | { 12 | public class Program 13 | { 14 | public static void Main(string[] args) 15 | { 16 | CreateHostBuilder(args).Build().Run(); 17 | } 18 | 19 | public static IHostBuilder CreateHostBuilder(string[] args) => 20 | Host.CreateDefaultBuilder(args) 21 | .ConfigureAppConfiguration((hostingContext, config) => 22 | { 23 | config.AddJsonFile("ocelot.json"); 24 | }) 25 | .ConfigureWebHostDefaults(webBuilder => 26 | { 27 | webBuilder.UseStartup10 | Create New 11 |
12 || 16 | @Html.DisplayNameFor(model => model.Title) 17 | | 18 |19 | @Html.DisplayNameFor(model => model.Genre) 20 | | 21 |22 | @Html.DisplayNameFor(model => model.ReleaseDate) 23 | | 24 |25 | @Html.DisplayNameFor(model => model.Owner) 26 | | 27 |28 | |
|---|---|---|---|---|
| 34 | @Html.DisplayFor(modelItem => item.Title) 35 | | 36 |37 | @Html.DisplayFor(modelItem => item.Genre) 38 | | 39 |40 | @Html.DisplayFor(modelItem => item.ReleaseDate) 41 | | 42 |43 | @Html.DisplayFor(modelItem => item.Owner) 44 | | 45 |46 | Edit | 47 | Details | 48 | Delete 49 | | 50 |