use Catalyst::Runtime '5.70';
+#Need to preload, otherwise the first hit is slow
+use CGI qw/:standard/;
+escapeHTML('');
+
# Set flags and add plugins for the application
#
# -Debug: activates the debug mode for very useful log messages
# local deployment.
__PACKAGE__->config( name => 'NDWeb' );
+__PACKAGE__->config->{'Plugin::Authentication'}{'use_session'} = 1;
-# Start the application
-__PACKAGE__->setup(qw/-Debug ConfigLoader Static::Simple/);
+# Start the application
+__PACKAGE__->setup(qw/
+ -Debug
+ ConfigLoader
+ Static::Simple
+
+ Authentication
+ Authentication::Store::NDWeb
+ Authentication::Credential::Password
+
+ Authorization::Roles
+ Authorization::ACL
+
+ Session
+ Session::Store::File
+ Session::State::Cookie
+ /);
+
+__PACKAGE__->deny_access_unless('/users',[qw/admin_users/]);
+
=head1 NAME
NDWeb - Catalyst based application