oda-hub / mmoda-frontend-module

GNU General Public License v2.0
0 stars 1 forks source link

D10 main #267

Open burnout87 opened 2 months ago

burnout87 commented 2 months ago

With the work of the last days, the API token form is now working (the email sending needs to be tested):

image

The module jwt_link is currently not available for Druapl 10, we use this in Drupal 7 to se the fields we want to include in the token. So, for now, these are set directly in the code of the mmoda module:

https://github.com/oda-hub/mmoda-frontend-module/blob/e0bb29b78c965de101e8593fa5326bcb0601da18/mmoda.module#L132-L155

Hopefully the module will be soon available also for Drupal 10, making our life easier.

Finally, the token structure is also slightly different:

eg

{
  "iat": 1725447485,
  "exp": 1725451085,
  "drupal": {
    "uid": "1"
  },
  "sub": "admin@example.com",
  "email": "admin@example.com",
  "name": "sitamin",
  "roles": [
    "authenticated",
    "administrator",
    "integral_private_qla",
    "unige_hpc_full"
  ],
  "field_matrix_room_id": "asd"
}

But afetr some test, it seems like it is still compatible with the dispatcher

burnout87 commented 2 months ago

Something to keep in mind when the Drupal 10 instance will be deployed, the current key is not compatible:

image