Visual Basic Examples

ChilkatHOMEAndroid™ASPVisual BasicVB.NETC#iOS (IPhone)Objective-CC++CMFCDelphiFoxProJavaPerl
PHP ExtensionPHP ActiveXPythonPowerShellRubySQL ServerVBScript

VB Examples

Bounced Mail
Bz2
Character Encoding
CSV
Digital Certificates
Digital Signatures
Email
FTP
HTML Conversion
HTTP
IMAP
Encryption
MHT / HTML Email
POP3
RSA
S/MIME
SFTP
SMTP
Socket
Spider
SSH
SSH Key
SSH Tunnel
String
Tar
Upload
XML
XMP
Zip Compression

More Examples...
Amazon S3
Email Object
DKIM / DomainKey
NTLM
DH Key Exchange
DSA
FileAccess
RSS
Atom
Self-Extractor
Service
Bzip2
PPMD
Deflate
LZW


VB Strings
VB Byte Array

 

 

 

 

 

 

 

Verify and Unwrap PCKS7 Signed MIME

Demonstrates calling the Verify method to verify and unwrap PKCS7 signed MIME. The MIME is restored to the original structure that it would have originally had prior to signing. The Verify method works with both detached signatures, as well as opaque/attached signatures.

Download Chilkat MIME ActiveX

Dim mime As New ChilkatMime

Dim success As Long
success = mime.UnlockComponent("Anything for 30-day trial")
If (success = 0) Then
    Text1.Text = Text1.Text & mime.LastErrorText & vbCrLf
    Exit Sub
End If

'  A PKCS7 signature usually embeds both the signing
'  certificate with its public key.  Therefore, it is usually
'  possible to verify a signature without the need to
'  already have the certificate installed.

'  Load the signed MIME from a file...
success = mime.LoadMimeFile("signedMime.txt")
If (success = 0) Then
    Text1.Text = Text1.Text & mime.LastErrorText & vbCrLf
    Exit Sub
End If

'  Verify the signed MIME and restore the MIME
'  to the structure/content it had prior to signing.
Dim verified As Long
verified = mime.Verify()
If (verified = 0) Then
    Text1.Text = Text1.Text & mime.LastErrorText & vbCrLf
    Exit Sub
End If

'  Examine the MIME after signature verification (i.e. "unwrapping")
Text1.Text = Text1.Text & mime.GetMime() & vbCrLf


© 2000-2012 Chilkat Software, Inc. All Rights Reserved.