├── .gitignore ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.MD ├── InvitationCodeAzureFunction ├── function.json ├── index.js └── sample.dat ├── LICENSE.md ├── README.md ├── ReadmeImages ├── configure_page_layouts.png ├── create-api-connector.png ├── custom-attribute-add.png ├── enable-api-connector.png ├── search-for-extensions-app-id.png └── select-custom-attribute.png ├── SECURITY.md ├── host.json ├── package-lock.json └── package.json /.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | lerna-debug.log* 8 | 9 | # Diagnostic reports (https://nodejs.org/api/report.html) 10 | report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json 11 | 12 | # Runtime data 13 | pids 14 | *.pid 15 | *.seed 16 | *.pid.lock 17 | 18 | # Directory for instrumented libs generated by jscoverage/JSCover 19 | lib-cov 20 | 21 | # Coverage directory used by tools like istanbul 22 | coverage 23 | 24 | # nyc test coverage 25 | .nyc_output 26 | 27 | # Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) 28 | .grunt 29 | 30 | # Bower dependency directory (https://bower.io/) 31 | bower_components 32 | 33 | # node-waf configuration 34 | .lock-wscript 35 | 36 | # Compiled binary addons (https://nodejs.org/api/addons.html) 37 | build/Release 38 | 39 | # Dependency directories 40 | node_modules/ 41 | jspm_packages/ 42 | 43 | # TypeScript v1 declaration files 44 | typings/ 45 | 46 | # Optional npm cache directory 47 | .npm 48 | 49 | # Optional eslint cache 50 | .eslintcache 51 | 52 | # Optional REPL history 53 | .node_repl_history 54 | 55 | # Output of 'npm pack' 56 | *.tgz 57 | 58 | # Yarn Integrity file 59 | .yarn-integrity 60 | 61 | # dotenv environment variables file 62 | .env 63 | .env.test 64 | 65 | # parcel-bundler cache (https://parceljs.org/) 66 | .cache 67 | 68 | # next.js build output 69 | .next 70 | 71 | # nuxt.js build output 72 | .nuxt 73 | 74 | # vuepress build output 75 | .vuepress/dist 76 | 77 | # Serverless directories 78 | .serverless/ 79 | 80 | # FuseBox cache 81 | .fusebox/ 82 | 83 | # DynamoDB Local files 84 | .dynamodb/ 85 | 86 | # TypeScript output 87 | dist 88 | out 89 | 90 | # Azure Functions artifacts 91 | bin 92 | obj 93 | appsettings.json 94 | local.settings.json 95 | 96 | # Other 97 | *.DS_Store* 98 | 99 | # Visual Studio Code 100 | .vscode/ -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Microsoft Open Source Code of Conduct 2 | 3 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). 4 | 5 | Resources: 6 | 7 | - [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/) 8 | - [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) 9 | - Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns 10 | -------------------------------------------------------------------------------- /CONTRIBUTING.MD: -------------------------------------------------------------------------------- 1 | # Contributing to InivationCodeNode 2 | 3 | This project welcomes contributions and suggestions. Most contributions require you to agree to a 4 | Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us 5 | the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com. 6 | 7 | When you submit a pull request, a CLA bot will automatically determine whether you need to provide 8 | a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions 9 | provided by the bot. You will only need to do this once across all repos using our CLA. 10 | 11 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). 12 | For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or 13 | contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments. 14 | 15 | - [Code of Conduct](#coc) 16 | - [Issues and Bugs](#issue) 17 | - [Feature Requests](#feature) 18 | - [Submission Guidelines](#submit) 19 | 20 | ## Code of Conduct 21 | Help us keep this project open and inclusive. Please read and follow our [Code of Conduct](https://opensource.microsoft.com/codeofconduct/). 22 | 23 | ## Found an Issue? 24 | If you find a bug in the source code or a mistake in the documentation, you can help us by 25 | [submitting an issue](#submit-issue) to the GitHub Repository. Even better, you can 26 | [submit a Pull Request](#submit-pr) with a fix. 27 | 28 | ## Want a Feature? 29 | You can *request* a new feature by [submitting an issue](#submit-issue) to the GitHub 30 | Repository. If you would like to *implement* a new feature, please submit an issue with 31 | a proposal for your work first, to be sure that we can use it. 32 | 33 | * **Small Features** can be crafted and directly [submitted as a Pull Request](#submit-pr). 34 | 35 | ## Submission Guidelines 36 | 37 | ### Submitting an Issue 38 | Before you submit an issue, search the archive, maybe your question was already answered. 39 | 40 | If your issue appears to be a bug, and hasn't been reported, open a new issue. 41 | Help us to maximize the effort we can spend fixing issues and adding new 42 | features, by not reporting duplicate issues. Providing the following information will increase the 43 | chances of your issue being dealt with quickly: 44 | 45 | * **Overview of the Issue** - if an error is being thrown a non-minified stack trace helps 46 | * **Version** - what version is affected (e.g. 0.1.2) 47 | * **Motivation for or Use Case** - explain what are you trying to do and why the current behavior is a bug for you 48 | * **Browsers and Operating System** - is this a problem with all browsers? 49 | * **Reproduce the Error** - provide a live example or a unambiguous set of steps 50 | * **Related Issues** - has a similar issue been reported before? 51 | * **Suggest a Fix** - if you can't fix the bug yourself, perhaps you can point to what might be 52 | causing the problem (line of code or commit) 53 | 54 | You can file new issues by providing the above information at the corresponding repository's issues link: https://github.com/[organization-name]/[repository-name]/issues/new]. 55 | 56 | ### Submitting a Pull Request (PR) 57 | Before you submit your Pull Request (PR) consider the following guidelines: 58 | 59 | * Search the repository (https://github.com/[organization-name]/[repository-name]/pulls) for an open or closed PR 60 | that relates to your submission. You don't want to duplicate effort. 61 | 62 | * Make your changes in a new git fork: 63 | 64 | * Commit your changes using a descriptive commit message 65 | * Push your fork to GitHub: 66 | * In GitHub, create a pull request 67 | * If we suggest changes then: 68 | * Make the required updates. 69 | * Rebase your fork and force push to your GitHub repository (this will update your Pull Request): 70 | 71 | ```shell 72 | git rebase master -i 73 | git push -f 74 | ``` 75 | 76 | That's it! Thank you for your contribution! 77 | -------------------------------------------------------------------------------- /InvitationCodeAzureFunction/function.json: -------------------------------------------------------------------------------- 1 | { 2 | "bindings": [ 3 | { 4 | "authLevel": "function", 5 | "type": "httpTrigger", 6 | "direction": "in", 7 | "name": "req", 8 | "methods": [ 9 | "post" 10 | ] 11 | }, 12 | { 13 | "type": "http", 14 | "direction": "out", 15 | "name": "res" 16 | } 17 | ] 18 | } 19 | -------------------------------------------------------------------------------- /InvitationCodeAzureFunction/index.js: -------------------------------------------------------------------------------- 1 | module.exports = async function (context, req) { 2 | 3 | // parse Basic Auth username and password 4 | var header = req.headers["authorization"] || "", // get the header 5 | token = header.split(/\s+/).pop() || "", // and the encoded auth token 6 | auth = new Buffer.from(token, "base64").toString(), // convert from base64 7 | parts = auth.split(/:/), // split on colon 8 | username = parts[0], 9 | password = parts[1]; 10 | 11 | // Check for HTTP Basic Authentication, return HTTP 401 error if invalid credentials. 12 | if ( 13 | username !== process.env["BASIC_AUTH_USERNAME"] || 14 | password !== process.env["BASIC_AUTH_PASSWORD"] 15 | ) { 16 | context.res = { 17 | status: 401, 18 | }; 19 | context.log("Invalid Authentication"); 20 | return; 21 | } 22 | 23 | context.log('JavaScript HTTP trigger function processed a request.'); 24 | 25 | //if dynamic, could integrate with a backend that tracks valid sign-up codes per email address. 26 | const validInvitationCodes = ["invitation-code-1", "invitation-code-2"] 27 | 28 | const invitationCodeAttributeKey = "extension_" + process.env["B2C_EXTENSIONS_APP_ID"] + "_InvitationCode"; 29 | 30 | let inviteCode = req.body && req.body[invitationCodeAttributeKey]; //extension app-id 31 | 32 | var body = { 33 | "version": "1.0.0", 34 | "status": 400, 35 | "action": "ValidationError", 36 | }; 37 | var status = 400; 38 | 39 | if(!inviteCode){ 40 | body["userMessage"] = "Please provide an invitation code."; 41 | } else if (!validInvitationCodes.includes(inviteCode)) { 42 | body["userMessage"] = "Your invitation code is invalid. Please try again." 43 | } else { 44 | status = 200; 45 | body = { 46 | "version": "1.0.0", 47 | "action": "Continue", 48 | [invitationCodeAttributeKey]: "" //overwrites extension attribute to "" in order to not store it in the directory 49 | }; 50 | } 51 | 52 | context.res = { 53 | status: status, 54 | body: body 55 | }; 56 | }; -------------------------------------------------------------------------------- /InvitationCodeAzureFunction/sample.dat: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Azure" 3 | } -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) Microsoft Corporation. 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | --- 2 | page_type: sample 3 | languages: 4 | - javascript 5 | - nodejs 6 | products: 7 | - azure-active-directory 8 | description: "A sample to demonstrate how to limit sign-ups to specific audiences using invitation codes using Node.js Azure Function and API connectors." 9 | urlFragment: active-directory-node-b2c-sign-up-user-flow-invitation-code 10 | --- 11 | 12 | # active-directory-node-b2c-user-flow-invitation-code 13 | 14 | ## Contents 15 | 16 | | File/folder | Description | 17 | | --------------------------- | ------------------------------------------ | 18 | | `InvitationCodeAzureFunction` | Sample source code for Node.js HTTP trigger. | 19 | | `README.md` | This README file. | 20 | | `.gitignore` | Define what to ignore at commit time. | 21 | | `CONTRIBUTING.md` | Guidance on how to contribute to this repository. | 22 | | `LICENSE.md` | The license for the sample. | 23 | | `SECURITY.md` | The security notice for the sample. | 24 | 25 | ## Key Concepts 26 | 27 | Often times, you may want to limit sign-ups to your application and tenant to specific audiences. An "audience" may be a singular person (with a corresponding email address), a set of people, or more using invitation codes. An invitation code is collected from a user during sign-up and validated. A user may get this invitation code from an email you send them or some other method. The exact logic is open ended and can accommodate a variety of scenarios. 28 | 29 | Key components: 30 | 31 | - [**Azure Functions HTTP trigger**](https://docs.microsoft.com/azure/azure-functions/functions-bindings-http-webhook-trigger?tabs=javascript) - API endpoint hosted by you that receives an invitation code and user information and checks whether it's valid. 32 | - **Azure AD B2C sign-up user flow** - The sign-up experience that will be limited by an invitation code. Will utilize [API connectors](https://docs.microsoft.com/azure/active-directory-b2c/api-connectors-overview) to integrate with the Azure Function HTTP trigger. 33 | 34 | This sample provides a starting point for an invitation code sign-up flow. 35 | 36 | ## Create a "InvitationCode" Custom Attribute 37 | 38 | 1. From the Azure Portal, go to **Azure AD B2C** 39 | 1. Select **User Attributes** 40 | 1. Select **Add** 41 | 1. Enter `InvitationCode` as the attribute **Name** 42 | 1. **Create** 43 | 44 | ![Custom attribute creation](ReadmeImages/custom-attribute-add.png) 45 | 46 | Learn more about [custom attributes](https://docs.microsoft.com/azure/active-directory-b2c/user-flow-custom-attributes). 47 | 48 | ## Create a user flow 49 | 50 | This can be either be a **sign up and sign in** or a just **sign up** or user flow. 51 | 52 | 1. [Follow these instructions](https://docs.microsoft.com/azure/active-directory-b2c/tutorial-create-user-flows). 53 | 1. If using an existing user flow, note that user flows must be of the "Recommended (next-generation preview)" version type. 54 | 1. In the user flow settings, navigate to **User attributes** and select the **InvitationCode** claim. 55 | 56 | ![Select custom attribute in user flow](ReadmeImages/select-custom-attribute.png) 57 | 58 | ## Configure page layouts 59 | 60 | 1. From the Azure Portal, go to **Azure AD B2C** 61 | 1. Navigate to **User flows** and select your user flow 62 | 1. Select **Page layouts** 63 | 1. Select **Local account sign up page** layout 64 | 1. Select the **Optional** value to **No**. 65 | 1. Use drag and drop to place the invitation code in the order that you'd like to appear when in the user sign-up form. 66 | 1. Set the **Label** to **"Invitation Code"** 67 | 68 | ![Configure page layouts in user flow](ReadmeImages/configure_page_layouts.png) 69 | 70 | ## Create and deploy your API 71 | 72 | These steps assume you use Visual Studio Code, but deploying the Azure Function via the Azure Portal, terminal or command prompt, or any other code editor will also work. 73 | 74 | **Prerequisite**: Install the [Azure Functions extension](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-azurefunctions) for Visual Studio Code. 75 | 76 | ### Run the API locally 77 | 78 | 1. Navigate to the **Azure extension** in Visual Studio code on the left navigation bar. You should see a 'Local Project' folder representing your local Azure Function. 79 | 1. Press **F5** (or use the **Debug > Start Debugging** menu command) to launch the debugger and attach to the Azure Functions host. (This command automatically uses the single debug configuration that Azure Functions created.) 80 | 1. The Azure Function extension will automatically generate a few files for local development, install dependencies, and install the Function Core tools if not already present. These tools help with the debugging experience. 81 | 1. Output from the Functions Core tools appears in the VS Code **Terminal** panel. Once the host has started, **Alt+click** the local URL shown in the output to open the browser and run the function. You can also see the url of the locally-hosted function by right clicking on the function on the Azure Functions explorer. 82 | 1. To redeploy the local instance during testing, just repeat these steps. 83 | 84 | ### Add environment variables 85 | 86 | This sample protects the web API endpoint using [HTTP Basic authentication](https://tools.ietf.org/html/rfc7617). 87 | 88 | Here, username and password are stored as environment variables so they're not stored as part of the repository. Read more about the [local.settings.json](https://docs.microsoft.com/azure/azure-functions/functions-run-local?tabs=macos%2Ccsharp%2Cbash#local-settings-file) file. 89 | 90 | 1. Create a **local.settings.json** file in your root folder 91 | 1. Copy and paste the below code onto the file: 92 | 93 | ```json 94 | { 95 | "IsEncrypted": false, 96 | "Values": { 97 | "AzureWebJobsStorage": "", 98 | "FUNCTIONS_WORKER_RUNTIME": "node", 99 | "BASIC_AUTH_USERNAME": "", 100 | "BASIC_AUTH_PASSWORD": "", 101 | "B2C_EXTENSIONS_APP_ID": "" 102 | } 103 | } 104 | ``` 105 | 106 | The **BASIC_AUTH_USERNAME** and **BASIC_AUTH_PASSWORD** are going to be the credentials used to authenticate the API call to your Azure Function. Choose your desired values. 107 | 108 | The `` is the application ID of the app used by Azure AD B2C to store custom attributes in the directory. You can find this application ID by navigating to **App registrations**, searching for `b2c-extensions-app` and copying the `Application (client) ID` from the **Overview** pane. Remove the `-` characters. 109 | 110 | ![Find extensions app](ReadmeImages/search-for-extensions-app-id.png) 111 | 112 | ### Deploy the application to the web 113 | 114 | 1. Follow steps of [this](https://docs.microsoft.com/azure/javascript/tutorial-vscode-serverless-node-04) guide #1-7 to deploy your Azure Function to the cloud. Copy the endpoint web URL of your Azure Function. 115 | 1. Once deployed, you'll see an **'Upload settings'** option. Select this. It will upload your environment variables onto the [Application settings](https://docs.microsoft.com/azure/azure-functions/functions-develop-vs-code?tabs=csharp#application-settings-in-azure) of the App service. These application settings can also be configured or [managed via the Azure portal](https://docs.microsoft.com/azure/azure-functions/functions-how-to-use-azure-function-app-settings). 116 | 117 | To learn more about Visual Studio Code development for Azure Functions, see [this](https://docs.microsoft.com/azure/azure-functions/functions-develop-vs-code?tabs=csharp#republish-project-files). 118 | 119 | ## Configure and enable the API connector 120 | 121 | Follow the steps outlined in ["Add an API connector"](https://docs.microsoft.com/azure/active-directory-b2c/add-api-connector) to create an API connector and enable it your user flow. The configuration should look like the below. 122 | 123 | ### API connector configuration 124 | 125 | Your API connector configuration should look like the following: 126 | 127 | ![API connector configuration](ReadmeImages/create-api-connector.png) 128 | 129 | - **Endpoint URL** is the Function URL you copied earlier if the deployed Azure Function. 130 | - **Username** and **Password** are the Username and Passwords you defined as environment variables earlier. 131 | 132 | ### Enable the API connector 133 | 134 | In the **API connector** settings for your user flow, select the API connector to be invoked at the **Before creating the user** step. This will invoke the API when a user hits 'Create' in the sign-up flow. The API will do a server-side validation of the invitation code to determine whether to allow the user to sign up. 135 | 136 | ![API connector selected](ReadmeImages/enable-api-connector.png) -------------------------------------------------------------------------------- /ReadmeImages/configure_page_layouts.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Azure-Samples/active-directory-b2c-node-sign-up-user-flow-invitation-code/47c99546aeb058144ebd3c2df0881c3606aac20c/ReadmeImages/configure_page_layouts.png -------------------------------------------------------------------------------- /ReadmeImages/create-api-connector.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Azure-Samples/active-directory-b2c-node-sign-up-user-flow-invitation-code/47c99546aeb058144ebd3c2df0881c3606aac20c/ReadmeImages/create-api-connector.png -------------------------------------------------------------------------------- /ReadmeImages/custom-attribute-add.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Azure-Samples/active-directory-b2c-node-sign-up-user-flow-invitation-code/47c99546aeb058144ebd3c2df0881c3606aac20c/ReadmeImages/custom-attribute-add.png -------------------------------------------------------------------------------- /ReadmeImages/enable-api-connector.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Azure-Samples/active-directory-b2c-node-sign-up-user-flow-invitation-code/47c99546aeb058144ebd3c2df0881c3606aac20c/ReadmeImages/enable-api-connector.png -------------------------------------------------------------------------------- /ReadmeImages/search-for-extensions-app-id.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Azure-Samples/active-directory-b2c-node-sign-up-user-flow-invitation-code/47c99546aeb058144ebd3c2df0881c3606aac20c/ReadmeImages/search-for-extensions-app-id.png -------------------------------------------------------------------------------- /ReadmeImages/select-custom-attribute.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Azure-Samples/active-directory-b2c-node-sign-up-user-flow-invitation-code/47c99546aeb058144ebd3c2df0881c3606aac20c/ReadmeImages/select-custom-attribute.png -------------------------------------------------------------------------------- /SECURITY.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | ## Security 4 | 5 | Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/). 6 | 7 | If you believe you have found a security vulnerability in any Microsoft-owned repository that meets [Microsoft's definition of a security vulnerability](https://docs.microsoft.com/en-us/previous-versions/tn-archive/cc751383(v=technet.10)), please report it to us as described below. 8 | 9 | ## Reporting Security Issues 10 | 11 | **Please do not report security vulnerabilities through public GitHub issues.** 12 | 13 | Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report). 14 | 15 | If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/en-us/msrc/pgp-key-msrc). 16 | 17 | You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc). 18 | 19 | Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue: 20 | 21 | * Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.) 22 | * Full paths of source file(s) related to the manifestation of the issue 23 | * The location of the affected source code (tag/branch/commit or direct URL) 24 | * Any special configuration required to reproduce the issue 25 | * Step-by-step instructions to reproduce the issue 26 | * Proof-of-concept or exploit code (if possible) 27 | * Impact of the issue, including how an attacker might exploit the issue 28 | 29 | This information will help us triage your report more quickly. 30 | 31 | If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://microsoft.com/msrc/bounty) page for more details about our active programs. 32 | 33 | ## Preferred Languages 34 | 35 | We prefer all communications to be in English. 36 | 37 | ## Policy 38 | 39 | Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://www.microsoft.com/en-us/msrc/cvd). 40 | 41 | -------------------------------------------------------------------------------- /host.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "extensionBundle": { 4 | "id": "Microsoft.Azure.Functions.ExtensionBundle", 5 | "version": "[1.*, 2.0.0)" 6 | }, 7 | "logging": { 8 | "fileLoggingMode": "always", 9 | "logLevel": { 10 | "default": "Information", 11 | "Host.Results": "Error", 12 | "Function": "Trace", 13 | "Host.Aggregator": "Trace" 14 | } 15 | } 16 | } -------------------------------------------------------------------------------- /package-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "invitation-code-b2c-sign-up-node", 3 | "version": "1.0.0", 4 | "lockfileVersion": 1 5 | } 6 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "invitation-code-b2c-sign-up-node", 3 | "version": "1.0.0", 4 | "description": "", 5 | "scripts": { 6 | "start": "func start", 7 | "test": "echo \"No tests yet...\"" 8 | }, 9 | "dependencies": {}, 10 | "devDependencies": {} 11 | } 12 | --------------------------------------------------------------------------------