Author Topic: http basic access authentication  (Read 672 times)

0 Members and 6 Guests are viewing this topic.

Offline arkancity

  • NULL
  • Posts: 2
  • Cookies: 0
    • View Profile
http basic access authentication
« on: November 29, 2014, 08:26:47 pm »
Hey guys (and girls lol)! :P

There is a webpage using only http basic access authentication for some files. I know the username, the name of the files and the exact path.   

Just a fictive example: http://fictive.site.com/u/JhonnyR/Mathtest/test1.JPG

User JhonnyR has the Mathtest folder. The Mathtest folder is protected by the BAA.
I'd like to reach the files by bypassing the authentication process or if there is a chance with a password (without the option of bruteforce).

I'd like to ask you for possible solutions or advice for learning reasons. How would you start to solve it?
Maybe it's easy for most of the users here but I'm a newbie.  :P


 
 

Offline Kulverstukas

  • Administrator
  • Zeus
  • *
  • Posts: 6627
  • Cookies: 542
  • Fascist dictator
    • View Profile
    • My blog
Re: http basic access authentication
« Reply #1 on: November 29, 2014, 09:18:04 pm »
Only possible way is to break into the server, or try to bruteforce your way in (if you're feeling lucky...).

Offline madf0x

  • Knight
  • **
  • Posts: 172
  • Cookies: 50
    • View Profile
Re: http basic access authentication
« Reply #2 on: November 29, 2014, 11:37:23 pm »
one of the main uses of http basic auth is restricting access to files, so knowing the file path and username doesn't help. As Kulverstukas stated this leaves you with the two options of breaking in, or bruteforcing the password.

Since you don't want to bruteforce, your next steps would be to do a little bit of recon. Theres the chance that there may be a known weakness in the http server that can bypass the basic auth. May be able to use some sort of LFI or abuse bad configuration to obtain the .htpasswd, or perhaps find a way to overwrite that file or .htaccess.

And of course if you manage to root the server than getting the file in question is trivial ;)

Baring brute-force your available options are very broad and situational to the target in question.

Offline 2d8

  • /dev/null
  • *
  • Posts: 17
  • Cookies: 1
    • View Profile
Re: http basic access authentication
« Reply #3 on: November 30, 2014, 01:52:11 pm »

That is just my 2 cents.If there is no SSL and you can wiretap connection between server and client it is easy to retrieve user's credentials.
In each HTTP packet of authenticated user there will be HTTP-header like Authorization: Basic YWRtaW46YWRtaW4=
And simple base64 decoding will give you user:password pair.

Offline arkancity

  • NULL
  • Posts: 2
  • Cookies: 0
    • View Profile
Re: http basic access authentication
« Reply #4 on: November 30, 2014, 08:22:14 pm »
Thank you guys for the suggestions. I really appreciate your support.  8)

Offline BaconBACON

  • /dev/null
  • *
  • Posts: 8
  • Cookies: 3
  • Elevensies!!!
    • View Profile
Re: http basic access authentication
« Reply #5 on: December 02, 2014, 09:24:41 pm »
You could use a key logger on the machine of someone whom you know accesses the server in question. You could quickly code one that activites when the user types in the address you want to compromise. A less easy klogger would implement a listener on outbound HTTP/S requests and activates when a GET request is made for the resource in question and deactivates after successful authentication.

Not sure if there are premade tools for this, though I have always hated the concept of key logging without some sort of activation/shutdown mechanism to reduce captured content.
There are few things that irritate me more than illogicality and arrogance, though the latter is more accurately the most irritating form of the former.