You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Greg Dritschler (JIRA)" <tu...@ws.apache.org> on 2008/02/07 21:29:10 UTC

[jira] Created: (TUSCANY-2030) Java 2 security

Java 2 security
---------------

                 Key: TUSCANY-2030
                 URL: https://issues.apache.org/jira/browse/TUSCANY-2030
             Project: Tuscany
          Issue Type: New Feature
    Affects Versions: Java-SCA-1.0.1
            Reporter: Greg Dritschler


In environments where Java 2 security is enabled, an AccessControlException may occur in Tuscany code even though it has privileges to perform the action, because there is code on the call stack that does not have such privileges.  doPrivileged calls must be used around such actions.

Here is an example of a failure.  There are undoubtedly others.

java.security.AccessControlException: Access denied (java.lang.RuntimePermission getClassLoader)
	at java.security.AccessController.checkPermission(AccessController.java:104)
	at java.lang.SecurityManager.checkPermission(SecurityManager.java:547)
	at com.ibm.ws.security.core.SecurityManager.checkPermission(SecurityManager.java:189)
	at java.lang.Class.getClassLoader(Class.java:234)
	at org.apache.tuscany.sca.core.invocation.JDKProxyFactory.createProxy(JDKProxyFactory.java:64)
	at org.apache.tuscany.sca.core.invocation.DefaultProxyFactoryExtensionPoint.createProxy(DefaultProxyFactoryExtensionPoint.java:105)
	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getInstance(CallableReferenceImpl.java:154)
	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getService(CallableReferenceImpl.java:162)
	at org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain.getService(EmbeddedSCADomain.java:138)
	at com.ibm.ws.soa.sca.runtime.impl.SimpleCompositeContextImpl.locateService(SimpleCompositeContextImpl.java:86)
	at com.ibm._jsp._Calculator._jspService(_Calculator.java:96)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org


[jira] Resolved: (TUSCANY-2030) Java 2 security

Posted by "Raymond Feng (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-2030?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Raymond Feng resolved TUSCANY-2030.
-----------------------------------

    Resolution: Fixed

Patch applied under r650681. Thanks!

> Java 2 security
> ---------------
>
>                 Key: TUSCANY-2030
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2030
>             Project: Tuscany
>          Issue Type: New Feature
>    Affects Versions: Java-SCA-1.0.1
>            Reporter: Greg Dritschler
>            Assignee: Raymond Feng
>             Fix For: Java-SCA-Next
>
>         Attachments: TUSCANY-2030.patch
>
>
> In environments where Java 2 security is enabled, an AccessControlException may occur in Tuscany code even though it has privileges to perform the action, because there is code on the call stack that does not have such privileges.  doPrivileged calls must be used around such actions.
> Here is an example of a failure.  There are undoubtedly others.
> java.security.AccessControlException: Access denied (java.lang.RuntimePermission getClassLoader)
> 	at java.security.AccessController.checkPermission(AccessController.java:104)
> 	at java.lang.SecurityManager.checkPermission(SecurityManager.java:547)
> 	at com.ibm.ws.security.core.SecurityManager.checkPermission(SecurityManager.java:189)
> 	at java.lang.Class.getClassLoader(Class.java:234)
> 	at org.apache.tuscany.sca.core.invocation.JDKProxyFactory.createProxy(JDKProxyFactory.java:64)
> 	at org.apache.tuscany.sca.core.invocation.DefaultProxyFactoryExtensionPoint.createProxy(DefaultProxyFactoryExtensionPoint.java:105)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getInstance(CallableReferenceImpl.java:154)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getService(CallableReferenceImpl.java:162)
> 	at org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain.getService(EmbeddedSCADomain.java:138)
> 	at com.ibm.ws.soa.sca.runtime.impl.SimpleCompositeContextImpl.locateService(SimpleCompositeContextImpl.java:86)
> 	at com.ibm._jsp._Calculator._jspService(_Calculator.java:96)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (TUSCANY-2030) Java 2 security

Posted by "Raymond Feng (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-2030?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Raymond Feng reassigned TUSCANY-2030:
-------------------------------------

    Assignee: Raymond Feng

