[Seasar-user:4759] Re: Sun Java Application Server でエラーが発生。
Shinsuke Akabane
[E-MAIL ADDRESS DELETED]
2006年 10月 10日 (火) 18:02:43 JST
赤羽と申します。
以前、SunJavaApplicationServer8.1でSeasar2を動作させた時の
設定方法を記載します。
この方法はJVMオプションにセキュリティマネージャー無効化の
オプションを追記するだけです。
takemuraさんのSunJavaのバージョンは7ということで
お役に立てるかどうか分かりませんが、
参考にしてみてください。
失礼します。
赤羽
===============================================================
<< セキュリティーマネージャーを無効にする>>
1.管理コンソールの「JVM オプション」ページに進みます。
2.「JVM オプション」ページで、このオプションを次のように追加します。
-Djava.security.policy
3.「保存」をクリックします。
4.サーバーを再起動します。
===============================================================
takemura wrote:
> takemuraと申します。
> お世話になっております。
>
>
> Sun ONE Application Server 7
> にS2JSF beta5を乗せたところSecurityManagerに引っかかりエラーに
> なってしまうので
>
> server.policyというポリシーファイルに
> grant {
> permission java.security.AllPermission;
> };
>
> と設定すると確かに全部動くようにはなるのですが、この設定はあまり推奨されて
> いないようなのでこれをはずしてサーバのエラーログを見ながらpermissionを
> 追加していき
> grant {
> permission java.lang.RuntimePermission "setContextClassLoader";
> permission java.lang.RuntimePermission "getProtectionDomain";
> permission java.lang.reflect.ReflectPermission "suppressAccessChecks";
> };
> でS2JSFの画面動作までは動くようになりました。しかし従業員管理サンプルの
> 検索を押すとエラーになってしまいます。この場合のエラーログを見てもどの
> パーミッションを追加すればいいのかが判断が出来ませんでした・・・。
>
> 何かこのパーミンションではないか、と心当たりがある方がおりましたら
> ご教授頂けると助かります。
>
>
>
>
>
> エラーログ↓↓↓↓
>
> [05/Oct/2006:16:36:56] 致命的 ( 3020): StandardWrapperValve[facesServlet]:
> サーブレット facesServlet のServlet.service()が例外を投げました
> org.seasar.framework.exception.OgnlRuntimeException: [ESSR0073]OGNLで例外が発生しました。理由はMethod [public java.lang.Integer
> examples.jsf.dto.EmployeeSearchDto.getEmpno()] cannot be accessed.
> at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:59)
> at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:42)
> at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:37)
> at org.seasar.dao.node.IfNode.accept(IfNode.java:53)
> at org.seasar.dao.node.ContainerNode.accept(ContainerNode.java:34)
> at org.seasar.dao.node.BeginNode.accept(BeginNode.java:32)
> at org.seasar.dao.node.ContainerNode.accept(ContainerNode.java:34)
> at
> org.seasar.dao.impl.AbstractDynamicCommand.apply(AbstractDynamicCommand.java:65)
> at
> org.seasar.dao.impl.SelectDynamicCommand.execute(SelectDynamicCommand.java:51)
> at
> org.seasar.dao.interceptors.S2DaoInterceptor.invoke(S2DaoInterceptor.java:51)
> at
> org.seasar.framework.aop.impl.NestedMethodInvocation.proceed(NestedMethodInvocation.java:43)
> at
> org.seasar.framework.aop.interceptors.TraceInterceptor.invoke(TraceInterceptor.java:58)
> at
> org.seasar.framework.aop.impl.NestedMethodInvocation.proceed(NestedMethodInvocation.java:43)
> at
> org.seasar.framework.aop.interceptors.InterceptorChain.invoke(InterceptorChain.java:42)
> at
> examples.jsf.dao.EmployeeDtoDao$$EnhancedByS2AOP$$f32dde$$MethodInvocation$$getSearchCount4.proceed(MethodInvocationClassGenerator.java)
> at
> examples.jsf.dao.EmployeeDtoDao$$EnhancedByS2AOP$$f32dde.getSearchCount(EmployeeDtoDao$$EnhancedByS2AOP$$f32dde.java)
> at
> examples.jsf.logic.impl.EmployeeLogicImpl.getSearchCount(EmployeeLogicImpl.java:41)
> at
> examples.jsf.logic.impl.EmployeeLogicImpl$$EnhancedByS2AOP$$1677737.getSearchCount$$invokeSuperMethod$$(EmployeeLogicImpl$$EnhancedByS2AOP$$1677737.java)
>
> at
> examples.jsf.logic.impl.EmployeeLogicImpl$$EnhancedByS2AOP$$1677737$$MethodInvocation$$getSearchCount5.proceed(MethodInvocationClassGenerator.java)
> at
> org.seasar.framework.aop.impl.NestedMethodInvocation.proceed(NestedMethodInvocation.java:45)
> at
> org.seasar.extension.tx.RequiredInterceptor.invoke(RequiredInterceptor.java:40)
> at
> org.seasar.framework.aop.impl.NestedMethodInvocation.proceed(NestedMethodInvocation.java:43)
> at
> org.seasar.framework.aop.interceptors.TraceInterceptor.invoke(TraceInterceptor.java:58)
> at
> org.seasar.framework.aop.impl.NestedMethodInvocation.proceed(NestedMethodInvocation.java:43)
> at
> org.seasar.framework.aop.interceptors.ThrowsInterceptor.invoke(ThrowsInterceptor.java:64)
> at
> org.seasar.framework.aop.impl.NestedMethodInvocation.proceed(NestedMethodInvocation.java:43)
> at
> org.seasar.framework.aop.interceptors.InterceptorChain.invoke(InterceptorChain.java:42)
> at
> examples.jsf.logic.impl.EmployeeLogicImpl$$EnhancedByS2AOP$$1677737$$MethodInvocation$$getSearchCount5.proceed(MethodInvocationClassGenerator.java)
> at
> examples.jsf.logic.impl.EmployeeLogicImpl$$EnhancedByS2AOP$$1677737.getSearchCount(EmployeeLogicImpl$$EnhancedByS2AOP$$1677737.java)
> at
> examples.jsf.action.impl.EmployeeSearchActionImpl.checkSearchCount(EmployeeSearchActionImpl.java:46)
> at
> examples.jsf.action.impl.EmployeeSearchActionImpl$$EnhancedByS2AOP$$1d48043.checkSearchCount$$invokeSuperMethod$$(EmployeeSearchActionImpl$$EnhancedByS2AOP$$1d48043.java)
>
> at
> examples.jsf.action.impl.EmployeeSearchActionImpl$$EnhancedByS2AOP$$1d48043$$MethodInvocation$$checkSearchCount0.proceed(MethodInvocationClass
> [05/Oct/2006:16:36:56] 致命的 ( 3020): Generator.java)
> at
> org.seasar.framework.aop.impl.NestedMethodInvocation.proceed(NestedMethodInvocation.java:45)
> at
> org.seasar.framework.aop.interceptors.ThrowsInterceptor.invoke(ThrowsInterceptor.java:64)
> at
> org.seasar.framework.aop.impl.NestedMethodInvocation.proceed(NestedMethodInvocation.java:43)
> at
> org.seasar.framework.aop.interceptors.TraceInterceptor.invoke(TraceInterceptor.java:58)
> at
> org.seasar.framework.aop.impl.NestedMethodInvocation.proceed(NestedMethodInvocation.java:43)
> at
> org.seasar.framework.aop.interceptors.InterceptorChain.invoke(InterceptorChain.java:42)
> at
> examples.jsf.action.impl.EmployeeSearchActionImpl$$EnhancedByS2AOP$$1d48043$$MethodInvocation$$checkSearchCount0.proceed(MethodInvocationClassGenerator.java)
>
> at
> examples.jsf.action.impl.EmployeeSearchActionImpl$$EnhancedByS2AOP$$1d48043.checkSearchCount(EmployeeSearchActionImpl$$EnhancedByS2AOP$$1d48043.java)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:324)
> at
> org.seasar.teeda.core.el.impl.MethodBindingImpl.invoke(MethodBindingImpl.java:70)
> at org.seasar.jsf.util.InvokeUtil.invokeInternal(InvokeUtil.java:92)
> at org.seasar.jsf.util.InvokeUtil.invoke(InvokeUtil.java:72)
> at
> org.seasar.jsf.application.ActionListenerImpl.processAction(ActionListenerImpl.java:65)
> at javax.faces.component.UICommand.broadcast(UICommand.java:152)
> at
> org.seasar.jsf.component.S2UIViewRoot.broadcastForPhase(S2UIViewRoot.java:119)
> at
> org.seasar.jsf.component.S2UIViewRoot.processApplication(S2UIViewRoot.java:90)
> at
> org.seasar.jsf.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:169)
> at
> org.seasar.jsf.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:102)
> at javax.faces.webapp.FacesServlet.service(FacesServlet.java:86)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
> at
> org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:98)
> at
> org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:176)
> at java.security.AccessController.doPrivileged(Native Method)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:172)
> at
> examples.jsf.util.RequestDumpFilter.doFilter(RequestDumpFilter.java:66)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:213)
> at
> org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:98)
> at
> org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:176)
> at java.security.AccessController.doPrivileged(Native Method)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:172)
> at
> org.seasar.extension.filter.EncodingFilter.doFilter(EncodingFilter.java:62)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:213)
> at
> org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:98)
> at
> org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:176)
> at java.security.AccessController.doPrivileged(Native Method)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:172)
> at org.sea
> [05/Oct/2006:16:36:56] INFO ( 3020): CORE3282: stdout:
> [session]org.seasar.jsf.lifecycle.LifecycleImpl.VIEW_ID=/employee/employeeSearch.html
> [05/Oct/2006:16:36:56] INFO ( 3020): CORE3282: stdout:
> [session]processModeDto=[E-MAIL ADDRESS DELETED]
> [05/Oct/2006:16:36:56] 致命的 ( 3020):
> sar.framework.container.filter.S2ContainerFilter.doFilter(S2ContainerFilter.java:63)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:213)
> at
> org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:98)
> at
> org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:176)
> at java.security.AccessController.doPrivileged(Native Method)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:172)
> at
> org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:213)
> at
> org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:98)
> at
> org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:176)
> at java.security.AccessController.doPrivileged(Native Method)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:172)
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:265)
> at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:212)
> at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:203)
> at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
> at
> com.iplanet.ias.web.connector.nsapi.NSAPIProcessor.process(NSAPIProcessor.java:158)
> at com.iplanet.ias.web.WebContainer.service(WebContainer.java:598)
> Caused by: java.lang.IllegalAccessException: Method [public
> java.lang.Integer examples.jsf.dto.EmployeeSearchDto.getEmpno()] cannot be
> accessed.
> at ognl.OgnlRuntime.invokeMethod(OgnlRuntime.java:483)
> at ognl.OgnlRuntime.getMethodValue(OgnlRuntime.java:904)
> at
> ognl.ObjectPropertyAccessor.getPossibleProperty(ObjectPropertyAccessor.java:54)
> at
> ognl.ObjectPropertyAccessor.getProperty(ObjectPropertyAccessor.java:122)
> at ognl.OgnlRuntime.getProperty(OgnlRuntime.java:1616)
> at ognl.ASTProperty.getValueBody(ASTProperty.java:96)
> at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:170)
> at ognl.SimpleNode.getValue(SimpleNode.java:210)
> at ognl.ASTChain.getValueBody(ASTChain.java:109)
> at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:170)
> at ognl.SimpleNode.getValue(SimpleNode.java:210)
> at ognl.ASTNotEq.getValueBody(ASTNotEq.java:49)
> at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:170)
> at ognl.SimpleNode.getValue(SimpleNode.java:210)
> at ognl.Ognl.getValue(Ognl.java:333)
> at ognl.Ognl.getValue(Ognl.java:413)
> at ognl.Ognl.getValue(Ognl.java:395)
> at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:56)
> ... 90 more
>
>
>
>
>
>
>
>
>
>
> ----- Original Message -----
> From: "Yasuo Higa" <[E-MAIL ADDRESS DELETED]>
> To: <[E-MAIL ADDRESS DELETED]>
> Sent: Friday, August 11, 2006 8:44 PM
> Subject: [Seasar-user:4327] Re: Sun Java Application Server でエラーが発生。
>
>
>> ひがです。
>>
>>> 赤羽と申します。
>>>
>>>
>>> Tomcatで稼働していたwarファイルを
>>> Sun Java Application Server 8.1に載せると
>>> 以下のエラーが発生しました。
>>> ------------------------------------------------------------------------------------------------
>>> java.security.AccessControlException: access denied
>>> (java.lang.RuntimePermission setContextClassLoader)
>>> at
>>> java.security.AccessControlContext.checkPermission(AccessControlContext.java:264)
>> SecurityManagerのチェックに引っかかっているようです。
>> SecurityManagerを使わないというモードで
>> Sun Java Application Server 8.1を立ち上げていただけるでしょうか。
>>
>> 他のアプリケーションサーバでは、(たぶん)SecurityManagerが
>> 使われていないのではないかと思います。
>>
>> よろしくお願いします。
>>
>> Yasuo Higa
>> The Seasar Foundation
>> _______________________________________________
>> Seasar-user mailing list
>> [E-MAIL ADDRESS DELETED]
>> https://www.seasar.org/mailman/listinfo/seasar-user
>>
>>
>
>
> _______________________________________________
> Seasar-user mailing list
> [E-MAIL ADDRESS DELETED]
> https://www.seasar.org/mailman/listinfo/seasar-user
>
--
_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
(株)インテック 第三システム開発部
赤羽 進亮 (Shinsuke Akabane)
Mail :[E-MAIL ADDRESS DELETED]
Tel :03-5665-5150
Fax :03-5665-5179
H.P. :http://www.intec.co.jp
_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
Seasar-user メーリングリストの案内