diff options
| author | inoguchi <> | 2019-07-08 11:56:18 +0000 |
|---|---|---|
| committer | inoguchi <> | 2019-07-08 11:56:18 +0000 |
| commit | 38918e2b1105203e3a43e4c44a53bf432952771c (patch) | |
| tree | 310341efad6ce481d2f014d248212cbd16751d44 /src | |
| parent | b7ed3b2ab5936f64572047d1bcd708bbdeeb5a59 (diff) | |
| download | openbsd-38918e2b1105203e3a43e4c44a53bf432952771c.tar.gz openbsd-38918e2b1105203e3a43e4c44a53bf432952771c.tar.bz2 openbsd-38918e2b1105203e3a43e4c44a53bf432952771c.zip | |
Clean up pvkfmt.c
- Replace EVP_CIPHER_CTX_init with EVP_CIPHER_CTX_new and handle return value
- Replace EVP_CIPHER_CTX_cleanup with EVP_CIPHER_CTX_free
- Change two 'return -1;' to 'goto err;' for avoiding leak
- Remove the case if enclevel == 0
- Change enclevel checking to make more consistent
- Change all goto label to 'err' and insert space before goto label
ok and advise from tb@
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib/libcrypto/pem/pvkfmt.c | 129 |
1 files changed, 66 insertions, 63 deletions
diff --git a/src/lib/libcrypto/pem/pvkfmt.c b/src/lib/libcrypto/pem/pvkfmt.c index c7b7207964..abb7f7eec9 100644 --- a/src/lib/libcrypto/pem/pvkfmt.c +++ b/src/lib/libcrypto/pem/pvkfmt.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: pvkfmt.c,v 1.21 2019/07/07 10:52:56 inoguchi Exp $ */ | 1 | /* $OpenBSD: pvkfmt.c,v 1.22 2019/07/08 11:56:18 inoguchi Exp $ */ |
| 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
| 3 | * project 2005. | 3 | * project 2005. |
| 4 | */ | 4 | */ |
| @@ -300,7 +300,7 @@ do_b2i_bio(BIO *in, int ispub) | |||
| 300 | else | 300 | else |
| 301 | ret = b2i_rsa(&p, length, bitlen, ispub); | 301 | ret = b2i_rsa(&p, length, bitlen, ispub); |
| 302 | 302 | ||
| 303 | err: | 303 | err: |
| 304 | free(buf); | 304 | free(buf); |
| 305 | return ret; | 305 | return ret; |
| 306 | } | 306 | } |
| @@ -320,27 +320,27 @@ b2i_dss(const unsigned char **in, unsigned int length, unsigned int bitlen, | |||
| 320 | dsa = DSA_new(); | 320 | dsa = DSA_new(); |
| 321 | ret = EVP_PKEY_new(); | 321 | ret = EVP_PKEY_new(); |
| 322 | if (!dsa || !ret) | 322 | if (!dsa || !ret) |
| 323 | goto memerr; | 323 | goto err; |
| 324 | if (!read_lebn(&p, nbyte, &dsa->p)) | 324 | if (!read_lebn(&p, nbyte, &dsa->p)) |
| 325 | goto memerr; | 325 | goto err; |
| 326 | if (!read_lebn(&p, 20, &dsa->q)) | 326 | if (!read_lebn(&p, 20, &dsa->q)) |
| 327 | goto memerr; | 327 | goto err; |
| 328 | if (!read_lebn(&p, nbyte, &dsa->g)) | 328 | if (!read_lebn(&p, nbyte, &dsa->g)) |
| 329 | goto memerr; | 329 | goto err; |
| 330 | if (ispub) { | 330 | if (ispub) { |
| 331 | if (!read_lebn(&p, nbyte, &dsa->pub_key)) | 331 | if (!read_lebn(&p, nbyte, &dsa->pub_key)) |
| 332 | goto memerr; | 332 | goto err; |
| 333 | } else { | 333 | } else { |
| 334 | if (!read_lebn(&p, 20, &dsa->priv_key)) | 334 | if (!read_lebn(&p, 20, &dsa->priv_key)) |
| 335 | goto memerr; | 335 | goto err; |
| 336 | /* Calculate public key */ | 336 | /* Calculate public key */ |
| 337 | if (!(dsa->pub_key = BN_new())) | 337 | if (!(dsa->pub_key = BN_new())) |
| 338 | goto memerr; | 338 | goto err; |
| 339 | if (!(ctx = BN_CTX_new())) | 339 | if (!(ctx = BN_CTX_new())) |
| 340 | goto memerr; | 340 | goto err; |
| 341 | if (!BN_mod_exp_ct(dsa->pub_key, dsa->g, | 341 | if (!BN_mod_exp_ct(dsa->pub_key, dsa->g, |
| 342 | dsa->priv_key, dsa->p, ctx)) | 342 | dsa->priv_key, dsa->p, ctx)) |
| 343 | goto memerr; | 343 | goto err; |
| 344 | BN_CTX_free(ctx); | 344 | BN_CTX_free(ctx); |
| 345 | } | 345 | } |
| 346 | 346 | ||
| @@ -349,7 +349,7 @@ b2i_dss(const unsigned char **in, unsigned int length, unsigned int bitlen, | |||
| 349 | *in = p; | 349 | *in = p; |
| 350 | return ret; | 350 | return ret; |
| 351 | 351 | ||
| 352 | memerr: | 352 | err: |
| 353 | PEMerror(ERR_R_MALLOC_FAILURE); | 353 | PEMerror(ERR_R_MALLOC_FAILURE); |
| 354 | DSA_free(dsa); | 354 | DSA_free(dsa); |
| 355 | EVP_PKEY_free(ret); | 355 | EVP_PKEY_free(ret); |
| @@ -371,27 +371,27 @@ b2i_rsa(const unsigned char **in, unsigned int length, unsigned int bitlen, | |||
| 371 | rsa = RSA_new(); | 371 | rsa = RSA_new(); |
| 372 | ret = EVP_PKEY_new(); | 372 | ret = EVP_PKEY_new(); |
| 373 | if (!rsa || !ret) | 373 | if (!rsa || !ret) |
| 374 | goto memerr; | 374 | goto err; |
| 375 | rsa->e = BN_new(); | 375 | rsa->e = BN_new(); |
| 376 | if (!rsa->e) | 376 | if (!rsa->e) |
| 377 | goto memerr; | 377 | goto err; |
| 378 | if (!BN_set_word(rsa->e, read_ledword(&p))) | 378 | if (!BN_set_word(rsa->e, read_ledword(&p))) |
| 379 | goto memerr; | 379 | goto err; |
| 380 | if (!read_lebn(&p, nbyte, &rsa->n)) | 380 | if (!read_lebn(&p, nbyte, &rsa->n)) |
| 381 | goto memerr; | 381 | goto err; |
| 382 | if (!ispub) { | 382 | if (!ispub) { |
| 383 | if (!read_lebn(&p, hnbyte, &rsa->p)) | 383 | if (!read_lebn(&p, hnbyte, &rsa->p)) |
| 384 | goto memerr; | 384 | goto err; |
| 385 | if (!read_lebn(&p, hnbyte, &rsa->q)) | 385 | if (!read_lebn(&p, hnbyte, &rsa->q)) |
| 386 | goto memerr; | 386 | goto err; |
| 387 | if (!read_lebn(&p, hnbyte, &rsa->dmp1)) | 387 | if (!read_lebn(&p, hnbyte, &rsa->dmp1)) |
| 388 | goto memerr; | 388 | goto err; |
| 389 | if (!read_lebn(&p, hnbyte, &rsa->dmq1)) | 389 | if (!read_lebn(&p, hnbyte, &rsa->dmq1)) |
| 390 | goto memerr; | 390 | goto err; |
| 391 | if (!read_lebn(&p, hnbyte, &rsa->iqmp)) | 391 | if (!read_lebn(&p, hnbyte, &rsa->iqmp)) |
| 392 | goto memerr; | 392 | goto err; |
| 393 | if (!read_lebn(&p, nbyte, &rsa->d)) | 393 | if (!read_lebn(&p, nbyte, &rsa->d)) |
| 394 | goto memerr; | 394 | goto err; |
| 395 | } | 395 | } |
| 396 | 396 | ||
| 397 | EVP_PKEY_set1_RSA(ret, rsa); | 397 | EVP_PKEY_set1_RSA(ret, rsa); |
| @@ -399,7 +399,7 @@ b2i_rsa(const unsigned char **in, unsigned int length, unsigned int bitlen, | |||
| 399 | *in = p; | 399 | *in = p; |
| 400 | return ret; | 400 | return ret; |
| 401 | 401 | ||
| 402 | memerr: | 402 | err: |
| 403 | PEMerror(ERR_R_MALLOC_FAILURE); | 403 | PEMerror(ERR_R_MALLOC_FAILURE); |
| 404 | RSA_free(rsa); | 404 | RSA_free(rsa); |
| 405 | EVP_PKEY_free(ret); | 405 | EVP_PKEY_free(ret); |
| @@ -548,20 +548,20 @@ check_bitlen_dsa(DSA *dsa, int ispub, unsigned int *pmagic) | |||
| 548 | bitlen = BN_num_bits(dsa->p); | 548 | bitlen = BN_num_bits(dsa->p); |
| 549 | if ((bitlen & 7) || (BN_num_bits(dsa->q) != 160) || | 549 | if ((bitlen & 7) || (BN_num_bits(dsa->q) != 160) || |
| 550 | (BN_num_bits(dsa->g) > bitlen)) | 550 | (BN_num_bits(dsa->g) > bitlen)) |
| 551 | goto badkey; | 551 | goto err; |
| 552 | if (ispub) { | 552 | if (ispub) { |
| 553 | if (BN_num_bits(dsa->pub_key) > bitlen) | 553 | if (BN_num_bits(dsa->pub_key) > bitlen) |
| 554 | goto badkey; | 554 | goto err; |
| 555 | *pmagic = MS_DSS1MAGIC; | 555 | *pmagic = MS_DSS1MAGIC; |
| 556 | } else { | 556 | } else { |
| 557 | if (BN_num_bits(dsa->priv_key) > 160) | 557 | if (BN_num_bits(dsa->priv_key) > 160) |
| 558 | goto badkey; | 558 | goto err; |
| 559 | *pmagic = MS_DSS2MAGIC; | 559 | *pmagic = MS_DSS2MAGIC; |
| 560 | } | 560 | } |
| 561 | 561 | ||
| 562 | return bitlen; | 562 | return bitlen; |
| 563 | 563 | ||
| 564 | badkey: | 564 | err: |
| 565 | PEMerror(PEM_R_UNSUPPORTED_KEY_COMPONENTS); | 565 | PEMerror(PEM_R_UNSUPPORTED_KEY_COMPONENTS); |
| 566 | return 0; | 566 | return 0; |
| 567 | } | 567 | } |
| @@ -572,7 +572,7 @@ check_bitlen_rsa(RSA *rsa, int ispub, unsigned int *pmagic) | |||
| 572 | int nbyte, hnbyte, bitlen; | 572 | int nbyte, hnbyte, bitlen; |
| 573 | 573 | ||
| 574 | if (BN_num_bits(rsa->e) > 32) | 574 | if (BN_num_bits(rsa->e) > 32) |
| 575 | goto badkey; | 575 | goto err; |
| 576 | bitlen = BN_num_bits(rsa->n); | 576 | bitlen = BN_num_bits(rsa->n); |
| 577 | nbyte = BN_num_bytes(rsa->n); | 577 | nbyte = BN_num_bytes(rsa->n); |
| 578 | hnbyte = (BN_num_bits(rsa->n) + 15) >> 4; | 578 | hnbyte = (BN_num_bits(rsa->n) + 15) >> 4; |
| @@ -585,17 +585,17 @@ check_bitlen_rsa(RSA *rsa, int ispub, unsigned int *pmagic) | |||
| 585 | * hnbyte. | 585 | * hnbyte. |
| 586 | */ | 586 | */ |
| 587 | if (BN_num_bytes(rsa->d) > nbyte) | 587 | if (BN_num_bytes(rsa->d) > nbyte) |
| 588 | goto badkey; | 588 | goto err; |
| 589 | if ((BN_num_bytes(rsa->iqmp) > hnbyte) || | 589 | if ((BN_num_bytes(rsa->iqmp) > hnbyte) || |
| 590 | (BN_num_bytes(rsa->p) > hnbyte) || | 590 | (BN_num_bytes(rsa->p) > hnbyte) || |
| 591 | (BN_num_bytes(rsa->q) > hnbyte) || | 591 | (BN_num_bytes(rsa->q) > hnbyte) || |
| 592 | (BN_num_bytes(rsa->dmp1) > hnbyte) || | 592 | (BN_num_bytes(rsa->dmp1) > hnbyte) || |
| 593 | (BN_num_bytes(rsa->dmq1) > hnbyte)) | 593 | (BN_num_bytes(rsa->dmq1) > hnbyte)) |
| 594 | goto badkey; | 594 | goto err; |
| 595 | } | 595 | } |
| 596 | return bitlen; | 596 | return bitlen; |
| 597 | 597 | ||
| 598 | badkey: | 598 | err: |
| 599 | PEMerror(PEM_R_UNSUPPORTED_KEY_COMPONENTS); | 599 | PEMerror(PEM_R_UNSUPPORTED_KEY_COMPONENTS); |
| 600 | return 0; | 600 | return 0; |
| 601 | } | 601 | } |
| @@ -723,9 +723,12 @@ do_PVK_body(const unsigned char **in, unsigned int saltlen, | |||
| 723 | const unsigned char *p = *in; | 723 | const unsigned char *p = *in; |
| 724 | unsigned int magic; | 724 | unsigned int magic; |
| 725 | unsigned char *enctmp = NULL, *q; | 725 | unsigned char *enctmp = NULL, *q; |
| 726 | EVP_CIPHER_CTX cctx; | 726 | EVP_CIPHER_CTX *cctx = NULL; |
| 727 | 727 | ||
| 728 | EVP_CIPHER_CTX_init(&cctx); | 728 | if ((cctx = EVP_CIPHER_CTX_new()) == NULL) { |
| 729 | PEMerror(ERR_R_MALLOC_FAILURE); | ||
| 730 | goto err; | ||
| 731 | } | ||
| 729 | if (saltlen) { | 732 | if (saltlen) { |
| 730 | char psbuf[PEM_BUFSIZE]; | 733 | char psbuf[PEM_BUFSIZE]; |
| 731 | unsigned char keybuf[20]; | 734 | unsigned char keybuf[20]; |
| @@ -758,23 +761,23 @@ do_PVK_body(const unsigned char **in, unsigned int saltlen, | |||
| 758 | } | 761 | } |
| 759 | inlen = keylen - 8; | 762 | inlen = keylen - 8; |
| 760 | q = enctmp + 8; | 763 | q = enctmp + 8; |
| 761 | if (!EVP_DecryptInit_ex(&cctx, EVP_rc4(), NULL, keybuf, NULL)) | 764 | if (!EVP_DecryptInit_ex(cctx, EVP_rc4(), NULL, keybuf, NULL)) |
| 762 | goto err; | 765 | goto err; |
| 763 | if (!EVP_DecryptUpdate(&cctx, q, &enctmplen, p, inlen)) | 766 | if (!EVP_DecryptUpdate(cctx, q, &enctmplen, p, inlen)) |
| 764 | goto err; | 767 | goto err; |
| 765 | if (!EVP_DecryptFinal_ex(&cctx, q + enctmplen, &enctmplen)) | 768 | if (!EVP_DecryptFinal_ex(cctx, q + enctmplen, &enctmplen)) |
| 766 | goto err; | 769 | goto err; |
| 767 | magic = read_ledword((const unsigned char **)&q); | 770 | magic = read_ledword((const unsigned char **)&q); |
| 768 | if (magic != MS_RSA2MAGIC && magic != MS_DSS2MAGIC) { | 771 | if (magic != MS_RSA2MAGIC && magic != MS_DSS2MAGIC) { |
| 769 | q = enctmp + 8; | 772 | q = enctmp + 8; |
| 770 | memset(keybuf + 5, 0, 11); | 773 | memset(keybuf + 5, 0, 11); |
| 771 | if (!EVP_DecryptInit_ex(&cctx, EVP_rc4(), NULL, keybuf, | 774 | if (!EVP_DecryptInit_ex(cctx, EVP_rc4(), NULL, keybuf, |
| 772 | NULL)) | 775 | NULL)) |
| 773 | goto err; | 776 | goto err; |
| 774 | explicit_bzero(keybuf, 20); | 777 | explicit_bzero(keybuf, 20); |
| 775 | if (!EVP_DecryptUpdate(&cctx, q, &enctmplen, p, inlen)) | 778 | if (!EVP_DecryptUpdate(cctx, q, &enctmplen, p, inlen)) |
| 776 | goto err; | 779 | goto err; |
| 777 | if (!EVP_DecryptFinal_ex(&cctx, q + enctmplen, | 780 | if (!EVP_DecryptFinal_ex(cctx, q + enctmplen, |
| 778 | &enctmplen)) | 781 | &enctmplen)) |
| 779 | goto err; | 782 | goto err; |
| 780 | magic = read_ledword((const unsigned char **)&q); | 783 | magic = read_ledword((const unsigned char **)&q); |
| @@ -789,8 +792,8 @@ do_PVK_body(const unsigned char **in, unsigned int saltlen, | |||
| 789 | 792 | ||
| 790 | ret = b2i_PrivateKey(&p, keylen); | 793 | ret = b2i_PrivateKey(&p, keylen); |
| 791 | 794 | ||
| 792 | err: | 795 | err: |
| 793 | EVP_CIPHER_CTX_cleanup(&cctx); | 796 | EVP_CIPHER_CTX_free(cctx); |
| 794 | if (enctmp && saltlen) | 797 | if (enctmp && saltlen) |
| 795 | free(enctmp); | 798 | free(enctmp); |
| 796 | return ret; | 799 | return ret; |
| @@ -827,7 +830,7 @@ b2i_PVK_bio(BIO *in, pem_password_cb *cb, void *u) | |||
| 827 | } | 830 | } |
| 828 | ret = do_PVK_body(&p, saltlen, keylen, cb, u); | 831 | ret = do_PVK_body(&p, saltlen, keylen, cb, u); |
| 829 | 832 | ||
| 830 | err: | 833 | err: |
| 831 | freezero(buf, buflen); | 834 | freezero(buf, buflen); |
| 832 | return ret; | 835 | return ret; |
| 833 | } | 836 | } |
| @@ -838,19 +841,22 @@ i2b_PVK(unsigned char **out, EVP_PKEY*pk, int enclevel, pem_password_cb *cb, | |||
| 838 | { | 841 | { |
| 839 | int outlen = 24, pklen; | 842 | int outlen = 24, pklen; |
| 840 | unsigned char *p = NULL, *start = NULL, *salt = NULL; | 843 | unsigned char *p = NULL, *start = NULL, *salt = NULL; |
| 841 | EVP_CIPHER_CTX cctx; | 844 | EVP_CIPHER_CTX *cctx = NULL; |
| 842 | 845 | ||
| 843 | EVP_CIPHER_CTX_init(&cctx); | 846 | if ((cctx = EVP_CIPHER_CTX_new()) == NULL) { |
| 844 | if (enclevel) | 847 | PEMerror(ERR_R_MALLOC_FAILURE); |
| 848 | goto err; | ||
| 849 | } | ||
| 850 | if (enclevel != 0) | ||
| 845 | outlen += PVK_SALTLEN; | 851 | outlen += PVK_SALTLEN; |
| 846 | pklen = do_i2b(NULL, pk, 0); | 852 | pklen = do_i2b(NULL, pk, 0); |
| 847 | if (pklen < 0) | 853 | if (pklen < 0) |
| 848 | return -1; | 854 | goto err; |
| 849 | outlen += pklen; | 855 | outlen += pklen; |
| 850 | start = p = malloc(outlen); | 856 | start = p = malloc(outlen); |
| 851 | if (!p) { | 857 | if (!p) { |
| 852 | PEMerror(ERR_R_MALLOC_FAILURE); | 858 | PEMerror(ERR_R_MALLOC_FAILURE); |
| 853 | return -1; | 859 | goto err; |
| 854 | } | 860 | } |
| 855 | 861 | ||
| 856 | write_ledword(&p, MS_PVKMAGIC); | 862 | write_ledword(&p, MS_PVKMAGIC); |
| @@ -862,16 +868,13 @@ i2b_PVK(unsigned char **out, EVP_PKEY*pk, int enclevel, pem_password_cb *cb, | |||
| 862 | write_ledword(&p, enclevel ? 1 : 0); | 868 | write_ledword(&p, enclevel ? 1 : 0); |
| 863 | write_ledword(&p, enclevel ? PVK_SALTLEN : 0); | 869 | write_ledword(&p, enclevel ? PVK_SALTLEN : 0); |
| 864 | write_ledword(&p, pklen); | 870 | write_ledword(&p, pklen); |
| 865 | if (enclevel) { | 871 | if (enclevel != 0) { |
| 866 | arc4random_buf(p, PVK_SALTLEN); | 872 | arc4random_buf(p, PVK_SALTLEN); |
| 867 | salt = p; | 873 | salt = p; |
| 868 | p += PVK_SALTLEN; | 874 | p += PVK_SALTLEN; |
| 869 | } | 875 | } |
| 870 | do_i2b(&p, pk, 0); | 876 | do_i2b(&p, pk, 0); |
| 871 | if (enclevel == 0) { | 877 | if (enclevel != 0) { |
| 872 | *out = start; | ||
| 873 | return outlen; | ||
| 874 | } else { | ||
| 875 | char psbuf[PEM_BUFSIZE]; | 878 | char psbuf[PEM_BUFSIZE]; |
| 876 | unsigned char keybuf[20]; | 879 | unsigned char keybuf[20]; |
| 877 | int enctmplen, inlen; | 880 | int enctmplen, inlen; |
| @@ -881,28 +884,28 @@ i2b_PVK(unsigned char **out, EVP_PKEY*pk, int enclevel, pem_password_cb *cb, | |||
| 881 | inlen = PEM_def_callback(psbuf, PEM_BUFSIZE, 1, u); | 884 | inlen = PEM_def_callback(psbuf, PEM_BUFSIZE, 1, u); |
| 882 | if (inlen <= 0) { | 885 | if (inlen <= 0) { |
| 883 | PEMerror(PEM_R_BAD_PASSWORD_READ); | 886 | PEMerror(PEM_R_BAD_PASSWORD_READ); |
| 884 | goto error; | 887 | goto err; |
| 885 | } | 888 | } |
| 886 | if (!derive_pvk_key(keybuf, salt, PVK_SALTLEN, | 889 | if (!derive_pvk_key(keybuf, salt, PVK_SALTLEN, |
| 887 | (unsigned char *)psbuf, inlen)) | 890 | (unsigned char *)psbuf, inlen)) |
| 888 | goto error; | 891 | goto err; |
| 889 | if (enclevel == 1) | 892 | if (enclevel == 1) |
| 890 | memset(keybuf + 5, 0, 11); | 893 | memset(keybuf + 5, 0, 11); |
| 891 | p = salt + PVK_SALTLEN + 8; | 894 | p = salt + PVK_SALTLEN + 8; |
| 892 | if (!EVP_EncryptInit_ex(&cctx, EVP_rc4(), NULL, keybuf, NULL)) | 895 | if (!EVP_EncryptInit_ex(cctx, EVP_rc4(), NULL, keybuf, NULL)) |
| 893 | goto error; | 896 | goto err; |
| 894 | explicit_bzero(keybuf, 20); | 897 | explicit_bzero(keybuf, 20); |
| 895 | if (!EVP_EncryptUpdate(&cctx, p, &enctmplen, p, pklen - 8)) | 898 | if (!EVP_EncryptUpdate(cctx, p, &enctmplen, p, pklen - 8)) |
| 896 | goto error; | 899 | goto err; |
| 897 | if (!EVP_EncryptFinal_ex(&cctx, p + enctmplen, &enctmplen)) | 900 | if (!EVP_EncryptFinal_ex(cctx, p + enctmplen, &enctmplen)) |
| 898 | goto error; | 901 | goto err; |
| 899 | } | 902 | } |
| 900 | EVP_CIPHER_CTX_cleanup(&cctx); | 903 | EVP_CIPHER_CTX_free(cctx); |
| 901 | *out = start; | 904 | *out = start; |
| 902 | return outlen; | 905 | return outlen; |
| 903 | 906 | ||
| 904 | error: | 907 | err: |
| 905 | EVP_CIPHER_CTX_cleanup(&cctx); | 908 | EVP_CIPHER_CTX_free(cctx); |
| 906 | free(start); | 909 | free(start); |
| 907 | return -1; | 910 | return -1; |
| 908 | } | 911 | } |
