Agent skill

Clickhouse Security Basics

by jeremylongshore in jeremylongshore/tons-of-skills-marketplace

Secure ClickHouse with user management, network restrictions, TLS, and audit logging.

MITAuto-check passedDatabases

Install Clickhouse Security Basics

skills CLI
$ npx skills add jeremylongshore/tons-of-skills-marketplace --skill clickhouse-security-basics -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install jeremylongshore/tons-of-skills-marketplace clickhouse-security-basics --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/.curated/clickhouse-security-basics .claude/skills/clickhouse-security-basics && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
clickhouse-security-basics
GitHub stars
2.8k
Token cost
~1.3k tokens
SKILL.md length
480 words
Files
3 (incl. references)
Skills in repo
3,342
Repo updated
First seen
Licence
MIT

At a glance

Secure ClickHouse with user management, network restrictions, TLS, and audit logging.

  • Works in 7 steps: Create restricted users (SQL-based RBAC) → Use roles for permission groups → Row-level security → …
  • Hardening a ClickHouse deployment
  • SKILL.md covers Overview, Prerequisites, Instructions and Output, plus 4 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Clickhouse Security Basics is an agent skill from jeremylongshore/tons-of-skills-marketplace. Secure ClickHouse with user management, network restrictions, TLS, and audit logging. Use when hardening a ClickHouse deployment, creating restricted users, enforcing multi-tenant row isolation, or configuring network-level access controls. Trigger with "clickhouse security", "clickhouse user management", "secure clickhouse", "clickhouse TLS", "clickhouse access control", "clickhouse firewall".

Its SKILL.md is about 1.3k tokens, which your agent loads only when the skill is triggered. The skill folder holds 3 other files, including reference files (for example `references/examples.md` and `references/implementation.md`). Compatibility notes: Designed for Claude Code

It sits in Databases, covering Data warehousing, Authorization and RBAC and Multi-tenancy. It works with ClickHouse and SQL. The repository describes itself as: Model-agnostic agent-skills platform with a harness-free canonical layer, verified adapters, and the ccpi package manager. Explore at tonsofskills.com. The licence is MIT.

When your agent uses it

  • Hardening a ClickHouse deployment
  • Creating restricted users
  • Enforcing multi-tenant row isolation
  • Configuring network-level access controls

Example prompts

  • “clickhouse security”
  • “clickhouse user management”
  • “secure clickhouse”
  • “/clickhouse-security-basics”

Requirements

  • Compatibility (from SKILL.md): Designed for Claude Code
  • Pre-approved tools (allowed-tools): Read

Workflow steps

7 steps, taken from the step headings in SKILL.md.

  1. Create restricted users (SQL-based RBAC)
  2. Use roles for permission groups
  3. Row-level security
  4. Network security
  5. TLS configuration
  6. Audit logging
  7. Application connection security

What it can do on your machine

Read from SKILL.md and the folder at commit cfae287. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Read

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are sql).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • clickhouse.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

  • Compatibility

    Designed for Claude Code

    From compatibility in the SKILL.md frontmatter.

Context cost

Clickhouse Security Basics loads about 1.3k tokens when it runs, and up to ~3.2k if it reads all its reference files. Until then it costs about 106 tokens; SKILL.md has 480 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~106
When it runs · the whole SKILL.md, loaded when a task matches
~1.3k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~3.2k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from jeremylongshore/tons-of-skills-marketplace at commit cfae287, republished under its MIT licence (© jeremylongshore). 480 words, ~1,318 tokens.

Download SKILL.mdSave it as .claude/skills/clickhouse-security-basics/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.
name
clickhouse-security-basics
description
Secure ClickHouse with user management, network restrictions, TLS, and audit logging. Use when hardening a ClickHouse deployment, creating restricted users, enforcing multi-tenant row isolation, or configuring network-level access controls. Trigger with "clickhouse security", "clickhouse user management", "secure clickhouse", "clickhouse TLS", "clickhouse access control", "clickhouse firewall".
allowed-tools
Read
compatibility
Designed for Claude Code
version
1.7.0
license
MIT
author
Jeremy Longshore <jeremy@intentsolutions.io>
tags
saas, database, analytics, clickhouse, olap

ClickHouse Security Basics

Overview

Secure a ClickHouse deployment with SQL-based user management, network restrictions, TLS encryption, and query audit logging. This skill walks the seven core hardening steps at a high level; the full copy-pasteable SQL, XML, and connection code lives in references/implementation.md.

Prerequisites

  • ClickHouse admin access
  • CLICKHOUSE_DEFAULT_ACCESS_MANAGEMENT=1 for SQL-based user management
  • For self-hosted: access to server config files (config.xml, users.xml)

Instructions

Work through the seven steps in order. Each summary below gives the essential first move; drill into references/implementation.md for the complete, copy-ready code for every step.

Step 1: Create restricted users (SQL-based RBAC)

Create least-privilege users and REVOKE destructive verbs from application users.

