You can subscribe to this list here.
| 2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
(3) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2002 |
Jan
(3) |
Feb
(2) |
Mar
(8) |
Apr
(3) |
May
(6) |
Jun
(1) |
Jul
(15) |
Aug
(6) |
Sep
|
Oct
(10) |
Nov
(2) |
Dec
(4) |
| 2003 |
Jan
(1) |
Feb
(7) |
Mar
(3) |
Apr
(6) |
May
(7) |
Jun
(5) |
Jul
(5) |
Aug
(25) |
Sep
(14) |
Oct
(2) |
Nov
|
Dec
(2) |
| 2004 |
Jan
(7) |
Feb
(4) |
Mar
(12) |
Apr
(16) |
May
(43) |
Jun
(56) |
Jul
(43) |
Aug
(40) |
Sep
(66) |
Oct
(12) |
Nov
(26) |
Dec
(10) |
| 2005 |
Jan
(13) |
Feb
(33) |
Mar
(16) |
Apr
(7) |
May
(10) |
Jun
(34) |
Jul
(41) |
Aug
(8) |
Sep
(4) |
Oct
(32) |
Nov
(20) |
Dec
(25) |
| 2006 |
Jan
(30) |
Feb
(101) |
Mar
(5) |
Apr
(75) |
May
(74) |
Jun
(22) |
Jul
(6) |
Aug
(70) |
Sep
(19) |
Oct
(21) |
Nov
(31) |
Dec
(50) |
| 2007 |
Jan
(15) |
Feb
(20) |
Mar
(24) |
Apr
(33) |
May
(13) |
Jun
(18) |
Jul
(13) |
Aug
(7) |
Sep
(63) |
Oct
(68) |
Nov
(29) |
Dec
(68) |
| 2008 |
Jan
(30) |
Feb
(33) |
Mar
(30) |
Apr
(103) |
May
(78) |
Jun
(48) |
Jul
(72) |
Aug
(24) |
Sep
(62) |
Oct
(63) |
Nov
(70) |
Dec
(37) |
| 2009 |
Jan
(34) |
Feb
(35) |
Mar
(64) |
Apr
(34) |
May
(34) |
Jun
(58) |
Jul
(30) |
Aug
(30) |
Sep
(46) |
Oct
(52) |
Nov
(12) |
Dec
(23) |
| 2010 |
Jan
(121) |
Feb
(18) |
Mar
(53) |
Apr
(62) |
May
(62) |
Jun
(20) |
Jul
(33) |
Aug
(20) |
Sep
(36) |
Oct
(35) |
Nov
(44) |
Dec
(63) |
| 2011 |
Jan
(19) |
Feb
(32) |
Mar
(94) |
Apr
(41) |
May
(47) |
Jun
(25) |
Jul
(34) |
Aug
(20) |
Sep
(9) |
Oct
(41) |
Nov
(33) |
Dec
(24) |
| 2012 |
Jan
(12) |
Feb
(36) |
Mar
(48) |
Apr
(32) |
May
(20) |
Jun
(15) |
Jul
(32) |
Aug
(13) |
Sep
(33) |
Oct
(54) |
Nov
(25) |
Dec
(16) |
| 2013 |
Jan
(45) |
Feb
(39) |
Mar
(38) |
Apr
(50) |
May
(29) |
Jun
(30) |
Jul
(33) |
Aug
(12) |
Sep
(9) |
Oct
(25) |
Nov
(29) |
Dec
(20) |
| 2014 |
Jan
(25) |
Feb
(19) |
Mar
(16) |
Apr
(33) |
May
(27) |
Jun
(37) |
Jul
(29) |
Aug
(27) |
Sep
(37) |
Oct
(58) |
Nov
(109) |
Dec
(26) |
| 2015 |
Jan
(4) |
Feb
(35) |
Mar
(22) |
Apr
(35) |
May
(28) |
Jun
(20) |
Jul
(4) |
Aug
(16) |
Sep
(37) |
Oct
(13) |
Nov
(13) |
Dec
(14) |
| 2016 |
Jan
(22) |
Feb
(7) |
Mar
(23) |
Apr
(30) |
May
(10) |
Jun
(10) |
Jul
(15) |
Aug
(12) |
Sep
(22) |
Oct
(31) |
Nov
(5) |
Dec
(5) |
| 2017 |
Jan
(30) |
Feb
(25) |
Mar
(28) |
Apr
(4) |
May
(19) |
Jun
(13) |
Jul
(7) |
Aug
(1) |
Sep
(2) |
Oct
(5) |
Nov
(12) |
Dec
(2) |
| 2018 |
Jan
(7) |
Feb
|
Mar
(7) |
Apr
(2) |
May
(8) |
Jun
(18) |
Jul
(6) |
Aug
(3) |
Sep
(15) |
Oct
(33) |
Nov
(13) |
Dec
(7) |
| 2019 |
Jan
(5) |
Feb
(7) |
Mar
(30) |
Apr
(5) |
May
(4) |
Jun
(69) |
Jul
(86) |
Aug
(22) |
Sep
(6) |
Oct
(7) |
Nov
(5) |
Dec
(3) |
| 2020 |
Jan
(10) |
Feb
(12) |
Mar
(22) |
Apr
(5) |
May
(1) |
Jun
(4) |
Jul
(6) |
Aug
|
Sep
(9) |
Oct
|
Nov
|
Dec
(1) |
| 2021 |
Jan
(4) |
Feb
(11) |
Mar
(7) |
Apr
(7) |
May
|
Jun
(3) |
Jul
(10) |
Aug
(6) |
Sep
|
Oct
|
Nov
(18) |
Dec
(2) |
| 2022 |
Jan
(1) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
(2) |
Jul
|
Aug
(4) |
Sep
|
Oct
|
Nov
|
Dec
|
| 2023 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(1) |
Jun
|
Jul
|
Aug
(5) |
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Herman V. <hv...@gm...> - 2012-12-20 00:27:53
|
Hello guys, I`m trying to install EJBCA version 4_0_12 and 4_0_12 running on Linux Centos X86_64, jboss-5.1.0.GA, ant-1.8.4 (compiled) following step by step all instructions here http://www.ejbca.org/installation.html but all the time I hace the same build failed message after "ant install" (all options as default) I search the web without solutions, Best regards, ejbca:batchsuperadmin: [echo] batch superadmin [java] Generating keys in directory /home/hvega/ejbca_4_0_13/p12. [java] javax.ejb.EJBTransactionRolledbackException: org.hibernate.exception.GenericJDBCException: Cannot open connection [java] at org.jboss.ejb3.tx.Ejb3TxPolicy.handleInCallerTx(Ejb3TxPolicy.java:115) [....] [java] ... 77 more [java] Caused by: javax.resource.ResourceException: Transaction is not active: tx=TransactionImple < ac, BasicAction: -1:0:0:0 status: ActionStatus.ABORT_ONLY > [java] at org.jboss.resource.connectionmanager.TxConnectionManager.getManagedConnection(TxConnectionManager.java:370) [java] at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:496) [java] at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:941) [java] at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:89) [java] ... 79 more [java] Java Result: 1 BUILD FAILED /home/hvega/ejbca_4_0_13/build.xml:64: The following error occurred while executing this line: /home/hvega/ejbca_4_0_13/bin/cli.xml:93: The following error occurred while executing this line: /home/hvega/ejbca_4_0_13/bin/cli.xml:128: Batch generation failed! -- Herman Vega Jara hvegax[a]gmail.com |
|
From: <pat...@ka...> - 2012-12-19 20:24:37
|
Hi, we have a szenario to delegate special rights to RA-Admins. In our case the RA-Admin should only be able to create an entity with special FQDNs as CN. At the moment i can only restrict the RA-Admin to special profiles but not for a special pattern for FQDN. Example: [CN=webserver01] variable + [.domain.de.local] fix --> webserver01.domain.de.local The RA-Admin should not be able to create for example the entry for another domain --> CN=webserver01.domain.fr.local. He should get an exception that he is not allowed to create a CN for this domain. I found an implemented function FieldValidator() which seems to be a possible solution to define for example a pattern for CN. The documentation for a possible usage of FieldValidator() is not existing and we are not JBOSS-admins. Has anybody some hints how we could integrate it? Mit freundlichen Grüßen / Best regards Patrick Gaikowski Tel: +49 7132 94 3568 Fax: +49 7132 94 73568 E-Mail: pat...@ka... KI 967850: IT International / IT Governance / Netzwerk Design und IT-Sicherheit Office: Lindichstrasse 11 D-74189 Weinsberg http://www.kaufland.de http://www.spannende-it.de Wir bleiben die Nr. 1: Kaufland ist "Bester Lebensmittelmarkt 2012"! Kaufland Informationssysteme GmbH & Co. KG Postfach 12 53 - 74149 Neckarsulm Kommanditgesellschaft Sitz: Neckarsulm Registergericht: Stuttgart HRA 104163 |
|
From: Tomas G. <to...@pr...> - 2012-12-19 13:19:25
|
In JBoss 5 the tomcat configuration holding all TLS config is in server/default/deploy/jbossweb.sar/server.xml. Cheers, Tomas ********** PrimeKey Solutions AB Anderstorpsvägen 16, 171 54 Solna, Sweden Mob: +46 (0)707421096 Internet: www.primekey.se Twitter: twitter.com/primekeyPKI ********** On 12/19/2012 01:46 PM, Saeed wrote: > Hi > > In Ejbca, I want to change my Tomcat certificate with a certificate that > is issued from > an external CA and does not exist in EJBCA. What shall I do?? > > Saeed > > > ------------------------------------------------------------------------------ > LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial > Remotely access PCs and mobile devices and provide instant support > Improve your efficiency, and focus on delivering more value-add services > Discover what IT Professionals Know. Rescue delivers > http://p.sf.net/sfu/logmein_12329d2d > > > > _______________________________________________ > Ejbca-develop mailing list > Ejb...@li... > https://lists.sourceforge.net/lists/listinfo/ejbca-develop > |
|
From: Saeed <sae...@ya...> - 2012-12-19 12:47:00
|
Hi In Ejbca, I want to change my Tomcat certificate with a certificate that is issued from an external CA and does not exist in EJBCA. What shall I do?? Saeed |
|
From: Tomas G. <to...@pr...> - 2012-12-19 12:03:41
|
Hi, We just released EJBCA 4.0.13 as an early gift from the EJBCA Team. This is a maintenance release containing a few new features and improvements. In all 25 issues have been resolved. * Noteworthy changes: - New self-registration work-flow available in the public web. - Added extended key usage for WiFi EAP authentication. - Some build improvements to avoid issues on some platforms (no javascript, no jasper). - More minor GUI improvements by David Carella of Linagora. - Minor bug fixes. The release do not contain any critical fixes, but is a natural step in improving the Community version of EJBCA. The self-registration work-flow that first appeared in the EJBCA v5.0 Enterprise version has now also been released in EJBCA 4.0. Self registration has been a long standing request from the community and also some customers, and we a glad to say that it is now available in all active versions of EJBCA. Don't miss to try it out! Get the new release from http://www.ejbca.org/. Happy holidays, PrimeKey EJBCA Team ********** PrimeKey Solutions AB Anderstorpsvägen 16, 171 54 Solna, Sweden Mob: +46 (0)707421096 Internet: www.primekey.se Twitter: twitter.com/primekeyPKI ********** |
|
From: ejbca-support <ejb...@pr...> - 2012-12-06 07:43:00
|
On 2012-12-05 14:59, Bruno Furtado wrote: > I've already configured the LDAP publisher and now I want to know how to distribute public key automatically to users. This is something you may be able to do in Windows using group policies. For other systems it is better to use a URL for active download and install by the user. Cheers Anders tech support > > > best regards, > -- > Bruno Furtado |
|
From: ejbca-support <ejb...@pr...> - 2012-12-05 05:30:46
|
On 2012-12-04 21:17, iqbbmm wrote: > Hi, > > > > We use a 3.11 .5 ejbca version and I would like to do one of the correction you did in the 4.0.6 (ECA-2380 concerning XSS public interface). Can you tell me precisely which files have been corrected ? This seems like a question outside of community support. However, if you checkout the code via SVN you can follow all the changes performed because all check-ins are marked with the associated ECA number. Cheers, Anders tech support > > > > Best regards, > > > > Alain Robert > |
|
From: Tomas G. <to...@pr...> - 2012-11-29 08:05:38
|
Hi,
If you want to develop JEE applications I think you need to study and learn more about JEE. Perhaps you should attend some JEE course and study some books?
Unforunately I think it will be hard to find someone with enough time to walk you through the concepts of JEE applications, application servers and class loaders in this forum.
Kind regards,
Tomas
Marcos Fontana <mar...@ho...> skrev:
>I was doing like this:
>
>I’ve a Project that will do some operations from EJBCA using JSF pages.
>
>I created some packages to hold my classes like certificate.model,
>certificate.controler, certificate.bean, and some others.
>
>In the certificate.model, I created the CertificateModel class, that
>hold the operations about creation of user and certificates, using the
>interface CertificateRequestSession. All here works fine in a java
>aplication, but not in JSF.
>
>I studied JSF in the University, but nothing to how use some API inside
>the project. So is from this all of my questions about this type of
>implementation.
>
>I tryed a lot to create a Web Service, using Apache Axis2, but i got a
>port conflict when the server goes UP, even if I change the port on
>configurations XML.
>
>So if you can gimme a hand, I will be a lot of pleased with you.
>
>Thanks
>
>
>
>De: Tomas Gustavsson
>Enviado: 28 de novembro de 2012 07:13
>Para: ejb...@li..., Marcos Fontana
>Assunto: RE: [Ejbca-develop] Error NoClassDefFoundError
>
>
>RE: [Ejbca-develop] Error NoClassDefFoundError
>perhaps you can explain how you project looks like. It's hard to guess
>what your jar and class files look like.
>
>Packaging EJBCA classes into war files is nothing strange and has been
>done before.
>
>Cheers,
>Tomas
>
>
>-----Original message-----
>From: Marcos Fontana <mar...@ho...>
>Sent: Monday 26th November 2012 12:58
>To: ejb...@li...
>Subject: Re: [Ejbca-develop] Error NoClassDefFoundError
>
>
>
>
>So, where shoud i look to find the right places to put the jars in the
>aplication server?
>
>
>
>
>--------------------------------------------------------------------------------------------------------------------------------------
>Application server class loaded works differently. You have to pack
>things correctly, and place external jar files in correct places.
>
>On 11/26/2012 11:58 AM, Marcos Fontana wrote:
>> Hi Tomas,
>> In the test class that worked fine, the classes are in the default
>> package. In the real aplication, the class is in certificate.model.
>> I done everything the same, even the imports. I never done nothing in
>> the class path of war file, even in the test case.
>>
>>
>--------------------------------------------------------------------------------------------------------------------------------------
>> Hi,
>>
>> How do you package your application? It seems to me that the missing
>> class is not included in the classpath of your war file.
>>
>> Cheers,
>> Tomas
>>
>> On 11/22/2012 08:00 PM, Marcos Fontana wrote:
>>> Enviado do Email do Windows
>>> *De:* Marcos Paulo Fontana
>>> *Enviado:* ?22? de ?novembro? de ?2012 ?16?:?57
>>> *Para:* mar...@ho...
>>> *Assunto:* ejb...@li...
>>>
>>> Hi,
>>>
>>> When I?m trying to create a certificate directly on the main in
>java,
>>> like following code, I can do it normaly, the user and certificate
>are
>>> created well.
>>>
>>> *public**static**void*main(String[] args)
>*throws*InvalidKeyException,
>>> NoSuchAlgorithmException, NoSuchProviderException,
>SignatureException,
>>> InvalidAlgorithmParameterException, SecurityException, IOException,
>>> CertificateEncodingException {
>>>
>>>
>>>
>Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>>
>>> CertificateRequestSession teste =
>>> InterfaceCache./getCertficateRequestSession/();
>>>
>>> Admin admin =
>*new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>>
>>> UserDataVO userdata = *new*UserDataVO();
>>>
>>> String username = "yMariano";
>>>
>>> String password = "a1b2c3";
>>>
>>> String DN = "E=y...@ho...,CN=Yara
>>> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
>>>
>>> *int*caid = 1963139164;
>>>
>>> String email = "yar...@ho...";
>>>
>>> userdata.setUsername(username);
>>>
>>> userdata.setPassword(password);
>>>
>>> userdata.setDN(DN);
>>>
>>> userdata.setCAId(caid);
>>>
>>> userdata.setEmail(email);
>>>
>>> userdata.setType(SecConst./USER_ENDUSER/);
>>>
>>>
>userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>>
>>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>>
>>>
>>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>>
>>>
>>>
>userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>>
>>> String pkcs10 =
>>>
>*new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>>> password)));
>>>
>>> *try*{
>>>
>>> teste.processCertReq(admin, userdata, pkcs10,
>>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*,
>SecConst./CERT_REQ_TYPE_PKCS10/);
>>>
>>> } *catch*(Exception ex) {
>>>
>>> // *TODO*Auto-generated catch block
>>>
>>> }
>>>
>>> }
>>>
>>> So I implemented all that in a JSF page and tryed to run it, like i
>done
>>> before, but got this error:
>>>
>>> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
>>> org/ejbca/util/InterfaceCache
>>>
>>> at
>>>
>javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>>
>>> at
>>>
>com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>>
>>> at
>>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>>
>>> at
>>>
>javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>>
>>> at
>>>
>javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>>
>>> at
>>>
>com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>>
>>> at
>com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>>
>>> at
>>>
>com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>>
>>> at
>>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>>
>org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>>
>>> at
>>>
>org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>>
>>> at
>>>
>org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>>
>>> at
>>>
>org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>>
>>> at
>>>
>org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>>
>>> at
>>>
>org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>>
>>> at
>>>
>org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>>
>>> at java.lang.Thread.run(Unknown Source)
>>>
>>> Caused by: java.lang.NoClassDefFoundError:
>org/ejbca/util/InterfaceCache
>>>
>>> at
>>>
>certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>>
>>> at
>>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>>
>>> at
>>>
>certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>>
>>> at
>>>
>certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>>
>>> at
>certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>>
>>> at
>sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>>> Method)
>>>
>>> at
>sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>>> Source)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>>
>>> at java.lang.reflect.Method.invoke(Unknown Source)
>>>
>>> at
>org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>>
>>> at
>>>
>org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>>
>>> at
>>>
>org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>>
>>> at
>>>
>javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>>
>>> ... 28 more
>>>
>>> Caused by: java.lang.ClassNotFoundException:
>>> org.ejbca.util.InterfaceCache from
>>>
>BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>>
>domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>>> roots=[MemoryContextHandler@242065626[path=
>>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>>>
>ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>>>
>context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>>>
>real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>>> delegates=null exported=[certificate.controler, certificate.bean,
>>> certificate.model, certificate.interfaces, certificate.facade,
>>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>>
>>> at
>>>
>org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>>
>>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>>
>>> ... 41 more
>>>
>>> 2012-11-22 16:45:01,853 WARNING
>>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>>> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
>>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>>
>>> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
>>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>>
>>> at
>>>
>com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>>>
>>> at
>>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>>
>>> at
>>>
>javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>>
>>> at
>>>
>javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>>
>>> at
>>>
>com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>>
>>> at
>com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>>
>>> at
>>>
>com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>>
>>> at
>>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>>
>org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>>
>>> at
>>>
>org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>>
>>> at
>>>
>org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>>
>>> at
>>>
>org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>>
>>> at
>>>
>org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>>
>>> at
>>>
>org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>>
>>> at
>>>
>org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>>
>>> at java.lang.Thread.run(Unknown Source)
>>>
>>> Caused by: javax.faces.el.EvaluationException:
>>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>>
>>> at
>>>
>javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>>
>>> at
>>>
>com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>>
>>> ... 27 more
>>>
>>> Caused by: java.lang.NoClassDefFoundError:
>org/ejbca/util/InterfaceCache
>>>
>>> at
>>>
>certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>>
>>> at
>>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>>
>>> at
>>>
>certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>>
>>> at
>>>
>certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>>
>>> at
>certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>>
>>> at
>sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>>> Method)
>>>
>>> at
>sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>>> Source)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>>
>>> at java.lang.reflect.Method.invoke(Unknown Source)
>>>
>>> at
>org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>>
>>> at
>>>
>org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>>
>>> at
>>>
>org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>>
>>> at
>>>
>javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>>
>>> ... 28 more
>>>
>>> Caused by: java.lang.ClassNotFoundException:
>>> org.ejbca.util.InterfaceCache from
>>>
>BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>>
>domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>>> roots=[MemoryContextHandler@242065626[path=
>>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>>>
>ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>>>
>context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>>>
>real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>>> delegates=null exported=[certificate.controler, certificate.bean,
>>> certificate.model, certificate.interfaces, certificate.facade,
>>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>>
>>> at
>>>
>org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>>
>>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>>
>>> ... 41 more
>>>
>>> 2012-11-22 16:45:01,855 SEVERE
>>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>>> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View
>ID:
>>> /cadastroProfile.jsp) Exception thrown during phase execution:
>>>
>javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
>>>
>>> 2012-11-22 16:45:01,856 ERROR
>>>
>[org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
>>> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
>>> Servlet threw exception
>>>
>>> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
>>>
>BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>>
>domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>>> roots=[MemoryContextHandler@242065626[path=
>>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>>>
>ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>>>
>context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>>>
>real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>>> delegates=null exported=[certificate.controler, certificate.bean,
>>> certificate.model, certificate.interfaces, certificate.facade,
>>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>>
>>> at
>>>
>org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>>
>>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>>
>>> at
>>>
>certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>>
>>> at
>>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>>
>>> at
>>>
>certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>>
>>> at
>>>
>certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>>
>>> at
>certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>>
>>> at
>sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>>> Method)
>>>
>>> at
>sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>>> Source)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>>
>>> at java.lang.reflect.Method.invoke(Unknown Source)
>>>
>>> at
>org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>>
>>> at
>>>
>org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>>
>>> at
>>>
>org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>>
>>> at
>>>
>javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>>
>>> at
>>>
>com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>>
>>> at
>>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>>
>>> at
>>>
>javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>>
>>> at
>>>
>javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>>
>>> at
>>>
>com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>>
>>> at
>com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>>
>>> at
>>>
>com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>>
>>> at
>>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>>
>org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>>
>>> at
>>>
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>>
>>> at
>>>
>org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>>
>>> at
>>>
>org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>>
>>> at
>>>
>org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>>
>>> at
>>>
>org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>>
>>> at
>>>
>org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>>
>>> at
>>>
>org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>>
>>> at
>>>
>org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>>
>>> at
>>>
>org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>>
>>> at java.lang.Thread.run(Unknown Source)
>>>
>>> Whith the following code, that i guess is all right:
>>>
>>> *public*String emitirCertificado(String username, String password,
>>> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
>>> NoSuchAlgorithmException, NoSuchProviderException,
>SignatureException,
>>> InvalidAlgorithmParameterException
>>>
>>> {
>>>
>>>
>>>
>Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>>
>>> ProfileBean pBean = *new*ProfileBean();
>>>
>>> UserDataVO userdata = *new*UserDataVO();
>>>
>>> CertificateRequestSession criaCert =
>>> InterfaceCache./getCertficateRequestSession/();
>>>
>>> Admin admin =
>*new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>>
>>> *int*caid;
>>>
>>> *if*(tipoUsuario == 1)
>>>
>>> {
>>>
>>> DN = DN + "Alunos";
>>>
>>> caid = 1963139164; //CAID _Alunos_
>>>
>>> }*else**if*(tipoUsuario == 2)
>>>
>>> {
>>>
>>> DN = DN + "Professores";
>>>
>>> caid = 1134085357; //CAID _Professores_
>>>
>>> }*else*
>>>
>>> DN = DN + "Administrativo";
>>>
>>> caid = 1911414444; //CAID _Administrativo_
>>>
>>> userdata.setUsername(username);
>>>
>>> userdata.setPassword(password);
>>>
>>> userdata.setDN(DN);
>>>
>>> userdata.setCAId(caid); //ID CA _que_ _assina_.
>>>
>>> userdata.setEmail(E);
>>>
>>> userdata.setType(SecConst./USER_ENDUSER/);
>>>
>>> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>>
>>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>>
>>>
>>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>>
>>>
>>>
>userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>>
>>> String pkcs10 =
>>>
>*new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>>> password)));
>>>
>>> *try*{
>>>
>>> criaCert.processCertReq(admin, userdata,
>pkcs10,
>>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*,
>SecConst./CERT_REQ_TYPE_PKCS10/);
>>>
>>> pBean.setMensagem("Profile e certificado criados com Sucesso");
>>>
>>> *return*"sucesso";
>>>
>>> } *catch*(Exception ex) {
>>>
>>> // *TODO*Auto-generated catch block
>>>
>>> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso
>servidores.
>>> Tente novamente!");
>>>
>>> *return*"erro";
>>>
>>> }
>>>
>>> }
>>>
>>>
>------------------------------------------------------------------------
>>>
>>> Nenhum v?rus encontrado nessa mensagem.
>>> Verificado por AVG -www.avgbrasil.com.br
><http://www.avgbrasil.com.br>
>> <http://www.avgbrasil.com.br>
>>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>>> Lan?amento: 11/20/12
>>>
>>>
>------------------------------------------------------------------------
>>>
>>> Nenhum v?rus encontrado nessa mensagem.
>>> Verificado por AVG -www.avgbrasil.com.br
><http://www.avgbrasil.com.br>
>> <http://www.avgbrasil.com.br>
>>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>>> Lan?amento: 11/20/12
>>>
>>> Aviso: Mensagem enviada com recursos de tecnologia da informa??o da
>Rede
>>> Energia S.A., podendo conter informa??o confidencial ou
>privilegiada. Se
>>> recebida por engano, favor devolv?-la ao remetente e elimin?-la, n?o
>a
>>> divulgando, copiando ou utilizando-a ou documentos a ela anexados.
>N?o
>>> gera obriga??es ? Rede Energia S.A. ou a suas empresas
>controladoras,
>>> controladas ou afiliadas (?empresas relacionadas?) a mensagem
>expedida
>>> por quem n?o tenha poderes de representa??o. A Rede Energia S.A. e
>as
>>> empresas relacionadas n?o se responsabilizam por v?rus, amea?as
>>> eletr?nicas ou altera??o do conte?do original da mensagem. ?
>monitorada
>>> toda mensagem enviada ou recebida utilizando recursos de tecnologia
>da
>>> informa??o da Rede Energia S.A. Notice: This message was sent
>through
>>> Rede Energia S.A. information technology resources and may contain
>>> confidential or privileged information. If received by mistake,
>please
>>> reply to the sender, eliminate and do not disclose, copy or use this
>>> message or attached documents. Neither Rede Energia S.A. nor its
>>> controlling, controlled or affiliated companies (?related
>companies?)
>>> shall be bound by any message sent by a person not having legal
>>> authority to represent them. Rede Energia S.A. and the related
>companies
>>> shall not be liable for the existence of virus, electronic threat or
>>> change in the original content of the message. Every message sent or
>>> received through Rede Energia S.A. information technology resources
>is
>>> monitored.
>>>
>>>
>>>
>------------------------------------------------------------------------------
>>> Monitor your physical, virtual and cloud infrastructure from a
>single
>>> web console. Get in-depth insight into apps, servers, databases,
>vmware,
>>> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>>> Pricing starts from $795 for 25 servers or applications!
>>>http://p.sf.net/sfu/zoho_dev2dev_nov
>>>
>>>
>>>
>>> _______________________________________________
>>> Ejbca-develop mailing list
>>> Ejb...@li...
>>>https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>>>
>>
>>
>>
>>
>> ------------------------------
>>
>> Message: 2
>> Date: Fri, 23 Nov 2012 01:18:49 +0100
>> From: Hans Witvliet <hw...@a-...>
>> Subject: [Ejbca-develop] some steps acomplished..
>> To: ejb...@li...
>> Message-ID: <135...@t4...>
>> Content-Type: text/plain
>>
>> Hi all,
>>
>> some steps accomplished, but new challenges to meet.
>>
>> Trying not to change too many variables at each step..
>> afaicr, the website says that 3.11.x should work with
>>
>>
>> So at my next step i'm trying to get ejbca-3.11 working with:
>> apache-ant-1.8.1-bin.zip
>> ejbca_3_11_5.zip
>> jboss-5.1.0.GA-jdk6.zip
>> jce_policy-6.zip
>> jdk-6u20-linux-i586.bin
>> mysql-connector-java-5.1.13.zip
>>
>> However, during ant clean it complains:
>>
>> Exception in thread "main" java.lang.NoClassDefFoundError:
>> org/apache/tools/ant/launch/Launcher
>> Caused by: java.lang.ClassNotFoundException:
>> org.apache.tools.ant.launch.Launcher
>> at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
>> at java.security.AccessController.doPrivileged(Native
>Method)
>> at
>java.net.URLClassLoader.findClass(URLClassLoader.java:190)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>> at
>sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
>> Could not find the main class: org.apache.tools.ant.launch.Launcher.
>> Program will exit.
>>
>>
>> The distro has a newer jdk available, but the error reains.
>> # zypper search jdk
>> "java-1_7_0-openjdk Java runtime environment based on OpenJDK 7 and
>> IcedTea 7"
>>
>> So, what (url please) JDK/JCE-binary package do you recommend to go
>> along with JBoss5?
>>
>> Oracle site doesn't make me any wiser ...
>>
>> hans
>>
>>
>>
>>
>>
>> ------------------------------
>>
>>
>------------------------------------------------------------------------------
>> Monitor your physical, virtual and cloud infrastructure from a single
>> web console. Get in-depth insight into apps, servers, databases,
>vmware,
>> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>> Pricing starts from $795 for 25 servers or applications!
>> http://p.sf.net/sfu/zoho_dev2dev_nov
>>
>> ------------------------------
>>
>> _______________________________________________
>> Ejbca-develop mailing list
>> Ejb...@li...
>> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>>
>>
>> End of Ejbca-develop Digest, Vol 78, Issue 3
>> ********************************************
>>
>>
>>
>------------------------------------------------------------------------------
>> Monitor your physical, virtual and cloud infrastructure from a single
>> web console. Get in-depth insight into apps, servers, databases,
>vmware,
>> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>> Pricing starts from $795 for 25 servers or applications!
>> http://p.sf.net/sfu/zoho_dev2dev_nov
>>
>>
>>
>> _______________________________________________
>> Ejbca-develop mailing list
>> Ejb...@li...
>> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>>
>
>
>
>
>------------------------------
>
>------------------------------------------------------------------------------
>Monitor your physical, virtual and cloud infrastructure from a single
>web console. Get in-depth insight into apps, servers, databases,
>vmware,
>SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>Pricing starts from $795 for 25 servers or applications!
>http://p.sf.net/sfu/zoho_dev2dev_nov
>
>------------------------------
>
>_______________________________________________
>Ejbca-develop mailing list
>Ejb...@li...
>https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
>
>End of Ejbca-develop Digest, Vol 78, Issue 6
>********************************************
>
>------------------------------------------------------------------------------
>
>Monitor your physical, virtual and cloud infrastructure from a single
>
>web console. Get in-depth insight into apps, servers, databases,
>vmware,
>
>SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>
>Pricing starts from $795 for 25 servers or applications!
>
>http://p.sf.net/sfu/zoho_dev2dev_nov
>_______________________________________________
>
>Ejbca-develop mailing list
>
>Ejb...@li...
>
>https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
>------------------------------------------------------------------------
>
>------------------------------------------------------------------------------
>Keep yourself connected to Go Parallel:
>INSIGHTS What's next for parallel hardware, programming and related
>areas?
>Interviews and blogs by thought leaders keep you ahead of the curve.
>http://goparallel.sourceforge.net
>
>------------------------------------------------------------------------
>
>_______________________________________________
>Ejbca-develop mailing list
>Ejb...@li...
>https://lists.sourceforge.net/lists/listinfo/ejbca-develop
|
|
From: ejbca-support <ejb...@pr...> - 2012-11-29 05:12:59
|
On 2012-11-28 22:26, Marcos Fontana wrote:
> I was doing like this:
>
> I’ve a Project that will do some operations from EJBCA using JSF pages.
>
> I created some packages to hold my classes like certificate.model, certificate.controler, certificate.bean, and some others.
>
> In the certificate.model, I created the CertificateModel class, that hold the operations about creation of user and certificates, using the interface CertificateRequestSession. All here works fine in a java aplication, but not in JSF.
>
> I studied JSF in the University, but nothing to how use some API inside the project. So is from this all of my questions about this type of implementation.
>
> I tryed a lot to create a Web Service, using Apache Axis2, but i got a port conflict when the server goes UP, even if I change the port on configurations XML.
>
> So if you can gimme a hand, I will be a lot of pleased with you.
Marcos,
If you really insist creating code for running *inside* of EJBCA it is easier
by becoming a part of EJBCA by for example using the "plugin" interface. Then you
don't have to package any EJBCA JAR etc.
See: EJBCA/src/sample/plugins
The error message you get indicates a packaging problem. You cannot
refer to EJBCA classes from a stand-alone WAR, you must package them
as well which is why "plugins" seems to be an easier way ahead.
For Web Services you don't need to create anything client-wise.
"ant clientToolBox" gives you a tool plus a library that can be
used by custom applications.
Anders
tech support
>
> Thanks
>
>
> *De:* Tomas Gustavsson
> *Enviado:* 28 de novembro de 2012 07:13
> *Para:* ejb...@li..., Marcos Fontana
> *Assunto:* RE: [Ejbca-develop] Error NoClassDefFoundError
>
> RE: [Ejbca-develop] Error NoClassDefFoundError
> perhaps you can explain how you project looks like. It's hard to guess what your jar and class files look like.
>
> Packaging EJBCA classes into war files is nothing strange and has been done before.
>
> Cheers,
> Tomas
>
> -----Original message-----
> *From:* Marcos Fontana <mar...@ho...>
> *Sent:* Monday 26th November 2012 12:58
> *To:* ejb...@li...
> *Subject:* Re: [Ejbca-develop] Error NoClassDefFoundError
>
> So, where shoud i look to find the right places to put the jars in the aplication server?
>
>
>
> --------------------------------------------------------------------------------------------------------------------------------------
> Application server class loaded works differently. You have to pack
> things correctly, and place external jar files in correct places.
>
> On 11/26/2012 11:58 AM, Marcos Fontana wrote:
> > Hi Tomas,
> > In the test class that worked fine, the classes are in the default
> > package. In the real aplication, the class is in certificate.model.
> > I done everything the same, even the imports. I never done nothing in
> > the class path of war file, even in the test case.
> >
> > --------------------------------------------------------------------------------------------------------------------------------------
> > Hi,
> >
> > How do you package your application? It seems to me that the missing
> > class is not included in the classpath of your war file.
> >
> > Cheers,
> > Tomas
> >
> > On 11/22/2012 08:00 PM, Marcos Fontana wrote:
> >> Enviado do Email do Windows
> >> *De:* Marcos Paulo Fontana
> >> *Enviado:* ?22? de ?novembro? de ?2012 ?16?:?57
> >> *Para:* mar...@ho...
> >> *Assunto:* ejb...@li...
> >>
> >> Hi,
> >>
> >> When I?m trying to create a certificate directly on the main in java,
> >> like following code, I can do it normaly, the user and certificate are
> >> created well.
> >>
> >> *public**static**void*main(String[] args) *throws*InvalidKeyException,
> >> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
> >> InvalidAlgorithmParameterException, SecurityException, IOException,
> >> CertificateEncodingException {
> >>
> >>
> >> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
> >>
> >> CertificateRequestSession teste =
> >> InterfaceCache./getCertficateRequestSession/();
> >>
> >> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
> >>
> >> UserDataVO userdata = *new*UserDataVO();
> >>
> >> String username = "yMariano";
> >>
> >> String password = "a1b2c3";
> >>
> >> String DN = "E=y...@ho...,CN=Yara
> >> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
> >>
> >> *int*caid = 1963139164;
> >>
> >> String email = "yar...@ho...";
> >>
> >> userdata.setUsername(username);
> >>
> >> userdata.setPassword(password);
> >>
> >> userdata.setDN(DN);
> >>
> >> userdata.setCAId(caid);
> >>
> >> userdata.setEmail(email);
> >>
> >> userdata.setType(SecConst./USER_ENDUSER/);
> >>
> >> userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
> >>
> >> userdata.setStatus(UserDataConstants./STATUS_NEW/);
> >>
> >>
> >> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
> >>
> >>
> >> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
> >>
> >> String pkcs10 =
> >> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
> >> password)));
> >>
> >> *try*{
> >>
> >> teste.processCertReq(admin, userdata, pkcs10,
> >> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
> >>
> >> } *catch*(Exception ex) {
> >>
> >> // *TODO*Auto-generated catch block
> >>
> >> }
> >>
> >> }
> >>
> >> So I implemented all that in a JSF page and tryed to run it, like i done
> >> before, but got this error:
> >>
> >> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
> >> org/ejbca/util/InterfaceCache
> >>
> >> at
> >> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
> >>
> >> at
> >> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
> >>
> >> at
> >> javax.faces.component.UICommand.broadcast(UICommand.java:387)
> >>
> >> at
> >> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
> >>
> >> at
> >> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
> >>
> >> at
> >> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
> >>
> >> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
> >>
> >> at
> >> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
> >>
> >> at
> >> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> >>
> >> at
> >> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> >>
> >> at
> >> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
> >>
> >> at
> >> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
> >>
> >> at
> >> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
> >>
> >> at
> >> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
> >>
> >> at
> >> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
> >>
> >> at
> >> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
> >>
> >> at
> >> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> >>
> >> at
> >> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
> >>
> >> at
> >> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
> >>
> >> at
> >> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> >>
> >> at
> >> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
> >>
> >> at
> >> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
> >>
> >> at
> >> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
> >>
> >> at
> >> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
> >>
> >> at java.lang.Thread.run(Unknown Source)
> >>
> >> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
> >>
> >> at
> >> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
> >>
> >> at
> >> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
> >>
> >> at
> >> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
> >>
> >> at
> >> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
> >>
> >> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
> >>
> >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> >> Method)
> >>
> >> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
> >> Source)
> >>
> >> at
> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> >>
> >> at java.lang.reflect.Method.invoke(Unknown Source)
> >>
> >> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
> >>
> >> at
> >> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
> >>
> >> at
> >> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
> >>
> >> at
> >> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
> >>
> >> ... 28 more
> >>
> >> Caused by: java.lang.ClassNotFoundException:
> >> org.ejbca.util.InterfaceCache from
> >> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> >> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> >> parentPolicy=AFTER_BUT_JAVA_BEFORE
> >> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
> >> roots=[MemoryContextHandler@242065626[path=
> >> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
> >> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
> >> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
> >> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
> >> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
> >> delegates=null exported=[certificate.controler, certificate.bean,
> >> certificate.model, certificate.interfaces, certificate.facade,
> >> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
> >>
> >> at
> >> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
> >>
> >> at java.lang.ClassLoader.loadClass(Unknown Source)
> >>
> >> ... 41 more
> >>
> >> 2012-11-22 16:45:01,853 WARNING
> >> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
> >> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
> >> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
> >>
> >> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
> >> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
> >>
> >> at
> >> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
> >>
> >> at
> >> javax.faces.component.UICommand.broadcast(UICommand.java:387)
> >>
> >> at
> >> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
> >>
> >> at
> >> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
> >>
> >> at
> >> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
> >>
> >> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
> >>
> >> at
> >> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
> >>
> >> at
> >> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> >>
> >> at
> >> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> >>
> >> at
> >> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
> >>
> >> at
> >> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
> >>
> >> at
> >> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
> >>
> >> at
> >> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
> >>
> >> at
> >> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
> >>
> >> at
> >> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
> >>
> >> at
> >> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> >>
> >> at
> >> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
> >>
> >> at
> >> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
> >>
> >> at
> >> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> >>
> >> at
> >> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
> >>
> >> at
> >> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
> >>
> >> at
> >> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
> >>
> >> at
> >> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
> >>
> >> at java.lang.Thread.run(Unknown Source)
> >>
> >> Caused by: javax.faces.el.EvaluationException:
> >> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
> >>
> >> at
> >> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
> >>
> >> at
> >> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
> >>
> >> ... 27 more
> >>
> >> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
> >>
> >> at
> >> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
> >>
> >> at
> >> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
> >>
> >> at
> >> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
> >>
> >> at
> >> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
> >>
> >> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
> >>
> >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> >> Method)
> >>
> >> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
> >> Source)
> >>
> >> at
> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> >>
> >> at java.lang.reflect.Method.invoke(Unknown Source)
> >>
> >> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
> >>
> >> at
> >> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
> >>
> >> at
> >> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
> >>
> >> at
> >> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
> >>
> >> ... 28 more
> >>
> >> Caused by: java.lang.ClassNotFoundException:
> >> org.ejbca.util.InterfaceCache from
> >> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> >> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> >> parentPolicy=AFTER_BUT_JAVA_BEFORE
> >> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
> >> roots=[MemoryContextHandler@242065626[path=
> >> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
> >> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
> >> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
> >> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
> >> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
> >> delegates=null exported=[certificate.controler, certificate.bean,
> >> certificate.model, certificate.interfaces, certificate.facade,
> >> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
> >>
> >> at
> >> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
> >>
> >> at java.lang.ClassLoader.loadClass(Unknown Source)
> >>
> >> ... 41 more
> >>
> >> 2012-11-22 16:45:01,855 SEVERE
> >> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
> >> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View ID:
> >> /cadastroProfile.jsp) Exception thrown during phase execution:
> >> javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
> >>
> >> 2012-11-22 16:45:01,856 ERROR
> >> [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
> >> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
> >> Servlet threw exception
> >>
> >> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
> >> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> >> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> >> parentPolicy=AFTER_BUT_JAVA_BEFORE
> >> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
> >> roots=[MemoryContextHandler@242065626[path=
> >> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
> >> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
> >> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
> >> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
> >> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
> >> delegates=null exported=[certificate.controler, certificate.bean,
> >> certificate.model, certificate.interfaces, certificate.facade,
> >> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
> >>
> >> at
> >> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
> >>
> >> at java.lang.ClassLoader.loadClass(Unknown Source)
> >>
> >> at
> >> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
> >>
> >> at
> >> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
> >>
> >> at
> >> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
> >>
> >> at
> >> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
> >>
> >> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
> >>
> >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> >> Method)
> >>
> >> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
> >> Source)
> >>
> >> at
> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> >>
> >> at java.lang.reflect.Method.invoke(Unknown Source)
> >>
> >> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
> >>
> >> at
> >> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
> >>
> >> at
> >> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
> >>
> >> at
> >> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
> >>
> >> at
> >> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
> >>
> >> at
> >> javax.faces.component.UICommand.broadcast(UICommand.java:387)
> >>
> >> at
> >> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
> >>
> >> at
> >> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
> >>
> >> at
> >> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
> >>
> >> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
> >>
> >> at
> >> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
> >>
> >> at
> >> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> >>
> >> at
> >> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
> >>
> >> at
> >> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> >>
> >> at
> >> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
> >>
> >> at
> >> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
> >>
> >> at
> >> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
> >>
> >> at
> >> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
> >>
> >> at
> >> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
> >>
> >> at
> >> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
> >>
> >> at
> >> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> >>
> >> at
> >> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
> >>
> >> at
> >> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
> >>
> >> at
> >> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> >>
> >> at
> >> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
> >>
> >> at
> >> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
> >>
> >> at
> >> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
> >>
> >> at
> >> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
> >>
> >> at java.lang.Thread.run(Unknown Source)
> >>
> >> Whith the following code, that i guess is all right:
> >>
> >> *public*String emitirCertificado(String username, String password,
> >> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
> >> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
> >> InvalidAlgorithmParameterException
> >>
> >> {
> >>
> >>
> >> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
> >>
> >> ProfileBean pBean = *new*ProfileBean();
> >>
> >> UserDataVO userdata = *new*UserDataVO();
> >>
> >> CertificateRequestSession criaCert =
> >> InterfaceCache./getCertficateRequestSession/();
> >>
> >> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
> >>
> >> *int*caid;
> >>
> >> *if*(tipoUsuario == 1)
> >>
> >> {
> >>
> >> DN = DN + "Alunos";
> >>
> >> caid = 1963139164; //CAID _Alunos_
> >>
> >> }*else**if*(tipoUsuario == 2)
> >>
> >> {
> >>
> >> DN = DN + "Professores";
> >>
> >> caid = 1134085357; //CAID _Professores_
> >>
> >> }*else*
> >>
> >> DN = DN + "Administrativo";
> >>
> >> caid = 1911414444; //CAID _Administrativo_
> >>
> >> userdata.setUsername(username);
> >>
> >> userdata.setPassword(password);
> >>
> >> userdata.setDN(DN);
> >>
> >> userdata.setCAId(caid); //ID CA _que_ _assina_.
> >>
> >> userdata.setEmail(E);
> >>
> >> userdata.setType(SecConst./USER_ENDUSER/);
> >>
> >> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
> >>
> >> userdata.setStatus(UserDataConstants./STATUS_NEW/);
> >>
> >>
> >> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
> >>
> >>
> >> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
> >>
> >> String pkcs10 =
> >> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
> >> password)));
> >>
> >> *try*{
> >>
> >> criaCert.processCertReq(admin, userdata, pkcs10,
> >> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
> >>
> >> pBean.setMensagem("Profile e certificado criados com Sucesso");
> >>
> >> *return*"sucesso";
> >>
> >> } *catch*(Exception ex) {
> >>
> >> // *TODO*Auto-generated catch block
> >>
> >> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso servidores.
> >> Tente novamente!");
> >>
> >> *return*"erro";
> >>
> >> }
> >>
> >> }
> >>
> >> ------------------------------------------------------------------------
> >>
> >> Nenhum v?rus encontrado nessa mensagem.
> >> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> > <http://www.avgbrasil.com.br>
> >> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
> >> Lan?amento: 11/20/12
> >>
> >> ------------------------------------------------------------------------
> >>
> >> Nenhum v?rus encontrado nessa mensagem.
> >> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> > <http://www.avgbrasil.com.br>
> >> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
> >> Lan?amento: 11/20/12
> >>
> >> Aviso: Mensagem enviada com recursos de tecnologia da informa??o da Rede
> >> Energia S.A., podendo conter informa??o confidencial ou privilegiada. Se
> >> recebida por engano, favor devolv?-la ao remetente e elimin?-la, n?o a
> >> divulgando, copiando ou utilizando-a ou documentos a ela anexados. N?o
> >> gera obriga??es ? Rede Energia S.A. ou a suas empresas controladoras,
> >> controladas ou afiliadas (?empresas relacionadas?) a mensagem expedida
> >> por quem n?o tenha poderes de representa??o. A Rede Energia S.A. e as
> >> empresas relacionadas n?o se responsabilizam por v?rus, amea?as
> >> eletr?nicas ou altera??o do conte?do original da mensagem. ? monitorada
> >> toda mensagem enviada ou recebida utilizando recursos de tecnologia da
> >> informa??o da Rede Energia S.A. Notice: This message was sent through
> >> Rede Energia S.A. information technology resources and may contain
> >> confidential or privileged information. If received by mistake, please
> >> reply to the sender, eliminate and do not disclose, copy or use this
> >> message or attached documents. Neither Rede Energia S.A. nor its
> >> controlling, controlled or affiliated companies (?related companies?)
> >> shall be bound by any message sent by a person not having legal
> >> authority to represent them. Rede Energia S.A. and the related companies
> >> shall not be liable for the existence of virus, electronic threat or
> >> change in the original content of the message. Every message sent or
> >> received through Rede Energia S.A. information technology resources is
> >> monitored.
> >>
> >>
> >> ------------------------------------------------------------------------------
> >> Monitor your physical, virtual and cloud infrastructure from a single
> >> web console. Get in-depth insight into apps, servers, databases, vmware,
> >> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> >> Pricing starts from $795 for 25 servers or applications!
> >>http://p.sf.net/sfu/zoho_dev2dev_nov
> >>
> >>
> >>
> >> _______________________________________________
> >> Ejbca-develop mailing list
> >> Ejb...@li...
> >>https://lists.sourceforge.net/lists/listinfo/ejbca-develop
> >>
> >
> >
> >
> >
> > ------------------------------
> >
> > Message: 2
> > Date: Fri, 23 Nov 2012 01:18:49 +0100
> > From: Hans Witvliet <hw...@a-...>
> > Subject: [Ejbca-develop] some steps acomplished..
> > To: ejb...@li...
> > Message-ID: <135...@t4...>
> > Content-Type: text/plain
> >
> > Hi all,
> >
> > some steps accomplished, but new challenges to meet.
> >
> > Trying not to change too many variables at each step..
> > afaicr, the website says that 3.11.x should work with
> >
> >
> > So at my next step i'm trying to get ejbca-3.11 working with:
> > apache-ant-1.8.1-bin.zip
> > ejbca_3_11_5.zip
> > jboss-5.1.0.GA-jdk6.zip
> > jce_policy-6.zip
> > jdk-6u20-linux-i586.bin
> > mysql-connector-java-5.1.13.zip
> >
> > However, during ant clean it complains:
> >
> > Exception in thread "main" java.lang.NoClassDefFoundError:
> > org/apache/tools/ant/launch/Launcher
> > Caused by: java.lang.ClassNotFoundException:
> > org.apache.tools.ant.launch.Launcher
> > at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
> > at java.security.AccessController.doPrivileged(Native Method)
> > at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
> > at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
> > at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
> > Could not find the main class: org.apache.tools.ant.launch.Launcher.
> > Program will exit.
> >
> >
> > The distro has a newer jdk available, but the error reains.
> > # zypper search jdk
> > "java-1_7_0-openjdk Java runtime environment based on OpenJDK 7 and
> > IcedTea 7"
> >
> > So, what (url please) JDK/JCE-binary package do you recommend to go
> > along with JBoss5?
> >
> > Oracle site doesn't make me any wiser ...
> >
> > hans
> >
> >
> >
> >
> >
> > ------------------------------
> >
> > ------------------------------------------------------------------------------
> > Monitor your physical, virtual and cloud infrastructure from a single
> > web console. Get in-depth insight into apps, servers, databases, vmware,
> > SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> > Pricing starts from $795 for 25 servers or applications!
> > http://p.sf.net/sfu/zoho_dev2dev_nov
> >
> > ------------------------------
> >
> > _______________________________________________
> > Ejbca-develop mailing list
> > Ejb...@li...
> > https://lists.sourceforge.net/lists/listinfo/ejbca-develop
> >
> >
> > End of Ejbca-develop Digest, Vol 78, Issue 3
> > ********************************************
> >
> >
> > ------------------------------------------------------------------------------
> > Monitor your physical, virtual and cloud infrastructure from a single
> > web console. Get in-depth insight into apps, servers, databases, vmware,
> > SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> > Pricing starts from $795 for 25 servers or applications!
> > http://p.sf.net/sfu/zoho_dev2dev_nov
> >
> >
> >
> > _______________________________________________
> > Ejbca-develop mailing list
> > Ejb...@li...
> > https://lists.sourceforge.net/lists/listinfo/ejbca-develop
> >
>
>
>
>
> ------------------------------
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
> ------------------------------
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
>
> End of Ejbca-develop Digest, Vol 78, Issue 6
> ********************************************
>
> ------------------------------------------------------------------------------
>
> Monitor your physical, virtual and cloud infrastructure from a single
>
> web console. Get in-depth insight into apps, servers, databases, vmware,
>
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>
> Pricing starts from $795 for 25 servers or applications!
>
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
> _______________________________________________
>
> Ejbca-develop mailing list
>
> Ejb...@li...
>
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
>
>
> ------------------------------------------------------------------------------
> Keep yourself connected to Go Parallel:
> INSIGHTS What's next for parallel hardware, programming and related areas?
> Interviews and blogs by thought leaders keep you ahead of the curve.
> http://goparallel.sourceforge.net
>
>
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
|
|
From: Marcos F. <mar...@ho...> - 2012-11-28 21:26:42
|
I was doing like this:
I’ve a Project that will do some operations from EJBCA using JSF pages.
I created some packages to hold my classes like certificate.model, certificate.controler, certificate.bean, and some others.
In the certificate.model, I created the CertificateModel class, that hold the operations about creation of user and certificates, using the interface CertificateRequestSession. All here works fine in a java aplication, but not in JSF.
I studied JSF in the University, but nothing to how use some API inside the project. So is from this all of my questions about this type of implementation.
I tryed a lot to create a Web Service, using Apache Axis2, but i got a port conflict when the server goes UP, even if I change the port on configurations XML.
So if you can gimme a hand, I will be a lot of pleased with you.
Thanks
De: Tomas Gustavsson
Enviado: 28 de novembro de 2012 07:13
Para: ejb...@li..., Marcos Fontana
Assunto: RE: [Ejbca-develop] Error NoClassDefFoundError
RE: [Ejbca-develop] Error NoClassDefFoundError
perhaps you can explain how you project looks like. It's hard to guess what your jar and class files look like.
Packaging EJBCA classes into war files is nothing strange and has been done before.
Cheers,
Tomas
-----Original message-----
From: Marcos Fontana <mar...@ho...>
Sent: Monday 26th November 2012 12:58
To: ejb...@li...
Subject: Re: [Ejbca-develop] Error NoClassDefFoundError
So, where shoud i look to find the right places to put the jars in the aplication server?
--------------------------------------------------------------------------------------------------------------------------------------
Application server class loaded works differently. You have to pack
things correctly, and place external jar files in correct places.
On 11/26/2012 11:58 AM, Marcos Fontana wrote:
> Hi Tomas,
> In the test class that worked fine, the classes are in the default
> package. In the real aplication, the class is in certificate.model.
> I done everything the same, even the imports. I never done nothing in
> the class path of war file, even in the test case.
>
> --------------------------------------------------------------------------------------------------------------------------------------
> Hi,
>
> How do you package your application? It seems to me that the missing
> class is not included in the classpath of your war file.
>
> Cheers,
> Tomas
>
> On 11/22/2012 08:00 PM, Marcos Fontana wrote:
>> Enviado do Email do Windows
>> *De:* Marcos Paulo Fontana
>> *Enviado:* ?22? de ?novembro? de ?2012 ?16?:?57
>> *Para:* mar...@ho...
>> *Assunto:* ejb...@li...
>>
>> Hi,
>>
>> When I?m trying to create a certificate directly on the main in java,
>> like following code, I can do it normaly, the user and certificate are
>> created well.
>>
>> *public**static**void*main(String[] args) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException, SecurityException, IOException,
>> CertificateEncodingException {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> CertificateRequestSession teste =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> String username = "yMariano";
>>
>> String password = "a1b2c3";
>>
>> String DN = "E=y...@ho...,CN=Yara
>> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
>>
>> *int*caid = 1963139164;
>>
>> String email = "yar...@ho...";
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid);
>>
>> userdata.setEmail(email);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> teste.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> }
>>
>> }
>>
>> So I implemented all that in a JSF page and tryed to run it, like i done
>> before, but got this error:
>>
>> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
>> org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,853 WARNING
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: javax.faces.el.EvaluationException:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> ... 27 more
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,855 SEVERE
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View ID:
>> /cadastroProfile.jsp) Exception thrown during phase execution:
>> javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
>>
>> 2012-11-22 16:45:01,856 ERROR
>> [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
>> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
>> Servlet threw exception
>>
>> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Whith the following code, that i guess is all right:
>>
>> *public*String emitirCertificado(String username, String password,
>> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException
>>
>> {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> ProfileBean pBean = *new*ProfileBean();
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> CertificateRequestSession criaCert =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> *int*caid;
>>
>> *if*(tipoUsuario == 1)
>>
>> {
>>
>> DN = DN + "Alunos";
>>
>> caid = 1963139164; //CAID _Alunos_
>>
>> }*else**if*(tipoUsuario == 2)
>>
>> {
>>
>> DN = DN + "Professores";
>>
>> caid = 1134085357; //CAID _Professores_
>>
>> }*else*
>>
>> DN = DN + "Administrativo";
>>
>> caid = 1911414444; //CAID _Administrativo_
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid); //ID CA _que_ _assina_.
>>
>> userdata.setEmail(E);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> criaCert.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> pBean.setMensagem("Profile e certificado criados com Sucesso");
>>
>> *return*"sucesso";
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso servidores.
>> Tente novamente!");
>>
>> *return*"erro";
>>
>> }
>>
>> }
>>
>> ------------------------------------------------------------------------
>>
>> Nenhum v?rus encontrado nessa mensagem.
>> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> <http://www.avgbrasil.com.br>
>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>> Lan?amento: 11/20/12
>>
>> ------------------------------------------------------------------------
>>
>> Nenhum v?rus encontrado nessa mensagem.
>> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> <http://www.avgbrasil.com.br>
>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>> Lan?amento: 11/20/12
>>
>> Aviso: Mensagem enviada com recursos de tecnologia da informa??o da Rede
>> Energia S.A., podendo conter informa??o confidencial ou privilegiada. Se
>> recebida por engano, favor devolv?-la ao remetente e elimin?-la, n?o a
>> divulgando, copiando ou utilizando-a ou documentos a ela anexados. N?o
>> gera obriga??es ? Rede Energia S.A. ou a suas empresas controladoras,
>> controladas ou afiliadas (?empresas relacionadas?) a mensagem expedida
>> por quem n?o tenha poderes de representa??o. A Rede Energia S.A. e as
>> empresas relacionadas n?o se responsabilizam por v?rus, amea?as
>> eletr?nicas ou altera??o do conte?do original da mensagem. ? monitorada
>> toda mensagem enviada ou recebida utilizando recursos de tecnologia da
>> informa??o da Rede Energia S.A. Notice: This message was sent through
>> Rede Energia S.A. information technology resources and may contain
>> confidential or privileged information. If received by mistake, please
>> reply to the sender, eliminate and do not disclose, copy or use this
>> message or attached documents. Neither Rede Energia S.A. nor its
>> controlling, controlled or affiliated companies (?related companies?)
>> shall be bound by any message sent by a person not having legal
>> authority to represent them. Rede Energia S.A. and the related companies
>> shall not be liable for the existence of virus, electronic threat or
>> change in the original content of the message. Every message sent or
>> received through Rede Energia S.A. information technology resources is
>> monitored.
>>
>>
>> ------------------------------------------------------------------------------
>> Monitor your physical, virtual and cloud infrastructure from a single
>> web console. Get in-depth insight into apps, servers, databases, vmware,
>> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>> Pricing starts from $795 for 25 servers or applications!
>>http://p.sf.net/sfu/zoho_dev2dev_nov
>>
>>
>>
>> _______________________________________________
>> Ejbca-develop mailing list
>> Ejb...@li...
>>https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>>
>
>
>
>
> ------------------------------
>
> Message: 2
> Date: Fri, 23 Nov 2012 01:18:49 +0100
> From: Hans Witvliet <hw...@a-...>
> Subject: [Ejbca-develop] some steps acomplished..
> To: ejb...@li...
> Message-ID: <135...@t4...>
> Content-Type: text/plain
>
> Hi all,
>
> some steps accomplished, but new challenges to meet.
>
> Trying not to change too many variables at each step..
> afaicr, the website says that 3.11.x should work with
>
>
> So at my next step i'm trying to get ejbca-3.11 working with:
> apache-ant-1.8.1-bin.zip
> ejbca_3_11_5.zip
> jboss-5.1.0.GA-jdk6.zip
> jce_policy-6.zip
> jdk-6u20-linux-i586.bin
> mysql-connector-java-5.1.13.zip
>
> However, during ant clean it complains:
>
> Exception in thread "main" java.lang.NoClassDefFoundError:
> org/apache/tools/ant/launch/Launcher
> Caused by: java.lang.ClassNotFoundException:
> org.apache.tools.ant.launch.Launcher
> at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
> Could not find the main class: org.apache.tools.ant.launch.Launcher.
> Program will exit.
>
>
> The distro has a newer jdk available, but the error reains.
> # zypper search jdk
> "java-1_7_0-openjdk Java runtime environment based on OpenJDK 7 and
> IcedTea 7"
>
> So, what (url please) JDK/JCE-binary package do you recommend to go
> along with JBoss5?
>
> Oracle site doesn't make me any wiser ...
>
> hans
>
>
>
>
>
> ------------------------------
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
> ------------------------------
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
>
> End of Ejbca-develop Digest, Vol 78, Issue 3
> ********************************************
>
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
>
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
------------------------------
------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
------------------------------
_______________________________________________
Ejbca-develop mailing list
Ejb...@li...
https://lists.sourceforge.net/lists/listinfo/ejbca-develop
End of Ejbca-develop Digest, Vol 78, Issue 6
********************************************
------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
Ejbca-develop mailing list
Ejb...@li...
https://lists.sourceforge.net/lists/listinfo/ejbca-develop |
|
From: Tomas G. <to...@pr...> - 2012-11-28 09:12:07
|
perhaps you can explain how you project looks like. It's hard to guess what your jar and class files look like.
Packaging EJBCA classes into war files is nothing strange and has been done before.
Cheers,
Tomas
-----Original message-----
From: Marcos Fontana <mar...@ho...>
Sent: Monday 26th November 2012 12:58
To: ejb...@li...
Subject: Re: [Ejbca-develop] Error NoClassDefFoundError
So, where shoud i look to find the right places to put the jars in the aplication server?
--------------------------------------------------------------------------------------------------------------------------------------
Application server class loaded works differently. You have to pack
things correctly, and place external jar files in correct places.
On 11/26/2012 11:58 AM, Marcos Fontana wrote:
> Hi Tomas,
> In the test class that worked fine, the classes are in the default
> package. In the real aplication, the class is in certificate.model.
> I done everything the same, even the imports. I never done nothing in
> the class path of war file, even in the test case.
>
> --------------------------------------------------------------------------------------------------------------------------------------
> Hi,
>
> How do you package your application? It seems to me that the missing
> class is not included in the classpath of your war file.
>
> Cheers,
> Tomas
>
> On 11/22/2012 08:00 PM, Marcos Fontana wrote:
>> Enviado do Email do Windows
>> *De:* Marcos Paulo Fontana
>> *Enviado:* ?22? de ?novembro? de ?2012 ?16?:?57
>> *Para:* mar...@ho...
>> *Assunto:* ejb...@li...
>>
>> Hi,
>>
>> When I?m trying to create a certificate directly on the main in java,
>> like following code, I can do it normaly, the user and certificate are
>> created well.
>>
>> *public**static**void*main(String[] args) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException, SecurityException, IOException,
>> CertificateEncodingException {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> CertificateRequestSession teste =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> String username = "yMariano";
>>
>> String password = "a1b2c3";
>>
>> String DN = "E=y...@ho...,CN=Yara
>> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
>>
>> *int*caid = 1963139164;
>>
>> String email = "yar...@ho...";
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid);
>>
>> userdata.setEmail(email);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> teste.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> }
>>
>> }
>>
>> So I implemented all that in a JSF page and tryed to run it, like i done
>> before, but got this error:
>>
>> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
>> org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,853 WARNING
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: javax.faces.el.EvaluationException:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> ... 27 more
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,855 SEVERE
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View ID:
>> /cadastroProfile.jsp) Exception thrown during phase execution:
>> javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
>>
>> 2012-11-22 16:45:01,856 ERROR
>> [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
>> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
>> Servlet threw exception
>>
>> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Whith the following code, that i guess is all right:
>>
>> *public*String emitirCertificado(String username, String password,
>> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException
>>
>> {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> ProfileBean pBean = *new*ProfileBean();
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> CertificateRequestSession criaCert =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> *int*caid;
>>
>> *if*(tipoUsuario == 1)
>>
>> {
>>
>> DN = DN + "Alunos";
>>
>> caid = 1963139164; //CAID _Alunos_
>>
>> }*else**if*(tipoUsuario == 2)
>>
>> {
>>
>> DN = DN + "Professores";
>>
>> caid = 1134085357; //CAID _Professores_
>>
>> }*else*
>>
>> DN = DN + "Administrativo";
>>
>> caid = 1911414444; //CAID _Administrativo_
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid); //ID CA _que_ _assina_.
>>
>> userdata.setEmail(E);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> criaCert.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> pBean.setMensagem("Profile e certificado criados com Sucesso");
>>
>> *return*"sucesso";
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso servidores.
>> Tente novamente!");
>>
>> *return*"erro";
>>
>> }
>>
>> }
>>
>> ------------------------------------------------------------------------
>>
>> Nenhum v?rus encontrado nessa mensagem.
>> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> <http://www.avgbrasil.com.br>
>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>> Lan?amento: 11/20/12
>>
>> ------------------------------------------------------------------------
>>
>> Nenhum v?rus encontrado nessa mensagem.
>> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> <http://www.avgbrasil.com.br>
>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>> Lan?amento: 11/20/12
>>
>> Aviso: Mensagem enviada com recursos de tecnologia da informa??o da Rede
>> Energia S.A., podendo conter informa??o confidencial ou privilegiada. Se
>> recebida por engano, favor devolv?-la ao remetente e elimin?-la, n?o a
>> divulgando, copiando ou utilizando-a ou documentos a ela anexados. N?o
>> gera obriga??es ? Rede Energia S.A. ou a suas empresas controladoras,
>> controladas ou afiliadas (?empresas relacionadas?) a mensagem expedida
>> por quem n?o tenha poderes de representa??o. A Rede Energia S.A. e as
>> empresas relacionadas n?o se responsabilizam por v?rus, amea?as
>> eletr?nicas ou altera??o do conte?do original da mensagem. ? monitorada
>> toda mensagem enviada ou recebida utilizando recursos de tecnologia da
>> informa??o da Rede Energia S.A. Notice: This message was sent through
>> Rede Energia S.A. information technology resources and may contain
>> confidential or privileged information. If received by mistake, please
>> reply to the sender, eliminate and do not disclose, copy or use this
>> message or attached documents. Neither Rede Energia S.A. nor its
>> controlling, controlled or affiliated companies (?related companies?)
>> shall be bound by any message sent by a person not having legal
>> authority to represent them. Rede Energia S.A. and the related companies
>> shall not be liable for the existence of virus, electronic threat or
>> change in the original content of the message. Every message sent or
>> received through Rede Energia S.A. information technology resources is
>> monitored.
>>
>>
>> ------------------------------------------------------------------------------
>> Monitor your physical, virtual and cloud infrastructure from a single
>> web console. Get in-depth insight into apps, servers, databases, vmware,
>> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>> Pricing starts from $795 for 25 servers or applications!
>>http://p.sf.net/sfu/zoho_dev2dev_nov
>>
>>
>>
>> _______________________________________________
>> Ejbca-develop mailing list
>> Ejb...@li...
>>https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>>
>
>
>
>
> ------------------------------
>
> Message: 2
> Date: Fri, 23 Nov 2012 01:18:49 +0100
> From: Hans Witvliet <hw...@a-...>
> Subject: [Ejbca-develop] some steps acomplished..
> To: ejb...@li...
> Message-ID: <135...@t4...>
> Content-Type: text/plain
>
> Hi all,
>
> some steps accomplished, but new challenges to meet.
>
> Trying not to change too many variables at each step..
> afaicr, the website says that 3.11.x should work with
>
>
> So at my next step i'm trying to get ejbca-3.11 working with:
> apache-ant-1.8.1-bin.zip
> ejbca_3_11_5.zip
> jboss-5.1.0.GA-jdk6.zip
> jce_policy-6.zip
> jdk-6u20-linux-i586.bin
> mysql-connector-java-5.1.13.zip
>
> However, during ant clean it complains:
>
> Exception in thread "main" java.lang.NoClassDefFoundError:
> org/apache/tools/ant/launch/Launcher
> Caused by: java.lang.ClassNotFoundException:
> org.apache.tools.ant.launch.Launcher
> at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
> Could not find the main class: org.apache.tools.ant.launch.Launcher.
> Program will exit.
>
>
> The distro has a newer jdk available, but the error reains.
> # zypper search jdk
> "java-1_7_0-openjdk Java runtime environment based on OpenJDK 7 and
> IcedTea 7"
>
> So, what (url please) JDK/JCE-binary package do you recommend to go
> along with JBoss5?
>
> Oracle site doesn't make me any wiser ...
>
> hans
>
>
>
>
>
> ------------------------------
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
> ------------------------------
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
>
> End of Ejbca-develop Digest, Vol 78, Issue 3
> ********************************************
>
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
>
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
------------------------------
------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
------------------------------
_______________________________________________
Ejbca-develop mailing list
Ejb...@li...
https://lists.sourceforge.net/lists/listinfo/ejbca-develop
End of Ejbca-develop Digest, Vol 78, Issue 6
********************************************
------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
Ejbca-develop mailing list
Ejb...@li...
https://lists.sourceforge.net/lists/listinfo/ejbca-develop
|
|
From: ejbca-support <ejb...@pr...> - 2012-11-28 06:03:25
|
On 2012-11-27 22:29, Marcos Fontana wrote:
>
> Hi Tomas,
>
> I read a lot of guides of JSF, put the jar’s in the right places,I saw a lot of questions in the fóruns with same type of error’s and I'm still getting this error:
>
> Even my teacher does not know why this still happens.
If you in an external WAR refer to classes inside of the EJBCA EAR you will run into problems.
It is not JSF that is causing the exception, it is a reference to EJBCA.
I would look into the EJBCA "plugin" extension mechanism or any other method that
put custom code inside of the EJBCA EAR.
Another solution is to use the external interfaces of EJBCA like Web Services.
If your goal is making an RA that is probably a better idea since you typically
want to limit EJBCA exposure.
Anders
>
>
>
> 2012-11-27 16:10:15,191 SEVERE [javax.enterprise.resource.webcontainer.jsf.application] (http-0.0.0.0-8080-1) java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>
> at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>
> at javax.faces.component.UICommand.broadcast(UICommand.java:387)
>
> at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>
> at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>
> at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>
> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>
> at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>
> at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>
> at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>
> at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>
> at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>
> at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>
> at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>
> at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>
> at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>
> at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>
> at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>
> at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>
> at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>
> at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>
> at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>
> at java.lang.Thread.run(Thread.java:662)
>
> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>
> at certificate.model.ModelProfile.cadastrarProfile(ModelProfile.java:30)
>
> at certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>
> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>
> 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:597)
>
> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>
> at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>
> at org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>
> at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>
> ... 28 more
>
> Caused by: java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from BaseClassLoader@45b3aac6{VFSClassLoaderPolicy@1690d0ea{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/ domain=ClassLoaderDomain@14eebce6{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/ parentPolicy=AFTER_BUT_JAVA_BEFORE parent=ClassLoaderDomain@e425743{DefaultDomain}} roots=[MemoryContextHandler@2105785912[path= context=vfsmemory://3j001-lw2f3e-ha1c633l-1-ha1c6m2s-2b real=vfsmemory://3j001-lw2f3e-ha1c633l-1-ha1c6m2s-2b], ZipEntryHandler@1413320424[path=CertificadosDigitais.war/WEB-INF/classes context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/ real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]] delegates=null exported=[certificate.controler, certificate.bean, certificate.model, certificate.interfaces,
> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>
> at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>
> at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>
> ... 40 more
>
> 2012-11-27 16:10:15,211 WARNING [javax.enterprise.resource.webcontainer.jsf.lifecycle] (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> javax.faces.FacesException: #{profileBean.cadastrarProfile}: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>
> at javax.faces.component.UICommand.broadcast(UICommand.java:387)
>
> at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>
> at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>
> at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>
> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>
> at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>
> at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationF
>
>
> --------------------------------------------------------------------------------------------------------------------------------------
> Application server class loaded works differently. You have to pack
> things correctly, and place external jar files in correct places.
>
> On 11/26/2012 11:58 AM, Marcos Fontana wrote:
>> Hi Tomas,
>> In the test class that worked fine, the classes are in the default
>> package. In the real aplication, the class is in certificate.model.
>> I done everything the same, even the imports. I never done nothing in
>> the class path of war file, even in the test case.
>>
>> --------------------------------------------------------------------------------------------------------------------------------------
>> Hi,
>>
>> How do you package your application? It seems to me that the missing
>> class is not included in the classpath of your war file.
>>
>> Cheers,
>> Tomas
>>
>> On 11/22/2012 08:00 PM, Marcos Fontana wrote:
>>> Enviado do Email do Windows
>>> *De:* Marcos Paulo Fontana
>>> *Enviado:* ?22? de ?novembro? de ?2012 ?16?:?57
>>> *Para:* mar...@ho...
>>> *Assunto:* ejb...@li...
>>>
>>> Hi,
>>>
>>> When I?m trying to create a certificate directly on the main in java,
>>> like following code, I can do it normaly, the user and certificate are
>>> created well.
>>>
>>> *public**static**void*main(String[] args) *throws*InvalidKeyException,
>>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>>> InvalidAlgorithmParameterException, SecurityException, IOException,
>>> CertificateEncodingException {
>>>
>>>
>>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>>
>>> CertificateRequestSession teste =
>>> InterfaceCache./getCertficateRequestSession/();
>>>
>>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>>
>>> UserDataVO userdata = *new*UserDataVO();
>>>
>>> String username = "yMariano";
>>>
>>> String password = "a1b2c3";
>>>
>>> String DN = "E=y...@ho...,CN=Yara
>>> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
>>>
>>> *int*caid = 1963139164;
>>>
>>> String email = "yar...@ho...";
>>>
>>> userdata.setUsername(username);
>>>
>>> userdata.setPassword(password);
>>>
>>> userdata.setDN(DN);
>>>
>>> userdata.setCAId(caid);
>>>
>>> userdata.setEmail(email);
>>>
>>> userdata.setType(SecConst./USER_ENDUSER/);
>>>
>>> userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>>
>>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>>
>>>
>>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>>
>>>
>>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>>
>>> String pkcs10 =
>>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>>> password)));
>>>
>>> *try*{
>>>
>>> teste.processCertReq(admin, userdata, pkcs10,
>>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>>
>>> } *catch*(Exception ex) {
>>>
>>> // *TODO*Auto-generated catch block
>>>
>>> }
>>>
>>> }
>>>
>>> So I implemented all that in a JSF page and tryed to run it, like i done
>>> before, but got this error:
>>>
>>> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
>>> org/ejbca/util/InterfaceCache
>>>
>>> at
>>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>>
>>> at
>>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>>
>>> at
>>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>>
>>> at
>>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>>
>>> at
>>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>>
>>> at
>>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>>
>>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>>
>>> at
>>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>>
>>> at
>>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>>
>>> at
>>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>>
>>> at
>>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>>
>>> at
>>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>>
>>> at
>>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>>
>>> at
>>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>>
>>> at
>>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>>
>>> at
>>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>>
>>> at
>>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>>
>>> at
>>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>>
>>> at
>>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>>
>>> at
>>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>>
>>> at
>>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>>
>>> at
>>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>>
>>> at java.lang.Thread.run(Unknown Source)
>>>
>>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>>
>>> at
>>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>>
>>> at
>>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>>
>>> at
>>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>>
>>> at
>>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>>
>>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>>
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>>> Method)
>>>
>>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>>> Source)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>>
>>> at java.lang.reflect.Method.invoke(Unknown Source)
>>>
>>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>>
>>> at
>>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>>
>>> at
>>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>>
>>> at
>>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>>
>>> ... 28 more
>>>
>>> Caused by: java.lang.ClassNotFoundException:
>>> org.ejbca.util.InterfaceCache from
>>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>>> roots=[MemoryContextHandler@242065626[path=
>>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>>> delegates=null exported=[certificate.controler, certificate.bean,
>>> certificate.model, certificate.interfaces, certificate.facade,
>>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>>
>>> at
>>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>>
>>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>>
>>> ... 41 more
>>>
>>> 2012-11-22 16:45:01,853 WARNING
>>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>>> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
>>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>>
>>> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
>>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>>
>>> at
>>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>>>
>>> at
>>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>>
>>> at
>>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>>
>>> at
>>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>>
>>> at
>>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>>
>>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>>
>>> at
>>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>>
>>> at
>>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>>
>>> at
>>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>>
>>> at
>>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>>
>>> at
>>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>>
>>> at
>>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>>
>>> at
>>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>>
>>> at
>>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>>
>>> at
>>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>>
>>> at
>>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>>
>>> at
>>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>>
>>> at
>>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>>
>>> at
>>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>>
>>> at
>>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>>
>>> at
>>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>>
>>> at java.lang.Thread.run(Unknown Source)
>>>
>>> Caused by: javax.faces.el.EvaluationException:
>>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>>
>>> at
>>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>>
>>> at
>>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>>
>>> ... 27 more
>>>
>>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>>
>>> at
>>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>>
>>> at
>>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>>
>>> at
>>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>>
>>> at
>>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>>
>>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>>
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>>> Method)
>>>
>>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>>> Source)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>>
>>> at java.lang.reflect.Method.invoke(Unknown Source)
>>>
>>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>>
>>> at
>>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>>
>>> at
>>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>>
>>> at
>>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>>
>>> ... 28 more
>>>
>>> Caused by: java.lang.ClassNotFoundException:
>>> org.ejbca.util.InterfaceCache from
>>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>>> roots=[MemoryContextHandler@242065626[path=
>>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>>> delegates=null exported=[certificate.controler, certificate.bean,
>>> certificate.model, certificate.interfaces, certificate.facade,
>>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>>
>>> at
>>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>>
>>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>>
>>> ... 41 more
>>>
>>> 2012-11-22 16:45:01,855 SEVERE
>>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>>> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View ID:
>>> /cadastroProfile.jsp) Exception thrown during phase execution:
>>> javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
>>>
>>> 2012-11-22 16:45:01,856 ERROR
>>> [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
>>> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
>>> Servlet threw exception
>>>
>>> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
>>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>>> roots=[MemoryContextHandler@242065626[path=
>>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>>> delegates=null exported=[certificate.controler, certificate.bean,
>>> certificate.model, certificate.interfaces, certificate.facade,
>>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>>
>>> at
>>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>>
>>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>>
>>> at
>>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>>
>>> at
>>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>>
>>> at
>>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>>
>>> at
>>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>>
>>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>>
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>>> Method)
>>>
>>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>>> Source)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>>
>>> at java.lang.reflect.Method.invoke(Unknown Source)
>>>
>>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>>
>>> at
>>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>>
>>> at
>>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>>
>>> at
>>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>>
>>> at
>>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>>
>>> at
>>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>>
>>> at
>>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>>
>>> at
>>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>>
>>> at
>>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>>
>>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>>
>>> at
>>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>>
>>> at
>>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>>
>>> at
>>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>>
>>> at
>>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>>
>>> at
>>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>>
>>> at
>>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>>
>>> at
>>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>>
>>> at
>>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>>
>>> at
>>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>>
>>> at
>>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>>
>>> at
>>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>>
>>> at
>>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>>
>>> at
>>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>>
>>> at
>>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>>
>>> at
>>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>>
>>> at
>>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>>
>>> at java.lang.Thread.run(Unknown Source)
>>>
>>> Whith the following code, that i guess is all right:
>>>
>>> *public*String emitirCertificado(String username, String password,
>>> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
>>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>>> InvalidAlgorithmParameterException
>>>
>>> {
>>>
>>>
>>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>>
>>> ProfileBean pBean = *new*ProfileBean();
>>>
>>> UserDataVO userdata = *new*UserDataVO();
>>>
>>> CertificateRequestSession criaCert =
>>> InterfaceCache./getCertficateRequestSession/();
>>>
>>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>>
>>> *int*caid;
>>>
>>> *if*(tipoUsuario == 1)
>>>
>>> {
>>>
>>> DN = DN + "Alunos";
>>>
>>> caid = 1963139164; //CAID _Alunos_
>>>
>>> }*else**if*(tipoUsuario == 2)
>>>
>>> {
>>>
>>> DN = DN + "Professores";
>>>
>>> caid = 1134085357; //CAID _Professores_
>>>
>>> }*else*
>>>
>>> DN = DN + "Administrativo";
>>>
>>> caid = 1911414444; //CAID _Administrativo_
>>>
>>> userdata.setUsername(username);
>>>
>>> userdata.setPassword(password);
>>>
>>> userdata.setDN(DN);
>>>
>>> userdata.setCAId(caid); //ID CA _que_ _assina_.
>>>
>>> userdata.setEmail(E);
>>>
>>> userdata.setType(SecConst./USER_ENDUSER/);
>>>
>>> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>>
>>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>>
>>>
>>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>>
>>>
>>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>>
>>> String pkcs10 =
>>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>>> password)));
>>>
>>> *try*{
>>>
>>> criaCert.processCertReq(admin, userdata, pkcs10,
>>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>>
>>> pBean.setMensagem("Profile e certificado criados com Sucesso");
>>>
>>> *return*"sucesso";
>>>
>>> } *catch*(Exception ex) {
>>>
>>> // *TODO*Auto-generated catch block
>>>
>>> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso servidores.
>>> Tente novamente!");
>>>
>>> *return*"erro";
>>>
>>> }
>>>
>>> }
>>>
>>>
>
>
>
>
>
> ------------------------------------------------------------------------------
> Keep yourself connected to Go Parallel:
> DESIGN Expert tips on starting your parallel project right.
> http://goparallel.sourceforge.net
>
>
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
|
|
From: Marcos F. <mar...@ho...> - 2012-11-27 21:29:56
|
Hi Tomas,
I read a lot of guides of JSF, put the jar’s in the right places,I saw a lot of questions in the fóruns with same type of error’s and I'm still getting this error:
Even my teacher does not know why this still happens.
2012-11-27 16:10:15,191 SEVERE [javax.enterprise.resource.webcontainer.jsf.application] (http-0.0.0.0-8080-1) java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
at javax.faces.component.UICommand.broadcast(UICommand.java:387)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
at certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
at certificate.model.ModelProfile.cadastrarProfile(ModelProfile.java:30)
at certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
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:597)
at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
at org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
... 28 more
Caused by: java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from BaseClassLoader@45b3aac6{VFSClassLoaderPolicy@1690d0ea{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/ domain=ClassLoaderDomain@14eebce6{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/ parentPolicy=AFTER_BUT_JAVA_BEFORE parent=ClassLoaderDomain@e425743{DefaultDomain}} roots=[MemoryContextHandler@2105785912[path= context=vfsmemory://3j001-lw2f3e-ha1c633l-1-ha1c6m2s-2b real=vfsmemory://3j001-lw2f3e-ha1c633l-1-ha1c6m2s-2b], ZipEntryHandler@1413320424[path=CertificadosDigitais.war/WEB-INF/classes context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/ real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]] delegates=null exported=[certificate.controler, certificate.bean, certificate.model, certificate.interfaces, certificate.dao] <IMPORT-ALL>NON_EMPTY}}
at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 40 more
2012-11-27 16:10:15,211 WARNING [javax.enterprise.resource.webcontainer.jsf.lifecycle] (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
javax.faces.FacesException: #{profileBean.cadastrarProfile}: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
at javax.faces.component.UICommand.broadcast(UICommand.java:387)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationF
--------------------------------------------------------------------------------------------------------------------------------------
Application server class loaded works differently. You have to pack
things correctly, and place external jar files in correct places.
On 11/26/2012 11:58 AM, Marcos Fontana wrote:
> Hi Tomas,
> In the test class that worked fine, the classes are in the default
> package. In the real aplication, the class is in certificate.model.
> I done everything the same, even the imports. I never done nothing in
> the class path of war file, even in the test case.
>
> --------------------------------------------------------------------------------------------------------------------------------------
> Hi,
>
> How do you package your application? It seems to me that the missing
> class is not included in the classpath of your war file.
>
> Cheers,
> Tomas
>
> On 11/22/2012 08:00 PM, Marcos Fontana wrote:
>> Enviado do Email do Windows
>> *De:* Marcos Paulo Fontana
>> *Enviado:* ?22? de ?novembro? de ?2012 ?16?:?57
>> *Para:* mar...@ho...
>> *Assunto:* ejb...@li...
>>
>> Hi,
>>
>> When I?m trying to create a certificate directly on the main in java,
>> like following code, I can do it normaly, the user and certificate are
>> created well.
>>
>> *public**static**void*main(String[] args) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException, SecurityException, IOException,
>> CertificateEncodingException {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> CertificateRequestSession teste =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> String username = "yMariano";
>>
>> String password = "a1b2c3";
>>
>> String DN = "E=y...@ho...,CN=Yara
>> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
>>
>> *int*caid = 1963139164;
>>
>> String email = "yar...@ho...";
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid);
>>
>> userdata.setEmail(email);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> teste.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> }
>>
>> }
>>
>> So I implemented all that in a JSF page and tryed to run it, like i done
>> before, but got this error:
>>
>> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
>> org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,853 WARNING
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: javax.faces.el.EvaluationException:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> ... 27 more
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,855 SEVERE
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View ID:
>> /cadastroProfile.jsp) Exception thrown during phase execution:
>> javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
>>
>> 2012-11-22 16:45:01,856 ERROR
>> [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
>> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
>> Servlet threw exception
>>
>> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Whith the following code, that i guess is all right:
>>
>> *public*String emitirCertificado(String username, String password,
>> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException
>>
>> {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> ProfileBean pBean = *new*ProfileBean();
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> CertificateRequestSession criaCert =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> *int*caid;
>>
>> *if*(tipoUsuario == 1)
>>
>> {
>>
>> DN = DN + "Alunos";
>>
>> caid = 1963139164; //CAID _Alunos_
>>
>> }*else**if*(tipoUsuario == 2)
>>
>> {
>>
>> DN = DN + "Professores";
>>
>> caid = 1134085357; //CAID _Professores_
>>
>> }*else*
>>
>> DN = DN + "Administrativo";
>>
>> caid = 1911414444; //CAID _Administrativo_
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid); //ID CA _que_ _assina_.
>>
>> userdata.setEmail(E);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> criaCert.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> pBean.setMensagem("Profile e certificado criados com Sucesso");
>>
>> *return*"sucesso";
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso servidores.
>> Tente novamente!");
>>
>> *return*"erro";
>>
>> }
>>
>> }
>>
>> |
|
From: Marcos F. <mar...@ho...> - 2012-11-26 11:55:20
|
So, where shoud i look to find the right places to put the jars in the aplication server?
--------------------------------------------------------------------------------------------------------------------------------------
Application server class loaded works differently. You have to pack
things correctly, and place external jar files in correct places.
On 11/26/2012 11:58 AM, Marcos Fontana wrote:
> Hi Tomas,
> In the test class that worked fine, the classes are in the default
> package. In the real aplication, the class is in certificate.model.
> I done everything the same, even the imports. I never done nothing in
> the class path of war file, even in the test case.
>
> --------------------------------------------------------------------------------------------------------------------------------------
> Hi,
>
> How do you package your application? It seems to me that the missing
> class is not included in the classpath of your war file.
>
> Cheers,
> Tomas
>
> On 11/22/2012 08:00 PM, Marcos Fontana wrote:
>> Enviado do Email do Windows
>> *De:* Marcos Paulo Fontana
>> *Enviado:* ?22? de ?novembro? de ?2012 ?16?:?57
>> *Para:* mar...@ho...
>> *Assunto:* ejb...@li...
>>
>> Hi,
>>
>> When I?m trying to create a certificate directly on the main in java,
>> like following code, I can do it normaly, the user and certificate are
>> created well.
>>
>> *public**static**void*main(String[] args) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException, SecurityException, IOException,
>> CertificateEncodingException {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> CertificateRequestSession teste =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> String username = "yMariano";
>>
>> String password = "a1b2c3";
>>
>> String DN = "E=y...@ho...,CN=Yara
>> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
>>
>> *int*caid = 1963139164;
>>
>> String email = "yar...@ho...";
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid);
>>
>> userdata.setEmail(email);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> teste.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> }
>>
>> }
>>
>> So I implemented all that in a JSF page and tryed to run it, like i done
>> before, but got this error:
>>
>> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
>> org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,853 WARNING
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: javax.faces.el.EvaluationException:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> ... 27 more
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,855 SEVERE
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View ID:
>> /cadastroProfile.jsp) Exception thrown during phase execution:
>> javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
>>
>> 2012-11-22 16:45:01,856 ERROR
>> [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
>> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
>> Servlet threw exception
>>
>> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Whith the following code, that i guess is all right:
>>
>> *public*String emitirCertificado(String username, String password,
>> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException
>>
>> {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> ProfileBean pBean = *new*ProfileBean();
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> CertificateRequestSession criaCert =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> *int*caid;
>>
>> *if*(tipoUsuario == 1)
>>
>> {
>>
>> DN = DN + "Alunos";
>>
>> caid = 1963139164; //CAID _Alunos_
>>
>> }*else**if*(tipoUsuario == 2)
>>
>> {
>>
>> DN = DN + "Professores";
>>
>> caid = 1134085357; //CAID _Professores_
>>
>> }*else*
>>
>> DN = DN + "Administrativo";
>>
>> caid = 1911414444; //CAID _Administrativo_
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid); //ID CA _que_ _assina_.
>>
>> userdata.setEmail(E);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> criaCert.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> pBean.setMensagem("Profile e certificado criados com Sucesso");
>>
>> *return*"sucesso";
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso servidores.
>> Tente novamente!");
>>
>> *return*"erro";
>>
>> }
>>
>> }
>>
>> ------------------------------------------------------------------------
>>
>> Nenhum v?rus encontrado nessa mensagem.
>> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> <http://www.avgbrasil.com.br>
>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>> Lan?amento: 11/20/12
>>
>> ------------------------------------------------------------------------
>>
>> Nenhum v?rus encontrado nessa mensagem.
>> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> <http://www.avgbrasil.com.br>
>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>> Lan?amento: 11/20/12
>>
>> Aviso: Mensagem enviada com recursos de tecnologia da informa??o da Rede
>> Energia S.A., podendo conter informa??o confidencial ou privilegiada. Se
>> recebida por engano, favor devolv?-la ao remetente e elimin?-la, n?o a
>> divulgando, copiando ou utilizando-a ou documentos a ela anexados. N?o
>> gera obriga??es ? Rede Energia S.A. ou a suas empresas controladoras,
>> controladas ou afiliadas (?empresas relacionadas?) a mensagem expedida
>> por quem n?o tenha poderes de representa??o. A Rede Energia S.A. e as
>> empresas relacionadas n?o se responsabilizam por v?rus, amea?as
>> eletr?nicas ou altera??o do conte?do original da mensagem. ? monitorada
>> toda mensagem enviada ou recebida utilizando recursos de tecnologia da
>> informa??o da Rede Energia S.A. Notice: This message was sent through
>> Rede Energia S.A. information technology resources and may contain
>> confidential or privileged information. If received by mistake, please
>> reply to the sender, eliminate and do not disclose, copy or use this
>> message or attached documents. Neither Rede Energia S.A. nor its
>> controlling, controlled or affiliated companies (?related companies?)
>> shall be bound by any message sent by a person not having legal
>> authority to represent them. Rede Energia S.A. and the related companies
>> shall not be liable for the existence of virus, electronic threat or
>> change in the original content of the message. Every message sent or
>> received through Rede Energia S.A. information technology resources is
>> monitored.
>>
>>
>> ------------------------------------------------------------------------------
>> Monitor your physical, virtual and cloud infrastructure from a single
>> web console. Get in-depth insight into apps, servers, databases, vmware,
>> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>> Pricing starts from $795 for 25 servers or applications!
>>http://p.sf.net/sfu/zoho_dev2dev_nov
>>
>>
>>
>> _______________________________________________
>> Ejbca-develop mailing list
>> Ejb...@li...
>>https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>>
>
>
>
>
> ------------------------------
>
> Message: 2
> Date: Fri, 23 Nov 2012 01:18:49 +0100
> From: Hans Witvliet <hw...@a-...>
> Subject: [Ejbca-develop] some steps acomplished..
> To: ejb...@li...
> Message-ID: <135...@t4...>
> Content-Type: text/plain
>
> Hi all,
>
> some steps accomplished, but new challenges to meet.
>
> Trying not to change too many variables at each step..
> afaicr, the website says that 3.11.x should work with
>
>
> So at my next step i'm trying to get ejbca-3.11 working with:
> apache-ant-1.8.1-bin.zip
> ejbca_3_11_5.zip
> jboss-5.1.0.GA-jdk6.zip
> jce_policy-6.zip
> jdk-6u20-linux-i586.bin
> mysql-connector-java-5.1.13.zip
>
> However, during ant clean it complains:
>
> Exception in thread "main" java.lang.NoClassDefFoundError:
> org/apache/tools/ant/launch/Launcher
> Caused by: java.lang.ClassNotFoundException:
> org.apache.tools.ant.launch.Launcher
> at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
> Could not find the main class: org.apache.tools.ant.launch.Launcher.
> Program will exit.
>
>
> The distro has a newer jdk available, but the error reains.
> # zypper search jdk
> "java-1_7_0-openjdk Java runtime environment based on OpenJDK 7 and
> IcedTea 7"
>
> So, what (url please) JDK/JCE-binary package do you recommend to go
> along with JBoss5?
>
> Oracle site doesn't make me any wiser ...
>
> hans
>
>
>
>
>
> ------------------------------
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
> ------------------------------
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
>
> End of Ejbca-develop Digest, Vol 78, Issue 3
> ********************************************
>
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
>
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
------------------------------
------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
------------------------------
_______________________________________________
Ejbca-develop mailing list
Ejb...@li...
https://lists.sourceforge.net/lists/listinfo/ejbca-develop
End of Ejbca-develop Digest, Vol 78, Issue 6
******************************************** |
|
From: Tomas G. <to...@pr...> - 2012-11-26 11:15:21
|
Application server class loaded works differently. You have to pack
things correctly, and place external jar files in correct places.
On 11/26/2012 11:58 AM, Marcos Fontana wrote:
> Hi Tomas,
> In the test class that worked fine, the classes are in the default
> package. In the real aplication, the class is in certificate.model.
> I done everything the same, even the imports. I never done nothing in
> the class path of war file, even in the test case.
>
> --------------------------------------------------------------------------------------------------------------------------------------
> Hi,
>
> How do you package your application? It seems to me that the missing
> class is not included in the classpath of your war file.
>
> Cheers,
> Tomas
>
> On 11/22/2012 08:00 PM, Marcos Fontana wrote:
>> Enviado do Email do Windows
>> *De:* Marcos Paulo Fontana
>> *Enviado:* ?22? de ?novembro? de ?2012 ?16?:?57
>> *Para:* mar...@ho...
>> *Assunto:* ejb...@li...
>>
>> Hi,
>>
>> When I?m trying to create a certificate directly on the main in java,
>> like following code, I can do it normaly, the user and certificate are
>> created well.
>>
>> *public**static**void*main(String[] args) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException, SecurityException, IOException,
>> CertificateEncodingException {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> CertificateRequestSession teste =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> String username = "yMariano";
>>
>> String password = "a1b2c3";
>>
>> String DN = "E=y...@ho...,CN=Yara
>> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
>>
>> *int*caid = 1963139164;
>>
>> String email = "yar...@ho...";
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid);
>>
>> userdata.setEmail(email);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> teste.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> }
>>
>> }
>>
>> So I implemented all that in a JSF page and tryed to run it, like i done
>> before, but got this error:
>>
>> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
>> org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,853 WARNING
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Caused by: javax.faces.el.EvaluationException:
>> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> ... 27 more
>>
>> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> ... 28 more
>>
>> Caused by: java.lang.ClassNotFoundException:
>> org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> ... 41 more
>>
>> 2012-11-22 16:45:01,855 SEVERE
>> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
>> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View ID:
>> /cadastroProfile.jsp) Exception thrown during phase execution:
>> javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
>>
>> 2012-11-22 16:45:01,856 ERROR
>> [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
>> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
>> Servlet threw exception
>>
>> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
>> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
>> parentPolicy=AFTER_BUT_JAVA_BEFORE
>> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
>> roots=[MemoryContextHandler@242065626[path=
>> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
>> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
>> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
>> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
>> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
>> delegates=null exported=[certificate.controler, certificate.bean,
>> certificate.model, certificate.interfaces, certificate.facade,
>> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>>
>> at
>> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>>
>> at java.lang.ClassLoader.loadClass(Unknown Source)
>>
>> at
>> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>>
>> at
>> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>>
>> at
>> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>>
>> at
>> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>>
>> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>>
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>>
>> at java.lang.reflect.Method.invoke(Unknown Source)
>>
>> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>>
>> at
>> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>>
>> at
>> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>>
>> at
>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>>
>> at
>> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>>
>> at
>> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>>
>> at
>> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>>
>> at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>>
>> at
>> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>>
>> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>>
>> at
>> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>>
>> at
>> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>>
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>>
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>>
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>>
>> at
>> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>>
>> at
>> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>>
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>>
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>>
>> at
>> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>>
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>>
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>>
>> at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>>
>> at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>>
>> at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>>
>> at java.lang.Thread.run(Unknown Source)
>>
>> Whith the following code, that i guess is all right:
>>
>> *public*String emitirCertificado(String username, String password,
>> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
>> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
>> InvalidAlgorithmParameterException
>>
>> {
>>
>>
>> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>>
>> ProfileBean pBean = *new*ProfileBean();
>>
>> UserDataVO userdata = *new*UserDataVO();
>>
>> CertificateRequestSession criaCert =
>> InterfaceCache./getCertficateRequestSession/();
>>
>> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>>
>> *int*caid;
>>
>> *if*(tipoUsuario == 1)
>>
>> {
>>
>> DN = DN + "Alunos";
>>
>> caid = 1963139164; //CAID _Alunos_
>>
>> }*else**if*(tipoUsuario == 2)
>>
>> {
>>
>> DN = DN + "Professores";
>>
>> caid = 1134085357; //CAID _Professores_
>>
>> }*else*
>>
>> DN = DN + "Administrativo";
>>
>> caid = 1911414444; //CAID _Administrativo_
>>
>> userdata.setUsername(username);
>>
>> userdata.setPassword(password);
>>
>> userdata.setDN(DN);
>>
>> userdata.setCAId(caid); //ID CA _que_ _assina_.
>>
>> userdata.setEmail(E);
>>
>> userdata.setType(SecConst./USER_ENDUSER/);
>>
>> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>>
>> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>>
>>
>> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>>
>>
>> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>>
>> String pkcs10 =
>> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
>> password)));
>>
>> *try*{
>>
>> criaCert.processCertReq(admin, userdata, pkcs10,
>> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>>
>> pBean.setMensagem("Profile e certificado criados com Sucesso");
>>
>> *return*"sucesso";
>>
>> } *catch*(Exception ex) {
>>
>> // *TODO*Auto-generated catch block
>>
>> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso servidores.
>> Tente novamente!");
>>
>> *return*"erro";
>>
>> }
>>
>> }
>>
>> ------------------------------------------------------------------------
>>
>> Nenhum v?rus encontrado nessa mensagem.
>> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> <http://www.avgbrasil.com.br>
>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>> Lan?amento: 11/20/12
>>
>> ------------------------------------------------------------------------
>>
>> Nenhum v?rus encontrado nessa mensagem.
>> Verificado por AVG -www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> <http://www.avgbrasil.com.br>
>> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
>> Lan?amento: 11/20/12
>>
>> Aviso: Mensagem enviada com recursos de tecnologia da informa??o da Rede
>> Energia S.A., podendo conter informa??o confidencial ou privilegiada. Se
>> recebida por engano, favor devolv?-la ao remetente e elimin?-la, n?o a
>> divulgando, copiando ou utilizando-a ou documentos a ela anexados. N?o
>> gera obriga??es ? Rede Energia S.A. ou a suas empresas controladoras,
>> controladas ou afiliadas (?empresas relacionadas?) a mensagem expedida
>> por quem n?o tenha poderes de representa??o. A Rede Energia S.A. e as
>> empresas relacionadas n?o se responsabilizam por v?rus, amea?as
>> eletr?nicas ou altera??o do conte?do original da mensagem. ? monitorada
>> toda mensagem enviada ou recebida utilizando recursos de tecnologia da
>> informa??o da Rede Energia S.A. Notice: This message was sent through
>> Rede Energia S.A. information technology resources and may contain
>> confidential or privileged information. If received by mistake, please
>> reply to the sender, eliminate and do not disclose, copy or use this
>> message or attached documents. Neither Rede Energia S.A. nor its
>> controlling, controlled or affiliated companies (?related companies?)
>> shall be bound by any message sent by a person not having legal
>> authority to represent them. Rede Energia S.A. and the related companies
>> shall not be liable for the existence of virus, electronic threat or
>> change in the original content of the message. Every message sent or
>> received through Rede Energia S.A. information technology resources is
>> monitored.
>>
>>
>> ------------------------------------------------------------------------------
>> Monitor your physical, virtual and cloud infrastructure from a single
>> web console. Get in-depth insight into apps, servers, databases, vmware,
>> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>> Pricing starts from $795 for 25 servers or applications!
>>http://p.sf.net/sfu/zoho_dev2dev_nov
>>
>>
>>
>> _______________________________________________
>> Ejbca-develop mailing list
>> Ejb...@li...
>>https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>>
>
>
>
>
> ------------------------------
>
> Message: 2
> Date: Fri, 23 Nov 2012 01:18:49 +0100
> From: Hans Witvliet <hw...@a-...>
> Subject: [Ejbca-develop] some steps acomplished..
> To: ejb...@li...
> Message-ID: <135...@t4...>
> Content-Type: text/plain
>
> Hi all,
>
> some steps accomplished, but new challenges to meet.
>
> Trying not to change too many variables at each step..
> afaicr, the website says that 3.11.x should work with
>
>
> So at my next step i'm trying to get ejbca-3.11 working with:
> apache-ant-1.8.1-bin.zip
> ejbca_3_11_5.zip
> jboss-5.1.0.GA-jdk6.zip
> jce_policy-6.zip
> jdk-6u20-linux-i586.bin
> mysql-connector-java-5.1.13.zip
>
> However, during ant clean it complains:
>
> Exception in thread "main" java.lang.NoClassDefFoundError:
> org/apache/tools/ant/launch/Launcher
> Caused by: java.lang.ClassNotFoundException:
> org.apache.tools.ant.launch.Launcher
> at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
> Could not find the main class: org.apache.tools.ant.launch.Launcher.
> Program will exit.
>
>
> The distro has a newer jdk available, but the error reains.
> # zypper search jdk
> "java-1_7_0-openjdk Java runtime environment based on OpenJDK 7 and
> IcedTea 7"
>
> So, what (url please) JDK/JCE-binary package do you recommend to go
> along with JBoss5?
>
> Oracle site doesn't make me any wiser ...
>
> hans
>
>
>
>
>
> ------------------------------
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
> ------------------------------
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
>
> End of Ejbca-develop Digest, Vol 78, Issue 3
> ********************************************
>
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
>
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
|
|
From: Marcos F. <mar...@ho...> - 2012-11-26 10:59:06
|
Hi Tomas,
In the test class that worked fine, the classes are in the default package. In the real aplication, the class is in certificate.model.
I done everything the same, even the imports. I never done nothing in the class path of war file, even in the test case.
--------------------------------------------------------------------------------------------------------------------------------------
Hi,
How do you package your application? It seems to me that the missing
class is not included in the classpath of your war file.
Cheers,
Tomas
On 11/22/2012 08:00 PM, Marcos Fontana wrote:
> Enviado do Email do Windows
> *De:* Marcos Paulo Fontana
> *Enviado:* ?22? de ?novembro? de ?2012 ?16?:?57
> *Para:* mar...@ho...
> *Assunto:* ejb...@li...
>
> Hi,
>
> When I?m trying to create a certificate directly on the main in java,
> like following code, I can do it normaly, the user and certificate are
> created well.
>
> *public**static**void*main(String[] args) *throws*InvalidKeyException,
> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
> InvalidAlgorithmParameterException, SecurityException, IOException,
> CertificateEncodingException {
>
>
> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>
> CertificateRequestSession teste =
> InterfaceCache./getCertficateRequestSession/();
>
> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>
> UserDataVO userdata = *new*UserDataVO();
>
> String username = "yMariano";
>
> String password = "a1b2c3";
>
> String DN = "E=y...@ho...,CN=Yara
> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
>
> *int*caid = 1963139164;
>
> String email = "yar...@ho...";
>
> userdata.setUsername(username);
>
> userdata.setPassword(password);
>
> userdata.setDN(DN);
>
> userdata.setCAId(caid);
>
> userdata.setEmail(email);
>
> userdata.setType(SecConst./USER_ENDUSER/);
>
> userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>
> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>
>
> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>
>
> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>
> String pkcs10 =
> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
> password)));
>
> *try*{
>
> teste.processCertReq(admin, userdata, pkcs10,
> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>
> } *catch*(Exception ex) {
>
> // *TODO*Auto-generated catch block
>
> }
>
> }
>
> So I implemented all that in a JSF page and tryed to run it, like i done
> before, but got this error:
>
> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
> org/ejbca/util/InterfaceCache
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>
> at
> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>
> at
> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>
> at
> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>
> at
> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>
> at
> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>
> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>
> at
> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>
> at
> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>
> at
> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>
> at
> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>
> at
> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>
> at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>
> at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>
> at java.lang.Thread.run(Unknown Source)
>
> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at
> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>
> at
> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>
> at
> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>
> at
> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>
> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
> Source)
>
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>
> at java.lang.reflect.Method.invoke(Unknown Source)
>
> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>
> at
> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>
> at
> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>
> ... 28 more
>
> Caused by: java.lang.ClassNotFoundException:
> org.ejbca.util.InterfaceCache from
> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> parentPolicy=AFTER_BUT_JAVA_BEFORE
> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
> roots=[MemoryContextHandler@242065626[path=
> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
> delegates=null exported=[certificate.controler, certificate.bean,
> certificate.model, certificate.interfaces, certificate.facade,
> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>
> at
> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>
> at java.lang.ClassLoader.loadClass(Unknown Source)
>
> ... 41 more
>
> 2012-11-22 16:45:01,853 WARNING
> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at
> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>
> at
> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>
> at
> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>
> at
> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>
> at
> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>
> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>
> at
> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>
> at
> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>
> at
> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>
> at
> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>
> at
> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>
> at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>
> at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>
> at java.lang.Thread.run(Unknown Source)
>
> Caused by: javax.faces.el.EvaluationException:
> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>
> at
> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>
> ... 27 more
>
> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at
> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>
> at
> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>
> at
> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>
> at
> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>
> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
> Source)
>
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>
> at java.lang.reflect.Method.invoke(Unknown Source)
>
> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>
> at
> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>
> at
> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>
> ... 28 more
>
> Caused by: java.lang.ClassNotFoundException:
> org.ejbca.util.InterfaceCache from
> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> parentPolicy=AFTER_BUT_JAVA_BEFORE
> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
> roots=[MemoryContextHandler@242065626[path=
> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
> delegates=null exported=[certificate.controler, certificate.bean,
> certificate.model, certificate.interfaces, certificate.facade,
> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>
> at
> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>
> at java.lang.ClassLoader.loadClass(Unknown Source)
>
> ... 41 more
>
> 2012-11-22 16:45:01,855 SEVERE
> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View ID:
> /cadastroProfile.jsp) Exception thrown during phase execution:
> javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
>
> 2012-11-22 16:45:01,856 ERROR
> [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
> Servlet threw exception
>
> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> parentPolicy=AFTER_BUT_JAVA_BEFORE
> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
> roots=[MemoryContextHandler@242065626[path=
> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
> delegates=null exported=[certificate.controler, certificate.bean,
> certificate.model, certificate.interfaces, certificate.facade,
> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>
> at
> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>
> at java.lang.ClassLoader.loadClass(Unknown Source)
>
> at
> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>
> at
> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>
> at
> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>
> at
> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>
> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
> Source)
>
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>
> at java.lang.reflect.Method.invoke(Unknown Source)
>
> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>
> at
> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>
> at
> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>
> at
> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>
> at
> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>
> at
> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>
> at
> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>
> at
> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>
> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>
> at
> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>
> at
> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>
> at
> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>
> at
> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>
> at
> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>
> at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>
> at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>
> at java.lang.Thread.run(Unknown Source)
>
> Whith the following code, that i guess is all right:
>
> *public*String emitirCertificado(String username, String password,
> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
> InvalidAlgorithmParameterException
>
> {
>
>
> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>
> ProfileBean pBean = *new*ProfileBean();
>
> UserDataVO userdata = *new*UserDataVO();
>
> CertificateRequestSession criaCert =
> InterfaceCache./getCertficateRequestSession/();
>
> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>
> *int*caid;
>
> *if*(tipoUsuario == 1)
>
> {
>
> DN = DN + "Alunos";
>
> caid = 1963139164; //CAID _Alunos_
>
> }*else**if*(tipoUsuario == 2)
>
> {
>
> DN = DN + "Professores";
>
> caid = 1134085357; //CAID _Professores_
>
> }*else*
>
> DN = DN + "Administrativo";
>
> caid = 1911414444; //CAID _Administrativo_
>
> userdata.setUsername(username);
>
> userdata.setPassword(password);
>
> userdata.setDN(DN);
>
> userdata.setCAId(caid); //ID CA _que_ _assina_.
>
> userdata.setEmail(E);
>
> userdata.setType(SecConst./USER_ENDUSER/);
>
> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>
> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>
>
> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>
>
> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>
> String pkcs10 =
> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
> password)));
>
> *try*{
>
> criaCert.processCertReq(admin, userdata, pkcs10,
> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>
> pBean.setMensagem("Profile e certificado criados com Sucesso");
>
> *return*"sucesso";
>
> } *catch*(Exception ex) {
>
> // *TODO*Auto-generated catch block
>
> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso servidores.
> Tente novamente!");
>
> *return*"erro";
>
> }
>
> }
>
> ------------------------------------------------------------------------
>
> Nenhum v?rus encontrado nessa mensagem.
> Verificado por AVG - www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
> Lan?amento: 11/20/12
>
> ------------------------------------------------------------------------
>
> Nenhum v?rus encontrado nessa mensagem.
> Verificado por AVG - www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> Vers?o: 2013.0.2793 / Banco de dados de v?rus: 2629/5907 - Data de
> Lan?amento: 11/20/12
>
> Aviso: Mensagem enviada com recursos de tecnologia da informa??o da Rede
> Energia S.A., podendo conter informa??o confidencial ou privilegiada. Se
> recebida por engano, favor devolv?-la ao remetente e elimin?-la, n?o a
> divulgando, copiando ou utilizando-a ou documentos a ela anexados. N?o
> gera obriga??es ? Rede Energia S.A. ou a suas empresas controladoras,
> controladas ou afiliadas (?empresas relacionadas?) a mensagem expedida
> por quem n?o tenha poderes de representa??o. A Rede Energia S.A. e as
> empresas relacionadas n?o se responsabilizam por v?rus, amea?as
> eletr?nicas ou altera??o do conte?do original da mensagem. ? monitorada
> toda mensagem enviada ou recebida utilizando recursos de tecnologia da
> informa??o da Rede Energia S.A. Notice: This message was sent through
> Rede Energia S.A. information technology resources and may contain
> confidential or privileged information. If received by mistake, please
> reply to the sender, eliminate and do not disclose, copy or use this
> message or attached documents. Neither Rede Energia S.A. nor its
> controlling, controlled or affiliated companies (?related companies?)
> shall be bound by any message sent by a person not having legal
> authority to represent them. Rede Energia S.A. and the related companies
> shall not be liable for the existence of virus, electronic threat or
> change in the original content of the message. Every message sent or
> received through Rede Energia S.A. information technology resources is
> monitored.
>
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
>
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
------------------------------
Message: 2
Date: Fri, 23 Nov 2012 01:18:49 +0100
From: Hans Witvliet <hw...@a-...>
Subject: [Ejbca-develop] some steps acomplished..
To: ejb...@li...
Message-ID: <135...@t4...>
Content-Type: text/plain
Hi all,
some steps accomplished, but new challenges to meet.
Trying not to change too many variables at each step..
afaicr, the website says that 3.11.x should work with
So at my next step i'm trying to get ejbca-3.11 working with:
apache-ant-1.8.1-bin.zip
ejbca_3_11_5.zip
jboss-5.1.0.GA-jdk6.zip
jce_policy-6.zip
jdk-6u20-linux-i586.bin
mysql-connector-java-5.1.13.zip
However, during ant clean it complains:
Exception in thread "main" java.lang.NoClassDefFoundError:
org/apache/tools/ant/launch/Launcher
Caused by: java.lang.ClassNotFoundException:
org.apache.tools.ant.launch.Launcher
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
Could not find the main class: org.apache.tools.ant.launch.Launcher.
Program will exit.
The distro has a newer jdk available, but the error reains.
# zypper search jdk
"java-1_7_0-openjdk Java runtime environment based on OpenJDK 7 and
IcedTea 7"
So, what (url please) JDK/JCE-binary package do you recommend to go
along with JBoss5?
Oracle site doesn't make me any wiser ...
hans
------------------------------
------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
------------------------------
_______________________________________________
Ejbca-develop mailing list
Ejb...@li...
https://lists.sourceforge.net/lists/listinfo/ejbca-develop
End of Ejbca-develop Digest, Vol 78, Issue 3
******************************************** |
|
From: Hans W. <hw...@a-...> - 2012-11-23 11:32:39
|
Ok, i noticed a reference towards an issue labelled as JBAS-7882. Perhaps that might be troubling me... Made to many changes on this machine so i will do a complete re-run on a fresh machine. Hans. On Fri, 2012-11-23 at 11:08 +0100, Tomas Gustavsson wrote: > All changes should be visible in the docs. You can find docs for older > releases through a link on ejbca.org (or by building with ant doc). > > Your issue with missing class for ant, could it be an installation > issue with ant? > JBoss should work with your version of java. > Does JBoss start ok withtout ejbca deployed as Anders asked. > > Regards, > Tomas > > Hans Witvliet <hw...@a-...> skrev: > Hi Anders, > > I fully understand that it is impossible to validate every single > subversion of jdk.... > > Perhaps i should re-phrase my question... > With the transition from JBoss4.x towards JBoss5.x, are there any > changes in the installation procedure? > (except the obvious one: making the proper sym-link ;-) > > Greetings, Hans > > > On Fri, 2012-11-23 at 09:58 +0100, ejbca-support wrote: > On 2012-11-23 09:52, Hans Witvliet wrote: > Hi, > > With regards to the JBoss directory: > Each time i try to run the complete installation, i start with a > complete new empty machine. So ! > i don't > upgrade, but do a complete fresh > installation. (just to avoid lingering parts from a previous > installation). > > > At run-1 i recreate the machine we build at the training, with ejb-3.10, > jbos4, jdk6u20, jce-policy-6. > > At run-2 i made a machine with the latest ejb-3 release, with > ejb-3.11.5, jboss-4.2.3.GA-jdk6, jdk6u20 and jce-policy-6. > > Now at run-3, i'll only wanted to change jboss. So: > ejb-3.11.5, jboss-5.1.0.GA-jdk6, jdk6u20 and jce-policy-6. > > So is is my assumption correct that: > A) jboss-5.1.0.GA-jdk6 does not work with jdk6u20 ? > B) I can not use java-1_7_0-openjdk ? > > As it is all matured software, i don't expect issues there. > If something goes wrong, it is 90% chance i made a typo, and for the > rest a 9% chance i'm mixing up combinations that do not match. > You wrote: "JBoss 5 only runs on JDK 6", so i should be able to use > jdk6u20 with jce, not? > > ! > Well, we > have (of course) not tested with every JDK minor release there is but > so far I have never heard about a compatibility problem between Open JDK 6 and JBoss 5. > > Cheers, > Anders > tech support > > > Hans > > > On Fri, 2012-11-23 at 07:02 +0100, ejbca-support wrote: > On 2012-11-23 01:18, Hans Witvliet wrote: > Hi all, > > Hans, > It looks like you have a JBoss issue currently. > Try getting JBoss startup cleanly without deploying EJBCA. > Clean the JBoss directory before installing it. > > JBoss 5 only runs on JDK 6. > > Cheers, > Anders > tech > support > > > > ______________________________________________ > > Monitor your physical, virtual and cloud infrastructure from a single > web console. Get in-depth insight into apps, servers, databases, vmware, > SAP, cloud infrastructure, etc. Download 30-day Free Trial. > Pricing starts from $795 for 25 servers or applications! > http://p.sf.net/sfu/zoho_dev2dev_nov > > ______________________________________________ > > Ejbca-develop mailing list > Ejb...@li... > https://lists.sourceforge.net/lists/listinfo/ejbca-develop > > > > ______________________________________________________________ > > Monitor your physical, virtual and cloud infrastructure from a single > web console. Get in-depth insight into apps, servers, databases, vmware, > SAP, cloud infrastructure, etc. Download 30-day Free Trial. > Pricing starts from $795 for 25 servers or applications! > http://p.sf.net/sfu/zoho_dev2dev_nov > > ______________________________________________________________ > > Ejbca-develop mailing list > Ejb...@li... > https://lists.sourceforge.net/lists/listinfo/ejbca-develop |
|
From: Tomas G. <to...@pr...> - 2012-11-23 10:09:06
|
All changes should be visible in the docs. You can find docs for older releases through a link on ejbca.org (or by building with ant doc). Your issue with missing class for ant, could it be an installation issue with ant? JBoss should work with your version of java. Does JBoss start ok withtout ejbca deployed as Anders asked. Regards, Tomas Hans Witvliet <hw...@a-...> skrev: >Hi Anders, > >I fully understand that it is impossible to validate every single >subversion of jdk.... > >Perhaps i should re-phrase my question... >With the transition from JBoss4.x towards JBoss5.x, are there any >changes in the installation procedure? >(except the obvious one: making the proper sym-link ;-) > >Greetings, Hans > > >On Fri, 2012-11-23 at 09:58 +0100, ejbca-support wrote: >> On 2012-11-23 09:52, Hans Witvliet wrote: >> > Hi, >> > >> > With regards to the JBoss directory: >> > Each time i try to run the complete installation, i start with a >> > complete new empty machine. So i don't upgrade, but do a complete >fresh >> > installation. (just to avoid lingering parts from a previous >> > installation). >> > >> > >> > At run-1 i recreate the machine we build at the training, with >ejb-3.10, >> > jbos4, jdk6u20, jce-policy-6. >> > >> > At run-2 i made a machine with the latest ejb-3 release, with >> > ejb-3.11.5, jboss-4.2.3.GA-jdk6, jdk6u20 and jce-policy-6. >> > >> > Now at run-3, i'll only wanted to change jboss. So: >> > ejb-3.11.5, jboss-5.1.0.GA-jdk6, jdk6u20 and jce-policy-6. >> > >> > So is is my assumption correct that: >> > A) jboss-5.1.0.GA-jdk6 does not work with jdk6u20 ? >> > B) I can not use java-1_7_0-openjdk ? >> > >> > As it is all matured software, i don't expect issues there. >> > If something goes wrong, it is 90% chance i made a typo, and for >the >> > rest a 9% chance i'm mixing up combinations that do not match. >> > You wrote: "JBoss 5 only runs on JDK 6", so i should be able to use >> > jdk6u20 with jce, not? >> >> Well, we have (of course) not tested with every JDK minor release >there is but >> so far I have never heard about a compatibility problem between Open >JDK 6 and JBoss 5. >> >> Cheers, >> Anders >> tech support >> >> > >> > Hans >> > >> > >> > On Fri, 2012-11-23 at 07:02 +0100, ejbca-support wrote: >> >> On 2012-11-23 01:18, Hans Witvliet wrote: >> >>> Hi all, >> >> >> >> Hans, >> >> It looks like you have a JBoss issue currently. >> >> Try getting JBoss startup cleanly without deploying EJBCA. >> >> Clean the JBoss directory before installing it. >> >> >> >> JBoss 5 only runs on JDK 6. >> >> >> >> Cheers, >> >> Anders >> >> tech support >> > >> > >> > >------------------------------------------------------------------------------ >> > Monitor your physical, virtual and cloud infrastructure from a >single >> > web console. Get in-depth insight into apps, servers, databases, >vmware, >> > SAP, cloud infrastructure, etc. Download 30-day Free Trial. >> > Pricing starts from $795 for 25 servers or applications! >> > http://p.sf.net/sfu/zoho_dev2dev_nov >> > _______________________________________________ >> > Ejbca-develop mailing list >> > Ejb...@li... >> > https://lists.sourceforge.net/lists/listinfo/ejbca-develop >> > > >------------------------------------------------------------------------------ >Monitor your physical, virtual and cloud infrastructure from a single >web console. Get in-depth insight into apps, servers, databases, >vmware, >SAP, cloud infrastructure, etc. Download 30-day Free Trial. >Pricing starts from $795 for 25 servers or applications! >http://p.sf.net/sfu/zoho_dev2dev_nov >_______________________________________________ >Ejbca-develop mailing list >Ejb...@li... >https://lists.sourceforge.net/lists/listinfo/ejbca-develop |
|
From: ejbca-support <ejb...@pr...> - 2012-11-23 10:04:54
|
On 2012-11-23 11:02, Hans Witvliet wrote: > Hi Anders, > > I fully understand that it is impossible to validate every single > subversion of jdk.... > > Perhaps i should re-phrase my question... > With the transition from JBoss4.x towards JBoss5.x, are there any > changes in the installation procedure? > (except the obvious one: making the proper sym-link ;-) Besides a patch that you have to do in JBoss 5 for running EJBCA web-services the installation procedure is identical. boot.log should be useful. Cheers, Anders > > Greetings, Hans > > > On Fri, 2012-11-23 at 09:58 +0100, ejbca-support wrote: >> On 2012-11-23 09:52, Hans Witvliet wrote: >>> Hi, >>> >>> With regards to the JBoss directory: >>> Each time i try to run the complete installation, i start with a >>> complete new empty machine. So i don't upgrade, but do a complete fresh >>> installation. (just to avoid lingering parts from a previous >>> installation). >>> >>> >>> At run-1 i recreate the machine we build at the training, with ejb-3.10, >>> jbos4, jdk6u20, jce-policy-6. >>> >>> At run-2 i made a machine with the latest ejb-3 release, with >>> ejb-3.11.5, jboss-4.2.3.GA-jdk6, jdk6u20 and jce-policy-6. >>> >>> Now at run-3, i'll only wanted to change jboss. So: >>> ejb-3.11.5, jboss-5.1.0.GA-jdk6, jdk6u20 and jce-policy-6. >>> >>> So is is my assumption correct that: >>> A) jboss-5.1.0.GA-jdk6 does not work with jdk6u20 ? >>> B) I can not use java-1_7_0-openjdk ? >>> >>> As it is all matured software, i don't expect issues there. >>> If something goes wrong, it is 90% chance i made a typo, and for the >>> rest a 9% chance i'm mixing up combinations that do not match. >>> You wrote: "JBoss 5 only runs on JDK 6", so i should be able to use >>> jdk6u20 with jce, not? >> >> Well, we have (of course) not tested with every JDK minor release there is but >> so far I have never heard about a compatibility problem between Open JDK 6 and JBoss 5. >> >> Cheers, >> Anders >> tech support >> >>> >>> Hans >>> >>> >>> On Fri, 2012-11-23 at 07:02 +0100, ejbca-support wrote: >>>> On 2012-11-23 01:18, Hans Witvliet wrote: >>>>> Hi all, >>>> >>>> Hans, >>>> It looks like you have a JBoss issue currently. >>>> Try getting JBoss startup cleanly without deploying EJBCA. >>>> Clean the JBoss directory before installing it. >>>> >>>> JBoss 5 only runs on JDK 6. >>>> >>>> Cheers, >>>> Anders >>>> tech support >>> >>> >>> ------------------------------------------------------------------------------ >>> Monitor your physical, virtual and cloud infrastructure from a single >>> web console. Get in-depth insight into apps, servers, databases, vmware, >>> SAP, cloud infrastructure, etc. Download 30-day Free Trial. >>> Pricing starts from $795 for 25 servers or applications! >>> http://p.sf.net/sfu/zoho_dev2dev_nov >>> _______________________________________________ >>> Ejbca-develop mailing list >>> Ejb...@li... >>> https://lists.sourceforge.net/lists/listinfo/ejbca-develop >>> |
|
From: Hans W. <hw...@a-...> - 2012-11-23 10:02:14
|
Hi Anders, I fully understand that it is impossible to validate every single subversion of jdk.... Perhaps i should re-phrase my question... With the transition from JBoss4.x towards JBoss5.x, are there any changes in the installation procedure? (except the obvious one: making the proper sym-link ;-) Greetings, Hans On Fri, 2012-11-23 at 09:58 +0100, ejbca-support wrote: > On 2012-11-23 09:52, Hans Witvliet wrote: > > Hi, > > > > With regards to the JBoss directory: > > Each time i try to run the complete installation, i start with a > > complete new empty machine. So i don't upgrade, but do a complete fresh > > installation. (just to avoid lingering parts from a previous > > installation). > > > > > > At run-1 i recreate the machine we build at the training, with ejb-3.10, > > jbos4, jdk6u20, jce-policy-6. > > > > At run-2 i made a machine with the latest ejb-3 release, with > > ejb-3.11.5, jboss-4.2.3.GA-jdk6, jdk6u20 and jce-policy-6. > > > > Now at run-3, i'll only wanted to change jboss. So: > > ejb-3.11.5, jboss-5.1.0.GA-jdk6, jdk6u20 and jce-policy-6. > > > > So is is my assumption correct that: > > A) jboss-5.1.0.GA-jdk6 does not work with jdk6u20 ? > > B) I can not use java-1_7_0-openjdk ? > > > > As it is all matured software, i don't expect issues there. > > If something goes wrong, it is 90% chance i made a typo, and for the > > rest a 9% chance i'm mixing up combinations that do not match. > > You wrote: "JBoss 5 only runs on JDK 6", so i should be able to use > > jdk6u20 with jce, not? > > Well, we have (of course) not tested with every JDK minor release there is but > so far I have never heard about a compatibility problem between Open JDK 6 and JBoss 5. > > Cheers, > Anders > tech support > > > > > Hans > > > > > > On Fri, 2012-11-23 at 07:02 +0100, ejbca-support wrote: > >> On 2012-11-23 01:18, Hans Witvliet wrote: > >>> Hi all, > >> > >> Hans, > >> It looks like you have a JBoss issue currently. > >> Try getting JBoss startup cleanly without deploying EJBCA. > >> Clean the JBoss directory before installing it. > >> > >> JBoss 5 only runs on JDK 6. > >> > >> Cheers, > >> Anders > >> tech support > > > > > > ------------------------------------------------------------------------------ > > Monitor your physical, virtual and cloud infrastructure from a single > > web console. Get in-depth insight into apps, servers, databases, vmware, > > SAP, cloud infrastructure, etc. Download 30-day Free Trial. > > Pricing starts from $795 for 25 servers or applications! > > http://p.sf.net/sfu/zoho_dev2dev_nov > > _______________________________________________ > > Ejbca-develop mailing list > > Ejb...@li... > > https://lists.sourceforge.net/lists/listinfo/ejbca-develop > > |
|
From: ejbca-support <ejb...@pr...> - 2012-11-23 08:58:58
|
On 2012-11-23 09:52, Hans Witvliet wrote: > Hi, > > With regards to the JBoss directory: > Each time i try to run the complete installation, i start with a > complete new empty machine. So i don't upgrade, but do a complete fresh > installation. (just to avoid lingering parts from a previous > installation). > > > At run-1 i recreate the machine we build at the training, with ejb-3.10, > jbos4, jdk6u20, jce-policy-6. > > At run-2 i made a machine with the latest ejb-3 release, with > ejb-3.11.5, jboss-4.2.3.GA-jdk6, jdk6u20 and jce-policy-6. > > Now at run-3, i'll only wanted to change jboss. So: > ejb-3.11.5, jboss-5.1.0.GA-jdk6, jdk6u20 and jce-policy-6. > > So is is my assumption correct that: > A) jboss-5.1.0.GA-jdk6 does not work with jdk6u20 ? > B) I can not use java-1_7_0-openjdk ? > > As it is all matured software, i don't expect issues there. > If something goes wrong, it is 90% chance i made a typo, and for the > rest a 9% chance i'm mixing up combinations that do not match. > You wrote: "JBoss 5 only runs on JDK 6", so i should be able to use > jdk6u20 with jce, not? Well, we have (of course) not tested with every JDK minor release there is but so far I have never heard about a compatibility problem between Open JDK 6 and JBoss 5. Cheers, Anders tech support > > Hans > > > On Fri, 2012-11-23 at 07:02 +0100, ejbca-support wrote: >> On 2012-11-23 01:18, Hans Witvliet wrote: >>> Hi all, >> >> Hans, >> It looks like you have a JBoss issue currently. >> Try getting JBoss startup cleanly without deploying EJBCA. >> Clean the JBoss directory before installing it. >> >> JBoss 5 only runs on JDK 6. >> >> Cheers, >> Anders >> tech support > > > ------------------------------------------------------------------------------ > Monitor your physical, virtual and cloud infrastructure from a single > web console. Get in-depth insight into apps, servers, databases, vmware, > SAP, cloud infrastructure, etc. Download 30-day Free Trial. > Pricing starts from $795 for 25 servers or applications! > http://p.sf.net/sfu/zoho_dev2dev_nov > _______________________________________________ > Ejbca-develop mailing list > Ejb...@li... > https://lists.sourceforge.net/lists/listinfo/ejbca-develop > |
|
From: Hans W. <hw...@a-...> - 2012-11-23 08:53:05
|
Hi, With regards to the JBoss directory: Each time i try to run the complete installation, i start with a complete new empty machine. So i don't upgrade, but do a complete fresh installation. (just to avoid lingering parts from a previous installation). At run-1 i recreate the machine we build at the training, with ejb-3.10, jbos4, jdk6u20, jce-policy-6. At run-2 i made a machine with the latest ejb-3 release, with ejb-3.11.5, jboss-4.2.3.GA-jdk6, jdk6u20 and jce-policy-6. Now at run-3, i'll only wanted to change jboss. So: ejb-3.11.5, jboss-5.1.0.GA-jdk6, jdk6u20 and jce-policy-6. So is is my assumption correct that: A) jboss-5.1.0.GA-jdk6 does not work with jdk6u20 ? B) I can not use java-1_7_0-openjdk ? As it is all matured software, i don't expect issues there. If something goes wrong, it is 90% chance i made a typo, and for the rest a 9% chance i'm mixing up combinations that do not match. You wrote: "JBoss 5 only runs on JDK 6", so i should be able to use jdk6u20 with jce, not? Hans On Fri, 2012-11-23 at 07:02 +0100, ejbca-support wrote: > On 2012-11-23 01:18, Hans Witvliet wrote: > > Hi all, > > Hans, > It looks like you have a JBoss issue currently. > Try getting JBoss startup cleanly without deploying EJBCA. > Clean the JBoss directory before installing it. > > JBoss 5 only runs on JDK 6. > > Cheers, > Anders > tech support |
|
From: ejbca-support <ejb...@pr...> - 2012-11-23 06:02:34
|
On 2012-11-23 01:18, Hans Witvliet wrote: > Hi all, Hans, It looks like you have a JBoss issue currently. Try getting JBoss startup cleanly without deploying EJBCA. Clean the JBoss directory before installing it. JBoss 5 only runs on JDK 6. Cheers, Anders tech support > > some steps accomplished, but new challenges to meet. > > Trying not to change too many variables at each step.. > afaicr, the website says that 3.11.x should work with > > > So at my next step i'm trying to get ejbca-3.11 working with: > apache-ant-1.8.1-bin.zip > ejbca_3_11_5.zip > jboss-5.1.0.GA-jdk6.zip > jce_policy-6.zip > jdk-6u20-linux-i586.bin > mysql-connector-java-5.1.13.zip > > However, during ant clean it complains: > > Exception in thread "main" java.lang.NoClassDefFoundError: > org/apache/tools/ant/launch/Launcher > Caused by: java.lang.ClassNotFoundException: > org.apache.tools.ant.launch.Launcher > at java.net.URLClassLoader$1.run(URLClassLoader.java:202) > at java.security.AccessController.doPrivileged(Native Method) > at java.net.URLClassLoader.findClass(URLClassLoader.java:190) > at java.lang.ClassLoader.loadClass(ClassLoader.java:307) > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) > at java.lang.ClassLoader.loadClass(ClassLoader.java:248) > Could not find the main class: org.apache.tools.ant.launch.Launcher. > Program will exit. > > > The distro has a newer jdk available, but the error reains. > # zypper search jdk > "java-1_7_0-openjdk Java runtime environment based on OpenJDK 7 and > IcedTea 7" > > So, what (url please) JDK/JCE-binary package do you recommend to go > along with JBoss5? > > Oracle site doesn't make me any wiser ... > > hans > > > > ------------------------------------------------------------------------------ > Monitor your physical, virtual and cloud infrastructure from a single > web console. Get in-depth insight into apps, servers, databases, vmware, > SAP, cloud infrastructure, etc. Download 30-day Free Trial. > Pricing starts from $795 for 25 servers or applications! > http://p.sf.net/sfu/zoho_dev2dev_nov > _______________________________________________ > Ejbca-develop mailing list > Ejb...@li... > https://lists.sourceforge.net/lists/listinfo/ejbca-develop > |
|
From: Hans W. <hw...@a-...> - 2012-11-23 00:18:59
|
Hi all,
some steps accomplished, but new challenges to meet.
Trying not to change too many variables at each step..
afaicr, the website says that 3.11.x should work with
So at my next step i'm trying to get ejbca-3.11 working with:
apache-ant-1.8.1-bin.zip
ejbca_3_11_5.zip
jboss-5.1.0.GA-jdk6.zip
jce_policy-6.zip
jdk-6u20-linux-i586.bin
mysql-connector-java-5.1.13.zip
However, during ant clean it complains:
Exception in thread "main" java.lang.NoClassDefFoundError:
org/apache/tools/ant/launch/Launcher
Caused by: java.lang.ClassNotFoundException:
org.apache.tools.ant.launch.Launcher
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
Could not find the main class: org.apache.tools.ant.launch.Launcher.
Program will exit.
The distro has a newer jdk available, but the error reains.
# zypper search jdk
"java-1_7_0-openjdk Java runtime environment based on OpenJDK 7 and
IcedTea 7"
So, what (url please) JDK/JCE-binary package do you recommend to go
along with JBoss5?
Oracle site doesn't make me any wiser ...
hans
|
|
From: Tomas G. <to...@pr...> - 2012-11-22 19:07:42
|
Hi,
How do you package your application? It seems to me that the missing
class is not included in the classpath of your war file.
Cheers,
Tomas
On 11/22/2012 08:00 PM, Marcos Fontana wrote:
> Enviado do Email do Windows
> *De:* Marcos Paulo Fontana
> *Enviado:* 22 de novembro de 2012 16:57
> *Para:* mar...@ho...
> *Assunto:* ejb...@li...
>
> Hi,
>
> When I’m trying to create a certificate directly on the main in java,
> like following code, I can do it normaly, the user and certificate are
> created well.
>
> *public**static**void*main(String[] args) *throws*InvalidKeyException,
> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
> InvalidAlgorithmParameterException, SecurityException, IOException,
> CertificateEncodingException {
>
>
> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>
> CertificateRequestSession teste =
> InterfaceCache./getCertficateRequestSession/();
>
> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>
> UserDataVO userdata = *new*UserDataVO();
>
> String username = "yMariano";
>
> String password = "a1b2c3";
>
> String DN = "E=y...@ho...,CN=Yara
> mariano, OU=Administrativo,O=IFSP,L=Piracaia,C=BR";
>
> *int*caid = 1963139164;
>
> String email = "yar...@ho...";
>
> userdata.setUsername(username);
>
> userdata.setPassword(password);
>
> userdata.setDN(DN);
>
> userdata.setCAId(caid);
>
> userdata.setEmail(email);
>
> userdata.setType(SecConst./USER_ENDUSER/);
>
> userdata.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>
> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>
>
> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>
>
> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>
> String pkcs10 =
> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
> password)));
>
> *try*{
>
> teste.processCertReq(admin, userdata, pkcs10,
> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>
> } *catch*(Exception ex) {
>
> // *TODO*Auto-generated catch block
>
> }
>
> }
>
> So I implemented all that in a JSF page and tryed to run it, like i done
> before, but got this error:
>
> javax.faces.el.EvaluationException: java.lang.NoClassDefFoundError:
> org/ejbca/util/InterfaceCache
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>
> at
> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>
> at
> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>
> at
> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>
> at
> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>
> at
> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>
> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>
> at
> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>
> at
> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>
> at
> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>
> at
> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>
> at
> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>
> at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>
> at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>
> at java.lang.Thread.run(Unknown Source)
>
> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at
> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>
> at
> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>
> at
> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>
> at
> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>
> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
> Source)
>
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>
> at java.lang.reflect.Method.invoke(Unknown Source)
>
> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>
> at
> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>
> at
> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>
> ... 28 more
>
> Caused by: java.lang.ClassNotFoundException:
> org.ejbca.util.InterfaceCache from
> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> parentPolicy=AFTER_BUT_JAVA_BEFORE
> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
> roots=[MemoryContextHandler@242065626[path=
> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
> delegates=null exported=[certificate.controler, certificate.bean,
> certificate.model, certificate.interfaces, certificate.facade,
> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>
> at
> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>
> at java.lang.ClassLoader.loadClass(Unknown Source)
>
> ... 41 more
>
> 2012-11-22 16:45:01,853 WARNING
> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
> (http-0.0.0.0-8080-1) #{profileBean.cadastrarProfile}:
> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> javax.faces.FacesException: #{profileBean.cadastrarProfile}:
> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at
> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:118)
>
> at
> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>
> at
> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>
> at
> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>
> at
> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>
> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>
> at
> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>
> at
> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>
> at
> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>
> at
> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>
> at
> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>
> at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>
> at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>
> at java.lang.Thread.run(Unknown Source)
>
> Caused by: javax.faces.el.EvaluationException:
> java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
>
> at
> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>
> ... 27 more
>
> Caused by: java.lang.NoClassDefFoundError: org/ejbca/util/InterfaceCache
>
> at
> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>
> at
> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>
> at
> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>
> at
> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>
> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
> Source)
>
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>
> at java.lang.reflect.Method.invoke(Unknown Source)
>
> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>
> at
> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>
> at
> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>
> ... 28 more
>
> Caused by: java.lang.ClassNotFoundException:
> org.ejbca.util.InterfaceCache from
> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> parentPolicy=AFTER_BUT_JAVA_BEFORE
> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
> roots=[MemoryContextHandler@242065626[path=
> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
> delegates=null exported=[certificate.controler, certificate.bean,
> certificate.model, certificate.interfaces, certificate.facade,
> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>
> at
> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>
> at java.lang.ClassLoader.loadClass(Unknown Source)
>
> ... 41 more
>
> 2012-11-22 16:45:01,855 SEVERE
> [javax.enterprise.resource.webcontainer.jsf.lifecycle]
> (http-0.0.0.0-8080-1) JSF1054: (Phase ID: INVOKE_APPLICATION 5, View ID:
> /cadastroProfile.jsp) Exception thrown during phase execution:
> javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@156f0858]
>
> 2012-11-22 16:45:01,856 ERROR
> [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/CertificadosDigitais].[Faces
> Servlet]] (http-0.0.0.0-8080-1) Servlet.service() for servlet Faces
> Servlet threw exception
>
> java.lang.ClassNotFoundException: org.ejbca.util.InterfaceCache from
> BaseClassLoader@54ed9ff8{VFSClassLoaderPolicy@3ca17e57{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> domain=ClassLoaderDomain@2c851425{name=vfszip:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/
> parentPolicy=AFTER_BUT_JAVA_BEFORE
> parent=ClassLoaderDomain@5867df9{DefaultDomain}}
> roots=[MemoryContextHandler@242065626[path=
> context=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a
> real=vfsmemory://3j001-jcuaql-h9u898ou-1-h9u89s8l-2a],
> ZipEntryHandler@1062948764[path=CertificadosDigitais.war/WEB-INF/classes
> context=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/
> real=file:/C:/Users/Marcos/workspace/jboss-5.1.0.GA/server/default/deploy/CertificadosDigitais.war/WEB-INF/classes]]
> delegates=null exported=[certificate.controler, certificate.bean,
> certificate.model, certificate.interfaces, certificate.facade,
> certificate.dao] <IMPORT-ALL>NON_EMPTY}}
>
> at
> org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:448)
>
> at java.lang.ClassLoader.loadClass(Unknown Source)
>
> at
> certificate.model.ModelCertificado.emitirCertificado(ModelCertificado.java:28)
>
> at
> certificate.model.ModelProfile.cadastraProfile(ModelProfile.java:29)
>
> at
> certificate.facade.FacadeProfile.cadastrarProfile(FacadeProfile.java:18)
>
> at
> certificate.controler.ControladorProfile.cadastrarProfile(ControladorProfile.java:18)
>
> at certificate.bean.ProfileBean.cadastrarProfile(ProfileBean.java:25)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
> Source)
>
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>
> at java.lang.reflect.Method.invoke(Unknown Source)
>
> at org.apache.el.parser.AstValue.invoke(AstValue.java:170)
>
> at
> org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
>
> at
> org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
>
> at
> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
>
> at
> com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
>
> at
> javax.faces.component.UICommand.broadcast(UICommand.java:387)
>
> at
> javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
>
> at
> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
>
> at
> com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
>
> at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
>
> at
> com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>
> at
> javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>
> at
> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
>
> at
> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>
> at
> org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>
> at
> org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
>
> at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
>
> at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>
> at java.lang.Thread.run(Unknown Source)
>
> Whith the following code, that i guess is all right:
>
> *public*String emitirCertificado(String username, String password,
> *int*tipoUsuario, String E, String DN) *throws*InvalidKeyException,
> NoSuchAlgorithmException, NoSuchProviderException, SignatureException,
> InvalidAlgorithmParameterException
>
> {
>
>
> Security./addProvider/(*new*org.bouncycastle.jce.provider.BouncyCastleProvider());
>
> ProfileBean pBean = *new*ProfileBean();
>
> UserDataVO userdata = *new*UserDataVO();
>
> CertificateRequestSession criaCert =
> InterfaceCache./getCertficateRequestSession/();
>
> Admin admin = *new*Admin(Admin./TYPE_CACOMMANDLINE_USER/);
>
> *int*caid;
>
> *if*(tipoUsuario == 1)
>
> {
>
> DN = DN + "Alunos";
>
> caid = 1963139164; //CAID _Alunos_
>
> }*else**if*(tipoUsuario == 2)
>
> {
>
> DN = DN + "Professores";
>
> caid = 1134085357; //CAID _Professores_
>
> }*else*
>
> DN = DN + "Administrativo";
>
> caid = 1911414444; //CAID _Administrativo_
>
> userdata.setUsername(username);
>
> userdata.setPassword(password);
>
> userdata.setDN(DN);
>
> userdata.setCAId(caid); //ID CA _que_ _assina_.
>
> userdata.setEmail(E);
>
> userdata.setType(SecConst./USER_ENDUSER/);
>
> _userdata_.setTokenType(SecConst./TOKEN_SOFT_BROWSERGEN/);
>
> userdata.setStatus(UserDataConstants./STATUS_NEW/);
>
>
> userdata.setEndEntityProfileId(SecConst./EMPTY_ENDENTITYPROFILE/);
>
>
> userdata.setCertificateProfileId(SecConst./CERTPROFILE_FIXED_ENDUSER/);
>
> String pkcs10 =
> *new*String(Base64./encode/(NonEjbTestTools./generatePKCS10Req/("CN="+username,
> password)));
>
> *try*{
>
> criaCert.processCertReq(admin, userdata, pkcs10,
> SecConst./CERT_REQ_TYPE_PKCS10/, *null*, SecConst./CERT_REQ_TYPE_PKCS10/);
>
> pBean.setMensagem("Profile e certificado criados com Sucesso");
>
> *return*"sucesso";
>
> } *catch*(Exception ex) {
>
> // *TODO*Auto-generated catch block
>
> pBean.setMensagem("Ops! Desculpe-nos, algo ocorreu em nosso servidores.
> Tente novamente!");
>
> *return*"erro";
>
> }
>
> }
>
> ------------------------------------------------------------------------
>
> Nenhum vírus encontrado nessa mensagem.
> Verificado por AVG - www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> Versão: 2013.0.2793 / Banco de dados de vírus: 2629/5907 - Data de
> Lançamento: 11/20/12
>
> ------------------------------------------------------------------------
>
> Nenhum vírus encontrado nessa mensagem.
> Verificado por AVG - www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> Versão: 2013.0.2793 / Banco de dados de vírus: 2629/5907 - Data de
> Lançamento: 11/20/12
>
> Aviso: Mensagem enviada com recursos de tecnologia da informação da Rede
> Energia S.A., podendo conter informação confidencial ou privilegiada. Se
> recebida por engano, favor devolvê-la ao remetente e eliminá-la, não a
> divulgando, copiando ou utilizando-a ou documentos a ela anexados. Não
> gera obrigações à Rede Energia S.A. ou a suas empresas controladoras,
> controladas ou afiliadas (“empresas relacionadas”) a mensagem expedida
> por quem não tenha poderes de representação. A Rede Energia S.A. e as
> empresas relacionadas não se responsabilizam por vírus, ameaças
> eletrônicas ou alteração do conteúdo original da mensagem. É monitorada
> toda mensagem enviada ou recebida utilizando recursos de tecnologia da
> informação da Rede Energia S.A. Notice: This message was sent through
> Rede Energia S.A. information technology resources and may contain
> confidential or privileged information. If received by mistake, please
> reply to the sender, eliminate and do not disclose, copy or use this
> message or attached documents. Neither Rede Energia S.A. nor its
> controlling, controlled or affiliated companies (“related companies”)
> shall be bound by any message sent by a person not having legal
> authority to represent them. Rede Energia S.A. and the related companies
> shall not be liable for the existence of virus, electronic threat or
> change in the original content of the message. Every message sent or
> received through Rede Energia S.A. information technology resources is
> monitored.
>
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
>
>
>
> _______________________________________________
> Ejbca-develop mailing list
> Ejb...@li...
> https://lists.sourceforge.net/lists/listinfo/ejbca-develop
>
|