Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

rewrite +> https

Status
Not open for further replies.
Sep 20, 2002
2
SG
hi all..
ok .. i'll show a sample of my site structure first.. will help ya'll to understand better...

<htdocs>
<secure1>
<x1>
<y1>
index1.html
</secure1>
<secure2>
<site>
<x2>
<y2>
SITEindex.html
</site>
index2.html
<secure2>
MAINindex1.html
MAINindex2.html
</htdocs>

(yes...too much coding for me...) ::)
anyway, ive got apache1.3.26+mod_ssl-2.8.10+openssl-0.9.6g
workin together n runnin fine, with mod_rewrite enabled too, on a unix.

heres the prob.. EITHER,
secure1-> when a user access the site at , w/o the 'S', i want him to be automatically redirected to httpS, AND any further sub-level requests (eg
)
to be redirected to httpS. same file/folder, but only via httpS.
complicatin things a bit, authentication. MAINindex1.html, will just be a welcome page (which should have been httpSed), followin a link from there to secure1 or index1.html etc or accessin it directly should pop up the basic authentication box bit.
OR, [surprise]
secure2-> user accesses , sees normal httP MAINindex.html. from then on, any subfolders should use httpS. only httpS. AND, the basic authentication should come up at this point as well.

individually, i can make httpS, basic auth work. but combining em all causes some headaches. and i know i can simply turn off port 80, but it aint that user friendly ya know.. besides, it'll look better for the bosses ;-)

anyone got any suggestions/ideas on which method i should go about implementing? secure1 or secure2? and how to go about configurin httpd.conf and .htaccess-es with the proper Rewrites, etc? heard wonderful things about rewrite, just dun have enough time to go about learnin it from scratch..
any help will be greatly appreciated! promise to pray to the computer gods for ya! [3eyes][pc3][3eyes]
tx lots... [peace]
~thomas

ps: .. if u cld, throw in how to fix trailin slash prb also will ya... eg /secure1 ---> /secure1/ .... tx again!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top