0

I would like to change received_header_text in exim config and I need to use server IP in it.

Is there a variable that I can use there to get server IP?


What I try to do:

See related question.

I thought about changing:

received_header_text = Received: ${if def:sender_rcvhost {from $sender_rcvhost\n\t}{${if def:sender_ident {from ${quote_local_part:$sender_ident} }}${if def:sender_helo_name {(helo=$sender_helo_name)\n\t}}}}by $primary_hostname ${if def:received_protocol {with $received_protocol}} ${if def:tls_cipher {($tls_cipher)\n\t}}(Exim $version_number)\n\t${if def:sender_address {(envelope-from <$sender_address>)\n\t}}id $message_exim_id${if def:received_for {\n\tfor $received_for}}

to:

received_header_text = ${if def:authenticated_id {Received: from $primary_hostname ([188.40.153.39] helo=[188.40.153.39]) by $primary_hostname with ESMTP\n\t(Exim $version_number)\n\t${if def:sender_address {(envelope-from <$sender_address>)\n\t}}id $message_exim_id${if def:received_for {\n\tfor $received_for}}\n\t}}Received: ${if def:sender_rcvhost {from $sender_rcvhost\n\t}{${if def:sender_ident {from ${quote_local_part:$sender_ident} }}${if def:sender_helo_name {(helo=$sender_helo_name)\n\t}}}}by $primary_hostname ${if def:received_protocol {with $received_protocol}} ${if def:tls_cipher {($tls_cipher)\n\t}}(Exim $version_number)\n\t${if def:sender_address {(envelope-from <$sender_address>)\n\t}}id $message_exim_id${if def:received_for {\n\tfor $received_for}}
3
  • Have you tried it? What's your expected output and what's the actual output? See How can I ask better questions on Server Fault?
    – masegaloeh
    Feb 27, 2015 at 14:07
  • Duplicate of (the slightly better question) serverfault.com/questions/671882/… . Answered there.
    – Todd Lyons
    Feb 27, 2015 at 21:58
  • It's a separate question because here I ask about IP - how could I put server IP into received_header_text without hard coding it but using some variable. So it won't need to be changed when IP of the server changes.
    – Zbyszek
    Feb 28, 2015 at 16:08

0

You must log in to answer this question.

Browse other questions tagged .