Re: [Catalyst] SMTP vs sendmail

2007-08-31 Thread Carl Johnstone
Except by piping to sendmail, you can also specify -odq, which says to sendmail 'dump this into the mail queue and return immediately, I don't want to wait for delivery to work' which can make the application much faster and leave the mail delivering to sendmail. No difference, when I SMTP

Re: [Catalyst] SMTP vs sendmail

2007-08-31 Thread Carl Johnstone
SMTPing to localhost usually doesn't make much sence - it is slow and as you mentioned already it causes trouble when the daemon is down or slow. So either you want to do queueing overhead, dns resolving and SMTPing to the *remote* host yourself or you simply open(MAILER,"|sendmail @args"). Usi

Re: [Catalyst] Rate limiting password attacks

2007-08-20 Thread Carl Johnstone
What's to stop the bot from grabbing the token from the home page and using it in its attack? The token has to be something the bot can't readily read, e.g., captcha. Bill said: "I have the ability to turn on form tokens on my forms, so to be able to post to a form you have to first fetch th

Re: [Catalyst] Rate limiting password attacks

2007-08-19 Thread Carl Johnstone
Bill Moseley wrote: Unfortunately, often want to have a login form on the home page and that page is typically static -- so can't use my token in that situation. How about using a variation of the token system. You have a token that's valid for any request that you change fairly frequently

Re: [Catalyst] Rate limiting password attacks

2007-08-17 Thread Carl Johnstone
Also considered issuing a redirect to a simple server that will delay the number of failed attempts seconds before redirecting back to the login page. Any smart attacker would get clued about this an not follow that redirect. Fun anyways, though. ;) As I just said in the other email

Re: [Catalyst] Rate limiting password attacks

2007-08-17 Thread Carl Johnstone
Well, that would be every environment where Catalyst runs. If you want to do something fancy, I'd suggest looking at lingerd, a C daemon written to take TCP connections handed off from mod_perl. It would require some C-level hacking, but I expect you could alter it for this purpose. Lingerd is

Re: [Catalyst] Rate limiting password attacks

2007-08-17 Thread Carl Johnstone
Anyone doing something like this already? Suggestions? Caveats? You'll almost certainly have to log it per-IP address rather than an a cookie or session or anything like that. Any real password-cracking bot is unlikely to honour your cookies or session identifiers. Which in return means

Re: [Catalyst] Re: Trimming and Quoting Oh My!

2007-07-26 Thread Carl Johnstone
I wasn't trying to get all "email reply nazi" on everyone's ass. It just seems to me that the list has become increasingly difficult to read/parse over the last few weeks. Is that a good sign? Does it mean that we're attracting some of these young kids that don't remember the days when everybo

Re: [Catalyst] Two Strange Catalyst/Apache Issues

2007-05-25 Thread Carl Johnstone
use lib qw(/.../bylines); # This block only matters when the app is outside the default Perl areas Is that really what you have? ... probably is right, and you are missing the lib of the end of the path? We use: use lib qw(/path/to/CatProject/lib/); Carl _

Re: [Catalyst] Too greedy name-based Virtual Host

2007-05-16 Thread Carl Johnstone
This works, and http://site2.domain.tld calls our Catalyst application, and it seems to work properly. But strangely enough, our application is now bound also on site1.domain.tld ! (so all the usual pages are not reachable anymore). Have you setup another VirtualHost for site.domain.tld? The

Re: [Catalyst] running catalyst through mod_perl

2007-05-15 Thread Carl Johnstone
[info] Registration powered by Catalyst 5.7007 fork: Cannot allocate memory unable to fork new process You've ran out of memory! Might be worth watching top/task manager in another window whilst you try to startup to see what's going on memory wise. Carl ___

Re: [Catalyst] A View that may include elements optionally returnedfrom other funcs

2007-04-25 Thread Carl Johnstone
Maybe I am confused about MVC, but wouldn't you want the view to decide how to present what is sent to it by the controller, and hence have the controller handle this? I don't know if it's you that's confused or me that's confused ;-) I can see your point of view though. From my point of vi

Re: [Catalyst] A View that may include elements optionally returnedfrom other funcs

2007-04-25 Thread Carl Johnstone
Ugh... Assume that the view gets everything from controller. Then this controller is the thing that should gather everything together before shipping it to the view. Let the template decide the form, let the controller decide the content. That's fair enough, but say you've got 20 possible

[Catalyst] UK Catalyst jobs

2007-04-05 Thread Carl Johnstone
Hi, I work for the Guardian Media Group in their regional division based in Manchester, England. We run the websites for the groups various regional interests - mainly newspapers, but we also have a local TV station Channel M. Our flagship title is the Manchester Evening News, for which we've jus

Re: [Catalyst] logout and go back to previous session?

2007-03-13 Thread Carl Johnstone
anonymous is not 100% anonymous. each "anonymous" session will have it's own user-id (without username and possibility to login as this user) - this is to make sure one doesn't have to register in order to use basic functionality of the system (which needs to create some records in database). It

Re: [Catalyst] putting an object in the stash

2007-03-13 Thread Carl Johnstone
Is it possible to do that without specifying all the keys by name? Or at least is there a way to get all the keys from $obj, then loop and create a hash, something like: my $hash; foreach(@keys) { $hash->{$_} = $obj->$_; } You're asking for trouble with something like that. Create a DB colum

Re: [Catalyst] logout and go back to previous session?

