{"_id":"@cgjgh/node-red-dashboard-2-cloudflare-auth","_rev":"2-879754653879fb4a98c327183f39c81b","name":"@cgjgh/node-red-dashboard-2-cloudflare-auth","dist-tags":{"latest":"0.1.9"},"versions":{"0.1.8":{"name":"@cgjgh/node-red-dashboard-2-cloudflare-auth","version":"0.1.8","keywords":["node-red","node-red-dashboard","cloudflare","cloudflare-access","cloudflare-tunnels","auth","authentication"],"license":"AGPL-3.0-or-later","_id":"@cgjgh/node-red-dashboard-2-cloudflare-auth@0.1.8","maintainers":[{"name":"cgjgh","email":"cgjgh36926@gmail.com"}],"homepage":"https://github.com/cgjgh/node-red-dashboard-2-cloudflare-auth#readme","bugs":{"url":"https://github.com/cgjgh/node-red-dashboard-2-cloudflare-auth/issues"},"dist":{"shasum":"1bc2ef188a97a6773a821216960359119cb989a1","tarball":"https://registry.npmjs.org/@cgjgh/node-red-dashboard-2-cloudflare-auth/-/node-red-dashboard-2-cloudflare-auth-0.1.8.tgz","fileCount":10,"integrity":"sha512-JiJOKhCZOHQwRwPAUScbz3Y9sfh/97i9zNWuQiRTlvfhV5NNvCzDvxkXMLqwUiCX7IyKa7/FP8XOijpueJYvRg==","signatures":[{"sig":"MEUCIEmWN+JMYF0cl+0Qi2m53oWoI10qfbnf76CySIpcF9npAiEAxXyR+xDuSJ9eIiccZur+rJupuyOyjwQtCwL+SbCqppM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":68324},"main":"src/index.js","engines":{"node":">=16.20"},"gitHead":"92645017f6dcdd37eacf7240c445ee8b85ba063d","scripts":{"dev":"node-red --userDir .node-red-data --settings settings.js","predev":"cd .node-red-data && npm install -f ../"},"_npmUser":{"name":"cgjgh","email":"cgjgh36926@gmail.com"},"node-red":{"plugins":{"node-red-dashboard-2-cloudflare-auth":"src/index.js"},"version":">=3.1"},"repository":{"url":"git+https://github.com/cgjgh/node-red-dashboard-2-cloudflare-auth.git","type":"git"},"_npmVersion":"10.2.4","description":"When used with Cloudflare Access authentication, this plugin will pass the email address of an authenticated user into the _client object under _client.user.email","directories":{},"_nodeVersion":"20.11.1","dependencies":{"@flowfuse/node-red-dashboard":"^1.10"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"nodemon":"3.1.0","node-red":"^3.1"},"_npmOperationalInternal":{"tmp":"tmp/node-red-dashboard-2-cloudflare-auth_0.1.8_1745411713892_0.22831674212621444","host":"s3://npm-registry-packages-npm-production"}},"0.1.9":{"name":"@cgjgh/node-red-dashboard-2-cloudflare-auth","version":"0.1.9","description":"When used with Cloudflare Access authentication, this plugin will pass the email address of an authenticated user into the _client object under _client.user.email","main":"src/index.js","scripts":{"predev":"cd .node-red-data && npm install -f ../","dev":"node-red --userDir .node-red-data --settings settings.js"},"node-red":{"version":">=3.1","plugins":{"node-red-dashboard-2-cloudflare-auth":"src/index.js"}},"engines":{"node":">=16.20"},"keywords":["node-red","node-red-dashboard","cloudflare","cloudflare-access","cloudflare-tunnels","auth","authentication"],"dependencies":{"@flowfuse/node-red-dashboard":"^1.10"},"devDependencies":{"node-red":"^3.1","nodemon":"3.1.0"},"license":"AGPL-3.0-or-later","repository":{"type":"git","url":"git+https://github.com/cgjgh/node-red-dashboard-2-cloudflare-auth.git"},"bugs":{"url":"https://github.com/cgjgh/node-red-dashboard-2-cloudflare-auth/issues"},"homepage":"https://github.com/cgjgh/node-red-dashboard-2-cloudflare-auth#readme","publishConfig":{"access":"public"},"_id":"@cgjgh/node-red-dashboard-2-cloudflare-auth@0.1.9","gitHead":"8734d03bb43cb2c9099c5abada680e10fc471578","_nodeVersion":"20.11.1","_npmVersion":"10.2.4","dist":{"integrity":"sha512-hy0nFHIl67Ec24CNsdNRn1od+1IgfpoNKWDzZImloJIad4clvQLnAOGNH+FzYCrWeJZyxlzhhK2148+Z9XZG5w==","shasum":"d6682edf2e2c3b659c3a1f0ae8fca3b775d0c088","tarball":"https://registry.npmjs.org/@cgjgh/node-red-dashboard-2-cloudflare-auth/-/node-red-dashboard-2-cloudflare-auth-0.1.9.tgz","fileCount":10,"unpackedSize":68315,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCTgrjbMLjdcW47boz+sEd6gsITVxt9UFmSkzg9sAMYywIhAOR1ZoMUeAEsMMkBiWPU/ZCU/khtcdSnrYP7mTCR5+gH"}]},"_npmUser":{"name":"cgjgh","email":"cgjgh36926@gmail.com"},"directories":{},"maintainers":[{"name":"cgjgh","email":"cgjgh36926@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/node-red-dashboard-2-cloudflare-auth_0.1.9_1745417918391_0.6613063780884811"},"_hasShrinkwrap":false}},"time":{"created":"2025-04-23T12:35:13.792Z","modified":"2025-04-23T14:18:38.746Z","0.1.8":"2025-04-23T12:35:14.107Z","0.1.9":"2025-04-23T14:18:38.581Z"},"bugs":{"url":"https://github.com/cgjgh/node-red-dashboard-2-cloudflare-auth/issues"},"license":"AGPL-3.0-or-later","homepage":"https://github.com/cgjgh/node-red-dashboard-2-cloudflare-auth#readme","keywords":["node-red","node-red-dashboard","cloudflare","cloudflare-access","cloudflare-tunnels","auth","authentication"],"repository":{"type":"git","url":"git+https://github.com/cgjgh/node-red-dashboard-2-cloudflare-auth.git"},"description":"When used with Cloudflare Access authentication, this plugin will pass the email address of an authenticated user into the _client object under _client.user.email","maintainers":[{"name":"cgjgh","email":"cgjgh36926@gmail.com"}],"readme":"# node-red-dashboard-2-cloudflare-auth\r\n\r\nEnables Cloudflare Access user auth information to be passed to Node-RED.\r\n\r\nThis authentication plugin was made for the fantastic [Node-RED Dashboard 2](https://github.com/FlowFuse/node-red-dashboard) project by [FlowFuse](https://github.com/FlowFuse). \r\nIt enables those using [Cloudflare Access](https://www.cloudflare.com/zero-trust/products/access/) to receive user information such as email address in Node-RED anytime they interact with Dashboard elements. This can be useful for configuring authorization (authz) rules, or for per-user scoped reads/writes, etc. \r\n\r\n## Getting Started\r\n\r\nPre-requisites:\r\n- A Cloudflare account\r\n- A Cloudflare [tunnel configured for your Node-RED instance](https://developers.cloudflare.com/cloudflare-one/connections/connect-networks/get-started/create-remote-tunnel/)\r\n- A Cloudflare [access policy configured for your Node-RED instance](https://developers.cloudflare.com/cloudflare-one/applications/configure-apps/self-hosted-apps/)\r\n\r\nSteps:\r\n1. Install @flowfuse/node-red-dashboard \r\n\r\n2. Install `@cgjgh/node-red-dashboard-2-cloudflare-auth` via npm or flows.nodered.org\r\n\r\n3. Create a Dashboard element and wire it up to a debug node set to display the whole msg object (not just payload)\r\n\r\n4. Navigate to your Node-RED dashboard instance via your Cloudflare tunnel, authenticate with Access, and click on the button in your Node-RED dashboard\r\n\r\n5. Navigate back to the Node-RED editor's debug window and see information provided under msg._client.user\r\n\r\n\r\n## Contributing\r\n\r\nPull requests and issues welcome! \r\n\r\nIn order to develop:\r\n\r\n1. Clone the repo\r\n2. Optionally run the devcontainer in vscode\r\n3. 'npm run dev' for local Node-RED instance with the module installed\r\n\r\n","readmeFilename":"README.md"}