sql
CREATE USER analyst
    IDENTIFIED WITH sha256_password BY 'strong-password-here'
    DEFAULT DATABASE analytics
    SETTINGS readonly = 1, max_execution_time = 60;
GRANT SELECT ON analytics.* TO analyst;
Step 2: Use roles for permission groups

Define data_reader / data_writer / schema_admin roles once, then grant roles to users instead of hand-managing per-user grants. Verify with SHOW GRANTS.

Step 3: Row-level security

Isolate multi-tenant data with CREATE ROW POLICY, mapping each user to a tenant via a custom setting (getSetting('custom_tenant_id')).

Step 4: Network security

Restrict connection sources — SQL HOST IP '10.0.0.0/8' (22.6+), users.xml per-user network allowlists for self-hosted, or the ClickHouse Cloud IP Access List.

Step 5: TLS configuration

Enable the HTTPS port (8443) in config.xml with a server cert, private key, and strict verification mode.

Step 6: Audit logging

Query system.query_log (on by default) to see who ran what, and filter exception_code = 516 to hunt failed logins.

Step 7: Application connection security

Connect over https://…:8443 with a minimal-privilege user (never default) and a password sourced from a secret manager — see the client snippet in references/examples.md.

Run through the Security Checklist in references/implementation.md before declaring a deployment hardened.

Show full SKILL.md (218 more words)Show less

Output

Applying this skill produces:

  • Restricted user and role definitions — least-privilege CREATE USER / CREATE ROLE / GRANT / REVOKE statements ready to run against your cluster.
  • Row policies for multi-tenant isolation.
  • config.xml / users.xml fragments for network allowlists and TLS.
  • Audit queries against system.query_log for access review and failed-login detection.
  • A completed security checklist confirming default credentials, TLS, IP allowlists, logging, and secret handling are all in place.

Error Handling

ErrorCauseSolution
Authentication failed (516)Wrong password or userVerify credentials
ACCESS_DENIED (497)Missing GRANTSHOW GRANTS FOR user to diagnose
READONLY (164)User in readonly modeGrant write if needed
Not enough privilegesRow policy blockingCheck SHOW ROW POLICIES

Examples

Four worked, end-to-end scenarios live in references/examples.md:

  1. Stand up a least-privilege analyst — read-only BI user capped on memory and time.
  2. Multi-tenant isolation with a row policy — each tenant sees only its own rows.
  3. Lock the app user to the VPC and require TLS — SQL HOST IP + TLS client.
  4. Audit the last hour and hunt failed logins — system.query_log queries.

Minimal first example — a read-only analyst:

sql
CREATE USER analyst
    IDENTIFIED WITH sha256_password BY 'strong-password-here'
    DEFAULT DATABASE analytics SETTINGS readonly = 1;
GRANT SELECT ON analytics.* TO analyst;

Resources

Next Steps

For production deployment, harden the wider cluster with the clickhouse-prod-checklist skill, which covers backups, replication, resource quotas, and monitoring beyond the security surface covered here.

© jeremylongshore, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 2 other files (references) in skills/.curated/clickhouse-security-basics of jeremylongshore/tons-of-skills-marketplace.

  • SKILL.md
  • references/examples.md
  • references/implementation.md

Open the folder on GitHubat commit cfae287

Compare with similar skills

Clickhouse Security Basics next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Clickhouse Security Basics compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Clickhouse Security Basics this skilljeremylongshore/tons-of-skills-marketplace2.8k—~1.3kAutomated safety check: PassMIT
Clickhouse Logs Queriessupabase/supabase111k—~2.4kAutomated safety check: PassApache-2.0
Chdb SQLvemetric/vemetric3951 repos~1.2kAutomated safety check: PassApache-2.0
BisectClickHouse/ClickHouse50k—~1.4kAutomated safety check: PassApache-2.0
Clickhouse System QueriesFrankChen021/datastoria327—~731Automated safety check: PassCustom licence
Webapp Buildersidequery/sidemantic129—~5.5kAutomated safety check: PassAGPL-3.0

