Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/pages/feature-guides/_meta.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,7 @@ export default {
'several-assets-and-artifacts-to-devguard-monorepos': {
title: 'Mapping Several Assets and Artifacts (e.g., Monorepos)',
},
'organization-wide-search': {
title: 'Searching specific Packages in Organization',
},
}
84 changes: 84 additions & 0 deletions src/pages/feature-guides/organization-wide-search.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
# Searching for Specific Packages in Your Organization

## Overview

DevGuard now allows **Admin and Owner roles** to search for specific packages across all repositories within an organization. This feature is designed to help you quickly identify where a particular package (e.g., `xz-util`) is used, including its version and the artifacts it appears in. This is especially useful for security audits, compliance checks, or dependency management.

**Location:** The feature is accessible from the **Organization Page**, in the **Tabs Area**, next to Settings. Only users with the correct permissions will see this tab.

---

## How It Works

### Search Process
- The search recursively scans each repository in your organization using a **LIKE statement** to match the package name.
- Only **direct (first-party) dependencies** are returned in the results.

### API Endpoint
A new API endpoint is available for programmatic access:

```
GET /api/v1/organizations/{organizationName}/dependency-components?search={packageName}
```

#### Response Fields
Field | Description |
|------------------------|--------------------------------------|
| `componentDependencyId`| Unique identifier for the dependency |
| `dependencyPurl` | Package URL (purl) of the dependency |
| `organizationId` | ID of the organization |
| `organizationName` | Name of the organization |
| `projectId` | ID of the project |
| `projectName` | Name of the project |
| `projectSlug` | Slug of the project |
| `assetId` | ID of the asset |
| `assetName` | Name of the asset |
| `assetSlug` | Slug of the asset |
| `assetVersionName` | Version name of the asset |
| `componentPurl` | Package URL (purl) of the component |
| `componentVersion` | Version of the component |
| `artifactName` | Name of the artifact |
| `artifactAssetVersion` | Version of the artifact |

---

## Use Cases

- **Security Audits:** Quickly check if a vulnerable package is used anywhere in your organization.
- **Compliance:** Verify that only approved package versions are in use.
- **Dependency Management:** Identify and update outdated or risky dependencies across multiple projects.

---

## Permissions

- Only users with **Admin** or **Owner** roles can access this feature and the associated API endpoint.

---

## Example Workflow

1. Navigate to your **Organization Page** in DevGuard.
2. Click on the new **Package Search** tab.
3. Enter the package name (e.g., `xz-util`) in the search bar.
4. View the results, which include:
- Repositories where the package is found
- Version of the package in each repository
- Artifacts containing the package

---

## Integration

This feature integrates seamlessly with DevGuard’s existing SBOM and dependency management tools, providing a unified view of your organization’s software supply chain.

---

## Notes

- The search is case-insensitive and supports partial matches.
- Only direct dependencies are included in the results.

---

**Need help or have feedback?** [Contact us](mailto:support@devguard.org) or visit our [GitHub repository](https://github.com/l3montree-dev/devguard)