[Virtuous Ten Studio] Therev29:
Can't sign with custom keys?

Hoping for some direction on this as I'm probably skipping something simple but this is my first run at making keys and certs so I'm kinda lost.

This is from the VTS log after the signing fails.

21:45:11.807: [Debug] - <>c__DisplayClass38.<BuildApkAsync>b__37: 'Signing with custom keys'
21:45:11.807: [Debug] - <>c__DisplayClass38.<BuildApkAsync>b__37: 'Custom cert: C:\Users\\Desktop\keytool_crt.pem'
21:45:11.807: [Debug] - <>c__DisplayClass38.<BuildApkAsync>b__37: 'Custom key: C:\Users\\Desktop\therev29key-privkey.pk8'
21:45:11.807: [Normal] - SignApkTool.SignApk: 'Signing file: C:\Users\\Documents\Virtuous Ten Studio\Projects\Sense Skins\REDZound_Sense_4.1_Skin-signed\Binary\REDZound_Sense4_Skin.apk'
21:45:11.840: [Debug] - FileSystem.GetJavaInstallationPath: 'Found java path: C:\Program Files (x86)\Java\jre6\bin\java.exe'
21:45:11.840: [Debug] - SignApkTool.SignApk: 'SignApk args: -jar "C:\Program Files (x86)\Virtuous Ten Studio\External\Sign\signapk.jar" "C:\Users\\Desktop\keytool_crt.pem" "C:\Users\\Desktop\therev29key-privkey.pk8" "C:\Users\\Documents\Virtuous Ten Studio\Projects\Sense Skins\REDZound_Sense_4.1_Skin-signed\Binary\REDZound_Sense4_Skin.apk.bak" "C:\Users\\Documents\Virtuous Ten Studio\Projects\Sense Skins\REDZound_Sense_4.1_Skin-signed\Binary\REDZound_Sense4_Skin.apk"'
21:45:12.166: [Debug] - SignApkTool.SignApk: 'SignApk: java.security.spec.InvalidKeySpecException: [B]Inappropriate key specification: invalid key format'[/B]
21:45:12.167: [Debug] - SignApkTool.SignApk: 'SignApk:	at sun.security.provider.DSAKeyFactory.engineGeneratePrivate(Unknown Source)'
21:45:12.167: [Debug] - SignApkTool.SignApk: 'SignApk:	at java.security.KeyFactory.generatePrivate(Unknown Source)'
21:45:12.167: [Debug] - SignApkTool.SignApk: 'SignApk:	at com.android.signapk.SignApk.readPrivateKey(SignApk.java:149)'
21:45:12.167: [Debug] - SignApkTool.SignApk: 'SignApk:	at com.android.signapk.SignApk.main(SignApk.java:319)'

So this Inappropriate key specification: invalid key format' is my doing if I'm correct:o but I'm not sure what I'm doing wrong.

I know i need .pk8 key and a .pem cert but don't think I'm going about it right... actually I know I'm not, kinda lost really....:(

This is what I'm doing- I make the key:

keytool -genkey -v -keystore therev29key.keystore -alias therevkey -keyalg RSA -keysize 1024 -validity 10000

export to p12:

keytool -importkeystore -srckeystore therev29key.keystore -destkeystore therev29key.p12 -srcstoretype JKS -deststoretype PKCS12 -srcstorepass MYPASSWORD -deststorepass MYPASSWORD -srcalias therevkey -destalias therevkey -srckeypass MYPASSWORD -destkeypass MYPASSWORD -noprompt

take the p12 from keytool and switch to openssl then convert the p12 to pem:

openssl pkcs12 -in therev29key.p12 -out therev29key.pem

Then take the pem to .pk8.

openssl pkcs8 -in therev29key.pem -topk8 -nocrypt -out therev29key-privkey.pk8

This is what I select in VTS.

for the cert I am doing this:

>keytool -exportcert -alias therevkey -keypass MYPASSWORD -keystore therev29key.keystore -storepass MYPASSWORD -rfc -file keytool_crt.pem

Don't ask me why for any of the above I'm not too sure it's all I've been able to gather after some hours of searching and results are all over the place. Any help / guidance would be appreciated!!!