GCP - Serviceusage Privesc

Support HackTricks

serviceusage

다음 권한은 API 키를 생성하고 훔치는 데 유용합니다. 문서에서 다음과 같이 설명합니다: API 키는 주체 없이 애플리케이션을 식별하는 간단한 암호화된 문자열입니다. 이들은 공개 데이터에 익명으로 접근하는 데 유용하며, 쿼터청구를 위해 API 요청을 프로젝트와 연관시키는 데 사용됩니다.

따라서 API 키를 사용하면 해당 회사가 API 사용에 대한 비용을 지불하게 할 수 있지만, 권한 상승은 할 수 없습니다.

다른 권한 및 API 키 생성 방법을 배우려면 다음을 확인하세요:

GCP - Apikeys Privesc

serviceusage.apiKeys.create

문서화되지 않은 API가 발견되어 API 키를 생성하는 데 사용할 수 있습니다:

curl -XPOST "https://apikeys.clients6.google.com/v1/projects/<project-uniq-name>/apiKeys?access_token=$(gcloud auth print-access-token)"

serviceusage.apiKeys.list

이미 생성된 API 키를 나열하기 위한 또 다른 문서화되지 않은 API가 발견되었습니다(응답에 API 키가 나타납니다):

curl "https://apikeys.clients6.google.com/v1/projects/<project-uniq-name>/apiKeys?access_token=$(gcloud auth print-access-token)"

serviceusage.services.enable , serviceusage.services.use

이 권한을 가진 공격자는 프로젝트에서 새로운 서비스를 활성화하고 사용할 수 있습니다. 이는 공격자가 admin 또는 cloudidentity와 같은 서비스를 활성화하여 Workspace 정보를 접근하려 하거나, 흥미로운 데이터에 접근하기 위해 다른 서비스를 사용할 수 있게 할 수 있습니다.

References

Support HackTricks and get benefits!

Do you work in a cybersecurity company? Do you want to see your company advertised in HackTricks? or do you want to have access the latest version of the PEASS or download HackTricks in PDF? Check the SUBSCRIPTION PLANS!

Discover The PEASS Family, our collection of exclusive NFTs

Get the official PEASS & HackTricks swag

Join the 💬 Discord group or the telegram group or follow me on Twitter 🐦@carlospolopm.

Share your hacking tricks submitting PRs to the hacktricks github repo****

.

Last updated