Home
last modified time | relevance | path

Searched defs:pkey (Results 1 – 25 of 312) sorted by relevance

12345678910>>...13

/netbsd-src/crypto/external/bsd/openssl.old/dist/crypto/evp/
H A Dp_lib.c29 int EVP_PKEY_bits(const EVP_PKEY *pkey) in EVP_PKEY_bits()
36 int EVP_PKEY_security_bits(const EVP_PKEY *pkey) in EVP_PKEY_security_bits()
45 int EVP_PKEY_size(const EVP_PKEY *pkey) in EVP_PKEY_size()
52 int EVP_PKEY_save_parameters(EVP_PKEY *pkey, int mode) in EVP_PKEY_save_parameters()
103 int EVP_PKEY_missing_parameters(const EVP_PKEY *pkey) in EVP_PKEY_missing_parameters()
161 int EVP_PKEY_up_ref(EVP_PKEY *pkey) in EVP_PKEY_up_ref()
178 static int pkey_set_type(EVP_PKEY *pkey, ENGINE *e, int type, const char *str, in pkey_set_type()
288 int EVP_PKEY_get_raw_private_key(const EVP_PKEY *pkey, unsigned char *priv, in EVP_PKEY_get_raw_private_key()
305 int EVP_PKEY_get_raw_public_key(const EVP_PKEY *pkey, unsigned char *pub, in EVP_PKEY_get_raw_public_key()
355 int EVP_PKEY_set_type(EVP_PKEY *pkey, int type) in EVP_PKEY_set_type()
[all …]
/netbsd-src/crypto/external/bsd/openssl/dist/crypto/evp/
H A Dp_legacy.c25 int EVP_PKEY_set1_RSA(EVP_PKEY *pkey, RSA *key) in EVP_PKEY_set1_RSA()
34 RSA *evp_pkey_get0_RSA_int(const EVP_PKEY *pkey) in evp_pkey_get0_RSA_int()
43 const RSA *EVP_PKEY_get0_RSA(const EVP_PKEY *pkey) in EVP_PKEY_get0_RSA()
48 RSA *EVP_PKEY_get1_RSA(EVP_PKEY *pkey) in EVP_PKEY_get1_RSA()
58 int EVP_PKEY_set1_EC_KEY(EVP_PKEY *pkey, EC_KEY *key) in EVP_PKEY_set1_EC_KEY()
69 EC_KEY *evp_pkey_get0_EC_KEY_int(const EVP_PKEY *pkey) in evp_pkey_get0_EC_KEY_int()
78 const EC_KEY *EVP_PKEY_get0_EC_KEY(const EVP_PKEY *pkey) in EVP_PKEY_get0_EC_KEY()
83 EC_KEY *EVP_PKEY_get1_EC_KEY(EVP_PKEY *pkey) in EVP_PKEY_get1_EC_KEY()
H A Dp_lib.c62 int EVP_PKEY_get_bits(const EVP_PKEY *pkey) in EVP_PKEY_get_bits()
74 int EVP_PKEY_get_security_bits(const EVP_PKEY *pkey) in EVP_PKEY_get_security_bits()
86 int EVP_PKEY_save_parameters(EVP_PKEY *pkey, int mode) in EVP_PKEY_save_parameters()
218 int EVP_PKEY_missing_parameters(const EVP_PKEY *pkey) in EVP_PKEY_missing_parameters()
383 EVP_PKEY *pkey = NULL; in new_raw_key_int() local
550 int EVP_PKEY_get_raw_private_key(const EVP_PKEY *pkey, unsigned char *priv, in EVP_PKEY_get_raw_private_key()
582 int EVP_PKEY_get_raw_public_key(const EVP_PKEY *pkey, unsigned char *pub, in EVP_PKEY_get_raw_public_key()
625 EVP_PKEY *pkey = NULL; in new_cmac_key_int() local
680 int EVP_PKEY_set_type(EVP_PKEY *pkey, int type) in EVP_PKEY_set_type()
685 int EVP_PKEY_set_type_str(EVP_PKEY *pkey, const char *str, int len) in EVP_PKEY_set_type_str()
[all …]
H A Dpmeth_check.c49 EVP_PKEY *pkey = ctx->pkey; in evp_pkey_public_check_combined() local
93 EVP_PKEY *pkey = ctx->pkey; in evp_pkey_param_check_combined() local
138 EVP_PKEY *pkey = ctx->pkey; in EVP_PKEY_private_check() local
162 EVP_PKEY *pkey = ctx->pkey; in EVP_PKEY_pairwise_check() local
/netbsd-src/crypto/external/bsd/openssl/dist/crypto/dh/
H A Ddh_ameth.c34 static DH *d2i_dhp(const EVP_PKEY *pkey, const unsigned char **pp, in d2i_dhp()
48 static int i2d_dhp(const EVP_PKEY *pkey, const DH *a, unsigned char **pp) in i2d_dhp()
55 static void int_dh_free(EVP_PKEY *pkey) in int_dh_free()
60 static int dh_pub_decode(EVP_PKEY *pkey, const X509_PUBKEY *pubkey) in dh_pub_decode()
111 static int dh_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in dh_pub_encode()
164 static int dh_priv_decode(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8) in dh_priv_decode()
177 static int dh_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in dh_priv_encode()
227 static int dh_param_decode(EVP_PKEY *pkey, in dh_param_decode()
239 static int dh_param_encode(const EVP_PKEY *pkey, unsigned char **pder) in dh_param_encode()
300 static int int_dh_size(const EVP_PKEY *pkey) in int_dh_size()
[all …]
/netbsd-src/crypto/external/bsd/openssl/dist/crypto/dsa/
H A Ddsa_ameth.c29 static int dsa_pub_decode(EVP_PKEY *pkey, const X509_PUBKEY *pubkey) in dsa_pub_decode()
87 static int dsa_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in dsa_pub_encode()
150 static int dsa_priv_decode(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8) in dsa_priv_decode()
163 static int dsa_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in dsa_priv_encode()
218 static int int_dsa_size(const EVP_PKEY *pkey) in int_dsa_size()
223 static int dsa_bits(const EVP_PKEY *pkey) in dsa_bits()
228 static int dsa_security_bits(const EVP_PKEY *pkey) in dsa_security_bits()
233 static int dsa_missing_parameters(const EVP_PKEY *pkey) in dsa_missing_parameters()
267 static void int_dsa_free(EVP_PKEY *pkey) in int_dsa_free()
320 static int dsa_param_decode(EVP_PKEY *pkey, in dsa_param_decode()
[all …]
/netbsd-src/crypto/external/bsd/openssl/dist/crypto/ec/
H A Dec_ameth.c68 static int eckey_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in eckey_pub_encode()
100 static int eckey_pub_decode(EVP_PKEY *pkey, const X509_PUBKEY *pubkey) in eckey_pub_decode()
148 static int eckey_priv_decode_ex(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8, in eckey_priv_decode_ex()
162 static int eckey_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in eckey_priv_encode()
205 static int int_ec_size(const EVP_PKEY *pkey) in int_ec_size()
210 static int ec_bits(const EVP_PKEY *pkey) in ec_bits()
215 static int ec_security_bits(const EVP_PKEY *pkey) in ec_security_bits()
232 static int ec_missing_parameters(const EVP_PKEY *pkey) in ec_missing_parameters()
272 static void int_ec_free(EVP_PKEY *pkey) in int_ec_free()
346 static int eckey_param_decode(EVP_PKEY *pkey, in eckey_param_decode()
[all …]
H A Decx_meth.c31 static int ecx_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in ecx_pub_encode()
56 static int ecx_pub_decode(EVP_PKEY *pkey, const X509_PUBKEY *pubkey) in ecx_pub_decode()
86 static int ecx_priv_decode_ex(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8, in ecx_priv_decode_ex()
100 static int ecx_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in ecx_priv_encode()
132 static int ecx_size(const EVP_PKEY *pkey) in ecx_size()
137 static int ecx_bits(const EVP_PKEY *pkey) in ecx_bits()
148 static int ecx_security_bits(const EVP_PKEY *pkey) in ecx_security_bits()
157 static void ecx_free(EVP_PKEY *pkey) in ecx_free()
168 static int ecx_key_print(BIO *bp, const EVP_PKEY *pkey, int indent, in ecx_key_print()
205 static int ecx_priv_print(BIO *bp, const EVP_PKEY *pkey, int indent, in ecx_priv_print()
[all …]
/netbsd-src/crypto/external/bsd/openssl.old/dist/crypto/dsa/
H A Ddsa_ameth.c20 static int dsa_pub_decode(EVP_PKEY *pkey, X509_PUBKEY *pubkey) in dsa_pub_decode()
77 static int dsa_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in dsa_pub_encode()
137 static int dsa_priv_decode(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8) in dsa_priv_decode()
203 static int dsa_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in dsa_priv_encode()
255 static int int_dsa_size(const EVP_PKEY *pkey) in int_dsa_size()
260 static int dsa_bits(const EVP_PKEY *pkey) in dsa_bits()
265 static int dsa_security_bits(const EVP_PKEY *pkey) in dsa_security_bits()
270 static int dsa_missing_parameters(const EVP_PKEY *pkey) in dsa_missing_parameters()
324 static void int_dsa_free(EVP_PKEY *pkey) in int_dsa_free()
375 static int dsa_param_decode(EVP_PKEY *pkey, in dsa_param_decode()
[all …]
/netbsd-src/crypto/external/bsd/openssl.old/dist/crypto/dh/
H A Ddh_ameth.c25 static DH *d2i_dhp(const EVP_PKEY *pkey, const unsigned char **pp, in d2i_dhp()
33 static int i2d_dhp(const EVP_PKEY *pkey, const DH *a, unsigned char **pp) in i2d_dhp()
40 static void int_dh_free(EVP_PKEY *pkey) in int_dh_free()
45 static int dh_pub_decode(EVP_PKEY *pkey, X509_PUBKEY *pubkey) in dh_pub_decode()
97 static int dh_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in dh_pub_encode()
150 static int dh_priv_decode(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8) in dh_priv_decode()
202 static int dh_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in dh_priv_encode()
249 static int dh_param_decode(EVP_PKEY *pkey, in dh_param_decode()
262 static int dh_param_encode(const EVP_PKEY *pkey, unsigned char **pder) in dh_param_encode()
347 static int int_dh_size(const EVP_PKEY *pkey) in int_dh_size()
[all …]
/netbsd-src/crypto/external/bsd/openssl.old/dist/crypto/hmac/
H A Dhm_ameth.c21 static int hmac_size(const EVP_PKEY *pkey) in hmac_size()
26 static void hmac_key_free(EVP_PKEY *pkey) in hmac_key_free()
36 static int hmac_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2) in hmac_pkey_ctrl()
54 static int hmac_set_priv_key(EVP_PKEY *pkey, const unsigned char *priv, in hmac_set_priv_key()
76 static int hmac_get_priv_key(const EVP_PKEY *pkey, unsigned char *priv, in hmac_get_priv_key()
/netbsd-src/crypto/external/bsd/openssl.old/dist/crypto/poly1305/
H A Dpoly1305_ameth.c23 static int poly1305_size(const EVP_PKEY *pkey) in poly1305_size()
28 static void poly1305_key_free(EVP_PKEY *pkey) in poly1305_key_free()
38 static int poly1305_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2) in poly1305_pkey_ctrl()
49 static int poly1305_set_priv_key(EVP_PKEY *pkey, const unsigned char *priv, in poly1305_set_priv_key()
70 static int poly1305_get_priv_key(const EVP_PKEY *pkey, unsigned char *priv, in poly1305_get_priv_key()
/netbsd-src/crypto/external/bsd/openssl.old/dist/crypto/siphash/
H A Dsiphash_ameth.c23 static int siphash_size(const EVP_PKEY *pkey) in siphash_size()
28 static void siphash_key_free(EVP_PKEY *pkey) in siphash_key_free()
39 static int siphash_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2) in siphash_pkey_ctrl()
50 static int siphash_set_priv_key(EVP_PKEY *pkey, const unsigned char *priv, in siphash_set_priv_key()
71 static int siphash_get_priv_key(const EVP_PKEY *pkey, unsigned char *priv, in siphash_get_priv_key()
/netbsd-src/crypto/external/bsd/openssl.old/dist/crypto/ec/
H A Decx_meth.c46 static int ecx_key_op(EVP_PKEY *pkey, int id, const X509_ALGOR *palg, in ecx_key_op()
125 static int ecx_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in ecx_pub_encode()
150 static int ecx_pub_decode(EVP_PKEY *pkey, X509_PUBKEY *pubkey) in ecx_pub_decode()
173 static int ecx_priv_decode(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8) in ecx_priv_decode()
198 static int ecx_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in ecx_priv_encode()
230 static int ecx_size(const EVP_PKEY *pkey) in ecx_size()
235 static int ecx_bits(const EVP_PKEY *pkey) in ecx_bits()
246 static int ecx_security_bits(const EVP_PKEY *pkey) in ecx_security_bits()
255 static void ecx_free(EVP_PKEY *pkey) in ecx_free()
268 static int ecx_key_print(BIO *bp, const EVP_PKEY *pkey, int indent, in ecx_key_print()
[all …]
H A Dec_ameth.c75 static int eckey_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in eckey_pub_encode()
153 static int eckey_pub_decode(EVP_PKEY *pkey, X509_PUBKEY *pubkey) in eckey_pub_decode()
202 static int eckey_priv_decode(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8) in eckey_priv_decode()
235 static int eckey_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in eckey_priv_encode()
283 static int int_ec_size(const EVP_PKEY *pkey) in int_ec_size()
288 static int ec_bits(const EVP_PKEY *pkey) in ec_bits()
293 static int ec_security_bits(const EVP_PKEY *pkey) in ec_security_bits()
309 static int ec_missing_parameters(const EVP_PKEY *pkey) in ec_missing_parameters()
348 static void int_ec_free(EVP_PKEY *pkey) in int_ec_free()
422 static int eckey_param_decode(EVP_PKEY *pkey, in eckey_param_decode()
[all …]
/netbsd-src/crypto/external/bsd/openssl/dist/crypto/rsa/
H A Drsa_ameth.c29 static int rsa_param_encode(const EVP_PKEY *pkey, in rsa_param_encode()
53 static int rsa_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in rsa_pub_encode()
76 static int rsa_pub_decode(EVP_PKEY *pkey, const X509_PUBKEY *pubkey) in rsa_pub_decode()
129 static int old_rsa_priv_decode(EVP_PKEY *pkey, in old_rsa_priv_decode()
140 static int old_rsa_priv_encode(const EVP_PKEY *pkey, unsigned char **pder) in old_rsa_priv_encode()
145 static int rsa_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in rsa_priv_encode()
173 static int rsa_priv_decode(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8) in rsa_priv_decode()
185 static int int_rsa_size(const EVP_PKEY *pkey) in int_rsa_size()
190 static int rsa_bits(const EVP_PKEY *pkey) in rsa_bits()
195 static int rsa_security_bits(const EVP_PKEY *pkey) in rsa_security_bits()
[all …]
/netbsd-src/crypto/external/bsd/openssl.old/dist/crypto/rsa/
H A Drsa_ameth.c30 static int rsa_param_encode(const EVP_PKEY *pkey, in rsa_param_encode()
75 static int rsa_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey) in rsa_pub_encode()
95 static int rsa_pub_decode(EVP_PKEY *pkey, X509_PUBKEY *pubkey) in rsa_pub_decode()
136 static int old_rsa_priv_decode(EVP_PKEY *pkey, in old_rsa_priv_decode()
149 static int old_rsa_priv_encode(const EVP_PKEY *pkey, unsigned char **pder) in old_rsa_priv_encode()
154 static int rsa_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey) in rsa_priv_encode()
182 static int rsa_priv_decode(EVP_PKEY *pkey, const PKCS8_PRIV_KEY_INFO *p8) in rsa_priv_decode()
204 static int int_rsa_size(const EVP_PKEY *pkey) in int_rsa_size()
209 static int rsa_bits(const EVP_PKEY *pkey) in rsa_bits()
214 static int rsa_security_bits(const EVP_PKEY *pkey) in rsa_security_bits()
[all …]
/netbsd-src/external/mpl/bind/dist/lib/dns/
H A Dopenssleddsa_link.c63 raw_key_to_ossl(unsigned int key_alg,int private,const unsigned char * key,size_t * key_len,EVP_PKEY ** pkey) raw_key_to_ossl() argument
165 EVP_PKEY *pkey = key->keydata.pkey; openssleddsa_sign() local
217 EVP_PKEY *pkey = key->keydata.pkey; openssleddsa_verify() local
300 EVP_PKEY *pkey = NULL; openssleddsa_generate() local
353 EVP_PKEY *pkey = key->keydata.pkey; openssleddsa_isprivate() local
373 EVP_PKEY *pkey = key->keydata.pkey; openssleddsa_destroy() local
381 EVP_PKEY *pkey = key->keydata.pkey; openssleddsa_todns() local
413 EVP_PKEY *pkey; openssleddsa_fromdns() local
500 eddsa_check(EVP_PKEY * pkey,EVP_PKEY * pubpkey) eddsa_check() argument
516 EVP_PKEY *pkey = NULL, *pubpkey = NULL; openssleddsa_parse() local
604 EVP_PKEY *pkey = NULL, *pubpkey = NULL; openssleddsa_fromlabel() local
[all...]
/netbsd-src/external/mpl/dhcp/bind/dist/lib/dns/
H A Dopenssleddsa_link.c65 size_t *key_len, EVP_PKEY **pkey) { in raw_key_to_ossl()
167 EVP_PKEY *pkey = key->keydata.pkey; in openssleddsa_sign() local
219 EVP_PKEY *pkey = key->keydata.pkey; in openssleddsa_verify() local
302 EVP_PKEY *pkey = NULL; in openssleddsa_generate() local
355 EVP_PKEY *pkey = key->keydata.pkey; in openssleddsa_isprivate() local
375 EVP_PKEY *pkey = key->keydata.pkey; in openssleddsa_destroy() local
383 EVP_PKEY *pkey = key->keydata.pkey; in openssleddsa_todns() local
415 EVP_PKEY *pkey; in openssleddsa_fromdns() local
502 eddsa_check(EVP_PKEY *pkey, EVP_PKEY *pubpkey) { in eddsa_check()
518 EVP_PKEY *pkey = NULL, *pubpkey = NULL; in openssleddsa_parse() local
[all …]
H A Dopensslecdsa_link.c159 EVP_PKEY *pkey = key->keydata.pkey; in opensslecdsa_sign() local
215 EVP_PKEY *pkey = key->keydata.pkey; in opensslecdsa_verify() local
329 EVP_PKEY *pkey; in opensslecdsa_generate() local
376 EVP_PKEY *pkey = key->keydata.pkey; in opensslecdsa_isprivate() local
388 EVP_PKEY *pkey = key->keydata.pkey; in opensslecdsa_destroy() local
397 EVP_PKEY *pkey; in opensslecdsa_todns() local
435 EVP_PKEY *pkey; in opensslecdsa_fromdns() local
503 EVP_PKEY *pkey; in opensslecdsa_tofile() local
608 eckey_to_pkey(EC_KEY *eckey, EVP_PKEY **pkey) { in eckey_to_pkey()
627 EVP_PKEY *pkey = NULL; in finalize_eckey() local
[all …]
/netbsd-src/external/bsd/libfido2/dist/examples/
H A Dutil.c134 EVP_PKEY *pkey = NULL; in read_ec_pubkey() local
166 EVP_PKEY *pkey = NULL; in write_es256_pubkey() local
223 EVP_PKEY *pkey = NULL; in write_es384_pubkey() local
280 EVP_PKEY *pkey = NULL; in read_rsa_pubkey() local
312 EVP_PKEY *pkey = NULL; in write_rs256_pubkey() local
369 EVP_PKEY *pkey = NULL; in read_eddsa_pubkey() local
393 EVP_PKEY *pkey = NULL; in write_eddsa_pubkey() local
/netbsd-src/external/bsd/libfido2/dist/src/
H A Deddsa.c30 EVP_PKEY_get_raw_public_key(const EVP_PKEY *pkey, unsigned char *pub, in EVP_PKEY_get_raw_public_key()
126 EVP_PKEY *pkey; in eddsa_pk_from_ptr() local
146 EVP_PKEY *pkey = NULL; in eddsa_pk_to_EVP_PKEY() local
156 eddsa_pk_from_EVP_PKEY(eddsa_pk_t *pk, const EVP_PKEY *pkey) in eddsa_pk_from_EVP_PKEY()
173 eddsa_verify_sig(const fido_blob_t *dgst, EVP_PKEY *pkey, in eddsa_verify_sig()
218 EVP_PKEY *pkey; in eddsa_pk_verify_sig() local
/netbsd-src/crypto/external/bsd/openssl/dist/demos/pkey/
H A DEVP_PKEY_RSA_keygen.c38 EVP_PKEY *pkey = NULL; in generate_rsa_key_long() local
110 EVP_PKEY *pkey = NULL; in generate_rsa_key_short() local
124 static int dump_key(const EVP_PKEY *pkey) in dump_key()
244 EVP_PKEY *pkey = NULL; in main() local
/netbsd-src/crypto/external/bsd/openssl.old/dist/crypto/pkcs12/
H A Dp12_kiss.c32 int PKCS12_parse(PKCS12 *p12, const char *pass, EVP_PKEY **pkey, X509 **cert, in PKCS12_parse()
132 EVP_PKEY **pkey, STACK_OF(X509) *ocerts) in parse_pk12()
166 int passlen, EVP_PKEY **pkey, STACK_OF(X509) *ocerts) in parse_bags()
178 EVP_PKEY **pkey, STACK_OF(X509) *ocerts) in parse_bag()
/netbsd-src/crypto/external/bsd/openssl/dist/crypto/pkcs12/
H A Dp12_kiss.c33 int PKCS12_parse(PKCS12 *p12, const char *pass, EVP_PKEY **pkey, X509 **cert, in PKCS12_parse()
137 EVP_PKEY **pkey, STACK_OF(X509) *ocerts) in parse_pk12()
172 int passlen, EVP_PKEY **pkey, STACK_OF(X509) *ocerts) in parse_bags()
185 EVP_PKEY **pkey, STACK_OF(X509) *ocerts) in parse_bag()

12345678910>>...13