Index: src/com/ecyrd/jspwiki/auth/AuthorizationManager.java =================================================================== RCS file: /p/cvs/JSPWiki/src/com/ecyrd/jspwiki/auth/AuthorizationManager.java,v retrieving revision 1.49 diff -u -r1.49 AuthorizationManager.java --- src/com/ecyrd/jspwiki/auth/AuthorizationManager.java 1 Jun 2007 05:39:17 -0000 1.49 +++ src/com/ecyrd/jspwiki/auth/AuthorizationManager.java 23 Nov 2007 15:10:26 -0000 @@ -405,10 +405,22 @@ try { URL policyURL = AuthenticationManager.findConfigFile( engine, DEFAULT_POLICY ); - File policyFile = new File( policyURL.getPath() ); - m_localPolicy = new LocalPolicy( policyFile, engine.getContentEncoding() ); - m_localPolicy.refresh(); - log.info("Initialized local security policy: " + policyFile.getAbsolutePath()); + if (policyURL != null) + { + File policyFile = new File( policyURL.getPath() ); + m_localPolicy = new LocalPolicy( policyFile, engine.getContentEncoding() ); + m_localPolicy.refresh(); + log.info("Initialized local security policy: " + policyFile.getAbsolutePath()); + } + else + { + StringBuffer sb = new + StringBuffer("Unable to locate default jspwiki.policy (WEB-INF/jspwiki.policy) file. "); + sb.append("Please ensure that the jspwiki.policy file exists in the default location. "); + sb.append("This file should exist regardless of the existance of a global policy file. "); + sb.append("The global policy file is identified by the java.security.policy variable."); + log.error(sb.toString()); + } } catch ( PolicyException e ) {