You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm selfhosting an addy instance using docker on a VPS, but I'm not exposing SMTP port of my VPS to internet, I'm using another email service as an MX and it forward all recieved email to my instance :
Email from internet --> external relay MX --> selfhosted Addy
To get rspamd ignore the external relay that forward email to my instance, and do security checks on the "real" sender, I'm trying to use rspamd external relay module https://rspamd.com/doc/modules/external_relay.html without success
I added two files via volume mapping to addy container :
And /etc/rspamd/local.d/maps.d/external_relay_hostname.map :
rspamd seems to accept the module as I can see it in Modules enabled and logs:
But rspamd still consider the external relay MX as the sender. So if the the "real" dmarc sender is configured to quarantine/reject, dmarc policy is applied (quarantine : add a header, reject : reject the email). (If the dmarc policy is set to none, emails are forwarded correctly)
lua; external_relay.lua:187: found nothing useful in Received headers
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello,
I'm selfhosting an addy instance using docker on a VPS, but I'm not exposing SMTP port of my VPS to internet, I'm using another email service as an MX and it forward all recieved email to my instance :
Email from internet --> external relay MX --> selfhosted Addy
To get rspamd ignore the external relay that forward email to my instance, and do security checks on the "real" sender, I'm trying to use rspamd external relay module https://rspamd.com/doc/modules/external_relay.html without success
I added two files via volume mapping to addy container :
/etc/rspamd/local.d/external_relay.conf (strategy = "hostname_map" ) :
![image](https://private-user-images.githubusercontent.com/95990909/318306497-1ae9d9ce-0bb5-4a4b-9b36-1077c30db544.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ0NTgyMzIsIm5iZiI6MTcyNDQ1NzkzMiwicGF0aCI6Ii85NTk5MDkwOS8zMTgzMDY0OTctMWFlOWQ5Y2UtMGJiNS00YTRiLTliMzYtMTA3N2MzMGRiNTQ0LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjQlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI0VDAwMDUzMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTU0ODE3MGE2NjJlNmM5MGZiY2Y4MDhkYjRlMzYxOGU1ODA0MDIwZjFkODIyYTBlMjdjNzUzMTE4NjFkNGViZjAmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.DjFTTxmlxIGLqThiy9MHv9zFgzDEOMN1ZoAROCmyn7U)
And /etc/rspamd/local.d/maps.d/external_relay_hostname.map :
![image](https://private-user-images.githubusercontent.com/95990909/318306573-89b230f8-b091-43b5-940b-28347d8a7902.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ0NTgyMzIsIm5iZiI6MTcyNDQ1NzkzMiwicGF0aCI6Ii85NTk5MDkwOS8zMTgzMDY1NzMtODliMjMwZjgtYjA5MS00M2I1LTk0MGItMjgzNDdkOGE3OTAyLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjQlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI0VDAwMDUzMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTJjNjVjZTU0MDk0YzBlMTQ4YzMxODNjZDczMjQ5M2FkYWUxOGE5ODY4ZDc0MDA1YmM3ZWQzMmU5M2QxMjM1YzImWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.W-d2BzC3q7FywW8DCwa2rAa2WjHpeeG9uE_wW48Shgs)
rspamd seems to accept the module as I can see it in Modules enabled and logs:
![image](https://private-user-images.githubusercontent.com/95990909/318306710-ff32bcf4-558b-41ce-b7cd-1088910182ac.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ0NTgyMzIsIm5iZiI6MTcyNDQ1NzkzMiwicGF0aCI6Ii85NTk5MDkwOS8zMTgzMDY3MTAtZmYzMmJjZjQtNTU4Yi00MWNlLWI3Y2QtMTA4ODkxMDE4MmFjLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjQlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI0VDAwMDUzMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWRkMzQxNjdiMmU0NTIzOTZiY2IyY2UzNjcyOTYxYmFjMmY2YmE1YmY5NTk2MDgzYjg5MDhkZDdkNDcyMzNlMDkmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.kbxL8x0DC8tamIvSviacnzEGlzyMGnJzFdCE4yCyZ1g)
But rspamd still consider the external relay MX as the sender. So if the the "real" dmarc sender is configured to quarantine/reject, dmarc policy is applied (quarantine : add a header, reject : reject the email). (If the dmarc policy is set to none, emails are forwarded correctly)
![image](https://private-user-images.githubusercontent.com/95990909/318307105-a651b0ff-b60c-48b7-ae31-b905d4a697eb.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ0NTgyMzIsIm5iZiI6MTcyNDQ1NzkzMiwicGF0aCI6Ii85NTk5MDkwOS8zMTgzMDcxMDUtYTY1MWIwZmYtYjYwYy00OGI3LWFlMzEtYjkwNWQ0YTY5N2ViLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjQlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI0VDAwMDUzMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPThkZDYxMjJjNWIzNjM0ZmY2MjA1NDgzYmRiNWM3ZDk4N2IzMDNlZGUzMzlmODQ4YWRkZmUwYmE0ZmEzNzczNDAmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.Ylzyd4U9YmsWmiRsyIqmg2_NrRCPiIJwB6_0Ocls7Z4)
![image](https://private-user-images.githubusercontent.com/95990909/318307509-7c83259c-2c3b-4ec8-be09-4e994198f71e.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ0NTgyMzIsIm5iZiI6MTcyNDQ1NzkzMiwicGF0aCI6Ii85NTk5MDkwOS8zMTgzMDc1MDktN2M4MzI1OWMtMmMzYi00ZWM4LWJlMDktNGU5OTQxOThmNzFlLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjQlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI0VDAwMDUzMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWI0OWEzYWU4NTJlOGIyOTYyM2M2YTRhMTZkODliZTk3ZGEyNGY2YmQ3OTk4OGUxOTk0YjM0YmFjYThiYWM4NWQmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.CDBOKVmo1-9tLPGcscPm3SO6sFMWV5YUMMCof4zivEU)
lua; external_relay.lua:187: found nothing useful in Received headers
Did any one use this type of configuration ?
Beta Was this translation helpful? Give feedback.
All reactions