Path: blob/main/xml/en/docs/mail/ngx_mail_realip_module.xml
1 views
<?xml version="1.0"?>12<!--3Copyright (C) Nginx, Inc.4-->56<!DOCTYPE module SYSTEM "../../../../dtd/module.dtd">78<module name="Module ngx_mail_realip_module"9link="/en/docs/mail/ngx_mail_realip_module.html"10lang="en"11rev="1">1213<section id="summary">1415<para>16The <literal>ngx_mail_realip_module</literal> module is used17to change the client address and port18to the ones sent in the PROXY protocol header (1.19.8).19The PROXY protocol must be previously enabled by setting the20<link doc="ngx_mail_core_module.xml" id="proxy_protocol"/> parameter21in the <literal>listen</literal> directive.22</para>2324</section>252627<section id="example" name="Example Configuration">2829<para>30<example>31listen 110 proxy_protocol;3233set_real_ip_from 192.168.1.0/24;34set_real_ip_from 192.168.2.1;35set_real_ip_from 2001:0db8::/32;36</example>37</para>3839</section>404142<section id="directives" name="Directives">4344<directive name="set_real_ip_from">45<syntax>46<value>address</value> |47<value>CIDR</value> |48<literal>unix:</literal></syntax>49<default/>50<context>mail</context>51<context>server</context>5253<para>54Defines trusted addresses that are known to send correct55replacement addresses.56If the special value <literal>unix:</literal> is specified,57all UNIX-domain sockets will be trusted.58</para>5960</directive>6162</section>6364</module>656667