CHANGELOG.md (8391B)
1 # Changelog 2 3 ## v1.14.0 (2022-10-31) 4 5 Require Elixir v1.10+. 6 7 ### Enhancements 8 9 * Add `Plug.Conn.prepend_req_headers/2` and `Plug.Conn.merge_req_headers/2` 10 * Support adapter upgrades with `Plug.Conn.upgrade_adapter/3` 11 * Add "Copy to Markdown" button in exception page 12 * Support exclusive use of tlsv1.3 13 14 ### Bug fixes 15 16 * Make sure last parameter works within maps 17 18 ### Deprecations 19 20 * Deprecate server pushes as they are no longer supported by browsers 21 22 ## v1.13.6 (2022-04-14) 23 24 ### Bug fixes 25 26 * Fix compile-time dependencies in Plug.Builder 27 28 ## v1.13.5 (2022-04-11) 29 30 ### Enhancements 31 32 * Support `:via` in `Plug.Router.forward/2` 33 34 ### Bug fixes 35 36 * Fix compile-time deps in Plug.Builder 37 * Do not require routes to be compile-time binaries in `Plug.Router.forward/2` 38 39 ## v1.13.4 (2022-03-10) 40 41 ### Bug fixes 42 43 * Improve deprecation warnings 44 45 ## v1.13.3 (2022-02-12) 46 47 ### Enhancements 48 49 * [Plug.Builder] Introduce `:copy_opts_to_assign` instead of `builder_opts/0` 50 * [Plug.Router] Do not introduce compile-time dependencies in `Plug.Router` 51 52 ## v1.13.2 (2022-02-04) 53 54 ### Bug fixes 55 56 * [Plug.Router] Properly fix regression on Plug.Router helper function accidentally renamed 57 58 ## v1.13.1 (2022-02-03) 59 60 ### Bug fixes 61 62 * [Plug.Router] Fix regression on Plug.Router helper function accidentally renamed 63 64 ## v1.13.0 (2022-02-02) 65 66 ### Enhancements 67 68 * [Plug.Builder] Do not add compile-time deps to literal options in function plugs 69 * [Plug.Parsers.MULTIPART] Allow custom conversion of multipart to parameters 70 * [Plug.Router] Allow suffix matches in the router (such as `/feeds/:name.atom`) 71 * [Plug.Session] Allow a list of `:rotating_options` for rotating session cookies 72 * [Plug.Static] Allow a list of `:encodings` to be given for handling static assets 73 * [Plug.Test] Raise an error when providing path not starting with "/" 74 75 ### Bug fixes 76 77 * [Plug.Upload] Normalize paths coming from environment variables 78 79 ### Deprecations 80 81 * [Plug.Router] Mixing prefix matches with globs is deprecated 82 * [Plug.Parsers.MULTIPART] Deprecate `:include_unnamed_parts_at` 83 84 ## v1.12.1 (2021-08-01) 85 86 ### Bug fixes 87 88 * [Plug] Make sure module plugs are compile time dependencies if init mode is compile-time 89 90 ## v1.12.0 (2021-07-22) 91 92 ### Enhancements 93 94 * [Plug] Accept mime v2.0 95 * [Plug] Accept telemetry v1.0 96 * [Plug.Conn] Improve performance of UTF-8 validation 97 * [Plug.Conn.Adapter] Add API for creating a connection 98 * [Plug.Static] Allow MFA in `:from` 99 100 ## v1.11.1 (2021-03-08) 101 102 ### Enhancements 103 104 * [Plug.Upload] Allow transfer of ownership in Plug.Upload 105 106 ### Bug fixes 107 108 * [Plug.Debugger] Drop CSP Header when showing error via Plug.Debugger 109 * [Plug.Test] Populate `query_params` from `Plug.Test.conn/3` 110 111 ## v1.11.0 (2020-10-29) 112 113 ### Enhancements 114 115 * [Plug.RewriteOn] Add a new public to handle `x-forwarded` headers 116 * [Plug.Router] Add macro for `head` requests 117 118 ### Bug fixes 119 120 * [Plug.CSRFProtection] Do not crash if request body params are not available 121 * [Plug.Conn.Query] Conform `www-url-encoded` parsing to whatwg spec 122 123 ### Deprecations 124 125 * [Plug.Parsers.MULTIPART] Deprecate passing MFA to MULTIPART in favor of a more composable approach 126 127 ## v1.10.4 (2020-08-07) 128 129 ### Bug fixes 130 131 * [Plug.Conn] Automatically set secure when deleting cookies to fix compatibility with SameSite 132 133 ## v1.10.3 (2020-06-10) 134 135 ### Enhancements 136 137 * [Plug.SSL] Allow host exclusion to be checked dynamically 138 139 ### Bug fixes 140 141 * [Plug.Router] Fix router telemetry event to follow Telemetry specification. This corrects the telemetry event added on v1.10.1. 142 143 ## v1.10.2 (2020-06-06) 144 145 ### Bug fixes 146 147 * [Plug] Make `:telemetry` a required dependency 148 * [Plug.Test] Populate `:query_string` when params are passed in 149 150 ### Enhancements 151 152 * [Plug] Add `Plug.run/3` for running multiple Plugs at runtime 153 * [Plug] Add `Plug.forward/4` for forwarding between Plugs 154 155 ## v1.10.1 (2020-05-15) 156 157 ### Enhancements 158 159 * [Plug.Conn] Add option to disable uft-8 validation on query strings 160 * [Plug.Conn] Support `:same_site` option when writing cookies 161 * [Plug.Router] Add router dispatch telemetry events 162 * [Plug.SSL] Support `:x_forwarded_host` and `:x_forwarded_port` on `:rewrite_on` 163 164 ### Bug fixes 165 166 * [Plug.Test] Ensure parameters are converted to string keys 167 168 ## v1.10.0 (2020-03-24) 169 170 ### Enhancements 171 172 * [Plug.BasicAuth] Add `Plug.BasicAuth` 173 * [Plug.Conn] Add built-in support for signed and encrypted cookies 174 * [Plug.Exception] Allow to use atoms as statuses in the `plug_status` field for exceptions 175 176 ### Bug fixes 177 178 * [Plug.Router] Handle malformed URI as bad requests 179 180 ## v1.9.0 (2020-02-07) 181 182 ### Bug fixes 183 184 * [Plug.Conn.Cookies] Make `decode` split on `;` only, remove `$`-prefix condition 185 * [Plug.CSRFProtection] Generate url safe CSRF masks 186 * [Plug.Parsers] Treat invalid content-types as parsing errors unless `:pass` is given 187 * [Plug.Parsers] Ensure parameters are merged when falling back to `:pass` clause 188 * [Plug.Parsers] Use HTTP status code 414 when query string is too long 189 * [Plug.SSL] Rewrite port when rewriting a request coming to a standard port 190 191 ### Enhancements 192 193 * [Plug] Make Plug fully compatible with new Elixir child specs 194 * [Plug.Exception] Add actions to exceptions that implement `Plug.Exception` and render actions in `Plug.Debugger` error page 195 * [Plug.Parsers] Add option to skip utf8 validation 196 * [Plug.Parsers] Make multipart support MFA for `:length` limit 197 * [Plug.Static] Accept MFA for `:header` option 198 199 ### Notes 200 * When implementing the `Plug.Exception` protocol, if the new `actions` function is not implemented, a warning will printed during compilation. 201 202 ## v1.8.3 (2019-07-28) 203 204 ### Bug fixes 205 206 * [Plug.Builder] Ensure init_mode option is respected within the Plug.Builder DSL itself 207 * [Plug.Session] Fix dropping session with custom max_age 208 209 ## v1.8.2 (2019-06-01) 210 211 ### Enhancements 212 213 * [Plug.CSRFProtection] Increase entropy and ensure forwards compatibility with future URL-safe CSRF tokens 214 215 ## v1.8.1 (2019-06-01) 216 217 ### Enhancements 218 219 * [Plug.CSRFProtection] Allow state to be dumped from the session and provide an API to validate both state and tokens 220 * [Plug.Session.Store] Add `get/1` to retrieve the store from a module/atom 221 * [Plug.Static] Support Nginx range requests 222 * [Plug.Telemetry] Allow extra options in `Plug.Telemetry` metadata 223 224 ## v1.8.0 (2019-03-31) 225 226 ### Enhancements 227 228 * [Plug.Conn] Add `get_session/1` for retrieving the whole session 229 * [Plug.CSRFProtection] Add `Plug.CSRFPRotection.load_state/2` and `Plug.CSRFPRotection.dump_state/0` to allow tokens to be generated in other processes 230 * [Plug.Parsers] Allow unnamed parts in multipart parser via `:include_unnamed_parts_at` 231 * [Plug.Router] Wrap router dispatch in a connection checkpoint to avoid losing information attached to the connection in error cases 232 * [Plug.Telemetry] Add `Plug.Telemetry` to facilitate with telemetry integration 233 234 ### Bug fixes 235 236 * [Plug.Conn.Status] Use IANA registered status code for HTTP 425 237 * [Plug.RequestID] Reduce RequestID size by relying on base64 encoding 238 * [Plug.Static] Ensure etags are quoted correctly 239 * [Plug.Static] Ensure vary header is set in 304 response 240 * [Plug.Static] Omit content-encoding header in 304 responses 241 242 ## v1.7.2 (2019-02-09) 243 244 * [Plug.Parser.MULTIPART] Support UTF-8 filename encoding in multipart parser 245 * [Plug.Router] Add `builder_opts` support to `:dispatch` plug 246 * [Plug.SSL] Do not disable client renegotiation 247 * [Plug.Upload] Raise when we can't write to disk during upload 248 249 ## v1.7.1 (2018-10-24) 250 251 * [Plug.Adapters.Cowboy] Less verbose output when plug_cowboy is missing 252 * [Plug.Adapters.Cowboy2] Less verbose output when plug_cowboy is missing 253 254 ## v1.7.0 (2018-10-20) 255 256 ### Enhancements 257 258 * [Plug] Require Elixir v1.4+ 259 * [Plug.Session] Support MFAs for cookie session secrets 260 * [Plug.Test] Add `put_peer_data` 261 * [Plug.Adapters.Cowboy] Extract into [plug_cowboy][plug_cowboy] 262 * [Plug.Adapters.Cowboy2] Extract into [plug_cowboy][plug_cowboy] 263 264 ### Bug fixes 265 266 * [Plug.SSL] Don't redirect excluded hosts on Plug.SSL 267 268 ### Breaking Changes 269 270 * [Plug] Applications may need to add `:plug_cowboy` to your deps to use this version 271 272 ## v1.6 273 274 See [CHANGELOG in the v1.6 branch](https://github.com/elixir-plug/plug/blob/v1.6/CHANGELOG.md). 275 276 [plug_cowboy]: https://github.com/elixir-plug/plug_cowboy