For Programmers: Free Programming Magazines  


Home > Archive > Smartphone Developer Forum > March 2006 > Correct usage of FileDrmStoreContent() ?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Correct usage of FileDrmStoreContent() ?
Rajan

2005-05-18, 8:58 am

What is the correct way to use FileDrmStoreContent() ? Whatever I do, I get a
Failure with GetLastError() returning "5" (ACCESS_DENIED). The WM5 enabled
smartphone I am having has a DRM engine. The cab I am installing the code
with is unsigned. I was told that FDRM APIs is not part of the Trusted APIs
list.

Here is what I am doing,

HRESULT result = FileDrmStoreContent(TEXT("\\test\\test.dm"),
TEXT("\\test\\test.jpeg"), NULL, NULL, &size);

test.dm is a OMA DRM v1 message with no rights object. Initially I had it
just as a Multi-Part boundary message like,
--boundary-1
Content-type: ...

--boundary-1--

and that didn't work. So, I also tried adding the following before
--boudary-1 as the API doc says that the file should start with
"Content-type:..." and that too didn't help.

Content-type: application/vnd.oma.drm.mesage;
boundary=boundary-1

Is FileDrmStoreContent() the only way to FDRM protect the content?

Your help is appreciated.

thanks,
Rajan


Rajan

2005-05-23, 8:58 am

HRESULT for the call seems to be returning E_FDRM_NOTDRMOBJECT, though I am
sure that the DRM message provided is valid. Any clues?

"Rajan" wrote:

> What is the correct way to use FileDrmStoreContent() ? Whatever I do, I get a
> Failure with GetLastError() returning "5" (ACCESS_DENIED). The WM5 enabled
> smartphone I am having has a DRM engine. The cab I am installing the code
> with is unsigned. I was told that FDRM APIs is not part of the Trusted APIs
> list.
>
> Here is what I am doing,
>
> HRESULT result = FileDrmStoreContent(TEXT("\\test\\test.dm"),
> TEXT("\\test\\test.jpeg"), NULL, NULL, &size);
>
> test.dm is a OMA DRM v1 message with no rights object. Initially I had it
> just as a Multi-Part boundary message like,
> --boundary-1
> Content-type: ...
>
> --boundary-1--
>
> and that didn't work. So, I also tried adding the following before
> --boudary-1 as the API doc says that the file should start with
> "Content-type:..." and that too didn't help.
>
> Content-type: application/vnd.oma.drm.mesage;
> boundary=boundary-1
>
> Is FileDrmStoreContent() the only way to FDRM protect the content?
>
> Your help is appreciated.
>
> thanks,
> Rajan
>
>

Rajan

2005-06-10, 8:58 am

The following at the top of the DRM message file gets it to work,
Content-type: application/vnd.oma.drm.message\r\n\r\n and then followed by
the actual DRM message

- Rajan

"Rajan" wrote:
[color=darkred]
> HRESULT for the call seems to be returning E_FDRM_NOTDRMOBJECT, though I am
> sure that the DRM message provided is valid. Any clues?
>
> "Rajan" wrote:
>
gynet_80

2006-03-16, 11:27 pm

quote:
Originally posted by Rajan
The following at the top of the DRM message file gets it to work,
Content-type: application/vnd.oma.drm.message\r\n\r\n and then followed by
the actual DRM message

- Rajan

"Rajan" wrote:
[color=darkred]
> HRESULT for the call seems to be returning E_FDRM_NOTDRMOBJECT, though I am
> sure that the DRM message provided is valid. Any clues?
>
> "Rajan" wrote:
>
hi, can you give some example on how to used the FileDrmStoreContent()?

i have download a gif file(with DRM) from lockstream.com and it is save as LSDD.dd

currently i am trying to use FileDrmStoreContent to save it from .dd to .gif/.jpg file.

i have try FileDrmStoreContent() but it doesn't work...:(

can you give me some example on how to do this?


cheers
:)

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com