ndr_print_time_t: void (struct ndr_print *, const char *, time_t)
ndr_print_timespec: void (struct ndr_print *, const char *, const struct timespec *)
ndr_print_timeval: void (struct ndr_print *, const char *, const struct timeval *)
-ndr_print_u16string: void (struct ndr_print *, const char *, const uint16_t *)
+ndr_print_u16string: void (struct ndr_print *, const char *, const unsigned char *)
ndr_print_udlong: void (struct ndr_print *, const char *, uint64_t)
ndr_print_udlongr: void (struct ndr_print *, const char *, uint64_t)
ndr_print_uid_t: void (struct ndr_print *, const char *, uid_t)
ndr_pull_timespec: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, struct timespec *)
ndr_pull_timeval: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, struct timeval *)
ndr_pull_trailer_align: enum ndr_err_code (struct ndr_pull *, size_t)
-ndr_pull_u16string: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, const uint16_t **)
+ndr_pull_u16string: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, const unsigned char **)
ndr_pull_udlong: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint64_t *)
ndr_pull_udlongr: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uint64_t *)
ndr_pull_uid_t: enum ndr_err_code (struct ndr_pull *, ndr_flags_type, uid_t *)
ndr_push_timespec: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const struct timespec *)
ndr_push_timeval: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const struct timeval *)
ndr_push_trailer_align: enum ndr_err_code (struct ndr_push *, size_t)
-ndr_push_u16string: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const uint16_t *)
+ndr_push_u16string: enum ndr_err_code (struct ndr_push *, ndr_flags_type, const unsigned char *)
ndr_push_udlong: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint64_t)
ndr_push_udlongr: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uint64_t)
ndr_push_uid_t: enum ndr_err_code (struct ndr_push *, ndr_flags_type, uid_t)
#include "lib/replace/replace.h"
#include "lib/util/attr.h"
+#include "lib/util/bytearray.h"
#include "librpc/gen_ndr/ndr_gmsa.h"
#include "librpc/gen_ndr/gmsa.h"
-static void assert_utf16_equal(const uint16_t *s1, const uint16_t *s2)
+static void assert_utf16_equal(const unsigned char *s1, const unsigned char *s2)
{
uint16_t c1;
uint16_t c2;
+ size_t n = 0;
assert_non_null(s1);
assert_non_null(s2);
do {
- c1 = *s1++;
- c2 = *s2++;
+ c1 = PULL_LE_U16(s1, n);
+ c2 = PULL_LE_U16(s2, n);
assert_int_equal(c1, c2);
+ n += 2;
} while (c1);
}
const DATA_BLOB blob = {data, sizeof data};
/* The UTF‐16 password contained in the blob. */
- const uint16_t current_password[] = {
- 16781, 38893, 3992, 51373, 15923, 7932, 46125, 2558, 34452,
- 30290, 33629, 52175, 11237, 39662, 24149, 37397, 11132, 19333,
- 4008, 61917, 9782, 34431, 59396, 14004, 57456, 4643, 36018,
- 13809, 19377, 45615, 4500, 41906, 13134, 3922, 30149, 14594,
- 62323, 37627, 63819, 14101, 32226, 28757, 21916, 10026, 4483,
- 50729, 41961, 43820, 37254, 34397, 24410, 18164, 35324, 51276,
- 5135, 22021, 60285, 770, 63905, 6660, 52725, 4490, 8697,
- 38539, 36481, 5923, 48763, 22745, 32851, 6331, 17667, 14586,
- 22153, 50590, 31390, 25994, 64532, 26985, 7286, 6379, 64476,
- 11322, 59188, 19010, 55290, 24783, 14809, 6553, 1291, 20746,
- 50886, 62962, 23379, 44922, 7754, 6910, 29146, 63937, 24509,
- 38781, 60409, 17028, 43589, 36843, 39787, 8730, 7072, 20390,
- 26656, 25846, 19514, 26258, 27121, 38664, 5283, 59418, 35361,
- 47263, 48001, 31518, 4533, 21653, 63671, 65234, 25134, 3297,
- 50225, 38336, 0,
- };
+ const unsigned char current_password[] = {
+ 141, 65, 237, 151, 152, 15, 173, 200, 51, 62, 252, 30, 45,
+ 180, 254, 9, 148, 134, 82, 118, 93, 131, 207, 203, 229, 43,
+ 238, 154, 85, 94, 21, 146, 124, 43, 133, 75, 168, 15, 221,
+ 241, 54, 38, 127, 134, 4, 232, 180, 54, 112, 224, 35, 18,
+ 178, 140, 241, 53, 177, 75, 47, 178, 148, 17, 178, 163, 78,
+ 51, 82, 15, 197, 117, 2, 57, 115, 243, 251, 146, 75, 249,
+ 21, 55, 226, 125, 85, 112, 156, 85, 42, 39, 131, 17, 41,
+ 198, 233, 163, 44, 171, 134, 145, 93, 134, 90, 95, 244, 70,
+ 252, 137, 76, 200, 15, 20, 5, 86, 125, 235, 2, 3, 161,
+ 249, 4, 26, 245, 205, 138, 17, 249, 33, 139, 150, 129, 142,
+ 35, 23, 123, 190, 217, 88, 83, 128, 187, 24, 3, 69, 250,
+ 56, 137, 86, 158, 197, 158, 122, 138, 101, 20, 252, 105, 105,
+ 118, 28, 235, 24, 220, 251, 58, 44, 52, 231, 66, 74, 250,
+ 215, 207, 96, 217, 57, 153, 25, 11, 5, 10, 81, 198, 198,
+ 242, 245, 83, 91, 122, 175, 74, 30, 254, 26, 218, 113, 193,
+ 249, 189, 95, 125, 151, 249, 235, 132, 66, 69, 170, 235, 143,
+ 107, 155, 26, 34, 160, 27, 166, 79, 32, 104, 246, 100, 58,
+ 76, 146, 102, 241, 105, 8, 151, 163, 20, 26, 232, 33, 138,
+ 159, 184, 129, 187, 30, 123, 181, 17, 149, 84, 183, 248, 210,
+ 254, 46, 98, 225, 12, 49, 196, 192, 149, 0, 0};
DATA_BLOB packed_blob = data_blob_null;