GHSA-pv22-fqcj-7xwh: Github.com/inspektor gadget/inspektor gadget Inspektor Gadget Security Policies Can Vulnerability

MODERATE
CVSS 6.7
CWE-285
Published
Advisory Summary

GHSA-pv22-fqcj-7xwh is a MODERATE (CVSS 6.7) inspektor gadget security policies can vulnerability (CWE-285: Improper Authorization) affecting Github.com/inspektor gadget/inspektor gadget libraries in the Go ecosystem. The issue involves inspektor gadget security policies can be bypassed. Remediation is available by upgrading affected packages to version 0.40.0.

GHSA-pv22-fqcj-7xwh at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-pv22-fqcj-7xwh
Severity MODERATE
CVSS v3.1 Base Score 6.7
CWE Classification CWE-285: Improper Authorization
Affected Product Github.com/inspektor gadget/inspektor gadget
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 6.7

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:L/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required High (PR:H)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity Low (I:L)
Availability High (A:H)

How to Fix GHSA-pv22-fqcj-7xwh

To remediate this vulnerability, upgrade all affected Github.com/inspektor gadget/inspektor gadget dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/inspektor-gadget/inspektor-gadget fixed: 0.40.0
Upgrade github.com/inspektor-gadget/inspektor-gadget to 0.40.0
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/inspektor-gadget/inspektor-gadget

How to Check if You Are Affected

To determine whether your application is affected by GHSA-pv22-fqcj-7xwh, inspect your project dependencies for Github.com/inspektor gadget/inspektor gadget:

inspect dependencies for github.com/inspektor-gadget/inspektor-gadget

Analyze the terminal output to locate any version of Github.com/inspektor gadget/inspektor gadget in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.40.0), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-285: Improper Authorization, where the product does not perform or incorrectly performs an authorization check when an actor attempts to access a resource or perform an action. In Github.com/inspektor gadget/inspektor gadget, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

Security policies like [`allowed-gadgets`](https://inspektor-gadget.io/docs/latest/reference/restricting-gadgets), [`disallow-pulling`](https://inspektor-gadget.io/docs/latest/reference/disallow-pulling), [`verify-image`](https://inspektor-gadget.io/docs/latest/reference/verify-assets#verify-image-based-gadgets) can be bypassed by a malicious client. ### Impact Users running `ig` in daemon mode or IG on Kubernetes that rely on any of the features mentioned above are vulnerable to this issue. In order to exploit this, the client needs access to the server, like the correct TLS certificates on the `ig daemon` case or access to the cluster in the Kubernetes case. ### Patches The issue has been fixed in v0.40.0 ### Workarounds There is not known workaround to fix it.

GHSA-pv22-fqcj-7xwh Affected Github.com/inspektor gadget/inspektor gadget Versions

1 component(s)
Fixed Versions:
0.40.0
Product / Package Ecosystem Affected Versions Fixed Version
github.com/inspektor-gadget/inspektor-gadget
Go
≥ 0.31.0
< 0.40.0
0.40.0

References

Frequently Asked Questions

What is GHSA-pv22-fqcj-7xwh?
GHSA-pv22-fqcj-7xwh is a security vulnerability in Github.com/inspektor gadget/inspektor gadget involving Inspektor Gadget Security Policies Can be Bypassed under CWE-285: Improper Authorization.
Which Github.com/inspektor gadget/inspektor gadget versions are affected?
Affected versions include releases prior to 0.40.0 across affected packages: github.com/inspektor-gadget/inspektor-gadget.
What version fixes GHSA-pv22-fqcj-7xwh?
Upgrading to 0.40.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/inspektor-gadget/inspektor-gadget affected?
Yes, github.com/inspektor-gadget/inspektor-gadget is affected in releases prior to 0.40.0. Upgrade your dependency to 0.40.0 or later.
What is the CVSS score of GHSA-pv22-fqcj-7xwh?
GHSA-pv22-fqcj-7xwh has a CVSS v3.1 base score of 6.7 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:L/A:H.
What CWE is associated with GHSA-pv22-fqcj-7xwh?
GHSA-pv22-fqcj-7xwh is classified under CWE-285: Improper Authorization (The product does not perform or incorrectly performs an authorization check when an actor attempts to access a resource or perform an action.).
How can I check Go dependencies for GHSA-pv22-fqcj-7xwh?
Run the dependency tree command: 'inspect dependencies for github.com/inspektor-gadget/inspektor-gadget'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-pv22-fqcj-7xwh",
  "modified" : "2025-05-06T19:13:21Z",
  "published" : "2025-05-06T00:42:04Z",
  "aliases" : [ ],
  "summary" : "Inspektor Gadget Security Policies Can be Bypassed",
  "details" : "Security policies like [`allowed-gadgets`](https://inspektor-gadget.io/docs/latest/reference/restricting-gadgets),  [`disallow-pulling`](https://inspektor-gadget.io/docs/latest/reference/disallow-pulling), [`verify-image`](https://inspektor-gadget.io/docs/latest/reference/verify-assets#verify-image-based-gadgets) can be bypassed by a malicious client.\n\n### Impact\n\nUsers running `ig` in daemon mode or IG on Kubernetes that rely on any of the features mentioned above are vulnerable to this issue. In order to exploit this, the client needs access to the server, like the correct TLS certificates on the `ig daemon` case or access to the cluster in the Kubernetes case. \n\n### Patches\n\nThe issue has been fixed in v0.40.0\n\n### Workarounds\n\nThere is not known workaround to fix it.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:L/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/inspektor-gadget/inspektor-gadget"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0.31.0"
      }, {
        "fixed" : "0.40.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/inspektor-gadget/inspektor-gadget/security/advisories/GHSA-pv22-fqcj-7xwh"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/inspektor-gadget/inspektor-gadget/commit/c51d419964f5b6f9344fcad4faba70e2e025212b"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/inspektor-gadget/inspektor-gadget"
  }, {
    "type" : "WEB",
    "url" : "https://pkg.go.dev/vuln/GO-2025-3665"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-285" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-05-06T00:42:04Z",
    "nvd_published_at" : null
  }
}