Lines Matching refs:attrs

1214 static void STORE_ATTR_INFO_attr_free(STORE_ATTR_INFO *attrs,
1217 if (ATTR_IS_SET(attrs, code)) {
1222 STORE_ATTR_INFO_modify_cstr(attrs, code, NULL, 0);
1229 STORE_ATTR_INFO_modify_sha1str(attrs, code, NULL, 0);
1233 STORE_ATTR_INFO_modify_dn(attrs, code, NULL);
1236 STORE_ATTR_INFO_modify_number(attrs, code, NULL);
1244 int STORE_ATTR_INFO_free(STORE_ATTR_INFO *attrs)
1246 if (attrs) {
1249 STORE_ATTR_INFO_attr_free(attrs, i);
1250 OPENSSL_free(attrs);
1255 char *STORE_ATTR_INFO_get0_cstr(STORE_ATTR_INFO *attrs, STORE_ATTR_TYPES code)
1257 if (!attrs) {
1262 if (ATTR_IS_SET(attrs, code))
1263 return attrs->values[code].cstring;
1268 unsigned char *STORE_ATTR_INFO_get0_sha1str(STORE_ATTR_INFO *attrs,
1271 if (!attrs) {
1276 if (ATTR_IS_SET(attrs, code))
1277 return attrs->values[code].sha1string;
1282 X509_NAME *STORE_ATTR_INFO_get0_dn(STORE_ATTR_INFO *attrs,
1285 if (!attrs) {
1290 if (ATTR_IS_SET(attrs, code))
1291 return attrs->values[code].dn;
1296 BIGNUM *STORE_ATTR_INFO_get0_number(STORE_ATTR_INFO *attrs,
1299 if (!attrs) {
1304 if (ATTR_IS_SET(attrs, code))
1305 return attrs->values[code].number;
1310 int STORE_ATTR_INFO_set_cstr(STORE_ATTR_INFO *attrs, STORE_ATTR_TYPES code,
1313 if (!attrs) {
1318 if (!ATTR_IS_SET(attrs, code)) {
1319 if ((attrs->values[code].cstring = BUF_strndup(cstr, cstr_size)))
1328 int STORE_ATTR_INFO_set_sha1str(STORE_ATTR_INFO *attrs, STORE_ATTR_TYPES code,
1331 if (!attrs) {
1336 if (!ATTR_IS_SET(attrs, code)) {
1337 if ((attrs->values[code].sha1string =
1348 int STORE_ATTR_INFO_set_dn(STORE_ATTR_INFO *attrs, STORE_ATTR_TYPES code,
1351 if (!attrs) {
1355 if (!ATTR_IS_SET(attrs, code)) {
1356 if ((attrs->values[code].dn = X509_NAME_dup(dn)))
1365 int STORE_ATTR_INFO_set_number(STORE_ATTR_INFO *attrs, STORE_ATTR_TYPES code,
1368 if (!attrs) {
1373 if (!ATTR_IS_SET(attrs, code)) {
1374 if ((attrs->values[code].number = BN_dup(number)))
1383 int STORE_ATTR_INFO_modify_cstr(STORE_ATTR_INFO *attrs, STORE_ATTR_TYPES code,
1386 if (!attrs) {
1391 if (ATTR_IS_SET(attrs, code)) {
1392 OPENSSL_free(attrs->values[code].cstring);
1393 attrs->values[code].cstring = NULL;
1394 CLEAR_ATTRBIT(attrs, code);
1396 return STORE_ATTR_INFO_set_cstr(attrs, code, cstr, cstr_size);
1399 int STORE_ATTR_INFO_modify_sha1str(STORE_ATTR_INFO *attrs,
1404 if (!attrs) {
1409 if (ATTR_IS_SET(attrs, code)) {
1410 OPENSSL_free(attrs->values[code].sha1string);
1411 attrs->values[code].sha1string = NULL;
1412 CLEAR_ATTRBIT(attrs, code);
1414 return STORE_ATTR_INFO_set_sha1str(attrs, code, sha1str, sha1str_size);
1417 int STORE_ATTR_INFO_modify_dn(STORE_ATTR_INFO *attrs, STORE_ATTR_TYPES code,
1420 if (!attrs) {
1425 if (ATTR_IS_SET(attrs, code)) {
1426 OPENSSL_free(attrs->values[code].dn);
1427 attrs->values[code].dn = NULL;
1428 CLEAR_ATTRBIT(attrs, code);
1430 return STORE_ATTR_INFO_set_dn(attrs, code, dn);
1433 int STORE_ATTR_INFO_modify_number(STORE_ATTR_INFO *attrs,
1436 if (!attrs) {
1441 if (ATTR_IS_SET(attrs, code)) {
1442 OPENSSL_free(attrs->values[code].number);
1443 attrs->values[code].number = NULL;
1444 CLEAR_ATTRBIT(attrs, code);
1446 return STORE_ATTR_INFO_set_number(attrs, code, number);
1472 STORE_ATTR_INFO *attrs = NULL;
1481 if (!attrs)
1482 attrs = STORE_ATTR_INFO_new();
1483 if (attrs == NULL) {
1488 STORE_ATTR_INFO_set_cstr(attrs,
1498 if (!attrs)
1499 attrs = STORE_ATTR_INFO_new();
1500 if (attrs == NULL) {
1505 STORE_ATTR_INFO_set_sha1str(attrs,
1512 if (!attrs)
1513 attrs = STORE_ATTR_INFO_new();
1514 if (attrs == NULL) {
1519 STORE_ATTR_INFO_modify_dn(attrs,
1524 if (!attrs)
1525 attrs = STORE_ATTR_INFO_new();
1526 if (attrs == NULL) {
1531 STORE_ATTR_INFO_modify_number(attrs,
1540 return attrs;