deploy: a068ad7dd4
This commit is contained in:
parent
f87c322606
commit
74fc47b19e
|
@ -15185,13 +15185,51 @@ a temporary directory (which starts with "synapse-exfiltrate") in <cod
|
||||||
│ ├───state
|
│ ├───state
|
||||||
│ ├───invite_state
|
│ ├───invite_state
|
||||||
│ └───knock_state
|
│ └───knock_state
|
||||||
└───user_data
|
├───user_data
|
||||||
├───account_data
|
│ ├───account_data
|
||||||
│ ├───global
|
│ │ ├───global
|
||||||
│ └───<room_id>
|
│ │ └───<room_id>
|
||||||
├───connections
|
│ ├───connections
|
||||||
├───devices
|
│ ├───devices
|
||||||
└───profile
|
│ └───profile
|
||||||
|
└───media_ids
|
||||||
|
└───<media_id>
|
||||||
|
</code></pre>
|
||||||
|
<p>The <code>media_ids</code> folder contains only the metadata of the media uploaded by the user.
|
||||||
|
It does not contain the media itself.
|
||||||
|
Furthermore, only the <code>media_ids</code> that Synapse manages itself are exported.
|
||||||
|
If another media repository (e.g. <a href="https://github.com/turt2live/matrix-media-repo">matrix-media-repo</a>)
|
||||||
|
is used, the data must be exported separately.</p>
|
||||||
|
<p>With the <code>media_ids</code> the media files can be downloaded.
|
||||||
|
Media that have been sent in encrypted rooms are only retrieved in encrypted form.
|
||||||
|
The following script can help with download the media files:</p>
|
||||||
|
<pre><code class="language-bash">#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Parameters
|
||||||
|
#
|
||||||
|
# source_directory: Directory which contains the export with the media_ids.
|
||||||
|
# target_directory: Directory into which all files are to be downloaded.
|
||||||
|
# repository_url: Address of the media repository resp. media worker.
|
||||||
|
# serverName: Name of the server (`server_name` from homeserver.yaml).
|
||||||
|
#
|
||||||
|
# Example:
|
||||||
|
# ./download_media.sh /tmp/export_data/media_ids/ /tmp/export_data/media_files/ http://localhost:8008 matrix.example.com
|
||||||
|
|
||||||
|
source_directory=$1
|
||||||
|
target_directory=$2
|
||||||
|
repository_url=$3
|
||||||
|
serverName=$4
|
||||||
|
|
||||||
|
mkdir -p $target_directory
|
||||||
|
|
||||||
|
for file in $source_directory/*; do
|
||||||
|
filename=$(basename ${file})
|
||||||
|
url=$repository_url/_matrix/media/v3/download/$serverName/$filename
|
||||||
|
echo "Downloading $filename - $url"
|
||||||
|
if ! wget -o /dev/null -P $target_directory $url; then
|
||||||
|
echo "Could not download $filename"
|
||||||
|
fi
|
||||||
|
done
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h2 id="manually-resetting-passwords"><a class="header" href="#manually-resetting-passwords">Manually resetting passwords</a></h2>
|
<h2 id="manually-resetting-passwords"><a class="header" href="#manually-resetting-passwords">Manually resetting passwords</a></h2>
|
||||||
<p>Users can reset their password through their client. Alternatively, a server admin
|
<p>Users can reset their password through their client. Alternatively, a server admin
|
||||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -193,13 +193,51 @@ a temporary directory (which starts with "synapse-exfiltrate") in <cod
|
||||||
│ ├───state
|
│ ├───state
|
||||||
│ ├───invite_state
|
│ ├───invite_state
|
||||||
│ └───knock_state
|
│ └───knock_state
|
||||||
└───user_data
|
├───user_data
|
||||||
├───account_data
|
│ ├───account_data
|
||||||
│ ├───global
|
│ │ ├───global
|
||||||
│ └───<room_id>
|
│ │ └───<room_id>
|
||||||
├───connections
|
│ ├───connections
|
||||||
├───devices
|
│ ├───devices
|
||||||
└───profile
|
│ └───profile
|
||||||
|
└───media_ids
|
||||||
|
└───<media_id>
|
||||||
|
</code></pre>
|
||||||
|
<p>The <code>media_ids</code> folder contains only the metadata of the media uploaded by the user.
|
||||||
|
It does not contain the media itself.
|
||||||
|
Furthermore, only the <code>media_ids</code> that Synapse manages itself are exported.
|
||||||
|
If another media repository (e.g. <a href="https://github.com/turt2live/matrix-media-repo">matrix-media-repo</a>)
|
||||||
|
is used, the data must be exported separately.</p>
|
||||||
|
<p>With the <code>media_ids</code> the media files can be downloaded.
|
||||||
|
Media that have been sent in encrypted rooms are only retrieved in encrypted form.
|
||||||
|
The following script can help with download the media files:</p>
|
||||||
|
<pre><code class="language-bash">#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Parameters
|
||||||
|
#
|
||||||
|
# source_directory: Directory which contains the export with the media_ids.
|
||||||
|
# target_directory: Directory into which all files are to be downloaded.
|
||||||
|
# repository_url: Address of the media repository resp. media worker.
|
||||||
|
# serverName: Name of the server (`server_name` from homeserver.yaml).
|
||||||
|
#
|
||||||
|
# Example:
|
||||||
|
# ./download_media.sh /tmp/export_data/media_ids/ /tmp/export_data/media_files/ http://localhost:8008 matrix.example.com
|
||||||
|
|
||||||
|
source_directory=$1
|
||||||
|
target_directory=$2
|
||||||
|
repository_url=$3
|
||||||
|
serverName=$4
|
||||||
|
|
||||||
|
mkdir -p $target_directory
|
||||||
|
|
||||||
|
for file in $source_directory/*; do
|
||||||
|
filename=$(basename ${file})
|
||||||
|
url=$repository_url/_matrix/media/v3/download/$serverName/$filename
|
||||||
|
echo "Downloading $filename - $url"
|
||||||
|
if ! wget -o /dev/null -P $target_directory $url; then
|
||||||
|
echo "Could not download $filename"
|
||||||
|
fi
|
||||||
|
done
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h2 id="manually-resetting-passwords"><a class="header" href="#manually-resetting-passwords">Manually resetting passwords</a></h2>
|
<h2 id="manually-resetting-passwords"><a class="header" href="#manually-resetting-passwords">Manually resetting passwords</a></h2>
|
||||||
<p>Users can reset their password through their client. Alternatively, a server admin
|
<p>Users can reset their password through their client. Alternatively, a server admin
|
||||||
|
|
Loading…
Reference in New Issue