This commit is contained in:
purplerain 2023-07-10 00:10:46 +00:00
parent 2a351e0cdc
commit f57be82572
Signed by: purplerain
GPG key ID: F42C07F07E2E35B7
704 changed files with 20524 additions and 10572 deletions

View file

@ -1,4 +1,4 @@
/* $OpenBSD: obj_dat.c,v 1.53 2023/05/23 11:51:12 tb Exp $ */
/* $OpenBSD: obj_dat.c,v 1.54 2023/07/08 12:27:51 beck Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
@ -280,6 +280,7 @@ OBJ_cleanup(void)
lh_ADDED_OBJ_free(added);
added = NULL;
}
LCRYPTO_ALIAS(OBJ_cleanup);
int
OBJ_new_nid(int num)
@ -290,6 +291,7 @@ OBJ_new_nid(int num)
new_nid += num;
return (i);
}
LCRYPTO_ALIAS(OBJ_new_nid);
int
OBJ_add_object(const ASN1_OBJECT *obj)
@ -338,6 +340,7 @@ OBJ_add_object(const ASN1_OBJECT *obj)
ASN1_OBJECT_free(o);
return (NID_undef);
}
LCRYPTO_ALIAS(OBJ_add_object);
ASN1_OBJECT *
OBJ_nid2obj(int n)
@ -366,6 +369,7 @@ OBJ_nid2obj(int n)
}
}
}
LCRYPTO_ALIAS(OBJ_nid2obj);
const char *
OBJ_nid2sn(int n)
@ -394,6 +398,7 @@ OBJ_nid2sn(int n)
}
}
}
LCRYPTO_ALIAS(OBJ_nid2sn);
const char *
OBJ_nid2ln(int n)
@ -422,6 +427,7 @@ OBJ_nid2ln(int n)
}
}
}
LCRYPTO_ALIAS(OBJ_nid2ln);
static int
obj_cmp(const ASN1_OBJECT * const *ap, const unsigned int *bp)
@ -475,6 +481,7 @@ OBJ_obj2nid(const ASN1_OBJECT *a)
return (NID_undef);
return (nid_objs[*op].nid);
}
LCRYPTO_ALIAS(OBJ_obj2nid);
/* Convert an object name into an ASN1_OBJECT
* if "noname" is not set then search for short and long names first.
@ -495,12 +502,14 @@ OBJ_txt2obj(const char *s, int no_name)
return t2i_ASN1_OBJECT_internal(s);
}
LCRYPTO_ALIAS(OBJ_txt2obj);
int
OBJ_obj2txt(char *buf, int buf_len, const ASN1_OBJECT *aobj, int no_name)
{
return i2t_ASN1_OBJECT_internal(aobj, buf, buf_len, no_name);
}
LCRYPTO_ALIAS(OBJ_obj2txt);
int
OBJ_txt2nid(const char *s)
@ -513,6 +522,7 @@ OBJ_txt2nid(const char *s)
ASN1_OBJECT_free(obj);
return nid;
}
LCRYPTO_ALIAS(OBJ_txt2nid);
int
OBJ_ln2nid(const char *s)
@ -535,6 +545,7 @@ OBJ_ln2nid(const char *s)
return (NID_undef);
return (nid_objs[*op].nid);
}
LCRYPTO_ALIAS(OBJ_ln2nid);
int
OBJ_sn2nid(const char *s)
@ -557,6 +568,7 @@ OBJ_sn2nid(const char *s)
return (NID_undef);
return (nid_objs[*op].nid);
}
LCRYPTO_ALIAS(OBJ_sn2nid);
const void *
OBJ_bsearch_(const void *key, const void *base, int num, int size,
@ -564,6 +576,7 @@ OBJ_bsearch_(const void *key, const void *base, int num, int size,
{
return OBJ_bsearch_ex_(key, base, num, size, cmp, 0);
}
LCRYPTO_ALIAS(OBJ_bsearch_);
const void *
OBJ_bsearch_ex_(const void *key, const void *base_, int num, int size,
@ -646,6 +659,7 @@ OBJ_create_objects(BIO *in)
}
/* return(num); */
}
LCRYPTO_ALIAS(OBJ_create_objects);
int
OBJ_create(const char *oid, const char *sn, const char *ln)
@ -676,6 +690,7 @@ OBJ_create(const char *oid, const char *sn, const char *ln)
free(buf);
return (ok);
}
LCRYPTO_ALIAS(OBJ_create);
size_t
OBJ_length(const ASN1_OBJECT *obj)
@ -688,6 +703,7 @@ OBJ_length(const ASN1_OBJECT *obj)
return obj->length;
}
LCRYPTO_ALIAS(OBJ_length);
const unsigned char *
OBJ_get0_data(const ASN1_OBJECT *obj)
@ -697,3 +713,4 @@ OBJ_get0_data(const ASN1_OBJECT *obj)
return obj->data;
}
LCRYPTO_ALIAS(OBJ_get0_data);