in reply to OT: WebApp Authorization Question
When I encountered this issue with Plucene, a Perl port of Lucene, I simply included a "userids" field with each document, which was a space-separated list of the id numbers of users allowed to see that document.
I had to make sure my Plucene tokenizer class considered numbers a word constituent rather than word boundary, which was not the default.
Then, when the user performed a search, my script would programmatically add a clause requiring that the user's user_id be present in that documents userids field. This was done using various classes and methods of Plucene; I did NOT just concatenate to the search string, which could have some issues. That said, what I did is roughly the same as adding " AND userid:5" to each search.
In your case, you could have a similar field, called "role_ids".
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: OT: WebApp Authorization Question
by Anonymous Monk on May 08, 2006 at 06:04 UTC |