Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

website/docs: add . in https://netbird.company* #12166

Merged
merged 8 commits into from
Dec 5, 2024
2 changes: 1 addition & 1 deletion website/integrations/services/netbird/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ The following placeholders will be used:
5. In the provider settings, add the following redirect URLs under **Redirect URIs/Origins (RegEx)**:
```
https://netbird.company
https://netbird.company*
https://netbird.company.*
http://localhost:53000
```
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
```
https://netbird.company
https://netbird.company*
https://netbird.company.*
http://localhost:53000
```
- Strict; https://netbird.company
- Regex; https://netbird.company/.*
- Strict; http://localhost:53000

I'm not sure about the 2nd entry in the list, but just having .* at the end would be an insecure configuration

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried with https://netbird.company/.* or https://netbird.company.* and it seems there are no issues. But if I don't add .* to the regex (ex. https://netbird.company/* or https://netbird.company*), for some reason, the Redirect URI Error always appears as shown in the image.

image

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, thanks @Marcus1Pierce for your patience. In the last release, we updated the Redirect URI fields such that you can select Strict or Regex format. So exactly as @BeryJu 's suggested change shows, we want users to indicate that it is Regex if they use the https://netbird.company/.* format.

Here's what that field looks like now:
Screenshot 2024-11-26 at 5 13 35 PM

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tanberry I tried as suggested by @BeryJu and everything works fine.

image

Or as suggested on the website https://docs.netbird.io/selfhosted/identity-providers#authentik (all using regex) as below also works fine.

image

I don't know which is the best, but from what I tried, everything works fine.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using all regex is insecure without escaping (which is why we added the configuration options for the comparison mode)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi again @Marcus1Pierce good to hear this works. Please make the change to the file with @BeryJu 's suggestion, run the linters again (make website), and push again, and then we can merge.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tanberry I have edited it again according to the suggestion by @BeryJu.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @Marcus1Pierce , we're getting there. Can you please run make website again, and re-push? Our dependabot bumped the version of the linter we use, and this PR is failing on that check. NOTE: you might need to first run make website-install in order to update the build tools locally, then run make website. Then push to the PR again.

Let us know if any problems.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tanberry Sorry for the late update. I have tried running make website-install and then make website, but the following error occurred:

[ERROR] Error: Unable to build website for locale en.
    at tryToBuildLocale (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/build.js:78:15)
    at async /mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/build.js:34:9
    ... 4 lines matching cause stack trace ...
    at async file:///mnt/d/Visual%20Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/bin/docusaurus.mjs:44:3 {
  [cause]: Error: Docusaurus found broken links!

  Please check the pages of your site in the list below, and make sure you don't reference any path that does not exist.
  Note: it's possible to ignore broken links with the 'onBrokenLinks' Docusaurus configuration, and let the build pass.

  Exhaustive list of all broken links found:
  - Broken link on source page path = /docs/add-secure-apps/flows-stages/flow/examples/flows:
     -> linking to /blueprints/example/flows-enrollment-2-stage.yaml
     -> linking to /blueprints/example/flows-enrollment-email-verification.yaml
     -> linking to /blueprints/example/flows-login-2fa.yaml
     -> linking to /blueprints/example/flows-login-conditional-captcha.yaml
     -> linking to /blueprints/example/flows-recovery-email-verification.yaml
     -> linking to /blueprints/example/flows-unenrollment.yaml
  - Broken link on source page path = /docs/users-sources/user/invitations:
     -> linking to /blueprints/example/flows-enrollment-2-stage.yaml

      at throwError (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/logger/lib/logger.js:80:11)
      at reportBrokenLinks (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/server/brokenLinks.js:250:47)
      at handleBrokenLinks (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/server/brokenLinks.js:282:5)
      at executeBrokenLinksCheck (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/buildLocale.js:91:47)
      at /mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/buildLocale.js:70:67
      at Object.async (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/logger/lib/perfLogger.js:42:47)
      at buildLocale (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/buildLocale.js:70:31)
      at async runBuildLocaleTask (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/build.js:93:5)
      at async /mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/build.js:74:13
      at async tryToBuildLocale (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/build.js:70:9)
      at async /mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/build.js:34:9
      at async mapAsyncSequential (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/utils/lib/jsUtils.js:21:24)
      at async Command.build (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/build/build.js:33:5)
      at async Promise.all (index 0)
      at async runCLI (/mnt/d/Visual Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/lib/commands/cli.js:56:5)
      at async file:///mnt/d/Visual%20Studio/GitHub/Marcus1Pierce/authentik/website/node_modules/@docusaurus/core/bin/docusaurus.mjs:44:3
}
[INFO] Docusaurus version: 3.6.2
Node version: v18.19.1
make: *** [Makefile:250: website-build] Error 1

6. Under **Signing Key**, select an available key. By default, the authentik self-signed certificate is available.
Expand Down