Medium.getProperty() returns VBOX_E_OBJECT_NOT_FOUND if the given key is not 
found. This indicates that the medium is not encrypted
but returns an error which is not what Ian wanted.

Regards,
Alexander

> On 03.05.2016 13:19, Klaus Espenlaub <klaus.espenl...@oracle.com> wrote:
> 
> Alexander,
> 
> should IMedium.getProperty("CRYPT/KeyStore", val.asOutParam()) (using C++ish 
> pseudocode) work, i.e. leave val as empty when the medium is not encrypted 
> and return some non-empty string if it is encrypted?
> 
> Sounds like it's a lot cheaper than getting all properties and fishing out 
> what one wants...
> 
> Klaus
> 
> On 30.04.2016 05:47, Ian Chapman wrote:
>> Hi Alexander,
>> 
>> Perfect, exactly what I need, thanks.
>> 
>> 
>>> you can check whether the „CRYPT/KeyStore“ medium property exists by
>>> querying
>>> all properties with IMedium::getProperties.
>>> 
>>> Regards,
>>> Alexander
>>> 
>>>> On 28.04.2016 12:52, Ian Chapman <packa...@amiga-hardware.com> wrote:
>>>> 
>>>> Hi,
>>>> 
>>>> Is it possible with the current API to check wether an IMedium is
>>>> encrypted or not _without_ VirtualBox returning an error if it isn't?
>>>> 
>>>> --
>>>> Ian Chapman.
> _______________________________________________
> vbox-dev mailing list
> vbox-dev@virtualbox.org
> https://www.virtualbox.org/mailman/listinfo/vbox-dev

Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail

_______________________________________________
vbox-dev mailing list
vbox-dev@virtualbox.org
https://www.virtualbox.org/mailman/listinfo/vbox-dev

Reply via email to