Lines Matching refs:serialfile
1499 BIGNUM *load_serial(const char *serialfile, int *exists, int create, in IMPLEMENT_LHASH_HASH_FN()
1511 in = BIO_new_file(serialfile, "r"); in IMPLEMENT_LHASH_HASH_FN()
1516 perror(serialfile); in IMPLEMENT_LHASH_HASH_FN()
1525 serialfile); in IMPLEMENT_LHASH_HASH_FN()
1532 serialfile); in IMPLEMENT_LHASH_HASH_FN()
1554 int save_serial(const char *serialfile, const char *suffix, in save_serial() argument
1564 j = strlen(serialfile); in save_serial()
1566 j = strlen(serialfile) + strlen(suffix) + 1; in save_serial()
1573 OPENSSL_strlcpy(buf[0], serialfile, BSIZE); in save_serial()
1576 BIO_snprintf(buf[0], sizeof(buf[0]), "%s.%s", serialfile, suffix); in save_serial()
1578 BIO_snprintf(buf[0], sizeof(buf[0]), "%s-%s", serialfile, suffix); in save_serial()
1605 int rotate_serial(const char *serialfile, const char *new_suffix, in rotate_serial() argument
1611 i = strlen(serialfile) + strlen(old_suffix); in rotate_serial()
1612 j = strlen(serialfile) + strlen(new_suffix); in rotate_serial()
1620 BIO_snprintf(buf[0], sizeof(buf[0]), "%s.%s", serialfile, new_suffix); in rotate_serial()
1621 BIO_snprintf(buf[1], sizeof(buf[1]), "%s.%s", serialfile, old_suffix); in rotate_serial()
1623 BIO_snprintf(buf[0], sizeof(buf[0]), "%s-%s", serialfile, new_suffix); in rotate_serial()
1624 BIO_snprintf(buf[1], sizeof(buf[1]), "%s-%s", serialfile, old_suffix); in rotate_serial()
1626 if (rename(serialfile, buf[1]) < 0 && errno != ENOENT in rotate_serial()
1632 "Unable to rename %s to %s\n", serialfile, buf[1]); in rotate_serial()
1636 if (rename(buf[0], serialfile) < 0) { in rotate_serial()
1638 "Unable to rename %s to %s\n", buf[0], serialfile); in rotate_serial()
1640 rename(buf[1], serialfile); in rotate_serial()