package sketch.avengergear.com;

import android.app.Activity;
import android.os.Bundle;

public class sketchUI extends Activity
{
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState)
    {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
    }
}

@@ -49,294 +49,1842 @@
 app.
-Activity;%0Aimport android.os.Bundle;%0A%0Apublic class sketchUI extends Activity%0A%7B%0A    /** Called when the activity is first created. */%0A    @Override%0A    public void onCreate(Bundle savedInstanceState)%0A    %7B%0A        super.onCreate(savedInstanceState);%0A        setContentView(R.layout.main);
+Service;%0Aimport android.content.Intent;%0Aimport android.os.IBinder;%0Aimport android.os.RemoteException;%0Aimport android.app.Activity;%0Aimport android.os.Bundle;%0Aimport android.util.Base64;%0Aimport android.util.Log;%0A%0Aimport org.spongycastle.jce.provider.BouncyCastleProvider;%0A%0Aimport java.io.IOException;%0Aimport java.io.InputStreamReader;%0Aimport java.io.UnsupportedEncodingException;%0Aimport java.security.KeyPair;%0Aimport java.security.KeyPairGenerator;%0Aimport java.security.PrivateKey;%0Aimport java.security.PublicKey;%0Aimport java.security.Security;%0Aimport java.security.SecureRandom;%0Aimport java.security.NoSuchAlgorithmException;%0Aimport java.security.NoSuchProviderException;%0Aimport java.util.Arrays;%0Aimport java.util.Map;%0A%0Apublic class sketchUI extends Activity%0A%7B%0A    private static final String TAG = %22SKETCH-UI%22;%0A%0A    static %7B%0A        Security.insertProviderAt(new org.spongycastle.jce.provider.BouncyCastleProvider(), 1);%0A    %7D%0A%0A    /** Called when the activity is first created. */%0A    @Override%0A    public void onCreate(Bundle savedInstanceState)%0A    %7B%0A        super.onCreate(savedInstanceState);%0A        setContentView(R.layout.main);%0A%0A        try %7B %0A            // Create the public and private keys%0A            KeyPairGenerator generator = KeyPairGenerator.getInstance(%22RSA%22, %22BC%22);%0A%0A            SecureRandom random = new SecureRandom();%0A            generator.initialize(2048, random);%0A            KeyPair keyPair = generator.genKeyPair();%0A%0A            byte%5B%5D pri = keyPair.getPrivate().getEncoded();%0A            byte%5B%5D pub = keyPair.getPublic().getEncoded();%0A%0A            Log.v(TAG, keyPair.getPrivate().toString() );%0A%0A        %7D catch (NoSuchProviderException e) %7B%0A            Log.e(TAG, %22No provider exception%22, e);%0A        %7D catch (NoSuchAlgorithmException e) %7B %0A            Log.e(TAG, %22No Algorithum exception%22, e);%0A        %7D%0A
 %0A   
@@ -1888,8 +1888,9 @@
     %7D%0A%7D%0A
+%0A

Initialize BC Private and Public Key gen test