Academy Web Attacks Skills Assesment

Hi All, could someone please give me a nudge on this please, starting
to not see the wood for the trees. I’ve found the 100 users and also found a user that I think I need to escalate privs to.

I log in as htb-student, then go to the “Change your Password” page where
I get GET request followed by a POST request. I’m pretty sure this is
where some tweakery needs to be done but I just can’t figure it out. I note
that in the POST request there is a token and when I browse to a certain
URL i can get a token for the user I need to change the password for.

Any help much appreciated

As usual, please ignore, now solved this

1 Like

im stuck at the first painel, after the loggin.
I dont know what to do
really

@onthesauce

your usual here lol

Ok i so i can enumerate, i can change every users password, but can’t seem to figure out who is admin.

Run through Burp Intruder to login and inspect packet/page size to see if that may tell me based on size difference. All looks the same.(mind you enabled intruder to follow redirections, not sure if it has anything to do with that).

I think you mentioned calendar functionality, do i need to log into each of the other 99 fellows manually and inspect?

need a nuge here

2 Likes

gosh, i swear i think finding the answers is me reaching out to @onthesauce . It was staring right at me. what the heck lol

i searched all the data for that elevated keyword, not sure what i was missing it. weird.

As long as it helps you get the flag haha! That one is like finding a needle in a haystack.

Although a trick to finding the admin might be running the burp intruder attack and using the grep-match option to search for ‘admin’ or ‘administrator’. Then it will flag whatever response contains that word. You would be guessing at the username, but it might save some headache.
-onthesauce

1 Like

Could someone help me? I’ve already get the IDOR, i changed the request to put, head and patch to reset.php and to api.php/user/**, sending it in the default format and in json and i get a “0” or a “1” in the answer, respectively, as well as “acess denied” and “missing parameters”. I would assume that the answer “1” would made the necessary changes to the admin user password, but no, the “1” is just the api answer. Any hint would be much appreciated. Thanks in advance

2 Likes

i did PE to the admin and got the vulnerable poin
but tried almost every XXE but none of them prints out

Please some help over here

Try simple XXE RCE with php://filter, you should see the flag.

Thanks mate, i have already done it. Thanks anyway, Cheers

1 Like

“Can anybody please help me? I am attempting a POST request with <!ENTITY name SYSTEM "php://filter/convert.base64-encode/resource=flag.php"> as an admin, but I cannot retrieve the flag. I’ve also tried using GET requests and other entities like details and date , but I still haven’t been successful.”

Don’t forget the “;” in your xml code

Thanks !!

Ho do i get the user with privileges ?

1 Like

Thanks for the hint. Very useful

1 - Find the api and you are gonna make something when you found it , dont forget to use HTTP Verb Tampering.
2 - Then log in by using that account you’ve changed the password.
3 - XXE and found the flag!!

Have a good dayy!!

1 Like

php://filter/convert.base64-encode/resource=/flag.php

you forgot the ‘/’

after you use the massive IDOR enum(getting all the json data). check the company tag resembling to an admin. Straight up gives you it is an admin account

i found those 100 users too, trying to figure out who’s the admin so i can reset the password

When I list all the users in the company in burpsuite I get nothing, but if I do it by changing the uid in the browser (the cookie) yes, why could it be?

Someone HELP. What I’m I missing here to get a privileged user:

PUT /api.php/user/52 HTTP/1.1
Host: 94.237.59.199:36661
User-Agent: Mozilla/5.0 (Windows NT 10.0; rv:109.0) Gecko/20100101 Firefox/115.0
Accept: /
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate, br
Referer: http://94.237.59.199:36661/settings.php
Content-Type: application/x-www-form-urlencoded
Content-Length: 110
Origin: http://94.237.59.199:36661
DNT: 1
Connection: close
Cookie: PHPSESSID=ivjukr6ogv377lqhr0no3lklod; uid=52
Sec-GPC: 1

{“uid”:“52”,
“token”:“e51a85fa-17ac-11ec-8e51-e78234eb7b0c”,“username”:“a.corrales”,“full_name”:“Amor Corrales”,“company”:“Administrator”,
“password”:“123”}