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

Missing identity_id key in set_user_account (userprofile) #315

Open
kh4rdur opened this issue Feb 6, 2025 · 0 comments
Open

Missing identity_id key in set_user_account (userprofile) #315

kh4rdur opened this issue Feb 6, 2025 · 0 comments
Assignees
Labels
accepted This issue was accepted, we will work on this at some point bug Something isn't working pending review

Comments

@kh4rdur
Copy link

kh4rdur commented Feb 6, 2025

Describe the bug
Since the latest update we've noticed Error messages after changing users that where created before the latest update.

{"@timestamp": "2025-02-06 15:51:12,505", "event": { "module": "assemblyline", "dataset": "assemblyline_ui" }, "host": { "ip": "" "hostname": "279d60e80c8b" }, "log": { "level": "ERROR", "logger": "assemblyline_ui" }, "process": { "pid": "758" }, "message": "Exception on /api/v4/user// [POST]\nTraceback (most recent call last):\n File "/var/lib/assemblyline/.local/lib/python3.11/site-packages/flask/app.py", line 2190, in wsgi_app\n response = self.full_dispatch_request()\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File "/var/lib/assemblyline/.local/lib/python3.11/site-packages/flask/app.py", line 1486, in full_dispatch_request\n rv = self.handle_user_exception(e)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File "/var/lib/assemblyline/.local/lib/python3.11/site-packages/flask/app.py", line 1484, in full_dispatch_request\n rv = self.dispatch_request()\n ^^^^^^^^^^^^^^^^^^^^^^^\n File "/var/lib/assemblyline/.local/lib/python3.11/site-packages/flask/app.py", line 1469, in dispatch_request\n return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File "/var/lib/assemblyline/.local/lib/python3.11/site-packages/assemblyline_ui/api/base.py", line 237, in base\n return func(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^^^\n File "/var/lib/assemblyline/.local/lib/python3.11/site-packages/assemblyline_ui/api/v4/user.py", line 528, in set_user_account\n data.pop('identity_id')\nKeyError: 'identity_id'\n"}

Seems like things have been changed on the identity_id part.

To Reproduce
Running version 4.5.0.x (before version 4.5.0.70)

  • create a user account
  • Update the system to version 4.5.0.70+
  • Try edittting the Clasification for the created user
  • you will get a error on the screen while saving.

Expected behavior
Account should be updated and missing identity_id field should be updated in the background.

Environment (please complete the following information if pertinent):

  • Assemblyline Version: 4.5.0.73
@kh4rdur kh4rdur added assess We still haven't decided if this will be worked on or not bug Something isn't working labels Feb 6, 2025
@cccs-rs cccs-rs added accepted This issue was accepted, we will work on this at some point pending review and removed assess We still haven't decided if this will be worked on or not labels Feb 9, 2025
cccs-rs added a commit to CybercentreCanada/assemblyline-ui that referenced this issue Feb 10, 2025
Handle cases where the value of `identity_id` was never assigned (dev)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accepted This issue was accepted, we will work on this at some point bug Something isn't working pending review
Projects
None yet
Development

No branches or pull requests

3 participants