8000 [Mailer] Mailer dkim and smime misconfiguration · Issue #59854 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content
[Mailer] Mailer dkim and smime misconfiguration #59854
Closed
@eliasfernandez

Description

@eliasfernandez

Symfony version(s) affected

7.3

Description

While writing the docs for the S/Mime and Dkim signers configuration, I realized a couple of errors:

The service "mailer.dkim_signer.listener" has a dependency on a non-existent service "Symfony\Component\Mime\Crypto\DkimSigner".``` 

Explanation. The DkimSigner is not injected at this point so it should be set by its service id

Failed to sign S/Mime message. Error: "error:1E08010C:DECODER routines::unsupported".

Explanation: The argument position for certificate and key are wrong.

How to reproduce

On a fresh symfony 7.3 installation

symfony local:new --version=next --webapp symfony-with-mailer

Create a new mailer configuration

#config/mailer.yaml
framework:
    mailer:
        dsn: '%env(MAILER_DSN)%'
        dkim_signer:
            key: 'file://%kernel.project_dir%/var/certificates/dkim.pem'
            domain: 'symfony.com'
            select: 's1'
        smime_signer:
            key: 'var/certificates/smime.key'
            certificate: '%kernel.project_dir%/var/certificates/smime.crt'
            passphrase: ''

With valid certificates and keys. Then run the mailer test:

bin/console mailer:test test@symfony.com

Possible Solution

No response

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0