[prev in list] [next in list] [prev in thread] [next in thread] 

List:       ms-cryptoapi
Subject:    Re: Getting  error "The message has been tampered with"
From:       Carlos Lopez <clopez () MICROSOFT ! COM>
Date:       2000-04-14 14:12:30
[Download RAW message or body]

I've had the same problem.  Make sure you include a CRLF at the end, after
Signed Message.  You're supposed to sign that as well (so I have noticed).
So the string you're supposed to sign is
"Content-Type:text/plain;charset=\"iso-8859-1\"\r\nContent-Transfer-Encoding
:7Bit\r\n\r\nSignedMessage\r\n".

If you have any other CRLF after the message that's fine, just don't sign
it.

Thanks
Carlos

 -----Original Message-----
From: brk [mailto:brk@vsofti.stph.net]
Sent: Thursday, April 13, 2000 8:54 PM
To: Microsoft Cryptographic API
Cc: Carlos Lopez
Subject: Re: Re: Getting error "The message has been tampered with"



Hi,

     The S/MIME message with which I am getting problems is given below. I
generated the digital signature for the body of the message  along with its
header (the part which is in bold).

Content-Type: text/plain;charset="iso-8859-1"
Content-Transfer-Encoding: 7bit

Signed Message

The above part is the one which I have signed.


The Entire message source is:


Return-Path: < brk@vsofti.stph.net <mailto:brk@vsofti.stph.net> >
Received: from 196.12.47.65 ([196.12.47.70])
 by relay.vsofti.stph.net (8.9.3/8.9.3) with SMTP id JAA26280
 for < brk@vsofti.stph.net <mailto:brk@vsofti.stph.net> >; Thu, 13 Apr 2000
09:05:09 +0530
Date: Thu, 13 Apr 2000 09:05:09 +0530
Message-Id: < 200004130335.JAA26280@relay.vsofti.stph.net
<mailto:200004130335.JAA26280@relay.vsofti.stph.net> >
From: ""< brk@vsofti.stph.net <mailto:brk@vsofti.stph.net> >
To: brk@vsofti.stph.net <mailto:brk@vsofti.stph.net>
Subject: Signed Message
MIME-Version: 1.0
Content-Type: multipart/signed;
 protocol="application/x-pkcs7-signature";
 micalg=SHA1;
 boundary="=gc0p4Jq0M2Yt08jU534c0p"
X-Priority: 3
X-VSILMail-Priority: Normal
X-Mailer: VS 1.2a
Sensitivity: Normal
X-UIDL: 57e83d21b5dc7fed73c0dd2f68f0135e

This is a multi-part message in MIME format.


Signed Message

["smime.p7s" (application/x-pkcs7-signature)]
Can this be helpful to find out the solution.

Thanks a lot,
Ravi


----- Original Message -----
From: Carlos Lopez < clopez@MICROSOFT.COM <mailto:clopez@MICROSOFT.COM> >
To: < CryptoAPI@DISCUSS.MICROSOFT.COM
<mailto:CryptoAPI@DISCUSS.MICROSOFT.COM> >
Sent: Thursday, April 13, 2000 11:18 PM
Subject: Re: Getting error "The message has been tampered with"

> Perhaps you can paste your S/MIME message and point out exactly what text
> you are signing.
>
> Carlos
>
> -----Original Message-----
> From: Fabro, Loic [ mailto:lfabro@MICROSTRATEGY.COM
<mailto:lfabro@MICROSTRATEGY.COM> ]
> Sent: Thursday, April 13, 2000 6:24 AM
> To: CryptoAPI@DISCUSS.MICROSOFT.COM
<mailto:CryptoAPI@DISCUSS.MICROSOFT.COM>
> Subject: Re: Getting error "The message has been tampered with"
>
>
> Hi,
>
> Could you post the complete "error" message, the "From" field value of
your
> email and the "Certificate user name" ?
>
> One thing to consider is the fact that the actual S/Mime
> standard/implementations is/are extremely picky! If your certificate was
> issued to the user "Fabro, Loic < lfabro@domain.com
<mailto:lfabro@domain.com> >" then the "From:" field
> of your email MUST reflect this _exact_ value, otherwise you will get an
> "error". For example, "Loic Fabro < lfabro@domain.com
<mailto:lfabro@domain.com> >", " lfabro@domain.com
<mailto:lfabro@domain.com> "
> and
> "Fabro, Loic " lfabro@domain.com <mailto:lfabro@domain.com> "" are not
considered the same user....
>
> Lotus Notes V5, for example, tells you "The signature can not be verified"
> (Sorry, I do not have the exact message in mind! ;-) ).
>
> Hope This Help!
> Loic.
>
> ______________
> Loïc Fabro
>
>
>
> -----Original Message-----
> From: brk [ mailto:brk@VSOFTI.STPH.NET <mailto:brk@VSOFTI.STPH.NET> ]
> Sent: Thursday, April 13, 2000 6:49 AM
> To: CryptoAPI@DISCUSS.MICROSOFT.COM
<mailto:CryptoAPI@DISCUSS.MICROSOFT.COM>
> Subject: Getting error "The message has been tampered with"
>
>
> Hi,
>
>     I am implementing S/MIME, where I am facing some problem with
generation
> of the digital signature.I have generated a detached signature using the
> CryptSignMessage function. I am sending the detached signature through a
> mail agent by following all the S/MIME specifications. Unfortunately the
> signed message which I am sending is recognised by Outlook express as well
> as Netscape messenger as a signed one but when I open the message it was
> showing the security warning "the message has been tampered with". I am
> using the SHA1 for hashing. I think  outlook express and netscape are not
> able to verify my detached signature.
> I even generated the detached signature using low level functions also,
> still the same error is coming. Everything seems to be right on my side.
Can
> anybody there help me out with a solution ? Does anybody know which
> functions the outlook express uses for generating signature and for
> verification?
>
> I really appreciate anybody's help. All experts there please show me a
way.
>
> Thanks in advance,
> Ravi
>
> ----------------------------------------------------------------
> Users Guide http://msdn.microsoft.com/workshop/essentials/mail.asp
<http://msdn.microsoft.com/workshop/essentials/mail.asp>
> contains important info including how to unsubscribe.  Save time, search
> the archives at http://discuss.microsoft.com/archives/index.html
<http://discuss.microsoft.com/archives/index.html>
>
> ----------------------------------------------------------------
> Users Guide http://msdn.microsoft.com/workshop/essentials/mail.asp
<http://msdn.microsoft.com/workshop/essentials/mail.asp>
> contains important info including how to unsubscribe.  Save time, search
> the archives at http://discuss.microsoft.com/archives/index.html
<http://discuss.microsoft.com/archives/index.html>
>
> ----------------------------------------------------------------
> Users Guide http://msdn.microsoft.com/workshop/essentials/mail.asp
<http://msdn.microsoft.com/workshop/essentials/mail.asp>
> contains important info including how to unsubscribe.  Save time, search
> the archives at http://discuss.microsoft.com/archives/index.html
<http://discuss.microsoft.com/archives/index.html>
>

----------------------------------------------------------------
Users Guide http://msdn.microsoft.com/workshop/essentials/mail.asp
contains important info including how to unsubscribe.  Save time, search
the archives at http://discuss.microsoft.com/archives/index.html


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic