[PATCH v2] Add dbus signal for information about server certification

Michael Chang mchang at novell.com
Tue Jul 5 07:11:37 EDT 2011


2011/7/5 Jouni Malinen <j at w1.fi>:
>
>> @@ -2641,6 +2686,12 @@ static const struct wpa_dbus_signal_desc wpas_dbus_interface_signals[] = {
>>  #endif /* CONFIG_P2P */
>> +     { "Certification", WPAS_DBUS_NEW_IFACE_INTERFACE,
>> +       {
>> +               { "certification", "a{sv}", ARG_OUT },
>> +               END_ARGS
>> +       }
>> +     },
>
> I'm not really that familiar with the format used here, but this looks a
> bit odd.. Is that list of arguments really correct?

I think we can translate above struct into "the signal returns an
array of dict entries that key is type String and value is type
Variant". The Variant is used as container to hold any arbitrary
types.

If you try dbus-monitor it would report the signal "Certification" like this

    array [
        dict entry(
            string "depth"
            variant           uint32 1
        )
        dict entry(
            string "subject"
            variant           string "xyzxyz"
        )
        dict entry(
            string "cert_hash"
            variant           string "123456ABCDE"
        )
        dict entry(
            variant           array of bytes [
                  00 11 22 33 44
               ]
        )
    ]

Hope this answers the question and thank you so much for applying the patch. :)

Regards,
Michael Chang


More information about the HostAP mailing list