# Haproxy: Transfer IP Client SMTP to Exchange 2013

**URL:** <https://discourse.haproxy.org/t/haproxy-transfer-ip-client-smtp-to-exchange-2013/951>\
**Category:** Help!\
**Created:** [January 23, 2017, 2:59pm UTC](https://discourse.haproxy.org/t/haproxy-transfer-ip-client-smtp-to-exchange-2013/951 "2017-01-23T14:59:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![RadForce](https://avatars.discourse-cdn.com/v4/letter/r/41988e/32.png) [@RadForce](https://discourse.haproxy.org/u/RadForce)\
**Post date:** [January 23, 2017, 2:59pm UTC](https://discourse.haproxy.org/t/haproxy-transfer-ip-client-smtp-to-exchange-2013/951/1 "2017-01-23T14:59:28Z")

</div>

How to make Haproxy transmit IP customers who send mail via SMTP server CAS?

Config smtp (lab)

frontend fe\_ex2013\_smtp  
mode tcp  
bind 10.1.100.60:25  
default\_backend be\_ex2013\_smtp

backend be\_ex2013\_smtp  
mode tcp  
no option http-server-close  
balance roundrobin  
option log-health-checks  
option smtpchk EHLO haproxy.check  
server CAS-01 10.1.100.105:25 send-proxy check  
server CAS-02 10.1.100.106:25 send-proxy check

backend be\_ex2013  
mode http  
balance roundrobin  
server CAS-01 10.1.100.105:443 check ssl inter 15s verify required ca-file /etc/ssl/contoso.crt  
server CAS-02 10.1.100.106:443 check ssl inter 15s verify required ca-file /etc/ssl/contoso.crt

---

<div class="post-metadata">

**Author:** ![RadForce](https://avatars.discourse-cdn.com/v4/letter/r/41988e/32.png) [@RadForce](https://discourse.haproxy.org/u/RadForce)\
**Post date:** [January 26, 2017, 3:24pm UTC](https://discourse.haproxy.org/t/haproxy-transfer-ip-client-smtp-to-exchange-2013/951/2 "2017-01-26T15:24:42Z")

</div>

Who can help ? Also in haproxy log present error 401 Unauthorized

---

<div class="post-metadata">

**Author:** ![AaronWest](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.haproxy.org/aaronwest/32/164_2.png) [@AaronWest](https://discourse.haproxy.org/u/AaronWest)\
**Post date:** [January 26, 2017, 11:04pm UTC](https://discourse.haproxy.org/t/haproxy-transfer-ip-client-smtp-to-exchange-2013/951/3 "2017-01-26T23:04:30Z")

</div>

The only real way would be switching to a 2 arm config and using tproxy as described here: [http://www.loadbalancer.org/eu/blog/configure-haproxy-with-tproxy-kernel-for-full-transparent-proxy](http://www.loadbalancer.org/eu/blog/configure-haproxy-with-tproxy-kernel-for-full-transparent-proxy)

You can almost certainly ignore the bits about compiling it into iptables and the Kernel as it’s been in there for ages now in most systems I’ve used.

---

<div class="post-metadata">

**Author:** ![RadForce](https://avatars.discourse-cdn.com/v4/letter/r/41988e/32.png) [@RadForce](https://discourse.haproxy.org/u/RadForce)\
**Post date:** [January 31, 2017, 7:37am UTC](https://discourse.haproxy.org/t/haproxy-transfer-ip-client-smtp-to-exchange-2013/951/4 "2017-01-31T07:37:34Z")

</div>

TPROXY for Linux… I use FreeBSD, how to configure transporter proxy?

---

<div class="post-metadata">

**Author:** ![AaronWest](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.haproxy.org/aaronwest/32/164_2.png) [@AaronWest](https://discourse.haproxy.org/u/AaronWest)\
**Post date:** [January 31, 2017, 1:08pm UTC](https://discourse.haproxy.org/t/haproxy-transfer-ip-client-smtp-to-exchange-2013/951/5 "2017-01-31T13:08:49Z")

</div>

I must confess I’m not much of a FreeBSD man so not the best person to help here.

However searching google did yield some results talking about it which seem positive : [http://www.serverphorums.com/read.php?10,691956](http://www.serverphorums.com/read.php?10,691956)
