Deprecate [DEFAULT] use_forwarded_for

... because functionality of this parameter is effectively duplicate of
the HTTPProxyToWSGI middleware in oslo.middleware library.

Closes-Bug: #1967686
Change-Id: I4db615093b739c7ff582f348a6fb6eabb8068257
This commit is contained in:
Takashi Kajinami 2022-04-04 00:27:42 +09:00
parent cbf142912d
commit b24fc87a1d
2 changed files with 11 additions and 0 deletions

View File

@ -32,6 +32,10 @@ from manila.wsgi import common as base_wsgi
use_forwarded_for_opt = cfg.BoolOpt( use_forwarded_for_opt = cfg.BoolOpt(
'use_forwarded_for', 'use_forwarded_for',
default=False, default=False,
deprecated_for_removal=True,
deprecated_reason='This feature is duplicate of the HTTPProxyToWSGI '
'middleware of oslo.middleware.',
deprecated_since='Zed',
help='Treat X-Forwarded-For as the canonical remote address. ' help='Treat X-Forwarded-For as the canonical remote address. '
'Only enable this if you have a sanitizing proxy.') 'Only enable this if you have a sanitizing proxy.')

View File

@ -0,0 +1,7 @@
---
deprecations:
- |
The ``[DEFAULT] use_forwarded_for`` parameter has been deprecated. Instead
of using this parameter, add the ``HTTPProxyToWSGI`` middleware to api
pipelines, and ``[oslo_middleware] enable_proxy_headers_parsing = True``
to manila.conf.