Chilkat
HOME
Android™
ASP
Visual Basic
VB.NET
C#
iOS (IPhone)
Objective-C
C++
C
MFC
Delphi
FoxPro
Java
Perl
PHP Extension
PHP ActiveX
Python
PowerShell
Ruby
SQL Server
VBScript
OMA DRM - Create DCF FileVisual Basic 6.0 example showing how to create an Open Mobile Alliance DCF file. ' Create a new .dcf file.
Dim omaDrm As New ChilkatOmaDrm
' A Chilkat Crypt unlock code will work here.
omaDrm.UnlockComponent "Anything for 30-day trial"
omaDrm.ContentType = "image/gif"
omaDrm.ContentUri = "cid:my-text-20060925101425-1396302043@site.com"
omaDrm.Headers = "Encryption-Method: AES128CBC;padding=RFC2630" + _
vbCrLf + "Content-Name: ""Orval""" + _
vbCrLf + "Content-Description: ""Orval""" + _
vbCrLf + "Content-Vendor: ""Orval""" + _
vbCrLf + "Icon-Uri: http://www.site.com/icons/orval2.dcf.png"
' Set the initialization vector.
omaDrm.SetEncodedIV "00010203040506070001020304050607", "hex"
' Set the 128-bit encryption key.
omaDrm.Base64Key = "BiVVJOQee6y4PWYL+fbvJA=="
' Load the file to be embedded within the .dcf
omaDrm.LoadUnencryptedFile "orval2.gif"
' Write the DCF file
omaDrm.CreateDcfFile "out.dcf"
|
© 2000-2012 Chilkat Software, Inc. All Rights Reserved.