glean-security-basics

Featured

Token security: Indexing tokens have write access -- never expose in frontend. Trigger: "glean security basics", "security-basics".

AI & Automation 2,266 stars 315 forks Updated today MIT

Install

View on GitHub

Quality Score: 99/100

Stars 20%
100
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Glean Security Basics ## Overview Glean indexes and searches across an enterprise's entire knowledge base — Confluence, Google Drive, Slack, GitHub, and dozens more connectors. Security concerns center on indexing token management (write-access tokens that can push content into the search index), client token scoping (user-level search permissions), and document-level access controls. A leaked indexing token allows injecting arbitrary content into enterprise search results. ## API Key Management ```typescript function createGleanClient(tokenType: "indexing" | "client"): { token: string; baseUrl: string } { const token = tokenType === "indexing" ? process.env.GLEAN_INDEXING_TOKEN : process.env.GLEAN_CLIENT_TOKEN; if (!token) { throw new Error(`Missing GLEAN_${tokenType.toUpperCase()}_TOKEN — store in secrets manager`); } // Indexing tokens have WRITE access — never expose in frontend code if (tokenType === "indexing") { console.log("WARNING: Indexing token loaded — backend use only"); } return { token, baseUrl: `https://${process.env.GLEAN_INSTANCE}.glean.com/api` }; } ``` ## Webhook Signature Verification ```typescript import crypto from "crypto"; import { Request, Response, NextFunction } from "express"; function verifyGleanWebhook(req: Request, res: Response, next: NextFunction): void { const signature = req.headers["x-glean-signature"] as string; const secret = process.env.GLEAN_WEBHOOK_SECRET!; const expected = crypto.createHmac("...

Details

Author
jeremylongshore
Repository
jeremylongshore/claude-code-plugins-plus-skills
Created
7 months ago
Last Updated
today
Language
Python
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category