├── samples
├── PwnedPasswords.Sample
│ ├── wwwroot
│ │ ├── js
│ │ │ ├── site.min.js
│ │ │ └── site.js
│ │ ├── favicon.ico
│ │ ├── lib
│ │ │ ├── bootstrap
│ │ │ │ ├── dist
│ │ │ │ │ ├── fonts
│ │ │ │ │ │ ├── glyphicons-halflings-regular.eot
│ │ │ │ │ │ ├── glyphicons-halflings-regular.ttf
│ │ │ │ │ │ ├── glyphicons-halflings-regular.woff
│ │ │ │ │ │ └── glyphicons-halflings-regular.woff2
│ │ │ │ │ └── js
│ │ │ │ │ │ └── npm.js
│ │ │ │ ├── .bower.json
│ │ │ │ └── LICENSE
│ │ │ ├── jquery-validation-unobtrusive
│ │ │ │ ├── .bower.json
│ │ │ │ ├── LICENSE.txt
│ │ │ │ └── jquery.validate.unobtrusive.min.js
│ │ │ ├── jquery
│ │ │ │ ├── .bower.json
│ │ │ │ └── LICENSE.txt
│ │ │ └── jquery-validation
│ │ │ │ ├── .bower.json
│ │ │ │ └── LICENSE.md
│ │ ├── css
│ │ │ ├── site.min.css
│ │ │ └── site.css
│ │ └── images
│ │ │ ├── banner2.svg
│ │ │ └── banner1.svg
│ ├── Pages
│ │ ├── _ViewStart.cshtml
│ │ ├── Privacy.cshtml
│ │ ├── About.cshtml
│ │ ├── _ViewImports.cshtml
│ │ ├── Privacy.cshtml.cs
│ │ ├── Index.cshtml.cs
│ │ ├── Contact.cshtml.cs
│ │ ├── About.cshtml.cs
│ │ ├── Contact.cshtml
│ │ ├── Error.cshtml.cs
│ │ ├── Error.cshtml
│ │ ├── Shared
│ │ │ ├── _LoginPartial.cshtml
│ │ │ ├── _ValidationScriptsPartial.cshtml
│ │ │ ├── _CookieConsentPartial.cshtml
│ │ │ └── _Layout.cshtml
│ │ └── Index.cshtml
│ ├── Areas
│ │ └── Identity
│ │ │ └── Pages
│ │ │ └── _ViewStart.cshtml
│ ├── appsettings.Development.json
│ ├── appsettings.json
│ ├── Data
│ │ ├── ApplicationDbContext.cs
│ │ └── Migrations
│ │ │ ├── ApplicationDbContextModelSnapshot.cs
│ │ │ └── 00000000000000_CreateIdentitySchema.Designer.cs
│ ├── Program.cs
│ ├── PwnedPasswords.Sample.csproj
│ ├── Properties
│ │ └── launchSettings.json
│ └── Startup.cs
└── PwnedPasswords.Sample.NetCore3
│ ├── Pages
│ ├── _ViewStart.cshtml
│ ├── Privacy.cshtml
│ ├── Shared
│ │ ├── _ValidationScriptsPartial.cshtml
│ │ ├── _LoginPartial.cshtml
│ │ └── _Layout.cshtml
│ ├── _ViewImports.cshtml
│ ├── Index.cshtml
│ ├── Index.cshtml.cs
│ ├── Privacy.cshtml.cs
│ ├── Error.cshtml
│ └── Error.cshtml.cs
│ ├── Areas
│ └── Identity
│ │ └── Pages
│ │ └── _ViewStart.cshtml
│ ├── app.db
│ ├── wwwroot
│ ├── favicon.ico
│ ├── js
│ │ └── site.js
│ ├── lib
│ │ ├── jquery-validation-unobtrusive
│ │ │ ├── LICENSE.txt
│ │ │ └── jquery.validate.unobtrusive.min.js
│ │ ├── jquery-validation
│ │ │ └── LICENSE.md
│ │ ├── bootstrap
│ │ │ ├── LICENSE
│ │ │ └── dist
│ │ │ │ └── css
│ │ │ │ ├── bootstrap-reboot.min.css
│ │ │ │ └── bootstrap-reboot.css
│ │ └── jquery
│ │ │ └── LICENSE.txt
│ └── css
│ │ └── site.css
│ ├── appsettings.Development.json
│ ├── appsettings.json
│ ├── Data
│ ├── ApplicationDbContext.cs
│ └── Migrations
│ │ └── 00000000000000_CreateIdentitySchema.cs
│ ├── CustomErrorDescriber.cs
│ ├── Properties
│ └── launchSettings.json
│ ├── Program.cs
│ ├── PwnedPasswords.Sample.NetCore3.csproj
│ └── Startup.cs
├── logo.png
├── version.props
├── CHANGELOG.md
├── .vscode
├── tasks.json
└── launch.json
├── src
├── PwnedPasswords.Validator
│ ├── PwnedPasswordValidatorOptions.cs
│ ├── PwnedPasswordErrorDescriber.cs
│ ├── PwnedPasswords.Validator.csproj
│ ├── PwnedPasswordValidator.cs
│ └── IdentityBuilderExtensions.cs
└── PwnedPasswords.Client
│ ├── PwnedPasswordClientOptions.cs
│ ├── IPwnedPasswordsClient.cs
│ ├── SHA1Util.cs
│ ├── PwnedPasswords.Client.csproj
│ └── PwnedPasswordsClient.cs
├── releasenotes.props
├── appveyor.yml
├── test
├── PwnedPasswords.Validator.Test
│ ├── Shared
│ │ ├── TestUserRole.cs
│ │ ├── TestUserClaim.cs
│ │ ├── TestUserToken.cs
│ │ ├── TestUserLogin.cs
│ │ ├── IdentityResultAssert.cs
│ │ ├── TestUser.cs
│ │ └── MockHelpers.cs
│ ├── PwnedPasswords.Validator.Test.csproj
│ └── PwnedPasswordValidatorTests.cs
└── PwnedPasswords.Client.Test
│ ├── PwnedPasswords.Client.Test.csproj
│ ├── MockHelpers.cs
│ └── HaveIBeenPwnedClientTests.cs
├── LICENSE
├── Directory.Build.props
├── .gitattributes
├── .gitignore
├── PwnedPasswords.sln
└── README.md
/samples/PwnedPasswords.Sample/wwwroot/js/site.min.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/andrewlock/PwnedPasswords/HEAD/logo.png
--------------------------------------------------------------------------------
/samples/PwnedPasswords.Sample/Pages/_ViewStart.cshtml:
--------------------------------------------------------------------------------
1 | @{
2 | Layout = "_Layout";
3 | }
4 |
--------------------------------------------------------------------------------
/samples/PwnedPasswords.Sample.NetCore3/Pages/_ViewStart.cshtml:
--------------------------------------------------------------------------------
1 | @{
2 | Layout = "_Layout";
3 | }
4 |
--------------------------------------------------------------------------------
/version.props:
--------------------------------------------------------------------------------
1 |
Use this page to detail your site's privacy policy.
-------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Debug", 5 | "System": "Information", 6 | "Microsoft": "Information" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample.NetCore3/Pages/Privacy.cshtml: -------------------------------------------------------------------------------- 1 | @page 2 | @model PrivacyModel 3 | @{ 4 | ViewData["Title"] = "Privacy Policy"; 5 | } 6 |Use this page to detail your site's privacy policy.
9 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample.NetCore3/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Debug", 5 | "System": "Information", 6 | "Microsoft": "Information" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andrewlock/PwnedPasswords/HEAD/samples/PwnedPasswords.Sample/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andrewlock/PwnedPasswords/HEAD/samples/PwnedPasswords.Sample/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andrewlock/PwnedPasswords/HEAD/samples/PwnedPasswords.Sample/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andrewlock/PwnedPasswords/HEAD/samples/PwnedPasswords.Sample/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample.NetCore3/Pages/Shared/_ValidationScriptsPartial.cshtml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample/Pages/About.cshtml: -------------------------------------------------------------------------------- 1 | @page 2 | @model AboutModel 3 | @{ 4 | ViewData["Title"] = "About"; 5 | } 6 |Use this area to provide additional information.
10 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample/Pages/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Microsoft.AspNetCore.Identity 2 | @using PwnedPasswords.Sample 3 | @using PwnedPasswords.Sample.Data 4 | @namespace PwnedPasswords.Sample.Pages 5 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 6 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Please see documentation at https://docs.microsoft.com/aspnet/core/client-side/bundling-and-minification 2 | // for details on configuring this project to bundle and minify static web assets. 3 | 4 | // Write your Javascript code. 5 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample.NetCore3/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Please see documentation at https://docs.microsoft.com/aspnet/core/client-side/bundling-and-minification 2 | // for details on configuring this project to bundle and minify static web assets. 3 | 4 | // Write your Javascript code. 5 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample.NetCore3/Pages/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Microsoft.AspNetCore.Identity 2 | @using PwnedPasswords.Sample.NetCore3 3 | @using PwnedPasswords.Sample.NetCore3.Data 4 | @namespace PwnedPasswords.Sample.NetCore3.Pages 5 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 6 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample.NetCore3/Pages/Index.cshtml: -------------------------------------------------------------------------------- 1 | @page 2 | @model IndexModel 3 | @{ 4 | ViewData["Title"] = "Home page"; 5 | } 6 | 7 |Learn about building Web apps with ASP.NET Core.
10 |
13 | Request ID: @Model.RequestId
14 |
19 | Swapping to Development environment will display more detailed information about the error that occurred. 20 |
21 |22 | Development environment should not be enabled in deployed applications, as it can result in sensitive information from exceptions being displayed to end users. For local debugging, development environment can be enabled by setting the ASPNETCORE_ENVIRONMENT environment variable to Development, and restarting the application. 23 |
24 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample.NetCore3/Pages/Error.cshtml: -------------------------------------------------------------------------------- 1 | @page 2 | @model ErrorModel 3 | @{ 4 | ViewData["Title"] = "Error"; 5 | } 6 | 7 |
13 | Request ID: @Model.RequestId
14 |
19 | Swapping to the Development environment displays detailed information about the error that occurred. 20 |
21 |22 | The Development environment shouldn't be enabled for deployed applications. 23 | It can result in displaying sensitive information from exceptions to end users. 24 | For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT environment variable to Development 25 | and restarting the app. 26 |
27 | -------------------------------------------------------------------------------- /samples/PwnedPasswords.Sample.NetCore3/Pages/Error.cshtml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Diagnostics; 4 | using System.Linq; 5 | using System.Threading.Tasks; 6 | using Microsoft.AspNetCore.Mvc; 7 | using Microsoft.AspNetCore.Mvc.RazorPages; 8 | using Microsoft.Extensions.Logging; 9 | 10 | namespace PwnedPasswords.Sample.NetCore3.Pages 11 | { 12 | [ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)] 13 | public class ErrorModel : PageModel 14 | { 15 | public string RequestId { get; set; } 16 | 17 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 18 | 19 | private readonly ILogger