> Java 2 security
> ---------------
>
>                 Key: TUSCANY-2030
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2030
>             Project: Tuscany
>          Issue Type: New Feature
>    Affects Versions: Java-SCA-1.0.1
>            Reporter: Greg Dritschler
>            Assignee: Raymond Feng
>             Fix For: Java-SCA-Next
>
>         Attachments: TUSCANY-2030.patch
>
>
> In environments where Java 2 security is enabled, an AccessControlException may occur in Tuscany code even though it has privileges to perform the action, because there is code on the call stack that does not have such privileges.  doPrivileged calls must be used around such actions.
> Here is an example of a failure.  There are undoubtedly others.
> java.security.AccessControlException: Access denied (java.lang.RuntimePermission getClassLoader)
> 	at java.security.AccessController.checkPermission(AccessController.java:104)
> 	at java.lang.SecurityManager.checkPermission(SecurityManager.java:547)
> 	at com.ibm.ws.security.core.SecurityManager.checkPermission(SecurityManager.java:189)
> 	at java.lang.Class.getClassLoader(Class.java:234)
> 	at org.apache.tuscany.sca.core.invocation.JDKProxyFactory.createProxy(JDKProxyFactory.java:64)
> 	at org.apache.tuscany.sca.core.invocation.DefaultProxyFactoryExtensionPoint.createProxy(DefaultProxyFactoryExtensionPoint.java:105)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getInstance(CallableReferenceImpl.java:154)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getService(CallableReferenceImpl.java:162)
> 	at org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain.getService(EmbeddedSCADomain.java:138)
> 	at com.ibm.ws.soa.sca.runtime.impl.SimpleCompositeContextImpl.locateService(SimpleCompositeContextImpl.java:86)
> 	at com.ibm._jsp._Calculator._jspService(_Calculator.java:96)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (TUSCANY-2030) Java 2 security

Posted by "Dan Becker (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-2030?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dan Becker updated TUSCANY-2030:
--------------------------------

    Patch Info: [Patch Available]

> Java 2 security
> ---------------
>
>                 Key: TUSCANY-2030
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2030
>             Project: Tuscany
>          Issue Type: New Feature
>    Affects Versions: Java-SCA-1.0.1
>            Reporter: Greg Dritschler
>             Fix For: Java-SCA-Next
>
>         Attachments: TUSCANY-2030.patch
>
>
> In environments where Java 2 security is enabled, an AccessControlException may occur in Tuscany code even though it has privileges to perform the action, because there is code on the call stack that does not have such privileges.  doPrivileged calls must be used around such actions.
> Here is an example of a failure.  There are undoubtedly others.
> java.security.AccessControlException: Access denied (java.lang.RuntimePermission getClassLoader)
> 	at java.security.AccessController.checkPermission(AccessController.java:104)
> 	at java.lang.SecurityManager.checkPermission(SecurityManager.java:547)
> 	at com.ibm.ws.security.core.SecurityManager.checkPermission(SecurityManager.java:189)
> 	at java.lang.Class.getClassLoader(Class.java:234)
> 	at org.apache.tuscany.sca.core.invocation.JDKProxyFactory.createProxy(JDKProxyFactory.java:64)
> 	at org.apache.tuscany.sca.core.invocation.DefaultProxyFactoryExtensionPoint.createProxy(DefaultProxyFactoryExtensionPoint.java:105)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getInstance(CallableReferenceImpl.java:154)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getService(CallableReferenceImpl.java:162)
> 	at org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain.getService(EmbeddedSCADomain.java:138)
> 	at com.ibm.ws.soa.sca.runtime.impl.SimpleCompositeContextImpl.locateService(SimpleCompositeContextImpl.java:86)
> 	at com.ibm._jsp._Calculator._jspService(_Calculator.java:96)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (TUSCANY-2030) Java 2 security

Posted by "Dan Becker (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-2030?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dan Becker updated TUSCANY-2030:
--------------------------------

    Attachment: TUSCANY-2030.patch

This patch when used in conjunction with fixes for TUSCANY-2108 and TUSCANY-2237 allow the Tuscany runtime to run under WAS 7.0 plus SOA FeP with Java 2 security on. However, there are still some security errors in the WebSphere code, which prevents the calculator sample from running error free.

> Java 2 security
> ---------------
>
>                 Key: TUSCANY-2030
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2030
>             Project: Tuscany
>          Issue Type: New Feature
>    Affects Versions: Java-SCA-1.0.1
>            Reporter: Greg Dritschler
>             Fix For: Java-SCA-Next
>
>         Attachments: TUSCANY-2030.patch
>
>
> In environments where Java 2 security is enabled, an AccessControlException may occur in Tuscany code even though it has privileges to perform the action, because there is code on the call stack that does not have such privileges.  doPrivileged calls must be used around such actions.
> Here is an example of a failure.  There are undoubtedly others.
> java.security.AccessControlException: Access denied (java.lang.RuntimePermission getClassLoader)
> 	at java.security.AccessController.checkPermission(AccessController.java:104)
> 	at java.lang.SecurityManager.checkPermission(SecurityManager.java:547)
> 	at com.ibm.ws.security.core.SecurityManager.checkPermission(SecurityManager.java:189)
> 	at java.lang.Class.getClassLoader(Class.java:234)
> 	at org.apache.tuscany.sca.core.invocation.JDKProxyFactory.createProxy(JDKProxyFactory.java:64)
> 	at org.apache.tuscany.sca.core.invocation.DefaultProxyFactoryExtensionPoint.createProxy(DefaultProxyFactoryExtensionPoint.java:105)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getInstance(CallableReferenceImpl.java:154)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getService(CallableReferenceImpl.java:162)
> 	at org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain.getService(EmbeddedSCADomain.java:138)
> 	at com.ibm.ws.soa.sca.runtime.impl.SimpleCompositeContextImpl.locateService(SimpleCompositeContextImpl.java:86)
> 	at com.ibm._jsp._Calculator._jspService(_Calculator.java:96)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TUSCANY-2030) Java 2 security

Posted by "Dan Becker (JIRA)" <tu...@ws.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2030?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12578775#action_12578775 ] 

Dan Becker commented on TUSCANY-2030:
-------------------------------------

I am investigating this an other java.security.AccessControlExceptions that occur with -Djava.security.manager turned on.

> Java 2 security
> ---------------
>
>                 Key: TUSCANY-2030
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2030
>             Project: Tuscany
>          Issue Type: New Feature
>    Affects Versions: Java-SCA-1.0.1
>            Reporter: Greg Dritschler
>             Fix For: Java-SCA-Next
>
>
> In environments where Java 2 security is enabled, an AccessControlException may occur in Tuscany code even though it has privileges to perform the action, because there is code on the call stack that does not have such privileges.  doPrivileged calls must be used around such actions.
> Here is an example of a failure.  There are undoubtedly others.
> java.security.AccessControlException: Access denied (java.lang.RuntimePermission getClassLoader)
> 	at java.security.AccessController.checkPermission(AccessController.java:104)
> 	at java.lang.SecurityManager.checkPermission(SecurityManager.java:547)
> 	at com.ibm.ws.security.core.SecurityManager.checkPermission(SecurityManager.java:189)
> 	at java.lang.Class.getClassLoader(Class.java:234)
> 	at org.apache.tuscany.sca.core.invocation.JDKProxyFactory.createProxy(JDKProxyFactory.java:64)
> 	at org.apache.tuscany.sca.core.invocation.DefaultProxyFactoryExtensionPoint.createProxy(DefaultProxyFactoryExtensionPoint.java:105)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getInstance(CallableReferenceImpl.java:154)
> 	at org.apache.tuscany.sca.core.context.CallableReferenceImpl.getService(CallableReferenceImpl.java:162)
> 	at org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain.getService(EmbeddedSCADomain.java:138)
> 	at com.ibm.ws.soa.sca.runtime.impl.SimpleCompositeContextImpl.locateService(SimpleCompositeContextImpl.java:86)
> 	at com.ibm._jsp._Calculator._jspService(_Calculator.java:96)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org