Lines Matching refs:opt

590 print_ipoptions(const uchar_t *opt, int optlen)
609 len = opt[1];
611 switch (opt[0]) {
622 print_route(opt);
631 print_ripso(opt);
636 print_cipso(opt);
642 print_route(opt);
653 print_route(opt);
658 opt[0], len, truncstr,
659 tohex((char *)&opt[2], len - 2));
667 opt += len;
673 print_route(const uchar_t *opt)
679 len = opt[1];
680 pointer = opt[2];
686 opt += (IPOPT_OFFSET + 1);
692 memcpy((char *)&addr, opt, sizeof (addr));
701 opt += sizeof (addr);
1188 print_ripso(const uchar_t *opt)
1195 prot_len = opt[1] - 3;
1203 "Type = Basic Security Option (%d), Length = %d", opt[0], opt[1]);
1208 ripso_class = get_pair_byval(ripso_class_tbl, (int)opt[2]);
1211 "Classification = Unknown (0x%02x)", opt[2]);
1226 if (opt[3 + i] & ripso_prot_tbl[index].val) {
1241 if ((opt[3 + i] & 1) == 0)
1256 * Note: opt starts with "Tag Type":
1262 cipso_high(const uchar_t *opt)
1266 if (((int)opt[1] + 6) < IP_MAX_OPT_LENGTH)
1268 for (i = 0; i < ((int)opt[1] - 3); i++)
1269 if (opt[3 + i] != 0xff)
1277 * Note: opt starts with "Tag Type":
1283 cipso2sl(const uchar_t *opt, bslabel_t *sl, int *high)
1289 taglen = opt[1];
1292 if (cipso_high(opt)) {
1296 LCLASS_SET((_bslabel_impl_t *)sl, opt[3]);
1298 q[i] = opt[TSOL_TT1_MIN_LENGTH + i];
1304 interpret_cipso_tagtype1(const uchar_t *opt)
1310 taglen = opt[1];
1316 "Tag Type = %d, Tag Length = %d", opt[0], opt[1]);
1318 "Sensitivity Level = 0x%02x", opt[3]);
1322 opt[TSOL_TT1_MIN_LENGTH + i]);
1334 cipso2sl(opt, &sl, &ishigh);
1363 interpret_cipso_tagtype3(const uchar_t *opt)
1384 tagtype = *opt++;
1385 (void) memcpy(&mask, opt + 3, sizeof (mask));
1389 "Generation = 0x%02x%02x%02x, Mask = 0x%04x", opt[0], opt[1],
1390 opt[2], mask);
1391 opt += 3 + sizeof (mask);
1400 (void) memcpy(&token, opt, sizeof (token));
1401 opt += sizeof (token);
1417 print_cipso(const uchar_t *opt)
1424 optlen = opt[1];
1437 "Type = CIPSO (%d), Length = %d", opt[0], opt[1]);
1438 (void) memcpy(&doi, opt + 2, sizeof (doi));
1442 if (opt[1] == TSOL_CIPSO_MIN_LENGTH) { /* no tags */
1449 opt += TSOL_CIPSO_MIN_LENGTH;
1462 switch (opt[0]) {
1464 taglen = interpret_cipso_tagtype1(opt);
1467 taglen = interpret_cipso_tagtype3(opt);
1471 "Unknown Tag Type %d", opt[0]);
1484 opt += taglen;