• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

Base64 binary import does not exist

 
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi guys!

I have a small issue with my code where im encrypting and decrypting messages. My import org.apache.commons.codec.binary.Base64;. does not work. It says binary does not exist_ Any idea why this happens?. Ive downloaded the codec but im starting to wonder if it has to do with where the codec folder is located, but i may be wrong. Any ideas?



thanks in advance
 
Ranch Hand
Posts: 789
Python C++ Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You probably just need to add it to your build path. "Properties" -> etc -> "add jar file".
 
Bartender
Posts: 1166
17
Netbeans IDE Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You seem to have lifted that code from http://www.java-redefined.com/2013/08/symmetric-and-asymmetric-key-encryption.html . It is bad form to post code without providing an acknowledgement.

P.S. That code has some significant weaknesses a major one being that the private key is created on the fly so is not private to the person who is to receive the cipher text! This defeats the aim of public key cryptography.
 
This is my favorite show. And this is my favorite tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic