Skip to content

Commit

Permalink
refactor: update mail configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
papac committed Jan 26, 2025
1 parent 5328f8b commit da763af
Showing 1 changed file with 32 additions and 2 deletions.
34 changes: 32 additions & 2 deletions config/mail.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,37 @@
"port" => app_env("SMTP_PORT"),
"tls" => app_env("SMTP_TLS"),
"ssl" => app_env("SMTP_SSL"),
"timeout" => app_env("SMTP_TIMEOUT")
"timeout" => app_env("SMTP_TIMEOUT"),

/**
* DKIM (DomainKeys Identified Mail) allows an organization to take
* responsibility for a message by signing it. It allows the receiver
* to verify that the message was not modified in transit.
*/
'dkim' => [
'enabled' => app_env('MAIL_DKIM_ENABLED', false),
'domain' => app_env('MAIL_DKIM_DOMAIN'),
'selector' => app_env('MAIL_DKIM_SELECTOR', 'default'),
'private_key' => app_env('MAIL_DKIM_PRIVATE_KEY'),
'passphrase' => app_env('MAIL_DKIM_PASSPHRASE'),
'identity' => app_env('MAIL_DKIM_IDENTITY'),
'algo' => 'rsa-sha256',
],

/**
* SPF (Sender Policy Framework) is an email authentication method designed
* to prevent email spoofing by allowing domain owners to specify which
* mail servers are authorized to send mail for their domains.
*/
'spf' => [
'enabled' => app_env('MAIL_SPF_ENABLED', false),
'strict' => app_env('MAIL_SPF_STRICT', true),
'policies' => [
'fail' => 'reject', // reject, mark, accept
'softfail' => 'mark',
'neutral' => 'accept',
],
],
],

/**
Expand All @@ -51,7 +81,7 @@
*/
"mail" => [
"default" => "contact",
"froms" => [
"from" => [
"contact" => [
"address" => app_env("MAIL_FROM_EMAIL"),
"name" => app_env("MAIL_FROM_NAME")
Expand Down

0 comments on commit da763af

Please sign in to comment.