.editorconfig
author Matthew Wild <mwild1@gmail.com>
Mon, 31 Oct 2022 14:32:02 +0000
branch0.12
changeset 12794 24b55f0e2db9
parent 11710 56feb0cf7052
child 13195 1266efb7101c
permissions -rw-r--r--
mod_http: Allow disabling CORS in the http_cors_override option and by default Fixes #1779. Due to an oversight in the logic, if the user set 'enabled' to false in an override, it would disable the item's requested CORS settings, but still apply Prosody's default CORS policy. This change ensures that 'enabled = false' will now disable CORS entirely for the requested item. Due to the new structure of the code, it was necessary to have a flag to say whether CORS is to be applied at all. Rather than hard-coding 'true' here, I chose to add a new option: 'http_default_cors_enabled'. This is a boolean that allows the operator to disable Prosody's default CORS policy entirely (the one that is used when a module or config does not override it). This makes it easier to disable CORS and then selectively enable it only on services you want it on.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
11710
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
     1
root = true
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
     2
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
     3
[*]
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
     4
end_of_line = lf
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
     5
indent_style = tab
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
     6
insert_final_newline = true
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
     7
trim_trailing_whitespace = true
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
     8
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
     9
[CHANGES]
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    10
indent_size = 4
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    11
indent_style = space
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    12
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    13
[configure]
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    14
indent_size = 3
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    15
indent_style = space
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    16
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    17
[**.xml]
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    18
indent_size = 2
56feb0cf7052 editorconfig: We use tabs
Kim Alvefur <zash@zash.se>
parents:
diff changeset
    19
indent_style = space