[jboss-cvs] JBossAS SVN: r63639 - in branches/Branch_4_2/testsuite: src/jdk15/org/jboss/test/aop/bean and 2 other directories.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Tue Jun 26 08:17:56 EDT 2007
Author: kabir.khan at jboss.com
Date: 2007-06-26 08:17:55 -0400 (Tue, 26 Jun 2007)
New Revision: 63639
Removed:
branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecureInternalPOJO.java
branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecureRunAsPOJO.java
branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecureInternalPOJO.java
branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecureRunAsPOJO.java
branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecureInternalPOJO.java
branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecureRunAsPOJO.java
Modified:
branches/Branch_4_2/testsuite/imports/sections/aop.xml
branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecuredPOJO.java
branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecuredPOJO.java
branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecuredPOJO.java
branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecurityTester.java
branches/Branch_4_2/testsuite/src/resources/aop/META-INF/jboss-aop.xml
Log:
[JBAOP-193] Undo previous commit since Branch_4_2 is frozen
Modified: branches/Branch_4_2/testsuite/imports/sections/aop.xml
===================================================================
--- branches/Branch_4_2/testsuite/imports/sections/aop.xml 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/imports/sections/aop.xml 2007-06-26 12:17:55 UTC (rev 63639)
@@ -84,11 +84,7 @@
<include name="org/jboss/test/aop/bean/NoInterceptorsPOJO*.class"/>
<include name="org/jboss/test/aop/bean/NonadvisedPOJO.class"/>
<include name="org/jboss/test/aop/bean/SecuredPOJO.class"/>
- <include name="org/jboss/test/aop/bean/SecureRunAsPOJO.class"/>
- <include name="org/jboss/test/aop/bean/SecureInternalPOJO.class"/>
<include name="org/jboss/test/aop/bean/AnnotatedSecuredPOJO.class"/>
- <include name="org/jboss/test/aop/bean/AnnotatedSecureRunAsPOJO.class"/>
- <include name="org/jboss/test/aop/bean/AnnotatedSecureInternalPOJO.class"/>
<include name="org/jboss/test/aop/bean/SomeException.class"/>
<include name="org/jboss/test/aop/bean/POJO*.class"/>
<include name="org/jboss/test/aop/bean/Call*.class"/>
Deleted: branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecureInternalPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecureInternalPOJO.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecureInternalPOJO.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -1,52 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, Red Hat Middleware LLC, and individual contributors
-* as indicated by the @author tags. See the copyright.txt file in the
-* distribution for a full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.aop.bean;
-
-import org.jboss.aspects.security.Permissions;
-import org.jboss.aspects.security.SecurityDomain;
-import org.jboss.aspects.security.Unchecked;
-/**
- *
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
- at SecurityDomain ("other")
-public class AnnotatedSecureInternalPOJO
-{
- @Unchecked
- public AnnotatedSecureInternalPOJO()
- {
-
- }
-
- @Permissions ({"allowed"})
- public void wrongRole()
- {
-
- }
-
- @Permissions ({"internal"})
- public void correctRole()
- {
-
- }
-}
Deleted: branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecureRunAsPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecureRunAsPOJO.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecureRunAsPOJO.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -1,60 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, Red Hat Middleware LLC, and individual contributors
-* as indicated by the @author tags. See the copyright.txt file in the
-* distribution for a full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.aop.bean;
-
-import org.jboss.aspects.security.Permissions;
-import org.jboss.aspects.security.RunAs;
-import org.jboss.aspects.security.SecurityDomain;
-import org.jboss.aspects.security.Unchecked;
-import org.jboss.test.aop.bean.AnnotatedSecureInternalPOJO;
-
-/**
- *
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
- at SecurityDomain("other")
- at RunAs("internal")
-public class AnnotatedSecureRunAsPOJO
-{
- @Unchecked
- AnnotatedSecureInternalPOJO pojo = new AnnotatedSecureInternalPOJO();
-
- @Unchecked
- boolean called;
-
- @Unchecked
- public void runAsWithCorrectRole()
- {
- called = true;
- pojo.correctRole();
- }
-
-
- @Unchecked
- public void runAsWithIncorrectRole()
- {
- called = true;
- pojo.wrongRole();
- }
-}
-
\ No newline at end of file
Modified: branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecuredPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecuredPOJO.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/jdk15/org/jboss/test/aop/bean/AnnotatedSecuredPOJO.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -24,9 +24,7 @@
import org.jboss.aspects.security.SecurityDomain;
import org.jboss.aspects.security.Permissions;
import org.jboss.aspects.security.Exclude;
-import org.jboss.aspects.security.RunAs;
import org.jboss.aspects.security.Unchecked;
-import org.jboss.test.aop.bean.AnnotatedSecureInternalPOJO;
/**
* @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
@@ -67,5 +65,6 @@
@Exclude
public void excluded() {}
+
}
Deleted: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecureInternalPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecureInternalPOJO.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecureInternalPOJO.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -1,55 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, Red Hat Middleware LLC, and individual contributors
-* as indicated by the @author tags. See the copyright.txt file in the
-* distribution for a full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.aop.bean;
-
-/**
- * @@org.jboss.aspects.security.SecurityDomain ("other")
- *
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class AnnotatedSecureInternalPOJO
-{
- /**
- * @@org.jboss.aspects.security.Unchecked
- */
- public AnnotatedSecureInternalPOJO()
- {
-
- }
-
- /**
- * @@org.jboss.aspects.security.Permissions ({"allowed"})
- */
- public void wrongRole()
- {
-
- }
-
- /**
- * @@org.jboss.aspects.security.Permissions ({"internal"})
- */
- public void correctRole()
- {
-
- }
-}
Deleted: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecureRunAsPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecureRunAsPOJO.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecureRunAsPOJO.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -1,61 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, Red Hat Middleware LLC, and individual contributors
-* as indicated by the @author tags. See the copyright.txt file in the
-* distribution for a full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.aop.bean;
-
-/**
- * @@org.jboss.aspects.security.SecurityDomain ("other")
- * @@org.jboss.aspects.security.RunAs ("internal")
- *
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class AnnotatedSecureRunAsPOJO
-{
- /**
- * @@org.jboss.aspects.security.Unchecked
- */
- AnnotatedSecureInternalPOJO pojo = new AnnotatedSecureInternalPOJO();
-
- /**
- * @@org.jboss.aspects.security.Unchecked
- */
- boolean called;
-
- /**
- * @@org.jboss.aspects.security.Unchecked
- */
- public void runAsWithCorrectRole()
- {
- called = true;
- pojo.correctRole();
- }
-
- /**
- * @@org.jboss.aspects.security.Unchecked
- */
- public void runAsWithIncorrectRole()
- {
- called = true;
- pojo.wrongRole();
- }
-
-}
Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecuredPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecuredPOJO.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/AnnotatedSecuredPOJO.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -27,7 +27,7 @@
* @author <a href="mailto:bill at jboss.org">Bill Burke</a>
* @version $Revision$
*/
-public class AnnotatedSecuredPOJO
+public class AnnotatedSecuredPOJO
{
/**
* @@org.jboss.aspects.security.Permissions ({"allowed"})
@@ -78,6 +78,7 @@
/**
* @@org.jboss.aspects.security.Exclude
*/
- public void excluded() {}
+ public void excluded() {}
+
}
Deleted: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecureInternalPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecureInternalPOJO.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecureInternalPOJO.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -1,40 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, Red Hat Middleware LLC, and individual contributors
-* as indicated by the @author tags. See the copyright.txt file in the
-* distribution for a full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.aop.bean;
-
-/**
- *
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class SecureInternalPOJO
-{
- public void wrongRole()
- {
-
- }
-
- public void correctRole()
- {
-
- }
-}
Deleted: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecureRunAsPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecureRunAsPOJO.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecureRunAsPOJO.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -1,44 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, Red Hat Middleware LLC, and individual contributors
-* as indicated by the @author tags. See the copyright.txt file in the
-* distribution for a full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.aop.bean;
-
-/**
- *
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class SecureRunAsPOJO
-{
- AnnotatedSecureInternalPOJO pojo = new AnnotatedSecureInternalPOJO();
- boolean called;
- public void runAsWithCorrectRole()
- {
- called = true;
- pojo.correctRole();
- }
-
- public void runAsWithIncorrectRole()
- {
- called = true;
- pojo.wrongRole();
- }
-}
Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecuredPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecuredPOJO.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecuredPOJO.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -34,7 +34,7 @@
// unchecked
public SecuredPOJO()
- {
+ {
}
// allowed
@@ -49,6 +49,7 @@
public void someMethod() {}
- public void excluded() {}
+ public void excluded() {}
+
}
Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecurityTester.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecurityTester.java 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/bean/SecurityTester.java 2007-06-26 12:17:55 UTC (rev 63639)
@@ -184,25 +184,6 @@
pojo.someField = 5;
pojo = new SecuredPOJO(5);
- System.out.println("Testing valid run-as");
- SecureRunAsPOJO runasPojo = new SecureRunAsPOJO();
- runasPojo.runAsWithCorrectRole();
- runasPojo.called = false;
-
- securityFailure = true;
- try
- {
- System.out.println("Testing invalid run-as");
- runasPojo.runAsWithIncorrectRole();
- }
- catch (SecurityException ignored)
- {
- log.info(ignored.getMessage());
- securityFailure = false;
- }
- if (!runasPojo.called) throw new RuntimeException("run-as method was not actually called");
- if (securityFailure) throw new RuntimeException("run-as failure was not caught for method");
-
log.info("test exclusion");
securityFailure = true;
try
@@ -239,7 +220,6 @@
securityFailure = false;
}
if (securityFailure) throw new RuntimeException("excluded failure was not caught for constructor");
-
}
catch (Throwable ex)
{
@@ -357,26 +337,6 @@
pojo.someField = 5;
pojo = new AnnotatedSecuredPOJO(5);
- AnnotatedSecureRunAsPOJO runasPojo = new AnnotatedSecureRunAsPOJO();
- System.out.println("Testing valid run-as");
- runasPojo.runAsWithCorrectRole();
- runasPojo.called = false;
-
- securityFailure = true;
- try
- {
- System.out.println("Testing invalid run-as");
- runasPojo.runAsWithIncorrectRole();
- }
- catch (SecurityException ignored)
- {
- log.info(ignored.getMessage());
- securityFailure = false;
- }
- if (!runasPojo.called) throw new RuntimeException("run-as method was not actually called");
- if (securityFailure) throw new RuntimeException("run-as failure was not caught for method");
-
-
log.info("test exclusion");
securityFailure = true;
try
Modified: branches/Branch_4_2/testsuite/src/resources/aop/META-INF/jboss-aop.xml
===================================================================
--- branches/Branch_4_2/testsuite/src/resources/aop/META-INF/jboss-aop.xml 2007-06-26 12:17:03 UTC (rev 63638)
+++ branches/Branch_4_2/testsuite/src/resources/aop/META-INF/jboss-aop.xml 2007-06-26 12:17:55 UTC (rev 63639)
@@ -390,67 +390,6 @@
</exclude-list>
</metadata>
-
- <metadata tag="security" class="org.jboss.test.aop.bean.SecureRunAsPOJO">
- <security-domain>other</security-domain>
- <security-identity>
- <run-as><role-name>internal</role-name></run-as>
- </security-identity>
- <method-permission>
- <unchecked/>
- <method>
- <method-name>runAsWithCorrectRole</method-name>
- </method>
- </method-permission>
- <method-permission>
- <unchecked/>
- <method>
- <method-name>runAsWithIncorrectRole</method-name>
- </method>
- </method-permission>
- <field-permission>
- <unchecked/>
- <field>
- <field-name>called</field-name>
- </field>
- </field-permission>
- <constructor-permission>
- <unchecked/>
- <constructor>
- <constructor-params/>
- </constructor>
- </constructor-permission>
- </metadata>
-
- <metadata tag="security" class="org.jboss.test.aop.bean.SecureInternalPOJO">
- <security-domain>other</security-domain>
- <method-permission>
- <role-name>allowed</role-name>
- <method>
- <method-name>wrongRole</method-name>
- </method>
- </method-permission>
- <method-permission>
- <role-name>internal</role-name>
- <method>
- <method-name>correctRole</method-name>
- </method>
- </method-permission>
- <field-permission>
- <unchecked/>
- <field>
- <field-name>called</field-name>
- </field>
- </field-permission>
- <constructor-permission>
- <unchecked/>
- <constructor>
- <constructor-params/>
- </constructor>
- </constructor-permission>
- </metadata>
-
-
<!-- Observable tester -->
<prepare expr="all(org.jboss.test.aop.bean.Temperature)"/>
More information about the jboss-cvs-commits
mailing list