Skip to content

Commit

Permalink
January wk 3/4 docs maintenance (DefectDojo#11632)
Browse files Browse the repository at this point in the history
* exclude old notifications from search

* sso page updates

* clarify intended docs use

* exclude old notifications from search

* sso page updates

* clarify intended docs use

* rm duplicate api article

---------

Co-authored-by: Paul Osinski <[email protected]>
  • Loading branch information
2 people authored and Ricardo Underwood committed Feb 2, 2025
1 parent e0de953 commit 4557fb8
Show file tree
Hide file tree
Showing 13 changed files with 645 additions and 237 deletions.
Binary file not shown.
Binary file added docs/assets/images/pro_login_settings.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/images/sso_betaui_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
Binary file added docs/assets/images/sso_oauth_beta_ui.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
2 changes: 2 additions & 0 deletions docs/content/en/about_defectdojo/about_docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ cascade:

![image](images/dashboard.png)

<span style="background-color:rgba(242, 86, 29, 0.3)">DefectDojo Inc. and open-source contributors maintain this documentation to support both the Community and Pro editions of DefectDojo.</span>

### What is DefectDojo?

DefectDojo is a DevSecOps platform. DefectDojo streamlines DevSecOps by serving as an aggregator and single pane of glass for your security tools. DefectDojo has smart features to enhance and tune the results from your security tools including the ability to merge findings, remember false positives, and distill duplicates. DefectDojo also integrates with JIRA, provides metrics / reports, and can also be used for traditional pen test management.
Expand Down
14 changes: 7 additions & 7 deletions docs/content/en/api/api-v2-docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ weight: 2
DefectDojo\'s API is created using [Django Rest
Framework](http://www.django-rest-framework.org/). The documentation of
each endpoint is available within each DefectDojo installation at
[`/api/v2/doc/`](https://demo.defectdojo.org/api/v2/) and can be accessed by choosing the API v2
[`/api/v2/oa3/swagger-ui`](https://demo.defectdojo.org/api/v2/oa3/swagger-ui/)) and can be accessed by choosing the API v2
Docs link on the user drop down menu in the header.

![image](images/api_v2_1.png)
![image](../../images/api_v2_1.png)

The documentation is generated using [drf-spectacular](https://drf-spectacular.readthedocs.io/) at [`/api/v2/oa3/swagger-ui/`](https://demo.defectdojo.org/api/v2/oa3/swagger-ui/), and is
interactive. On the top of API v2 docs is a link that generates an OpenAPI v3 spec.
Expand All @@ -20,12 +20,12 @@ To interact with the documentation, a valid Authorization header value
is needed. Visit the `/api/key-v2` view to generate your
API Key (`Token <api_key>`) and copy the header value provided.

![image](images/api_v2_2.png)
![image](../../images/api_v2_2.png)

Each section allows you to make calls to the API and view the Request
URL, Response Body, Response Code and Response Headers.

![image](images/api_v2_3.png)
![image](../../images/api_v2_3.png)

If you're logged in to the Defect Dojo web UI, you do not need to provide the authorization token.

Expand All @@ -42,7 +42,7 @@ For example: :

### Alternative authentication method

If you use [an alternative authentication method](../social-authentication/) for users, you may want to disable DefectDojo API tokens because it could bypass your authentication concept. \
If you use [an alternative authentication method](../archived_docs/integrations/social-authentication/) for users, you may want to disable DefectDojo API tokens because it could bypass your authentication concept. \
Using of DefectDojo API tokens can be disabled by specifying the environment variable `DD_API_TOKENS_ENABLED` to `False`.
Or only `api/v2/api-token-auth/` endpoint can be disabled by setting `DD_API_TOKEN_AUTH_ENDPOINT_ENABLED` to `False`.

Expand Down Expand Up @@ -125,7 +125,7 @@ The json object result is: :
{{< /highlight >}}

See [Django Rest Framework\'s documentation on interacting with an
API](http://www.django-rest-framework.org/topics/api-clients/) for
API](https://www.django-rest-framework.org/) for
additional examples and tips.

## Manually calling the API
Expand Down Expand Up @@ -178,4 +178,4 @@ Example for importing a scan result:
| [.Net/C# library](https://www.nuget.org/packages/DefectDojo.Api/) | working (2021-06-08) | |
| [dd-import](https://github.com/MaibornWolff/dd-import) | working (2021-08-24) | dd-import is not directly an API wrapper. It offers some convenience functions to make it easier to import findings and language data from CI/CD pipelines. |

Some of the api wrappers contain quite a bit of logic to ease scanning and importing in CI/CD environments. We are in the process of simplifying this by making the DefectDojo API smarter (so api wrappers / script can be dumber).
Some of the api wrappers contain quite a bit of logic to ease scanning and importing in CI/CD environments. We are in the process of simplifying this by making the DefectDojo API smarter (so api wrappers / script can be dumber).
682 changes: 633 additions & 49 deletions docs/content/en/customize_dojo/user_management/configure_sso.md

Large diffs are not rendered by default.

181 changes: 0 additions & 181 deletions docs/content/en/open_source/api-v2-docs.md

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ title: "Authentication via OAuth2/SAML2"
description: "OAuth2/SAML2 let users authenticate against enterprise directories."
draft: false
weight: 3
exclude_search: true
---

## Auth0
Expand Down
1 change: 1 addition & 0 deletions docs/content/en/open_source/archived_docs/notifications.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ title: "Notifications"
description: "DefectDojo can inform you about changes on different channels."
draft: false
weight: 6
exclude_search: true
---

## Notifications
Expand Down
1 change: 1 addition & 0 deletions docs/layouts/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<div class="col-lg-12 text-center">
<h1>{{ .Title }}</h1>
</div>
<div class="row justify-content-center text-center">Official documentation for DefectDojo Pro and Open-Source editions,<br>maintained by DefectDojo Inc. and the Open-Source community.</div>
<div class="col-lg-9 col-xl-8 text-center">
<p class="lead">{{ .Params.lead | safeHTML }}</p>
<a class="btn btn-primary btn-cta rounded-pill btn-lg my-3" href="/en/{{ if site.Params.doks.docsVersioning }}{{ site.Params.doks.docsVersion }}/{{ end }}about_defectdojo/about_docs/" role="button" style="--bs-btn-bg: #f2561d; --bs-btn-hover-bg: #f28d1d;">Open The Docs</a>
Expand Down

0 comments on commit 4557fb8

Please sign in to comment.