Skip to content

Incompatible with mage #69

@binki

Description

@binki

When using mage (x64 from NETFX 4.8.1 Tools which I believe comes from the .net 4.8.1 SDK), I get the following errors:

"C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8.1 Tools\x64\mage.exe" -update "«redacted».exe.manifest" -CertFile "C:\Users\binki\AppData\Local\Temp\tmpD067.tmp"  -TimestampUri http://timestamp.comodoca.com -csp "Google Cloud KMS Provider" /kc "projects/«redacted»/locations/us/keyRings/binki-test-keyring-01/cryptoKeys/key/cryptoKeyVersions/1"
I0427 22:01:26.895829   35392 logging.cc:81] returning 0x8009002a from EnumKeysFn due to status INVALID_ARGUMENT: at bridge.cc:390: end of enumeration reached: 1 [type.googleapis.com/kmscng.StatusDetails='SECURITY_STATUS=0x8009002a']
I0427 22:01:28.338332   35392 logging.cc:81] returning 0x80090009 from GetKeyPropertyFn due to status INVALID_ARGUMENT: at bridge.cc:42: unsupported flag specified: 1073741824 [type.googleapis.com/kmscng.StatusDetails='SECURITY_STATUS=0x80090009']
I0427 22:01:28.339889   35392 logging.cc:81] returning 0x80090009 from GetKeyPropertyFn due to status INVALID_ARGUMENT: at bridge.cc:42: unsupported flag specified: 1073741824 [type.googleapis.com/kmscng.StatusDetails='SECURITY_STATUS=0x80090009']
I0427 22:01:28.340202   35392 logging.cc:81] returning 0x80090009 from GetKeyPropertyFn due to status INVALID_ARGUMENT: at bridge.cc:42: unsupported flag specified: 1073741824 [type.googleapis.com/kmscng.StatusDetails='SECURITY_STATUS=0x80090009']
I0427 22:01:28.340285   35392 logging.cc:81] returning 0x80090009 from GetKeyPropertyFn due to status INVALID_ARGUMENT: at bridge.cc:42: unsupported flag specified: 1073741824 [type.googleapis.com/kmscng.StatusDetails='SECURITY_STATUS=0x80090009']
I0427 22:01:28.340402   35392 logging.cc:81] returning 0x80090009 from GetKeyPropertyFn due to status INVALID_ARGUMENT: at bridge.cc:42: unsupported flag specified: 1073741824 [type.googleapis.com/kmscng.StatusDetails='SECURITY_STATUS=0x80090009']
I0427 22:01:28.340582   35392 logging.cc:81] returning 0x80090029 from GetKeyPropertyFn due to status NOT_FOUND: at object.cc:146: unsupported property specified: PublicKeyLength [type.googleapis.com/kmscng.StatusDetails='SECURITY_STATUS=0x80090029']
I0427 22:01:28.340655   35392 logging.cc:81] returning 0x80090029 from GetKeyPropertyFn due to status NOT_FOUND: at object.cc:146: unsupported property specified: Length [type.googleapis.com/kmscng.StatusDetails='SECURITY_STATUS=0x80090029']
Internal error, please try again. The requested operation is not supported.

I think the first error is a red herring because it seems that reaching the end of an enumeration is not actually an error, it is just normal course of using NCryptEnumKeys.

The later errors regarding unsupported properties and not being able to return the key length are probably preventing mage from proceeding. Can you please add support for the specified flags and operations to the library?

I understand that mage is probably performing unnecessary operations (not sure why it would need to query the key size when nothing else needs that), but it is a Microsoft-provided tool so the operations it performs should probably be supported by the CNG.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions