Exposed Zotero API Key Allows Unauthorized Write Access to Group Library

Disclosed by
Sidhanta_Palei
Summary by Sidhanta_Palei

Summary: Exposed API Key in Public Repository Leading to Unauthorized Zotero Group Library Access

Description

An exposed Zotero API key was identified within a publicly accessible file in the repository:

GES-DISC Reference Management System.

This API key grants unauthorized read and write access to a Zotero group library, potentially exposing the library to risks such as data corruption, unauthorized modifications, and potential data deletion.

Impact

The exposed API key allows an attacker to:

  1. Retrieve sensitive bibliographic data: Titles, DOIs, tags, and other metadata from the Zotero library.
  2. Modify library content: Add, update, or delete tags and notes without authorization.
  3. Potential data corruption: Unauthorized changes, such as adding arbitrary notes or tags, could compromise data integrity.

Reproduction Steps

  1. Access the public repository:

    The file contains a Zotero API key embedded within its code.

  2. Retrieve library items:
    By using a Zotero library client or direct API call, bibliographic data (e.g., titles, DOIs, tags) can be fetched from the library without authentication.

  3. Write unauthorized content:
    The key also allows creating or modifying library content, such as adding notes or tags to items.

Recommendations

  1. Remove the exposed API key from the repository immediately.
  2. Regenerate the API key in Zotero to invalidate the compromised one.
  3. Adopt secure coding practices:
    • Use environment variables or secure vaults for storing sensitive credentials.
    • Regularly scan repositories for secrets using tools like GitGuardian or TruffleHog.
  4. Audit the Zotero library for unauthorized changes, such as unrecognized notes, tags, or modifications.
  5. Educate developers on the risks of hardcoding sensitive credentials in public or private repositories.

By addressing this issue promptly, the risk of data loss, unauthorized modifications, or misuse of the Zotero library can be mitigated.

Activity