Bitcoin Forum
March 29, 2024, 08:53:33 AM *
News: Latest Bitcoin Core release: 26.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: A lightweight Bitcoin crypto library for Java/Android  (Read 3387 times)
0x6763
Guest

February 25, 2011, 06:03:26 PM
Last edit: February 28, 2011, 04:51:12 AM by 0x6763
 #1

I wrote a very lightweight Bitcoin crypto library for use with Android or any normal JVM-based project (it does not depend on any Android specific APIs).  I developed it with the Android Development Kit and it tests without problems on the Android emulator.  It compiles for Android versions at least as old as Android 1.5 (API level 3).  The purpose of this library is to remove the need to include the big Bouncy Castle library when only a very tiny portion of Bouncy Castle is needed for working with Bitcoin.  To give an idea of how lightweight it is, when exporting to a jar file containing the compiled code (no docs or source), it is barely over 40KB in size.  It includes a very small amount of code copied from Bouncy Castle.

I am willing to sell copies of this library in binary and/or source code form.  Documentation will be freely viewable and downloadable as soon as I determine where I want to put it online (possibly github, if it can placed there in a way that lets others browse it).  Until I find a public place to put the javadocs, I am willing to email a copy of the javadocs.

The javadocs are viewable here: http://x6763.github.com/BitcoinCrypto/doc/index.html

To purchase a copy of this library's source code, you must agree that you will not publicly share the source code any sooner than July 4, 2011.  You can privately share the source code with other developers working on any of your projects using this library only if they agree not share the source code with anyone else no sooner than July 4, 2011.  The portions of code written by myself will be released into public domain as stated here: http://unlicense.org/UNLICENSE.  The portions of code from the Bouncy Castle library is subject to the Bouncy Castle license as stated here: http://www.bouncycastle.org/licence.html.

The library supports the following features used by Bitcoin:

ECDSA releated features (using the secp256k1 elliptic curve):
* Key pair generation
* Public key generation from private key
* Key serialization/de-serialization - private keys serialize to an array of 32 bytes, as opposed to the bloated storage format used by the official Bitcoin client/OpenSSL
* Signing data
* Verifying signatures

A simple, and consistent API for the following hashes:
* SHA-256
* SHA-1 - included since it's part of the Transaction Script spec
* RIPEMD-160
* Hash160 - provides a simple way to do ripemd160(sha256(data))
* Hash256 - provides a simple way to do sha256(sha256(data))

Prices are negotiable.  PM me if interested.
You get merit points when someone likes your post enough to give you some. And for every 2 merit points you receive, you can send 1 merit point to someone else!
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1711702413
Hero Member
*
Offline Offline

Posts: 1711702413

View Profile Personal Message (Offline)

Ignore
1711702413
Reply with quote  #2

1711702413
Report to moderator
1711702413
Hero Member
*
Offline Offline

Posts: 1711702413

View Profile Personal Message (Offline)

Ignore
1711702413
Reply with quote  #2

1711702413
Report to moderator
error
Hero Member
*****
Offline Offline

Activity: 588
Merit: 500



View Profile
February 25, 2011, 06:08:51 PM
 #2

What's the deal with July 4, 2011?

3KzNGwzRZ6SimWuFAgh4TnXzHpruHMZmV8
0x6763
Guest

February 25, 2011, 06:15:58 PM
 #3

I just wanted to keep the source code private for a little while.  The date is really completely arbitrary, but just a little more memorable (at least to me) than something like June 1st or July 1st.
error
Hero Member
*****
Offline Offline

Activity: 588
Merit: 500



View Profile
February 25, 2011, 06:16:45 PM
 #4

OK, well I'll come back on July 4, then Smiley

3KzNGwzRZ6SimWuFAgh4TnXzHpruHMZmV8
0x6763
Guest

February 25, 2011, 06:45:49 PM
 #5

OK, well I'll come back on July 4, then Smiley

OK
Smiley
0x6763
Guest

February 25, 2011, 07:17:58 PM
 #6

Added link to javadocs to the original post (also posted here so you don't have to scroll to find it):

http://x6763.github.com/BitcoinCrypto/doc/index.html
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!