update my blog post on matrix room de-ciphering
This commit is contained in:
parent
8c70e2bec2
commit
f8f29c280d
3 changed files with 49 additions and 20 deletions
12
README.md
12
README.md
|
@ -1,10 +1,8 @@
|
||||||
# My Blog
|
# My Blog
|
||||||
|
|
||||||
|
```bash
|
||||||
|
nix-shell -p jekyll rubyPackages.sass
|
||||||
|
jekyll build
|
||||||
|
source ~/.awsrc
|
||||||
|
aws s3 sync _site/ s3://quentin.dufour.io/
|
||||||
```
|
```
|
||||||
echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p
|
|
||||||
RUBYOPT=--disable-did_you_mean bundle install
|
|
||||||
bundle exec jekyll serve
|
|
||||||
mc mirror --overwrite _site garage/quentin.dufour.io
|
|
||||||
```
|
|
||||||
|
|
||||||
test
|
|
||||||
|
|
|
@ -42,16 +42,8 @@ First, you should inform your users with a message, something like:
|
||||||
You will not be able to post new messages here, please follow the provided redirection to join the new room.
|
You will not be able to post new messages here, please follow the provided redirection to join the new room.
|
||||||
Sorry for the inconvenience.
|
Sorry for the inconvenience.
|
||||||
|
|
||||||
Now, open the developper tools in your old room by typing in the message box:
|
Now we will prepare a **state event** that point to the **new** room, create a file named `migration.json`
|
||||||
|
based on the following template:
|
||||||
```
|
|
||||||
/devtools
|
|
||||||
```
|
|
||||||
|
|
||||||
*You can also open it by going in "Room Settings" -> "Advanced" -> "Open Devtools"*
|
|
||||||
|
|
||||||
A window must appear. Click on "Send Custom Event". Then click on the red button "Event" to create a "State Event".
|
|
||||||
Put `m.room.tombstone` as the Event Type, keep the State Key field empty, and finally enter the following content (replace the example room ID by the one of your new room):
|
|
||||||
|
|
||||||
```json
|
```json
|
||||||
{
|
{
|
||||||
|
@ -60,6 +52,34 @@ Put `m.room.tombstone` as the Event Type, keep the State Key field empty, and fi
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
This event must be sent in the **old** room. Let's say its identifier is `!MFnHRRrCTMeHvfnNUD:deuxfleurs.fr`.
|
||||||
|
The URL template is thus:
|
||||||
|
|
||||||
|
```
|
||||||
|
https://im.deuxfleurs.fr/_matrix/client/v3/rooms/!MFnHRRrCTMeHvfnNUD:deuxfleurs.fr/state/m.room.tombstone
|
||||||
|
```
|
||||||
|
|
||||||
|
The last thing we need is to build an header file containing the required information for authentication onto the API.
|
||||||
|
Create a file named `hdrs.txt` based on the following template.
|
||||||
|
|
||||||
|
```text
|
||||||
|
Authorization: Bearer see_below_how_you_can_find_me
|
||||||
|
Content-Type: application/json
|
||||||
|
```
|
||||||
|
|
||||||
|
*The authorization header can be extracted from an Element Web instance by opening the developer panel (F12) and going to the Network tab.
|
||||||
|
Then select a request going to your matrix backend, on the right part of your screen search the "Authorization" line and copy/paste its value.*
|
||||||
|
|
||||||
|
Finally you can send the request to the API by again adapting the following command template:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
curl \
|
||||||
|
-H @hdrs.txt \
|
||||||
|
-X PUT \
|
||||||
|
-d @migration.json \
|
||||||
|
'https://im.deuxfleurs.fr/_matrix/client/v3/rooms/!MFnHRRrCTMeHvfnNUD:deuxfleurs.fr/state/m.room.tombstone'
|
||||||
|
```
|
||||||
|
|
||||||
And that's all, you have migrated your old encrypted room to a new clear text one!
|
And that's all, you have migrated your old encrypted room to a new clear text one!
|
||||||
|
|
||||||
If you want to explore all the possibilities offered by the developer tools, you can read [Matrix specification](https://spec.matrix.org/).
|
If you want to explore all the possibilities offered by the developer tools, you can read [Matrix specification](https://spec.matrix.org/).
|
||||||
|
|
17
index.html
17
index.html
|
@ -12,8 +12,9 @@ layout: default
|
||||||
<p>
|
<p>
|
||||||
Je suis ingénieur en informatique et libriste.
|
Je suis ingénieur en informatique et libriste.
|
||||||
J'ai travaillé sur <a href="https://www.torproject.org/">Tor</a> pendant <a href="https://theses.fr/s204646">ma thèse</a>.
|
J'ai travaillé sur <a href="https://www.torproject.org/">Tor</a> pendant <a href="https://theses.fr/s204646">ma thèse</a>.
|
||||||
Depuis, j'ai cofondé <a href="https://deuxfleurs.fr">Deuxfleurs</a>, un hébergeur associatif expérimental pour lequel je travaille.
|
Je suis membre de <a href="https://deuxfleurs.fr">Deuxfleurs</a>, un hébergeur associatif expérimental.
|
||||||
Nous développons des logiciels pour faciliter l'auto-hébergement comme <a href="https://garagehq.deuxfleurs.fr/">Garage</a>, une solution de stockage de données distribuée.
|
Nous développons des logiciels libres comme <a href="https://garagehq.deuxfleurs.fr/">Garage</a> pour un monde plus résilient et souverain.
|
||||||
|
Le reste du temps, je suis disponible pour vous accompagner sur vos projet informatiques en <em>freelance</em>, écrivez-moi !
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<nav class="list">
|
<nav class="list">
|
||||||
|
@ -40,7 +41,7 @@ layout: default
|
||||||
<section id="posts">
|
<section id="posts">
|
||||||
<h2>J'écris sur</h2>
|
<h2>J'écris sur</h2>
|
||||||
<section>
|
<section>
|
||||||
<h3>concevoir des systèmes informatiques</h3>
|
<h3>comment concevoir des systèmes informatiques</h3>
|
||||||
<div class="list">
|
<div class="list">
|
||||||
<ul>
|
<ul>
|
||||||
{% for post in site.categories.developpement %}
|
{% for post in site.categories.developpement %}
|
||||||
|
@ -177,6 +178,16 @@ layout: default
|
||||||
<p>Un logiciel de stockage de données géo-distribué écrit en Rust. C'est une alternative à AWS S3 et Minio.</p>
|
<p>Un logiciel de stockage de données géo-distribué écrit en Rust. C'est une alternative à AWS S3 et Minio.</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="card">
|
||||||
|
<h4><a href="https://git.deuxfleurs.fr/Deuxfleurs/diplonat">Diplonat</a></h4>
|
||||||
|
<p>À partir de déclarations dans Consul, diplonat se charge de configurer le réseau pour vous (upnp, pare-feu, etc.).</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="card">
|
||||||
|
<h4><a href="https://git.deuxfleurs.fr/Deuxfleurs/tricot">Tricot</a></h4>
|
||||||
|
<p>Tricot est un reverse proxy HTTP(S) inspiré de Traefik, fortement simplifié, et avec une approche <em>cluster-first</em>.</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
</section>
|
</section>
|
||||||
</section>
|
</section>
|
||||||
{% include footer.html %}
|
{% include footer.html %}
|
||||||
|
|
Loading…
Reference in a new issue