1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2026-11-09 03:36:48 +00:00
webvirtcloud/instances
catborise 4546653b5a fix: serve JSON endpoints as application/json and build DOM safely
Several views returned json.dumps() output through HttpResponse, i.e. as
text/html, and guess_mac_address reflects the URL's vname into it
(reflected XSS). Templates filled the log table and volume dropdowns by
concatenating server data into HTML strings, and log messages contain
user-entered snapshot/disk/clone names (stored XSS that runs when a
superuser opens the Logs tab).

- Use JsonResponse in guess_mac_address, random_mac_address,
  guess_clone_name, sshkeys, storages.get_volumes,
  datasource.os_metadata_json and logs.vm_logs; sshkeys?plain=true is
  served as text/plain.
- stats_tab.html builds log rows with .text(); instance.html and
  create_instance_w2.html build <option> elements with .val().text().
2026-10-02 18:29:11 +03:00
..
api fix(reconciliation): serialize compute sync and enforce UUID identity 2026-09-28 14:55:49 +03:00
fixtures Instances overhaul 2020-07-13 15:33:09 +06:00
migrations fix(reconciliation): serialize compute sync and enforce UUID identity 2026-09-28 14:55:49 +03:00
templates fix: serve JSON endpoints as application/json and build DOM safely 2026-10-02 18:29:11 +03:00
templatetags lint with black python. convert f style strings to old one. some small fixes 2020-11-05 12:34:31 +03:00
__init__.py Fixe migrations for new deployments 2020-05-28 18:19:25 +06:00
apps.py format python code with black 2022-11-02 08:54:35 +03:00
forms.py Corrected untranslated items 2023-12-13 14:00:02 +08:00
models.py fix(reconciliation): serialize compute sync and enforce UUID identity 2026-09-28 14:55:49 +03:00
test_create_instance.py fix(instances): guard mutations and refresh lists after sync 2026-09-28 14:56:19 +03:00
test_index.py fix(instances): guard mutations and refresh lists after sync 2026-09-28 14:56:19 +03:00
test_root_pass.py fix(instances): guard mutations and refresh lists after sync 2026-09-28 14:56:19 +03:00
test_security_mutations.py fix(instances): guard mutations and refresh lists after sync 2026-09-28 14:56:19 +03:00
test_xss.py fix: serve JSON endpoints as application/json and build DOM safely 2026-10-02 18:29:11 +03:00
tests.py fix(instances): guard mutations and refresh lists after sync 2026-09-28 14:56:19 +03:00
urls.py external snapshot implementation 2023-04-13 12:25:42 +03:00
utils.py fix(reconciliation): serialize compute sync and enforce UUID identity 2026-09-28 14:55:49 +03:00
views.py fix: serve JSON endpoints as application/json and build DOM safely 2026-10-02 18:29:11 +03:00