Force encoding of US-ASCII to UTF-8 in unescape_uri.

Because URI paths may contain non US-ASCII characters we need to force
the encoding of any unescaped URIs to UTF-8 if they are US-ASCII.
This essentially replicates the functionality of the monkey patch to
URI.parser.unescape in active_support/core_ext/uri.rb.

Fixes #16104.

(cherry picked from commit 8a297131349bf4e0ade4a0941e5da0c987396d89)
Merge branch 'rosetta_flash' of https://github.com/gcampbell/rails into gcampbell-rosetta_flash

* 'rosetta_flash' of https://github.com/gcampbell/rails:
  Address CVE-2014-4671 (JSONP Flash exploit)

Conflicts:
	actionpack/CHANGELOG.md
Merge pull request #16127 from Envek/fix_16111

Dump PostgreSQL primary key with custom function as a default.

Conflicts:
	activerecord/CHANGELOG.md
	activerecord/test/cases/adapters/postgresql/uuid_test.rb
Fixed JSON coder when loading NULL from DB
Merge pull request #16162 from chancancode/fix_json_coder

Fixed JSON coder when loading NULL from DB
Fixed SQL syntax for postgresql
Return an absolute instead of relative path from an asset url in the case of the `asset_host` proc returning nil

(cherry picked from commit d005777469b7182b1a8f657a5b94363b321bef5d)

Conflicts:
	actionview/lib/action_view/helpers/asset_url_helper.rb
Address ORA-00972: identifier is too long when tested with Oracle
by using shorter attribute names.
Merge pull request #16181 from yahonda/ora972_faces_41

Address ORA-00972: identifier is too long when tested with Oracle
docs, remove unneeded `\` and remove trailing whitespace. [ci skip]
Don't accept parameters as argument for redirect to [via @homakov]

Closes #16170
nodoc enum hooks [ci skip]
docs, `select` and friends with `multiple=true` include a blank string.

[Jonas Baumann & Yves Senn]

The submitted params from a select with `multiple: true` look as follows:

```
{post: {category: [""]}}

{post: {category: ["", "Category 1", "Category 2"]}}
```

This is a follow up to #1552.
Fix that render layout should also be picked up by the template dependency tracker, but only half-ways. You can add that layout option on the same render call, and both templates should be added to the dependency tree. But thats going to require a more serious rework of the tracker. Please do help fix this part of it too. For now, render layout needs to be on its own line.
Merge pull request #16319 from Domon/fix-each-validator-example

Fix example code of EachValidator [ci skip]
Merge pull request #16148 from rails/fix_json_autoload

Fix json autoload
Conflicts:
	activesupport/CHANGELOG.md
Fixed CHANGELOG formating [ci skip]
Merge pull request #16328 from noinkling/template_password_confirmation_fix

Give password_confirmation div the "field" class in the scaffold generator "_form" partial

Conflicts:
	railties/CHANGELOG.md
docs, cleanup mixed indents within `form_options_helper.rb` RDoc.

[ci skip]

This fixes the broken code block rendering and indents the examples
within the parameter list.
Raise an exception when attachments are added after `mail` was called.

Closes #16163

Adding attachments after a call to `mail` will result in invalid emails.
This is related to the fact, that `mail` is making the required preparations
before the email is ready to be sent. These change depending on your
added attachments.

Conflicts:
	actionmailer/CHANGELOG.md