Manual:$wgApiFrameOptions/zh

From Linux Web Expert

<translate> Security</translate>: $wgApiFrameOptions
Control framing of api pages.
<translate> Introduced in version:</translate>1.20.0 (Gerrit change 20472; git #32b99b11)
<translate> Removed in version:</translate><translate> still in use</translate>
<translate> Allowed values:</translate>(字符串)或false
<translate> Default value:</translate>'DENY'

Details

Disallow framing of API pages directly, by setting the X-Frame-Options header. Since the API returns CSRF tokens, allowing the results to be framed can compromise your user's account security.

Options are:

  • 'DENY' - Do not allow framing. This is recommended for most wikis.
  • 'SAMEORIGIN' - Allow framing by pages on the same domain.
  • false - Allow all framing.

See also