mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-11-26 10:39:23 +01:00
wscutil: Add wsc_build_wsc_ack
This commit is contained in:
parent
9c9ecfa239
commit
983d598d1d
@ -2304,6 +2304,27 @@ done:
|
||||
return ret;
|
||||
}
|
||||
|
||||
uint8_t *wsc_build_wsc_ack(const struct wsc_ack *ack, size_t *out_len)
|
||||
{
|
||||
struct wsc_attr_builder *builder;
|
||||
uint8_t *ret;
|
||||
|
||||
builder = wsc_attr_builder_new(256);
|
||||
build_version(builder, 0x10);
|
||||
build_message_type(builder, WSC_MESSAGE_TYPE_WSC_ACK);
|
||||
build_enrollee_nonce(builder, ack->enrollee_nonce);
|
||||
build_registrar_nonce(builder, ack->registrar_nonce);
|
||||
|
||||
if (!ack->version2)
|
||||
goto done;
|
||||
|
||||
START_WFA_VENDOR_EXTENSION();
|
||||
|
||||
done:
|
||||
ret = wsc_attr_builder_free(builder, false, out_len);
|
||||
return ret;
|
||||
}
|
||||
|
||||
uint8_t *wsc_build_nack(const struct wsc_nack *nack, size_t *out_len)
|
||||
{
|
||||
struct wsc_attr_builder *builder;
|
||||
|
@ -602,6 +602,7 @@ uint8_t *wsc_build_m7_encrypted_settings(
|
||||
uint8_t *wsc_build_m8(const struct wsc_m8 *m8, const uint8_t *encrypted,
|
||||
size_t encrypted_len, size_t *out_len);
|
||||
|
||||
uint8_t *wsc_build_wsc_ack(const struct wsc_ack *ack, size_t *out_len);
|
||||
uint8_t *wsc_build_nack(const struct wsc_nack *nack, size_t *out_len);
|
||||
|
||||
uint8_t *wsc_build_wsc_done(const struct wsc_done *done, size_t *out_len);
|
||||
|
Loading…
Reference in New Issue
Block a user