This problem does not appear to be version specific for me. I have tried this several times with different versions and different system configurations. As the title states, when I add the script extension to GeoServer it stops working. Any suggestions? I am running this on Debian 8.
Here is an excerpt from data/logs/geoserver.log:
2015-08-12 11:52:31,066 WARN [support.DisposableBeanAdapter] - Invocation of destroy method failed on bean with name 'geoServerLoader': java.lang.NullPointerException
2015-08-12 11:52:31,067 ERROR [context.ContextLoader] - Context initialization failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'wcsURLMapping' defined in URL [jar:file:/var/lib/tomcat8/webapps/geoserver-test/WEB-INF/lib/gs-wcs-2.7.1.jar!/applicationContext.xml]: Cannot resolve reference to bean 'catalog' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'localWorkspaceCatalog' defined in URL [jar:file:/var/lib/tomcat8/webapps/geoserver-test/WEB-INF/lib/gs-main-2.7.1.jar!/applicationContext.xml]: Cannot resolve reference to bean 'advertisedCatalog' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'advertisedCatalog' defined in URL [jar:file:/var/lib/tomcat8/webapps/geoserver-test/WEB-INF/lib/gs-main-2.7.1.jar!/applicationContext.xml]: Cannot resolve reference to bean 'secureCatalog' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'secureCatalog' defined in URL [jar:file:/var/lib/tomcat8/webapps/geoserver-test/WEB-INF/lib/gs-main-2.7.1.jar!/applicationContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.geoserver.security.SecureCatalogImpl]: Constructor threw exception; nested exception is java.lang.NullPointerException at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:329) ...