Similar skills

  • Clickhouse Logs Queries

    supabase/supabase

    Official

    Write, review, and migrate Supabase logs queries against the ClickHouse-backed logs table (the logs.all.otel analytics endpoint).

    111k GitHub stars~2.4k tokensUpdated yesterday
    DatabasesAuto-check passed
  • Chdb SQL

    vemetric/vemetric

    A skill your agent uses when the user wants to run SQL — especially analytical SQL — on local files (parquet/csv/json), URLs, S3 paths, or remote databases (Postgres, MySQL, MongoDB, ClickHouse…

    395 GitHub starsUsed in 1 repo~1.2k tokens
    DatabasesAuto-check passed
  • Bisect

    ClickHouse/ClickHouse

    Bisect a ClickHouse regression using pre-built master binaries from CI.

    50k GitHub stars~1.4k tokensUpdated today
    DatabasesAuto-check passed
  • Clickhouse System Queries

    FrankChen021/datastoria

    Query ClickHouse system tables to inspect query logs, monitor cluster health, check replication status, and analyze slow queries.

    327 GitHub stars~731 tokensUpdated 2 mo ago
    DatabasesAuto-check passed
  • Webapp Builder

    sidequery/sidemantic

    Build interactive analytics webapps, demos, dashboards, or embedded app surfaces from Sidemantic semantic models using copyable component primitives and deterministic query inspection.

    129 GitHub stars~5.5k tokensUpdated 4 days ago
    DatabasesAuto-check passed
  • Cpu Profile

    ClickHouse/ClickHouse

    Profile a ClickHouse query using the sampling query profiler and system.tracelog.

    50k GitHub stars~1.9k tokensUpdated today
    DatabasesAuto-check: notes

More from jeremylongshore/tons-of-skills-marketplace

All 3,342 skills in this repo
  • Performing Security Code Review

    jeremylongshore/tons-of-skills-marketplace

    Execute this skill enables AI assistant to conduct a security-focused code review using the security-agent plugin.

    2.8k GitHub starsUsed in 2 repos~1.3k tokens
    Auto-check: notes
  • Adapting Transfer Learning Models

    jeremylongshore/tons-of-skills-marketplace

    Build this skill automates the adaptation of pre-trained machine learning models using transfer learning techniques.

    2.8k GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Agent Context Loader

    jeremylongshore/tons-of-skills-marketplace

    Execute proactive auto-loading: automatically detects and loads agents.md files.

    2.8k GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Aggregating Performance Metrics

    jeremylongshore/tons-of-skills-marketplace

    Aggregate and centralize performance metrics from applications, systems, databases, caches, and services.

    2.8k GitHub stars~1.2k tokensUpdated today
    Auto-check passed
  • Analyzing Capacity Planning

    jeremylongshore/tons-of-skills-marketplace

    Execute this skill enables AI assistant to analyze capacity requirements and plan for future growth.

    2.8k GitHub stars~947 tokensUpdated today
    Auto-check passed
  • Analyzing Database Indexes

    jeremylongshore/tons-of-skills-marketplace

    Process use when you need to work with database indexing. An agent skill from jeremylongshore/tons-of-skills-marketplace.

    2.8k GitHub stars~2k tokensUpdated today
    Auto-check passed

Works with

Questions about Clickhouse Security Basics

What does Clickhouse Security Basics do?

Secure ClickHouse with user management, network restrictions, TLS, and audit logging. Clickhouse Security Basics is an agent skill from jeremylongshore/tons-of-skills-marketplace. Secure ClickHouse with user management, network restrictions, TLS, and audit logging.

When should I use Clickhouse Security Basics?

Clickhouse Security Basics fits situations like: hardening a ClickHouse deployment; creating restricted users; enforcing multi-tenant row isolation; configuring network-level access controls.

How do I install Clickhouse Security Basics in Claude Code?

Run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill clickhouse-security-basics -a claude-code`. Or copy the skill folder (skills/.curated/clickhouse-security-basics in jeremylongshore/tons-of-skills-marketplace) into .claude/skills/clickhouse-security-basics in your project. Claude Code loads it when a task matches its description.

How do I install Clickhouse Security Basics in Codex?

Run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill clickhouse-security-basics -a codex`. Or copy the skill folder (skills/.curated/clickhouse-security-basics in jeremylongshore/tons-of-skills-marketplace) into .agents/skills/clickhouse-security-basics in your project. Codex loads it when a task matches its description.

Can I use Clickhouse Security Basics in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill clickhouse-security-basics -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/clickhouse-security-basics, .gemini/skills/clickhouse-security-basics, .github/skills/clickhouse-security-basics and .opencode/skills/clickhouse-security-basics in your project.

What does Clickhouse Security Basics need to run?

SKILL.md names no scripts, command-line tools or credentials: Clickhouse Security Basics is instructions for the agent only. Its frontmatter pre-approves these tools: Read. Compatibility (from SKILL.md): Designed for Claude Code.

Does Clickhouse Security Basics access the network?

SKILL.md names 1 domain. As links in the text: clickhouse.com. This is read from the text; nothing was executed.

Is Clickhouse Security Basics safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Clickhouse Security Basics use?

Clickhouse Security Basics is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Clickhouse Security Basics use?

About 1.3k tokens (SKILL.md is roughly 5.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 1.9k tokens, read only when the agent opens those files.

What are the alternatives to Clickhouse Security Basics?

Skills that share tags, products or a category with Clickhouse Security Basics: Clickhouse Logs Queries (supabase/supabase, 111k stars), Chdb SQL (vemetric/vemetric, 395 stars), Bisect (ClickHouse/ClickHouse, 50k stars) and Clickhouse System Queries (FrankChen021/datastoria, 327 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Clickhouse Security Basics?

jeremylongshore (a GitHub user) maintains it in jeremylongshore/tons-of-skills-marketplace, which has 2,827 GitHub stars. The repository holds 3,342 skills in this directory. The repository was last updated on October 10, 2026.

Source: jeremylongshore/tons-of-skills-marketplace on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.