Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gérer les erreurs de connexions au serveur d’identité #119

Open
BHoury opened this issue Mar 28, 2024 · 2 comments
Open

Gérer les erreurs de connexions au serveur d’identité #119

BHoury opened this issue Mar 28, 2024 · 2 comments
Labels
bug Une fonctionnalité existante a un comportement imprévu

Comments

@BHoury
Copy link
Collaborator

BHoury commented Mar 28, 2024

Nous avons observé sur B3Desk 1.1.6 un plantage de l'application web quand l'authentification OpenID ne répondait pas (par exemple OpenID down).

Logs :

[2024-03-27 09:28:48 +0000] [11] [CRITICAL] WORKER TIMEOUT (pid:15)
[2024-03-27 09:28:55 +0000] [17] [ERROR] Exception in worker process
Traceback (most recent call last):
  File "/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py", line 467, in _make_request
    self._validate_conn(conn)
  File "/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py", line 1092, in _validate_conn
    conn.connect()
  File "/usr/local/lib/python3.8/site-packages/urllib3/connection.py", line 642, in connect
    sock_and_verified = _ssl_wrap_socket_and_match_hostname(
  File "/usr/local/lib/python3.8/site-packages/urllib3/connection.py", line 783, in _ssl_wrap_socket_and_match_hostname
    ssl_sock = ssl_wrap_socket(
  File "/usr/local/lib/python3.8/site-packages/urllib3/util/ssl_.py", line 469, in ssl_wrap_socket
    ssl_sock = _ssl_wrap_socket_impl(sock, context, tls_in_tls, server_hostname)
  File "/usr/local/lib/python3.8/site-packages/urllib3/util/ssl_.py", line 513, in _ssl_wrap_socket_impl
    return ssl_context.wrap_socket(sock, server_hostname=server_hostname)
  File "/usr/local/lib/python3.8/ssl.py", line 500, in wrap_socket
    return self.sslsocket_class._create(
  File "/usr/local/lib/python3.8/ssl.py", line 1073, in _create
    self.do_handshake()
  File "/usr/local/lib/python3.8/ssl.py", line 1342, in do_handshake
    self._sslobj.do_handshake()
socket.timeout: _ssl.c:1114: The handshake operation timed out

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/local/lib/python3.8/site-packages/requests/adapters.py", line 486, in send
    resp = conn.urlopen(
  File "/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py", line 844, in urlopen
    retries = retries.increment(
  File "/usr/local/lib/python3.8/site-packages/urllib3/util/retry.py", line 470, in increment
    raise reraise(type(error), error, _stacktrace)
  File "/usr/local/lib/python3.8/site-packages/urllib3/util/util.py", line 39, in reraise
    raise value
  File "/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py", line 790, in urlopen
    response = self._make_request(
  File "/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py", line 491, in _make_request
    raise new_e
  File "/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py", line 469, in _make_request
    self._raise_timeout(err=e, url=url, timeout_value=conn.timeout)
  File "/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py", line 370, in _raise_timeout
    raise ReadTimeoutError(
urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='auth.apps.education.fr', port=443): Read timed out. (read timeout=5.0)
@azmeuk
Copy link
Collaborator

azmeuk commented Mar 29, 2024

C'est une variante de #39 mais avec le serveur OIDC.

Comment faut-il résoudre cette situation ?
Est-ce qu'on affiche un message d'erreur sur toutes les pages du site, ou bien on essaye de maintenir le service sur les pages qui ne nécessitent pas d'OIDC ?

@azmeuk azmeuk added the bug Une fonctionnalité existante a un comportement imprévu label Mar 29, 2024
@azmeuk azmeuk changed the title Plantage de B3desk - OpenID non disponible Gérer les erreurs de connexions au serveur d’identité Mar 29, 2024
@BHoury
Copy link
Collaborator Author

BHoury commented Mar 29, 2024

Il faut maintenir les pages qui ne nécessitent pas OIDC pour permettre aux personnes qui ont un lien d'invitation à une visio de pouvoir y accéder.
Pour les pages qui nécessitent OIDC il faudrait un message d'erreur indiquant que l'authentification n'est pas disponible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Une fonctionnalité existante a un comportement imprévu
Projects
None yet
Development

No branches or pull requests

2 participants