search for: file_rwlock

Displaying 2 results from an estimated 2 matches for "file_rwlock".

Did you mean: file_lock
2004 Aug 06
4
No Duplicate Users - Patch
...authenticator, username, password); + authenticator, source, username, password); if(result == AUTH_OK) client->username = strdup(username); @@ -106,6 +130,7 @@ typedef struct { char *filename; + int allow_duplicate_users; rwlock_t file_rwlock; } htpasswd_auth_state; @@ -150,14 +175,20 @@ #define MAX_LINE_LEN 512 /* Not efficient; opens and scans the entire file for every request */ -static auth_result htpasswd_auth(auth_t *auth, char *username, char *password) +static auth_result htpasswd_auth(auth_t *auth, source_t *source, cha...
2004 Aug 06
0
No Duplicate Users - Patch
...can > connect to a mountpoint more than once. This is pretty much a required > feature for any decent use of the listener authentication capabilities of > icecast. > > thoughts ? comments ? This is good, but I have one comment... > > thread_rwlock_rlock(&state->file_rwlock); > + if (!state->allow_duplicate_users) { > + if (auth_is_listener_connected(source, username)) { > + return AUTH_FAILED; Currently, we only have a generic 'AUTH_FAILED' here. I'd like to see an AUTH_FORBIDDEN (or some other name) added, which would b...