Forum Moderators: phranque

Message Too Old, No Replies

Converting GET into POST through .htaccess?

         

taylorstrait

5:43 pm on Jul 15, 2010 (gmt 0)

10+ Year Member



I am installing a WikiMedia engine wiki on a corporate intranet site, that runs in an iframe of the client's CMS. However, the server is to be hosted off-site and their network uses a split-tunneling VPN. This means that I cannot restrict access to the wiki to a specific IP range.

My solution is to encode the login information into the CMS iframe link (protected behind a login/pw) that automatically logs the user into the wiki. All unlogged in users will be denied wiki access.

However, mediawiki only accepts login parameters through POST requests, and I do not have access to send POST requests through the CMS' iframe linking system. My plan therefore is to convert GET requests with username and password parameters into POST requests when they hit the wiki directory on the server to allow users to transparently login. Just having them log in is not an option (as per executive decision)

Is this possible and are there any resources recommended to get me started? Thanks in advance.

coopster

1:17 am on Jul 16, 2010 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Welcome to WebmasterWorld, taylorstrait.

The whole user/password via HTTP GET (a link) is old school, most browsers won't support that direction. If I were you, in this situation, I would probably develop a custom server-side process that uses cURL to accept requests by logged-in users to POST to the other server. It's a bit more work but probably your best bet.