slack-messaging — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited slack-messaging (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Send and read Slack messages programmatically via the Slack Web API. Two deterministic shell scripts backed by a shared helper library:
send.sh — post a message to a channel via chat.postMessageread.sh — fetch recent messages from a channel via conversations.historyand emit them as stable JSON
Credentials are read exclusively from the SLACK_BOT_TOKEN environment variable. The token is never written to a file, never appears in script output or logs, and is never committed to the repository.
SLACK_BOT_TOKEN. Never from a file, never echoed.curl -k, no --insecure, no verify=false.curl … | sh).2>/dev/nullon calls whose result matters, no empty catch.
set -euo pipefail in every script.tool (curl/jq) or missing SLACK_BOT_TOKEN; 3 API failure (HTTP non-2xx, network error, or Slack ok:false).
From scratch.
messaging-bot).| Scope | Použití |
|---|---|
chat:write | odesílání zpráv (send.sh) |
channels:history | čtení zpráv z veřejných kanálů (read.sh) |
channels:read | přístup k metadatům veřejných kanálů |
groups:history | čtení zpráv z privátních kanálů (read.sh) |
xoxb-…) z OAuth & Permissions.Nastav token jako env var — NIKDY ho necommituj do repa, NIKDY ho nevkládej do .env souboru sledovaného Gitem:
# shell profil (mimo repo) — ~/.zshrc nebo ~/.bash_profile
export SLACK_BOT_TOKEN=xoxb-...
# CI secret (GitHub Actions):
# Settings → Secrets → New repository secret → Name: SLACK_BOT_TOKEN
# V workflow: env: SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}V každém kanálu, do kterého chceš psát nebo číst, spusť příkaz ve Slacku:
/invite @jmeno-tveho-botaV Slacku klikni na název kanálu → View channel details → posuň se dolů → Channel ID (začíná C… nebo G… u privátních). To ID předávej skriptům.
# TEXT jako argument
send.sh C0123456789 "Zpráva z terminálu"
# TEXT ze stdin (přes -)
echo "Zpráva z pipeline" | send.sh C0123456789 -
# Výstup: ts odeslané zprávy na stdout, log na stderr
# 1718870400.123456
# action=sent channel=C0123456789 ts=1718870400.123456Chybové stavy:
send.sh # exit 1: usage (chybějící argumenty)
send.sh C0123 "" # exit 1: prázdný text
unset SLACK_BOT_TOKEN
send.sh C0123 "text" # exit 2: chybějící token# Posledních 20 zpráv (výchozí)
read.sh C0123456789
# Posledních 5 zpráv
read.sh C0123456789 5
# Výstup: stabilní JSON pole seřazené od nejstarší zprávy
# [
# { "user": "U0123456789", "text": "ahoj", "ts": "1718870400.123456" },
# { "user": "U0567890123", "text": "díky", "ts": "1718870461.234567" }
# ]Chybové stavy:
read.sh # exit 1: usage (chybějící channel ID)
read.sh C0123 0 # exit 1: neplatný limit (musí být 1..200)
read.sh C0123 abc # exit 1: neplatný limit (musí být celé číslo)
unset SLACK_BOT_TOKEN
read.sh C0123 # exit 2: chybějící token[
{ "user": "U0123456789", "text": "zpráva", "ts": "1718870400.123456" },
{ "user": null, "text": "bot msg", "ts": "1718870461.234567" }
]user je null pro zprávy od botů bez user poletext je "" když Slack pole chybíts je Slack timestamp (řetězec, unikátní ID zprávy)~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.