mirror of https://github.com/mautrix/docs.git
30 lines
1.3 KiB
Markdown
30 lines
1.3 KiB
Markdown
# Authentication
|
|
0. Open a private chat with the bridge bot. Usually `@googlechatbot:your.server`.
|
|
* If the bot doesn't accept the invite, see the [troubleshooting page](../../general/troubleshooting.md)
|
|
1. Open <https://chat.google.com> in a private browser window and log in
|
|
normally, then extract cookies:
|
|
1. Press <kbd>F12</kbd> to open developer tools.
|
|
2. select the "Application" (Chrome) or "Storage" (Firefox) tab.
|
|
3. In the sidebar, expand "Cookies" and select `https://chat.google.com`.
|
|
4. In the cookie list, find the `COMPASS`, `SSID`, `SID`, `OSID` and `HSID`
|
|
rows.
|
|
* When using Firefox, you may have multiple `COMPASS` cookies with
|
|
different paths. Pick the one where path is `/`.
|
|
5. Form a JSON object with the extracted cookies. It should look something
|
|
like this (field names are case-insensitive):
|
|
```json
|
|
{
|
|
"compass": "dynamite-ui=...",
|
|
"ssid": "...",
|
|
"sid": "...",
|
|
"osid": "...",
|
|
"hsid": "..."
|
|
}
|
|
```
|
|
6. Close the browser window to prevent the cookies being invalidated
|
|
(Google uses refresh tokens, so you need to close the window within
|
|
a few minutes).
|
|
2. Send `login-cookie {the json object}` to the bot.
|
|
3. Recent chats should now get portals automatically. Other chats will get
|
|
portals as you receive messages.
|