I am pretty new to Mac OS, or Bouncy Castle/Encryption at all, hence I am following the guide here and downloaded the PGP-JDK1.5-1.7 version of Bouncy Castle jar.
I issued the below command to see where Java is installed:
bash-3.2$ sudo find / -name "*.security"
Password:
/Applications/Xcode.app/Contents/Applications/Application Loader.app/Contents/MacOS/itms/java/lib/security/java.security
find: /dev/fd/3: Not a directory
find: /dev/fd/4: Not a directory
/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home/lib/security/java.security
/Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home/jre/lib/security/java.security
/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/security/java.security
/Users/fn.lastname/code/vault/security_java_jars_Aug11/java.security
I then added security.provider.11=org.bouncycastle.jce.provider.BouncyCastleProvider to /Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home/jre/lib/security/java.security and also added the bouncy castle jar to /Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home/jre/lib/ext
The changed java.security content is as below:
security.provider.1=sun.security.provider.Sun
security.provider.2=sun.security.rsa.SunRsaSign
security.provider.3=sun.security.ec.SunEC
security.provider.4=com.sun.net.ssl.internal.ssl.Provider
security.provider.5=com.sun.crypto.provider.SunJCE
security.provider.6=sun.security.jgss.SunProvider
security.provider.7=com.sun.security.sasl.Provider
security.provider.8=org.jcp.xml.dsig.internal.dom.XMLDSigRI
security.provider.9=sun.security.smartcardio.SunPCSC
security.provider.10=apple.security.AppleProvider
security.provider.11=org.bouncycastle.jce.provider.BouncyCastleProvider
I went to eclipse(STS) and executed the program here to see if the Bouncy Castle is successfully installed. It just returned "BC provider not installed".
I tried the same on the location at /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/security/java.security
Again ran the program with out any success. I also tried googling other sites, alas much help. Seems to have good support for Windows, but for mac I need help even to find if I am at the right Java version.
Could any of you please let me know where I could sense issues? Thanks in advance.