cansecurity 0.3.0 is out... and it adds the conditionals! Very cool! 
See http://groups.google.com/group/nodejs/browse_thread/thread/6bcd6d9ce5e18fd1

Feedback always appreciated and welcome.

npm install cansecurity
https://github.com/deitch/cansecurity

On Saturday, November 12, 2011 5:54:07 PM UTC+2, deitch wrote:
>
> Not quite. If you do
>
> server.get("/api/path/:foo", (abc===true && cansec.restrictToSelf()), 
> nextStep);
>
> then it will run them at initialization, instead of at path matching
> time. You could do:
>
> server.get("/api/path/:foo", function(req,res,next){if (abc === true)
> {cansec.restrictToSelf(req,res,next);} else {next();};}, nextStep);
>
>
>

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to