If a forwarded header exists this is a list of all ip addresses from the client ip to the last proxy server.
(self)
| 178 | |
| 179 | @cached_property |
| 180 | def access_route(self) -> list[str]: |
| 181 | """If a forwarded header exists this is a list of all ip addresses |
| 182 | from the client ip to the last proxy server. |
| 183 | """ |
| 184 | if "X-Forwarded-For" in self.headers: |
| 185 | return self.list_storage_class( |
| 186 | parse_list_header(self.headers["X-Forwarded-For"]) |
| 187 | ) |
| 188 | elif self.remote_addr is not None: |
| 189 | return self.list_storage_class([self.remote_addr]) |
| 190 | return self.list_storage_class() |
| 191 | |
| 192 | @cached_property |
| 193 | def full_path(self) -> str: |
nothing calls this directly
no test coverage detected