Changeset 308:5f882de409eb in freeDiameter
- Timestamp:
- May 17, 2010, 3:23:48 PM (14 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
freeDiameter/fdd.y
r304 r308 496 496 tls_cred: TLS_CRED '=' QSTRING ',' QSTRING ';' 497 497 { 498 FILE * fd; 499 fd = fopen($3, "r"); 500 if (fd == NULL) { 501 int ret = errno; 502 TRACE_DEBUG(INFO, "Unable to open certificate file %s for reading: %s\n", $3, strerror(ret)); 503 yyerror (&yylloc, conf, "Error on file name"); 504 YYERROR; 505 } 506 fclose(fd); 507 fd = fopen($5, "r"); 508 if (fd == NULL) { 509 int ret = errno; 510 TRACE_DEBUG(INFO, "Unable to open private key file %s for reading: %s\n", $5, strerror(ret)); 511 yyerror (&yylloc, conf, "Error on file name"); 512 YYERROR; 513 } 514 fclose(fd); 498 515 conf->cnf_sec_data.cert_file = $3; 499 516 conf->cnf_sec_data.key_file = $5; … … 510 527 tls_ca: TLS_CA '=' QSTRING ';' 511 528 { 529 FILE * fd; 530 fd = fopen($3, "r"); 531 if (fd == NULL) { 532 int ret = errno; 533 TRACE_DEBUG(INFO, "Unable to open CA file %s for reading: %s\n", $3, strerror(ret)); 534 yyerror (&yylloc, conf, "Error on file name"); 535 YYERROR; 536 } 537 fclose(fd); 512 538 conf->cnf_sec_data.ca_file = $3; 513 539 CHECK_GNUTLS_DO( conf->cnf_sec_data.ca_file_nr += gnutls_certificate_set_x509_trust_file( … … 521 547 tls_crl: TLS_CRL '=' QSTRING ';' 522 548 { 549 FILE * fd; 550 fd = fopen($3, "r"); 551 if (fd == NULL) { 552 int ret = errno; 553 TRACE_DEBUG(INFO, "Unable to open CRL file %s for reading: %s\n", $3, strerror(ret)); 554 yyerror (&yylloc, conf, "Error on file name"); 555 YYERROR; 556 } 557 fclose(fd); 523 558 conf->cnf_sec_data.crl_file = $3; 524 559 CHECK_GNUTLS_DO( gnutls_certificate_set_x509_crl_file(
Note: See TracChangeset
for help on using the changeset viewer.