🇰🇷 한글 설명
pg_partman 5.5.0 미만 버전에서 run_maintenance() 함수가 예외 발생 시 루프를 즉시 종료하는 취약점이 있습니다. partman_user 권한을 가진 사용자가 의도적으로 오류를 유발하는 데이터를 삽입하면, 이후의 모든 파티션 유지관리 작업이 중단되어 데이터베이스 전체의 자동 파티션 관리가 불가능해집니다.
💡 쉬운 설명
데이터베이스 관리 도구에 일부러 오류가 나는 데이터를 넣어 관리 시스템을 멈추게 만드는 공격입니다. 이로 인해 데이터베이스의 자동 정리 기능이 작동하지 않아 시스템 관리에 큰 차질이 생길 수 있습니다.
🇺🇸 원문 (English)
pg_partman is a PostgreSQL extension that manages partitioned tables by time or ID. Prior to 5.5.0, run_maintenance() handles exceptions outside the loop that processes rows from part_config, so an exception for one partition set immediately terminates the loop and skips every later set. A role with partman_user access can insert or update a row that reliably fails and assign it a low maintenance_order value so it is processed before legitimate rows. Repeated maintenance ticks then abort before legitimate partition sets are maintained, causing database-wide loss of automated partition maintenance. This issue is fixed in version 5.5.0.
📍 영향받는 시스템
pg_partman 5.5.0 미만 버전
⚔️ 공격 벡터
partman_user 권한을 가진 사용자가 오류를 유발하는 행을 낮은 maintenance_order로 삽입하여 유지관리 루프를 중단시킴
🛡️ 대응 방법
pg_partman를 5.5.0 이상 버전으로 업데이트
🔧 검증 코드
출력된 버전 번호가 5.5.0 미만이면 취약한 상태입니다.
psql -c "SELECT extversion FROM pg_extension WHERE extname = 'pg_partman';"