{
    use esmith::ssl;
    my $domain = $DomainName || "localdomain";
    my $hostname = $SystemName || "localhost";

    # expand default self signed crt
    my $dcrt = "/home/e-smith/ssl.crt/$hostname.$domain.crt";
    use esmith::templates;
    esmith::templates::processTemplate({
        TEMPLATE_PATH => "/home/e-smith/ssl.crt/crt",
        OUTPUT_FILENAME => $dcrt,
        });

    # choose crt to add to pem
    $crt = ( defined $modSSL{'key'} and defined $modSSL{'crt'} and related_key_cert($modSSL{'key'},$modSSL{'crt'}) )? $modSSL{'crt'} : $dcrt;
    open(CRT, $crt) or die "Could not open crt file: $!";
    my @crt = <CRT>;
    chomp @crt;
    $OUT = join "\n", @crt;
    close CRT;
}
