email digital signatures

hello ,

i have written a normal java program for digitally signing an email by using my private key and that works fine.
in webmethods i have used the inbuilt serviceso pub:smime but at the point where i need to digitally sign with my private key it will giving an error “invalid private key information”

i have also converted .p12 file into .der and placed in our IS.but it is giving an error…
i am generating private and public key outside and then copying into my servers pub file…

Please could anyone suggest me what can i do…