Exemple #1
0
void RC4EAPOL::write_body(OutputMemoryStream& stream) {
    if (key_.size()) {
        header_.key_length = Endian::host_to_be(static_cast<uint16_t>(key_.size()));
    }
    stream.write(header_);
    stream.write(key_.begin(), key_.end());
}
Exemple #2
0
void RSNEAPOL::write_body(OutputMemoryStream& stream) {
    if (key_.size()) {
        if (!header_.key_t && header_.install) {
            header_.key_length = Endian::host_to_be<uint16_t>(32);
            wpa_length(static_cast<uint16_t>(key_.size()));
        }
        else if (key_.size()) {
            wpa_length(static_cast<uint16_t>(key_.size()));
        }
    }
    stream.write(header_);
    stream.write(key_.begin(), key_.end());
}
Exemple #3
0
void Dot11AssocRequest::write_fixed_parameters(OutputMemoryStream& stream) {
    stream.write(body_);
}
Exemple #4
0
void Dot11Disassoc::write_fixed_parameters(OutputMemoryStream& stream) {
    stream.write(body_);
}
Exemple #5
0
void Dot11ReAssocResponse::write_fixed_parameters(OutputMemoryStream& stream) {
    stream.write(body_);
}
Exemple #6
0
void Dot11Authentication::write_fixed_parameters(OutputMemoryStream& stream) {
    stream.write(body_);
}
Exemple #7
0
void IPv6::write_header(const ext_header& header, OutputMemoryStream& stream) {
    const uint8_t length = header.length_field() / 8;
    stream.write(header.option());
    stream.write(length);
    stream.write(header.data_ptr(), header.data_size());
}