sam ky

Ranch Hand
+ Follow
since Aug 03, 2003
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
1
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by sam ky

Thank you, Richard. It helped me.
10 years ago
Hi,

Could you help me to point out what is the default RSA padding.

Precisely, if I create cipher instance as below, sure java is using some sort of padding as encrypted text bytes length always shows 256 bytes for 2048 RSA key irrespective of plain text is one characters or 10 characters.



I wanted to know what is default padding java use internally if no padding is specified in Cipher.getInstance("RSA"). is that PKCS#1 v 1.5?


Thanks,
Sam
10 years ago
I would suggest you to implement a simple encryption and decryption algorithms and use it only for specific properties, this is how I followed in one of the project.

Here is the approach:

username=admin
password=enc:%^%#$#

if any property value starts with enc:, then write a logic to decrypt before use it. Hope this helps.


12 years ago
Hi,

I'm also facing this issue. the keytool list shows the alias tomcat but tomcat couldn't picking it. I also mentioned the alias name in server.xml as tomcat but tomcat is throwing an error
java.io.IOException: Alias name tomcat does not identify a key entry

Any suggestion would be much appreciated

12 years ago


Hello Guys,

Could you throw some light on this issue:

I have configured the SSL/https port for Tomcat as per the configuration mentioned in Tomcat site

(1)Generated a key using KeyTool
(2)Generated a CSR
(3)Got the Verisign- CA certificate
(4)Imported the CERT using Keytool (successful)
(5)Uncommented the https connector port in tomcat's server.xml


Here is the exception in Catelina log file:

java.io.IOException: jsse.invalid_ssl_conf
at org.apache.tomcat.util.net.jsse.JSSESocketFactory.checkConfig(JSSESocketFactory.java:755)
at org.apache.tomcat.util.net.jsse.JSSESocketFactory.init(JSSESocketFactory.java:460)
at org.apache.tomcat.util.net.jsse.JSSESocketFactory.createSocket(JSSESocketFactory.java:130)
at org.apache.tomcat.util.net.JIoEndpoint.init(JIoEndpoint.java:538)
at org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:176)
at org.apache.catalina.connector.Connector.initialize(Connector.java:1014)
at org.apache.catalina.core.StandardService.initialize(StandardService.java:680)
at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:795)
at org.apache.catalina.startup.Catalina.load(Catalina.java:524)
at org.apache.catalina.startup.Catalina.load(Catalina.java:548)
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.catalina.startup.Bootstrap.load(Bootstrap.java:261)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Caused by: javax.net.ssl.SSLException: No available certificate or key corresponds to the SSL cipher suites which are enabled.
at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.checkEnabledSuites(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.accept(Unknown Source)
at org.apache.tomcat.util.net.jsse.JSSESocketFactory.checkConfig(JSSESocketFactory.java:751)
... 15 more
Jul 27, 2011 11:11:14 AM org.apache.catalina.startup.Catalina load
SEVERE: Catalina.start
LifecycleException: Protocol handler initialization failed: java.io.IOException: jsse.invalid_ssl_conf
at org.apache.catalina.connector.Connector.initialize(Connector.java:1016)
at org.apache.catalina.core.StandardService.initialize(StandardService.java:680)
at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:795)
at org.apache.catalina.startup.Catalina.load(Catalina.java:524)
at org.apache.catalina.startup.Catalina.load(Catalina.java:548)
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.catalina.startup.Bootstrap.load(Bootstrap.java:261)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)




I checked the key and the alias tomcat is present in it.
keytool -list -keystore hakioskcheckin2_key -storepass XXXXXX

Keystore type: JKS
Keystore provider: SUN

Your keystore contains 1 entry

tomcat, Jul 26, 2011, trustedCertEntry,
Certificate fingerprint (MD5): -removed intentionally-


Server.xml updated with below:

<Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true"
keystoreFile="C:\Program Files\Java\jre6\bin\hakioskcheckin2_key"
keystorePass="Hawaiian1"
maxThreads="150" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS" />



Thanks in advance,

Sammaiah
12 years ago
Hello,

Welcome to Javaranch!!

Regarding your problem, you have used wrong syntax for specifying Main-Class in Manifest file. Update it with below.

Main-Class: com/wateen/cvp/test/CRMServTest


Thanks,
Sammaiah
14 years ago
Hello,

You shouldn't use swing components for web based applications. Swing is meant for developing window based(thik) client applications. Here in this article, JOptionPane is used just to demonstrate the flexibility of using JSF but you shouldn't use JFrames/JButtons etc to render on browser. JSF has it's own components library for web applications.

Hope it helps.
14 years ago
JSF
Expose your project functionalities through SOAP interface(s). In short, expose public methods through a web service(s) .

Hope it helps.

14 years ago
Just check if you have permissions to Temp folder. This problem may also happen if there is no space in primary drive.

14 years ago
Hi,

I have a crazy requirement to develop a standalone web service which should be accessible to another process. The problem here is that there is a restriction to install the servers in a machine where webservice is supposed to provide a service. The webservice has to run with out deploying in any server...ofcourse which is stupid, but the requirement is like that. It should be self serviced, ie.. can include source code to implement web server logic.

Is there any such open source in-process container to provide runtime environment for the webservice. I knew that axis2 standalone server can help but It would be great if there is any any lighter version of code which can be merged with my webservice that will provide a runtime environment.

If there is no other option, is there any way that I can access axis2 standalone server through my java program to start and stop when needed?.


Thanks,
Sam

14 years ago
Hello,

Use document/literal and ADB binding.

Thanks,
Sam
14 years ago
Hi All,

Intermittantly, my web service client is throwing IOInterruptedException in production.AXIS2 is used for generating stubs.

Note: It is a synchronous web service.

Any suggestion would be much appreciated.

Thanks,
Sam


14 years ago
set your driver jar file in classpath.
Right click on project and select javabuild path and then select libraries tab and then add below:
("E:\sqldeveloper\jdbc\lib\yourjarfilename.jar")

thnx
Hi,
Thanks for the response.
The data volume is really high, like 6months past history of customers... It could be more than 1 crore records in real environment...

It would be great if any one could through a best approach...

Thnx,
Sam
Hi All,
can some one please through a best approach to go ahead for below problem:

We have a requirement to insert huge number of records in batches.
In case if one record fails, the application should continue with remaining records with out rollback remaining records.

We are using commit only end of all the records and even not able to trace which record get failed in batch approach.

Thnx,
sam