2007-03-13 Thread Carl Johnstone
now. somebody else can use the same computer/browser to connect to his account - named, with full login/password things. so we create him a session (short term, only till the closing of browser). but. after this "named" user will logout, or close the browser and reopen - we should be able to go b

Re: [Catalyst] Detecting if a user aborted a (long) download

2007-03-12 Thread Carl Johnstone
Here's a worst-case scenario you send it to IE and somewhere along the line it picks up a Vary header. IE won't store anything in it's cache with a Vary header - not even downloaded files. So it downloads the file then deletes it. You can't save it elsewhere or retrieve it! http://support.

Re: [Catalyst] Chained, slashes, and escaping

2007-03-06 Thread Carl Johnstone
When I access the following URI: /tag/sl%2Fashes $tag gets set to sl instead of sl/ashes. Apparently back in the early days of the web, a URL like that caused problems I ran into this a couple of weeks ago. As far as I could the development myapp_server actually deals with everything corre

Re: [Catalyst] New Catalyst site

2007-02-28 Thread Carl Johnstone
How is the content managed? I'd like to know if you integrated your Catalyst application with an existing content management system and if so, how you pulled this off. Having to choose a CMS and framework for a similar site myself this really could help me make a decision. We've got an exist

[Catalyst] New Catalyst site

2007-02-28 Thread Carl Johnstone
Hi, I would like to announce that www.manchestereveningnews.co.uk has just been relaunched using Catalyst and mod_perl. For those that live outside the UK. The Manchester Evening News is the UK's most popular regional newspaper outside London and the sister paper of "The Guardian" (which sta

Re: [Catalyst] Re: memory usage of mod_perl process

2007-02-13 Thread Carl Johnstone
Just a couple of comments on this topic. If you're using apache2.2 then mod_cache is available. This can be used to cache the result of a request either in memory or disk. Ideal for the situations where you want to cache the front page of your site every minute. http://httpd.apache.org/docs/

Re: [Catalyst] Catalyst vs Rails vs Django Cook off

2007-01-15 Thread Carl Johnstone
Now to say the truth, I won't use RoR because I don't know Ruby, but I want to know which are the advantages and disadvantages of Catalyst comparing with other frameworks. The most important advantage/disadvantage *to you* must be that Catalyst is Perl and you know that, and RoR is Ruby and yo

Re: [Catalyst] Catalyst vs Rails vs Django Cook off

2007-01-15 Thread Carl Johnstone
Leandro Hermida > Speed does matter and I believe the original thread question is a valid one. Not everyone has the time or the know-how to do wheel reinvention and write custom daemons (I know I don't). That's why people write kernels and libraries and abstraction of lower level things so

Re: [Catalyst] Catalyst vs Rails vs Django Cook off

2007-01-15 Thread Carl Johnstone
Is it true that Catalyst is so slow comparing with other frameworks? Does it matter? If speed is so important, you should write your own custom httpd that does exactly what you need in assembly language. Carl ___ List: Catalyst@lists.rawmode.or

Re: [Catalyst] Catalyst & Bricolage Integration

2006-11-23 Thread Carl Johnstone
We're working on something similar to Perrin. Our (bought-in) CMS is designed for directly publishing HTML, instead we get it to generate XML files. We also have meta-data to allow editors to enable/disable certain features like comments. So we have something like - 1.xml: 1 news A Story

Re: [Catalyst] regexes and auto actions

2006-11-13 Thread Carl Johnstone
Hi, I posted this a couple of weeks ago. The site is split into many areas (and subareas) defined by URL path, the same types of content appear in each area of the site. There's stuff that needs setting up that's specific to the area of the site, this appears around the main part of the cont

Re: [Catalyst] regexes and auto actions

2006-11-01 Thread Carl Johnstone
In practice however only /article/auto and /auto get called. Do those two auto subs return true? I'm fairly sure they do (don't have access to the code at the moment). I don't think I've got a bug, just that the way Catalyst works isn't exactly what I expected... Carl _

Re: [Catalyst] regexes and auto actions

2006-11-01 Thread Carl Johnstone
Use a controller base class that implements the story/comments actions, and just set the relevant section (i.e. news, sport, football) in an auto or a begin action. We've already got an auto in the base class to do that, we can then generate navigation, breadcrumbs etc. However we have specifi

[Catalyst] regexes and auto actions

2006-10-31 Thread Carl Johnstone
Hi, Got a question regarding the best way of setting up handlers. The site is split into many areas (and subareas) defined by URL path, the same types of content appear in each area of the site. There's stuff that needs setting up that's specific to the area of the site, this appears around

Re: [Catalyst] development setup

2006-06-23 Thread Carl Johnstone
> And I suppose the fact that you use a shared apache installation is > because everyone is woking on the same project, so you have a common > access point for the application... ?-) Yes, we could have anything up to a dozen people working on the same project. By using slightly different URLs eg:

Re: [Catalyst] development setup

2006-06-23 Thread Carl Johnstone
> Do you mean that you have a shared apache installation under which every > developer runs his/her own code ? Yes. Carl ___ List: Catalyst@lists.rawmode.org Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst Searchable archive: http://www.

[Catalyst] development setup

2006-06-23 Thread Carl Johnstone
Hi, At work we're looking at using catalyst for some new developments, and would like a development setup that's similar to our existing mod-perl setup. We currently have a central apache/mod_perl server, that then loads htdocs from each of the developers/designers as neccessary. We use Apache: