Password protection question.

D

DLU

Is there a way to password protect separate pages.
For instance my program has a link to files posted on the website. Some
of these files are in separate folders such as documents, or contacts.
These are in individual pages. I would like to be able to password
protect just an individual page.

http://home.surewest.net/bikesac/bikesac/
--
***************************************
* This is the Spammish Inquisition *
* Not Lumber Cartel Unit 75 [TINLC] *
* I am not SPEWS.ORG *
***************************************
 
D

dorayme

DLU said:
I looked at this but am not sure how to implement it.

What are you having trouble with exactly? An htaccess is a plain text
file that sits on some servers which you can modify or have server admin
modify. Your server bluntly gives:

"Server: NOYB"

in a validation check so I can't tell.

There are more sophisticated ways to proceed with php but htaccess is
more basic...
 
D

DLU

dorayme said:
What are you having trouble with exactly? An htaccess is a plain text
file that sits on some servers which you can modify or have server admin
modify. Your server bluntly gives:

"Server: NOYB"

My server for site shown above is not the sever that is actually public.
The full site is at:
http://clubhouse.sierraclub.org/ca/cnrcc/
in a validation check so I can't tell.

There are more sophisticated ways to proceed with php but htaccess is
more basic...
As far as I can tell, I have to write the code and upload it to the
server. I do not know if the server has it available, however I will be
in the offices of the IT crew on Friday so will ask them if it can be
implemented.

Then I have not seen how to apply it to a page.

--
***************************************
* This is the Spammish Inquisition *
* Not Lumber Cartel Unit 75 [TINLC] *
* I am not SPEWS.ORG *
***************************************
 
D

DLU

dorayme said:
What are you having trouble with exactly? An htaccess is a plain text
file that sits on some servers which you can modify or have server admin
modify. Your server bluntly gives:

"Server: NOYB"

in a validation check so I can't tell.

There are more sophisticated ways to proceed with php but htaccess is
more basic...
I guess I am confused.
It looks like .htaccess is a file extension. So do I make a file called
password.htaccess, or is it a folder?

What would I upload to the server to check it. The tutorial does not
seem to be complete. I do not seem to be able to save a file named
".htaccess"
--
***************************************
* This is the Spammish Inquisition *
* Not Lumber Cartel Unit 75 [TINLC] *
* I am not SPEWS.ORG *
***************************************
 
P

Phil

http://httpd.apache.org/docs/2.0/mod/core.html#files


<files filename >

AuthType Basic
AuthName "popup caption here"
AuthUserFile path/pswdfile
Require valid-user

</files>


in pswdfile contains

username:encryptedpswd


the encrypted password is encrypted with crypt() and is one way password
so if you forget it you have to reset it with FTP.
the previously referenced site will do the password crypt for you.

if directory listing is allowed then you can see the file but it will
ask for UN/PW to access or download.
 
R

richard

Is there a way to password protect separate pages.
For instance my program has a link to files posted on the website. Some
of these files are in separate folders such as documents, or contacts.
These are in individual pages. I would like to be able to password
protect just an individual page.

http://home.surewest.net/bikesac/bikesac/


Ask your host first. They may not allow individual pages to be
password protected.
 
D

dorayme

DLU said:
I guess I am confused.
It looks like .htaccess is a file extension. So do I make a file called
password.htaccess, or is it a folder?

It is not a file extension in the normal way. It is the name of the file
itself. Some OSs will not easily let you name a file this way and
display it in the finder (normal visible desktop, directories...). Macs
do have such named files but they are by default invisible and part of
the background machinary... There are ways to get show such files but
let's get practical: this is what I do:

I get my plain text editor out and create a new doc and name it
"htaccess" (without the "") and upload this to a server that will accept
such a file (Windows servers don't).

And then I change the name on the server itself by means of my FTP
program. It will accept the dot. My OS is sort of bypassed. In fact,
when I first did this, I heard my Mac OS X say something and I think it
was:

"Look Pal, you don't have to look all that sneaky, I know what you just
did! And you know what? I couldn't give a stuff. If you want to stick a
dot in front of your files on the server, go ahead, you are not fiddling
with me..."
What would I upload to the server to check it.

You would upload a plain text file called htaccess and youwould rename
it .htaccess.
The tutorial does not
seem to be complete. I do not seem to be able to save a file named
".htaccess"

There are three parts to the tute, links at the bottom of the page I
think.
 
B

Bergamot

Guy said:
On a Microsoft IIS server, you might also try saving the text file
as foo.htaccess and then renaming it to .htaccess on the server.

Pssst... .htaccess is an Apache thing
 
J

Jonathan N. Little

Guy said:
On a Microsoft IIS server, you might also try saving the text file
as foo.htaccess and then renaming it to .htaccess on the server.

No. .htaccess is for an Apache server. MS uses other methods...
 
D

dorayme

"Jonathan N. Little said:
No. .htaccess is for an Apache server. MS uses other methods...

What I do on IIS, is log into an admin page and ask server admin to do
it. OP might look to see what facilities he has in any control panel on
the server's company website (different to his website, of course) or
simply ring or email them.
 
N

Neredbojias

Is there a way to password protect separate pages.
For instance my program has a link to files posted on the website.
Some of these files are in separate folders such as documents, or
contacts. These are in individual pages. I would like to be able to
password protect just an individual page.

http://home.surewest.net/bikesac/bikesac/

I've seen alot about .htaccess and MS methods, but actually I think the
easiest way is by using php. -A few lines, that's it. Of course, it
helps to know php and it must be available (-which is usual nowadays.)

I p/w-protected an adult page at the following link and bet you can't
"crack" it:

http://adult.neredbojias.org/
 
R

Raymond SCHMIT

I've seen alot about .htaccess and MS methods, but actually I think the
easiest way is by using php. -A few lines, that's it. Of course, it
helps to know php and it must be available (-which is usual nowadays.)

I p/w-protected an adult page at the following link and bet you can't
"crack" it:

http://adult.neredbojias.org/


Could you ....? no no, not giveing us your password :)
Could you make available your coding ? (whick looks very good)
 
R

rf

Raymond SCHMIT said:
Could you ....? no no, not giveing us your password :)
Could you make available your coding ? (whick looks very good)

As he is running PHP on that site I suspect he is going to use the login
credentials to set up a standard PHP session. Standard PHP sessions are, by
definition, secure.
 
N

Neredbojias

Could you ....? no no, not giveing us your password :)
Could you make available your coding ? (whick looks very good)

Here is a pertinent example partial from the current p/w-ed page. The
only things I changed were the password (natch) and the conditional 1st
line detail (it is actually primed earlier in the online version for
styles, etc.)

http://www.neredbojias.org/_dems/samplepw.txt
 
R

richard

I've seen alot about .htaccess and MS methods, but actually I think the
easiest way is by using php. -A few lines, that's it. Of course, it
helps to know php and it must be available (-which is usual nowadays.)

I p/w-protected an adult page at the following link and bet you can't
"crack" it:

http://adult.neredbojias.org/


btw, getting the password took several hours.

by that time, I'm elsewhere.
 
R

richard

I looked at this but am not sure how to implement it.


The file is not implemented on a page you write.
It is acted upon by the server.
Each time a new page is opened, the .htaccess file is checked
automatically for any references to that page.

If you don't already have one, you create one with something as simple
as notepad.
Notepad saves the file as a .htaccess.txt. Once uploaded, rename it
removing the .txt
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

IE, Firefox conflict. 105
How to orient mouseover display. 1
asp.net 29
.NET Question. 28
Visitation Counter. 7
IE7. 3
OK, Next Question. 59
Thumbnail gif Question. 39

Members online

Forum statistics

Threads
473,764
Messages
2,569,566
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top