under sub { validate_cookie() }; get "/foo" => sub { my $c = shift; ... }; get "/bar" => sub { my $c = shift; ... };