Page Index Toggle Pages: [1] 2  Send TopicPrint
Hot Topic (More than 10 Replies) [DONE] Maintain .htpasswd from the profiles (Read 9089 times)
CescoAiel
New Member
*
Offline


I may be a bloody novice,
but I know what I say
:P

Posts: 26
Joined: May 23rd, 2002
Gender: Male
[DONE] Maintain .htpasswd from the profiles
May 26th, 2002 at 7:23pm
Print Post  
This is my first fully 'independent' mod, so be gentle! †Wink

This mod allows for maintaining an .htpasswd file from the profiles (i.e. Register.pl and Profile.pl) for protecting other parts of your site. This way people only need to register once to gain access to both the BBS and the other protected parts. †8)

I have developed and tested this on an English YaBB 1 Gold SP1.1, so I cannot say if it'll work on other versions too. †???

This mod also adds a few new fields to the Admin Panel so you can set the location of the htpasswd program, the location of your .htpasswd file and whether you want the feature enabled.

Future enhancements I am considering: .htgroups based on selected custom user group and a way to (re)build .htpasswd (and .htgroups when applicable) from the current users database.

It works for me, let me know if it does for you too! † Grin
« Last Edit: Aug 19th, 2002 at 10:21am by CescoAiel »  

htpassword.mod ( 5 KB | Downloads )

I may be a bloody novice, but I know what I say Tongue
Back to top
IP Logged
 
pryce
Guest


Re: Maintain .htpasswd from the profiles
Reply #1 - Aug 19th, 2002 at 9:44am
Print Post  
Just to let you know, I LOVE THIS MOD!
  
Back to top
 
IP Logged
 
CescoAiel
New Member
*
Offline


I may be a bloody novice,
but I know what I say
:P

Posts: 26
Joined: May 23rd, 2002
Gender: Male
Re: Maintain .htpasswd from the profiles
Reply #2 - Aug 19th, 2002 at 10:21am
Print Post  
Thankx! † Grin

I'm glad at least someone does... Been awfully quite about this mod... And It still not in the mod database! † Shocked

PS: Once I got some more time, I'll start coding for v 2.0, which'll allow for groups as well, and which will be compatible with EMARO mod (Even More Advanced Registration Options) to ensure they only get added *after* approval...
  

I may be a bloody novice, but I know what I say Tongue
Back to top
IP Logged
 
Christer Alexander
God Member
*****
Offline


Make my day...

Posts: 3443
Location: Lethbridge
Joined: Feb 10th, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #3 - Aug 19th, 2002 at 2:11pm
Print Post  
For it to be in the mod db, you'll have to email it to Michael Prager or Dave Baughman.
  

Code
Select All
unless(0) { stab("LoonyPandora"); next; } 

Back to top
IP Logged
 
CescoAiel
New Member
*
Offline


I may be a bloody novice,
but I know what I say
:P

Posts: 26
Joined: May 23rd, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #4 - Aug 19th, 2002 at 3:01pm
Print Post  
That I did already!

TWICE!      Undecided

I'll try again when I get to v2.0
  

I may be a bloody novice, but I know what I say Tongue
Back to top
IP Logged
 
pryce
Guest


Re: [DONE] Maintain .htpasswd from the profiles
Reply #5 - Aug 20th, 2002 at 2:25am
Print Post  
I actually got it out of the db.  It may be listed under a different version.

And to let you know, I'm using several of  your other mods!  I know no one else replied.  If you do release more, please post them here, I love 'em!
  
Back to top
 
IP Logged
 
CescoAiel
New Member
*
Offline


I may be a bloody novice,
but I know what I say
:P

Posts: 26
Joined: May 23rd, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #6 - Aug 20th, 2002 at 8:22am
Print Post  
Quote:
I actually got it out of the db. †It may be listed under a different version.



You did? ???

Can you tell me the search you used? I'll try myself as well...  Found it! Apparently it got added between the last time I checked and now! My apologies to the DB admins... I have blurbed my mouth again, without checking if it still held true!  Lips Sealed

And eh... Thx for the compliment! † :blushing:
  

I may be a bloody novice, but I know what I say Tongue
Back to top
IP Logged
 
Possum
Guest


Re: [DONE] Maintain .htpasswd from the profiles
Reply #7 - Oct 28th, 2002 at 1:36pm
Print Post  
Hi CescoAiel,

Thanks for your htpasswd mod. It is a great idea!

I have implemented the htpasswd mod and it works great. However, there seems like a small bug somewhere... when I register as a new user, an error message appeared: "Internal Server Error"

When I look at admin control panel, the user account was successfully created and an entry correctly added to .htpasswd.

My server log says: malformed header from script. Bad header=Adding password for user abc: /usr/cgiwrap/cgiwrap

Any idea why this is so?
  
Back to top
 
IP Logged
 
CescoAiel
New Member
*
Offline


I may be a bloody novice,
but I know what I say
:P

Posts: 26
Joined: May 23rd, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #8 - Oct 28th, 2002 at 1:48pm
Print Post  
To be honest, I haven't got any experience with the cgiwrap gateway, so I can only guess that it doesn't like the script accessing the htpasswd tool the way it does... † Undecided

I'll see if I can figure this out!
  

I may be a bloody novice, but I know what I say Tongue
Back to top
IP Logged
 
CescoAiel
New Member
*
Offline


I may be a bloody novice,
but I know what I say
:P

Posts: 26
Joined: May 23rd, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #9 - Oct 28th, 2002 at 2:00pm
Print Post  
Checking on the web I found this tidbit of info...  8)
Maybe it'll help to figure out what's happening:

Quote:
I am getting a 500 Server Error, how can I debug my script?
CGIwrap supports a debugging mode which can help to debug scripts. To use it, call CGIwrap via the URL http://.../cgiwrapd/... instead of http://.../cgiwrap/....


Could you try and reply with the result? Maybe I'll be able to understand a bit better what's happening that way?!...   Grin

  

I may be a bloody novice, but I know what I say Tongue
Back to top
IP Logged
 
Eagle_f90
God Member
*****
Offline


For those with wings,
fly to your dreams.

Posts: 926
Location: Derry
Joined: Mar 7th, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #10 - Nov 25th, 2002 at 3:14am
Print Post  
I don't know much about the .htaccess file but I think it is only for Linux. So would this mod work if on an NT server?
  

For those with wings, fly to your dreams

Dreams are what we find at the end of reality, your reality if what you find at the end of your dreams.

Back to top
WWW  
IP Logged
 
CescoAiel
New Member
*
Offline


I may be a bloody novice,
but I know what I say
:P

Posts: 26
Joined: May 23rd, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #11 - Nov 25th, 2002 at 1:30pm
Print Post  
AFAIK the .htaccess and .htpaaswd system is something of Apache, not Linux per sť.

Having said that, I assume it'll work for Apache on NT as well, but as I do not have a NT server running Apache  :party3: :party2: :party: :party2: I can neither confirm nor deny it...

--FP
  

I may be a bloody novice, but I know what I say Tongue
Back to top
IP Logged
 
Caspan
New Member
*
Offline


What the............ .......?

Posts: 4
Joined: Sep 12th, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #12 - Nov 25th, 2002 at 2:59pm
Print Post  
.htaccess is only used by apache unless other web servers have implimented this most secure form of password protection. Apache when ever a request is made looks in that dir for that file for stuff like 404 error pages 500 error page so that you can set exactly what you want your site to do depending on what dir your requesting pages from but the main function of .htaccess is for password autentacation. that error 500 your getting is probly spcific to your server and the cgi code you stuffing in it and that it dosent have a module installed for perl that its looking for so it dies with a 500 error. I'm no expert but from what your saying this sounds like this is because of your server not liking some code where others seam to take the code fine so i would try looking into making sure your perl is up to date. Hope this helps
  

Don't like the soup. Good eat some more!
Back to top
IP Logged
 
CescoAiel
New Member
*
Offline


I may be a bloody novice,
but I know what I say
:P

Posts: 26
Joined: May 23rd, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #13 - Nov 25th, 2002 at 3:58pm
Print Post  
Cazpan,

It may just be me, but where does the ERR 500 come in?  :freak: And I cannot recall reading about a dying server either?  :uhoh:

Is my browser omitting stuff from this thread?   ???

--FP
  

I may be a bloody novice, but I know what I say Tongue
Back to top
IP Logged
 
Caspan
New Member
*
Offline


What the............ .......?

Posts: 4
Joined: Sep 12th, 2002
Gender: Male
Re: [DONE] Maintain .htpasswd from the profiles
Reply #14 - Nov 25th, 2002 at 11:42pm
Print Post  
OK well an error 500 came straight from the server from perl to be exact Apache handles the request and send the data to the perl module specified by the shabang line of your script perl then takes that and runs the code now most people if using the yabb forum get a cgi error outside of the main CGI file with get a very usefull error like error cant open file not enough permisions to perform this task but some times when its the main cgi file sence it crashed nothing in the file works at all. Becasue perl phrases in the entire file of code first and looks for errors then if it finds and just exits with an error 500 telling you that something is wrong with your code. but if you get lucky you get some usefull info from it if you not lucky you have to go through your code and usualy its one little thing like you forgot to end a line with ; and perl cant read in the file so it exits with that error.

If you need more help with this please ask I have no problem with helping with this matter as I have alot of experience with apache and perl
  

Don't like the soup. Good eat some more!
Back to top
IP Logged
 
Page Index Toggle Pages: [1] 2 
Send TopicPrint