@@ -102,11 +102,14 @@ pub enum Host {
102
102
/// * `options` - Command line options used to configure the server.
103
103
/// * `application_name` - Sets the `application_name` parameter on the server.
104
104
/// * `sslcert` - Location of the client SSL certificate file.
105
+ /// * `sslcert_inline` - The contents of the client SSL certificate.
105
106
/// * `sslkey` - Location for the secret key file used for the client certificate.
107
+ /// * `sslkey_inline` - The contents of the client SSL key.
106
108
/// * `sslmode` - Controls usage of TLS. If set to `disable`, TLS will not be used. If set to `prefer`, TLS will be used
107
109
/// if available, but not used otherwise. If set to `require`, `verify-ca`, or `verify-full`, TLS will be forced to
108
110
/// be used. Defaults to `prefer`.
109
111
/// * `sslrootcert` - Location of SSL certificate authority (CA) certificate.
112
+ /// * `sslrootcert_inline` - The contents of the SSL certificate authority.
110
113
/// * `host` - The host to connect to. On Unix platforms, if the host starts with a `/` character it is treated as the
111
114
/// path to the directory containing Unix domain sockets. Otherwise, it is treated as a hostname. Multiple hosts
112
115
/// can be specified, separated by commas. Each host will be tried in turn when connecting. Required if connecting
@@ -548,6 +551,9 @@ impl Config {
548
551
return Err ( Error :: config_parse ( Box :: new ( InvalidValue ( "sslcert" ) ) ) ) ;
549
552
}
550
553
} ,
554
+ "sslcert_inline" => {
555
+ self . ssl_cert ( value. as_bytes ( ) ) ;
556
+ }
551
557
"sslkey" => match std:: fs:: read ( & value) {
552
558
Ok ( contents) => {
553
559
self . ssl_key ( & contents) ;
@@ -556,6 +562,9 @@ impl Config {
556
562
return Err ( Error :: config_parse ( Box :: new ( InvalidValue ( "sslkey" ) ) ) ) ;
557
563
}
558
564
} ,
565
+ "sslkey_inline" => {
566
+ self . ssl_key ( value. as_bytes ( ) ) ;
567
+ }
559
568
"sslmode" => {
560
569
let mode = match value {
561
570
"disable" => SslMode :: Disable ,
@@ -575,6 +584,9 @@ impl Config {
575
584
return Err ( Error :: config_parse ( Box :: new ( InvalidValue ( "sslrootcert" ) ) ) ) ;
576
585
}
577
586
} ,
587
+ "sslrootcert_inline" => {
588
+ self . ssl_root_cert ( value. as_bytes ( ) ) ;
589
+ }
578
590
"host" => {
579
591
for host in value. split ( ',' ) {
580
592
self . host ( host) ;
0 commit comments