[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [iaik-jce] Problem with running S/MIME example program



Yes.   I found that if I remove the mailcap file, I can no longer send the
plain messages from the SMimeSend test program.   So the file is being
found, but the mappings don't seem to be happening correctly.   I'm not that
familiar with the activation package--is their a way of programatically
querying the MailcapCommandMap to see all MIME types that are mapped?  I
haven't seen anything like that in the javadocs for the activation package.

--Rob Hall
----- Original Message -----
From: "Hiltenkamp, Andreas" <Andreas.Hiltenkamp@healy-hudson.com>
To: <iaik-jce@iaik.at>
Sent: Saturday, March 03, 2001 7:36 AM
Subject: RE: [iaik-jce] Problem with running S/MIME example program


> Are you sure that the runtime you are executing is the runtime where you
put
> the mailcap ?
>
> > Mailcap file search order:
> >
> > The MailcapCommandMap looks in various places in the user's
> > system for mailcap file entries. When requests are made to
> > search for commands in the MailcapCommandMap, it searches
> > mailcap files in the following order:
> >
> > Programatically added entries to the MailcapCommandMap instance.
> > The file .mailcap in the user's home directory.
> > The file <java.home>/lib/mailcap.
> > The file or resource named META-INF/mailcap.
> > The file or resource named META-INF/mailcap.default (usually
> > found only in the activation.jar file).
>
> This info ist found at
>
http://java.sun.com/products/javabeans/glasgow/javadocs/javax/activation/Mai
> lcapCommandMap.html
>
> try to put the mailcap in in your home directory
> or use the complete path to the java exe when you start the program
>
> hope it helps
>
> andi
>
>
> > -----Original Message-----
> > From: Robert W. Hall [mailto:robh@dsoft-tech.com]
> > Sent: Freitag, 2. März 2001 23:59
> > To: iaik-jce@iaik.at
> > Subject: [iaik-jce] Problem with running S/MIME example program
> >
> >
> > Hello,
> >
> > I'm doing some tests with the IAIK JCE (full version) and
> > IAIK S/MIME for
> > Java. I'm trying to run the example program (SMimeSend.java)
> > and the plain
> > text test works fine, but when I try and send myself a signed message
> > (explicitly signed) I run into this error:
> >
> > sending explicitly signed message...
> > javax.mail.SendFailedException: Sending failed;
> >   nested exception is:
> >         javax.mail.MessagingException: IOException while
> > sending message;
> >   nested exception is:
> >         javax.activation.UnsupportedDataTypeException: no
> > object DCH for
> > MIME type application/x-pkcs7-signature; name=smime.p7s
> >         at javax.mail.Transport.send0(Transport.java:219)
> >         at javax.mail.Transport.send(Transport.java:81)
> >         at demo.smime.SMimeSend.start(SMimeSend.java:166)
> >         at demo.smime.SMimeSend.main(SMimeSend.java:500)
> > javax.mail.MessagingException: IOException while sending message;
> >   nested exception is:
> >         javax.activation.UnsupportedDataTypeException: no
> > object DCH for
> > MIME type application/x-pkcs7-signature; name=smime.p7s
> >         at
> > com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:353)
> >         at javax.mail.Transport.send0(Transport.java:164)
> >         at javax.mail.Transport.send(Transport.java:81)
> >         at demo.smime.SMimeSend.start(SMimeSend.java:166)
> >         at demo.smime.SMimeSend.main(SMimeSend.java:500)
> >
> > I get a similar error for sending an implicitly signed
> > message, but the mime
> > type is application/x-pkcs7-mime.
> >
> >
> > I'm using the 'mailcap' file that came with the S/MIME library:
> > # Default mailcap file for the JavaMail System
> > #
> > # for our content-handlers
> > #
> > text/plain;;
> > x-java-content-handler=com.sun.mail.handlers.text_plain
> > multipart/*;;
> > x-java-content-handler=com.sun.mail.handlers.multipart_mixed
> > message/*;;
> > x-java-content-handler=com.sun.mail.handlers.message_rfc822
> > #
> > # IAIK 'mailcap' file
> > #
> > multipart/signed;;
> > x-java-content-handler=iaik.security.smime.signed_content
> > application/x-pkcs7-signature;;
> > x-java-content-handler=iaik.security.smime.signed_content
> > application/x-pkcs7-mime;;
> > x-java-content-handler=iaik.security.smime.encrypted_content
> > application/x-pkcs10;;
> > x-java-content-handler=iaik.security.smime.pkcs10_content
> > application/pkcs7-signature;;
> > x-java-content-handler=iaik.security.smime.signed_content
> > application/pkcs7-mime;;
> > x-java-content-handler=iaik.security.smime.encrypted_content
> > application/pkcs10;;
> > x-java-content-handler=iaik.security.smime.pkcs10_content
> >
> > and it is installed in my JDK lib directory per the
> > documentation.   Yet at
> > run-time, the Java activation framework can't seem to map the
> > handler.   Any
> > ideas?
> >
> > Rob
> >
> > --
> > Mailinglist-archive at
> > http://jcewww.iaik.at/mailarchive/iaik-jce/jcethreads.html
> >
> > To unsubscribe send an email to listserv@iaik.at with the
> > folowing content: UNSUBSCRIBE iaik-jce
> >
> >
> --
> Mailinglist-archive at
http://jcewww.iaik.at/mailarchive/iaik-jce/jcethreads.html
>
> To unsubscribe send an email to listserv@iaik.at with the folowing
content: UNSUBSCRIBE iaik-jce
>

--
Mailinglist-archive at http://jcewww.iaik.at/mailarchive/iaik-jce/jcethreads.html

To unsubscribe send an email to listserv@iaik.at with the folowing content: UNSUBSCRIBE iaik-jce