Skip to content
Snippets Groups Projects
Commit ce68d9ea authored by Adam Cooke's avatar Adam Cooke
Browse files

update Received headers to use UTC timestamps

parent 5f88ee85
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -95,7 +95,7 @@ class IncomingMessagePrototype
:content => attachment[:data]
}
end
mail.header['Received'] = "from #{@source_type} (#{@ip} [#{@ip}]) by Postal with HTTP; #{Time.now.rfc2822.to_s}"
mail.header['Received'] = "from #{@source_type} (#{@ip} [#{@ip}]) by Postal with HTTP; #{Time.now.utc.rfc2822.to_s}"
mail.to_s
end
end
Loading
Loading
Loading
Loading
@@ -326,7 +326,7 @@ module Postal
@headers = {}
@receiving_headers = true
 
received_header_content = "from #{@helo_name} (#{@hostname} [#{@ip_address}]) by #{Postal.config.dns.smtp_server_hostname} with SMTP; #{Time.now.rfc2822.to_s}".force_encoding('BINARY')
received_header_content = "from #{@helo_name} (#{@hostname} [#{@ip_address}]) by #{Postal.config.dns.smtp_server_hostname} with SMTP; #{Time.now.utc.rfc2822.to_s}".force_encoding('BINARY')
if !Postal.config.smtp_server.strip_received_headers?
@data << "Received: #{received_header_content}\r\n"
end
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment