mirror of
https://github.com/matrix-org/matrix-spec
synced 2026-03-25 20:44:09 +01:00
C2S: Drop allow_remote and allow_redirect on new endpoints
This commit is contained in:
parent
e7442b6bad
commit
3e6ba86889
|
|
@ -27,6 +27,10 @@ paths:
|
||||||
the query string. These URLs may be copied by users verbatim and provided
|
the query string. These URLs may be copied by users verbatim and provided
|
||||||
in a chat message to another user, disclosing the sender's access token.
|
in a chat message to another user, disclosing the sender's access token.
|
||||||
{{% /boxes/note %}}
|
{{% /boxes/note %}}
|
||||||
|
|
||||||
|
Clients MAY be redirected using the 307/308 responses below to download
|
||||||
|
the request object. This is typical when the homeserver uses a Content
|
||||||
|
Delivery Network (CDN).
|
||||||
operationId: getContentAuthed
|
operationId: getContentAuthed
|
||||||
security:
|
security:
|
||||||
- accessTokenQuery: []
|
- accessTokenQuery: []
|
||||||
|
|
@ -34,9 +38,7 @@ paths:
|
||||||
parameters:
|
parameters:
|
||||||
- $ref: '#/components/parameters/serverName'
|
- $ref: '#/components/parameters/serverName'
|
||||||
- $ref: '#/components/parameters/mediaId'
|
- $ref: '#/components/parameters/mediaId'
|
||||||
- $ref: '#/components/parameters/allow_remote'
|
|
||||||
- $ref: '#/components/parameters/timeout_ms'
|
- $ref: '#/components/parameters/timeout_ms'
|
||||||
- $ref: '#/components/parameters/allow_redirect'
|
|
||||||
responses:
|
responses:
|
||||||
"200":
|
"200":
|
||||||
description: The content that was previously uploaded.
|
description: The content that was previously uploaded.
|
||||||
|
|
@ -78,6 +80,10 @@ paths:
|
||||||
the query string. These URLs may be copied by users verbatim and provided
|
the query string. These URLs may be copied by users verbatim and provided
|
||||||
in a chat message to another user, disclosing the sender's access token.
|
in a chat message to another user, disclosing the sender's access token.
|
||||||
{{% /boxes/note %}}
|
{{% /boxes/note %}}
|
||||||
|
|
||||||
|
Clients MAY be redirected using the 307/308 responses below to download
|
||||||
|
the request object. This is typical when the homeserver uses a Content
|
||||||
|
Delivery Network (CDN).
|
||||||
operationId: getContentOverrideNameAuthed
|
operationId: getContentOverrideNameAuthed
|
||||||
security:
|
security:
|
||||||
- accessTokenQuery: []
|
- accessTokenQuery: []
|
||||||
|
|
@ -92,9 +98,7 @@ paths:
|
||||||
example: filename.jpg
|
example: filename.jpg
|
||||||
schema:
|
schema:
|
||||||
type: string
|
type: string
|
||||||
- $ref: '#/components/parameters/allow_remote'
|
|
||||||
- $ref: '#/components/parameters/timeout_ms'
|
- $ref: '#/components/parameters/timeout_ms'
|
||||||
- $ref: '#/components/parameters/allow_redirect'
|
|
||||||
responses:
|
responses:
|
||||||
"200":
|
"200":
|
||||||
description: The content that was previously uploaded.
|
description: The content that was previously uploaded.
|
||||||
|
|
@ -137,6 +141,10 @@ paths:
|
||||||
the query string. These URLs may be copied by users verbatim and provided
|
the query string. These URLs may be copied by users verbatim and provided
|
||||||
in a chat message to another user, disclosing the sender's access token.
|
in a chat message to another user, disclosing the sender's access token.
|
||||||
{{% /boxes/note %}}
|
{{% /boxes/note %}}
|
||||||
|
|
||||||
|
Clients MAY be redirected using the 307/308 responses below to download
|
||||||
|
the request object. This is typical when the homeserver uses a Content
|
||||||
|
Delivery Network (CDN).
|
||||||
operationId: getContentThumbnailAuthed
|
operationId: getContentThumbnailAuthed
|
||||||
security:
|
security:
|
||||||
- accessTokenQuery: []
|
- accessTokenQuery: []
|
||||||
|
|
@ -173,9 +181,7 @@ paths:
|
||||||
enum:
|
enum:
|
||||||
- crop
|
- crop
|
||||||
- scale
|
- scale
|
||||||
- $ref: '#/components/parameters/allow_remote'
|
|
||||||
- $ref: '#/components/parameters/timeout_ms'
|
- $ref: '#/components/parameters/timeout_ms'
|
||||||
- $ref: '#/components/parameters/allow_redirect'
|
|
||||||
- in: query
|
- in: query
|
||||||
name: animated
|
name: animated
|
||||||
x-addedInMatrixVersion: "1.11"
|
x-addedInMatrixVersion: "1.11"
|
||||||
|
|
@ -440,20 +446,6 @@ components:
|
||||||
example: ascERGshawAWawugaAcauga
|
example: ascERGshawAWawugaAcauga
|
||||||
schema:
|
schema:
|
||||||
type: string
|
type: string
|
||||||
allow_remote:
|
|
||||||
in: query
|
|
||||||
name: allow_remote
|
|
||||||
required: false
|
|
||||||
description: |-
|
|
||||||
Indicates to the server that it should not attempt to fetch the media if
|
|
||||||
it is deemed remote. This is to prevent routing loops where the server
|
|
||||||
contacts itself.
|
|
||||||
|
|
||||||
Defaults to `true` if not provided.
|
|
||||||
example: false
|
|
||||||
schema:
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
timeout_ms:
|
timeout_ms:
|
||||||
in: query
|
in: query
|
||||||
name: timeout_ms
|
name: timeout_ms
|
||||||
|
|
@ -469,19 +461,6 @@ components:
|
||||||
type: integer
|
type: integer
|
||||||
format: int64
|
format: int64
|
||||||
default: 20000
|
default: 20000
|
||||||
allow_redirect:
|
|
||||||
in: query
|
|
||||||
name: allow_redirect
|
|
||||||
x-addedInMatrixVersion: "1.7"
|
|
||||||
required: false
|
|
||||||
description: |
|
|
||||||
Indicates to the server that it may return a 307 or 308 redirect
|
|
||||||
response that points at the relevant media content. When not explicitly
|
|
||||||
set to `true` the server must return the media content itself.
|
|
||||||
example: false
|
|
||||||
schema:
|
|
||||||
type: boolean
|
|
||||||
default: false
|
|
||||||
responses:
|
responses:
|
||||||
rateLimited:
|
rateLimited:
|
||||||
description: This request was rate-limited.
|
description: This request was rate-limited.
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue