forked from mtusi2026/mtusi2026lab4
Record level 3 evidence and fill in the report
Evidence comes from the stand started from an empty state and from a fresh clone: the public smoke, the contract checks, lint and 325 own tests, the storage layout with an out-of-API comparison of a stored object against its metadata, failover of each replica under writes, the upload failover scenario, persistence with StartedAt of every service including S3, the S3 outage scenario and 22 S3 privacy and bootstrap checks. The storage evidence script now covers the attachment tables and the S3 secrets. REPORT.md follows the lab 4 template: launch from a clean clone, architecture with the source of truth for each fact, the write order between PostgreSQL and S3 and what each failure leaves behind, where each upload limit applies, roles and services, the .env.example mapping, grade 3 rows and the grade 3 failure table. The design notes the botocore Expect header that hung uploads behind the port proxy. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
24f9d6195b
commit
db901d6401
@@ -3,12 +3,12 @@ set -eu
|
||||
cd "$(dirname "$0")/.."
|
||||
psql() { docker compose exec -T postgres psql -U messenger -d messenger -c "$1"; }
|
||||
header() { echo "date: $(date -u +%FT%TZ) commit: $(git rev-parse --short HEAD)"; }
|
||||
counts="SELECT (SELECT count(*) FROM users) users, (SELECT count(*) FROM sessions) sessions, (SELECT count(*) FROM chats) chats, (SELECT count(*) FROM chat_members) members, (SELECT count(*) FROM messages) messages, (SELECT count(*) FROM idempotency_keys) keys, (SELECT count(*) FROM schema_migrations) versions"
|
||||
counts="SELECT (SELECT count(*) FROM users) users, (SELECT count(*) FROM sessions) sessions, (SELECT count(*) FROM chats) chats, (SELECT count(*) FROM chat_members) members, (SELECT count(*) FROM messages) messages, (SELECT count(*) FROM idempotency_keys) keys, (SELECT count(*) FROM attachments) attachments, (SELECT count(*) FROM message_attachments) links, (SELECT count(*) FROM schema_migrations) versions"
|
||||
kdf="SELECT substring(password_hash from '^[$]argon2id[$]v=[0-9]+[$]m=[0-9]+,t=[0-9]+,p=[0-9]+[$]') AS kdf_prefix, count(*) AS users, min(length(password_hash)) AS hash_length FROM users GROUP BY 1"
|
||||
tokens="SELECT octet_length(token_hash) AS stored_bytes, count(*) AS sessions FROM sessions GROUP BY 1"
|
||||
{
|
||||
header
|
||||
for table in users sessions chats chat_members messages idempotency_keys schema_migrations; do
|
||||
for table in users sessions chats chat_members messages idempotency_keys attachments message_attachments schema_migrations; do
|
||||
echo "\$ psql -c '\\d+ $table'"
|
||||
psql "\\d+ $table"
|
||||
done
|
||||
@@ -36,8 +36,8 @@ tokens="SELECT octet_length(token_hash) AS stored_bytes, count(*) AS sessions FR
|
||||
echo "\$ git ls-files secrets .env backups volumes"
|
||||
git ls-files secrets .env backups volumes
|
||||
echo "(пусто: секретов, .env, дампов и volumes в Git нет)"
|
||||
echo "\$ git check-ignore -v secrets/database_url secrets/postgres_password .env backups/"
|
||||
git check-ignore -v secrets/database_url secrets/postgres_password .env backups/
|
||||
echo "\$ git check-ignore -v secrets/database_url secrets/postgres_password secrets/s3_root_password secrets/s3_secret_access_key .env backups/"
|
||||
git check-ignore -v secrets/database_url secrets/postgres_password secrets/s3_root_password secrets/s3_secret_access_key .env backups/
|
||||
echo "\$ docker volume ls --filter name=mtusi2026lab4"
|
||||
docker volume ls --filter name=mtusi2026lab4
|
||||
} > evidence/secrets.txt
|
||||
|
||||
Reference in New Issue
Block a user