1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2026-11-08 19:26:48 +00:00
Commit graph

432 commits

Author SHA1 Message Date
catborise
8a3ee13b41 fix(instances): restrict disk views to superusers and validate disk input
Disk and media mutation views (add_new_vol, add_existing_vol, edit_volume,
delete_vol, detach_vol, add_cdrom, detach_cdrom, mount_iso, unmount_iso)
were reachable by any owner with is_change, although the UI only shows the
Disk tab to superusers. An ordinary user could delete any volume on the
compute or attach arbitrary host files to their VM.

- Require superuser for all disk/media views, matching the UI.
- delete_vol resolves the volume from the VM's own disk XML by dev and
  ignores the posted storage/name.
- Validate bus/cache/io/discard/detect_zeroes against the hypervisor's
  lists, and format/serial/volume name against strict patterns.
- add_existing_vol only accepts volumes that exist in the selected pool.
- edit_volume only accepts a dev attached to the VM.
- vrtManager: escape all values interpolated into disk XML and pass dev
  as an XPath variable in detach_disk/edit_disk.
2026-10-02 17:11:12 +03:00
catborise
73d8fd71fb fix(instances): guard mutations and refresh lists after sync 2026-09-28 14:56:19 +03:00
catborise
2cdf5dfca1 fix(reconciliation): serialize compute sync and enforce UUID identity 2026-09-28 14:55:49 +03:00
catborise
b3e6fb2b7a feat(security): enforce require_POST on power actions, prevent open redirects, and isolate instance permissions 2026-09-27 13:20:45 +03:00
catborise
3f8eeb04bd fix(reconciliation): implement UUID-based domain reconciliation and connection safety 2026-09-27 13:13:43 +03:00
catborise
708b986e8e feat(security): apply Codex review hardening to console tokens and superuser authorization 2026-09-27 11:30:03 +03:00
catborise
1227674d8f feat(security): implement P0 critical security fixes for API, console, and access control
- Computes API: mark password as write_only in ComputeSerializer, restrict ComputeViewSet and architectures to IsAdminUser.
- Instances API: enforce user ownership tenant isolation in InstanceViewSet.list, restrict MigrateViewSet and CreateInstanceViewSet to IsAdminUser, require IsAdminUser for mutating FlavorViewSet.
- Storage, Network, and Interface APIs: restrict StorageViewSet, VolumeViewSet, NetworkViewSet, InterfaceViewSet to IsAdminUser.
- AppSettings & NWFilters: protect appsettings and nwfilter views with @superuser_only (403 Forbidden for non-superusers).
- noVNC Console: sign tokens with TimestampSigner (salt='console.novnc', max_age=600), verify signature and user authorization in novncd with backward-compatible fallback for debug/test mode.
- Accounts: avoid hardcoded default admin password; generate cryptographically secure random password unless ADMIN_PASSWORD is set (preserve 'admin' in test runner).
- gstfsd daemon: bind to 127.0.0.1 by default instead of 0.0.0.0.
- Tests: added comprehensive test coverage for API security, token expiration/rejection, and view permissions (132 tests passing).
2026-09-27 10:50:09 +03:00
catborise
e980aca2ff feat(console): remove deprecated SPICE support in favor of noVNC
- Remove obsolete spice-html5 static assets and SPICE console templates
- Restrict default console types to VNC with migration 0012
- Filter out SPICE in VM creation form and backend capabilities
- Return friendly deprecation notice if legacy VM is opened with SPICE
- Clean up docs, architecture references, and libvirt-bootstrap scripts
2026-09-26 22:43:40 +03:00
catborise
60565b05b3 fix(tests): decouple tests from local libvirt, support configurable test host, and fix URL/logging bugs 2026-09-25 11:51:45 +03:00
catborise
c31ed28042 test: expand unit test coverage across admin, accounts, vrtManager, logs, appsettings, and datasource 2026-09-25 11:26:53 +03:00
catborise
7a9b3c9e13 feat(dev): improve Rocky Linux and RHEL compatibility for local development
- Relax libvirt-python and lxml version pins to allow precompiled distro packages
- Add PEP 508 environment marker to crypt-r (python_version >= 3.13) to avoid unnecessary C compilation on Python 3.12
- Add stdlib crypt fallback when crypt_r is not available in instances/views.py
- Make LDAP imports and configuration optional in settings.py.template
- Add --system-site-packages and missing packages in webvirtcloud.sh for RHEL/CentOS
- Update README with working Rocky Linux / RHEL / Fedora installation and local dev setup
2026-09-25 09:45:54 +03:00
catborise
3633c0096e refactor(console): replace deprecated optparse with argparse and fix regex escape sequences 2026-09-24 22:08:08 +03:00
Jan Krcmar
80541239ec fix template clone icon replaced with copy icon 2026-04-15 17:29:08 +02:00
Liang Suilong
8bca7db917 crypt-r replaces crypt stdlib, support python-3.13 2025-03-30 10:33:51 +08:00
catborise
3f23acbb9d
Merge pull request #638 from catborise/master
fix default nic type problem
2024-02-28 08:18:08 +03:00
catborise
765b759953 if nic type is default then make it virtio 2024-02-28 08:16:44 +03:00
catborise
a048adef8e do not show warning message when instance is shutdown 2024-02-28 08:13:08 +03:00
catborise
9ee1571f5b
Merge pull request #634 from catborise/master
fix user machine for listing
2024-02-13 14:35:03 +03:00
catborise
81b96b6512 fix listing vms for normal users 2024-02-13 14:24:38 +03:00
catborise
1f90a6c8c9
Merge pull request #631 from catborise/master
update requirements
2024-01-17 10:24:13 +03:00
catborise
9a05c182cc fix chevron up down icons 2024-01-17 10:19:03 +03:00
Wang Hong
c58d6f484d Corrected untranslated items 2023-12-13 14:00:02 +08:00
MisterBlueBear
7e8c05fff9 Global setting for NIC type 2023-11-01 18:08:38 -04:00
MisterBlueBear
5a211c0c56 Get MAC OUI from settings.py 2023-10-18 17:34:40 -04:00
Amélie Krejčí
1b2b3a3bce
Get UserAttributes object using get_or_create
This is done to automatically create the UserAttributes object in case LDAP User Backend didn't create it.
2023-09-23 09:52:48 +02:00
catborise
cf6f74f6c3 fix sr-only toggle dropdown to hide 2023-08-23 09:26:39 +03:00
cserma
f2222a6ea8 change name for network model to nic type 2023-08-17 13:22:18 +03:00
cserma
7d1cfb69b0 network interface model selection added for new instance and new interface 2023-08-16 09:13:11 +03:00
catborise
b47ec2e8f9 bootstrap icon conversion fixes 2023-08-11 09:40:38 +03:00
Emre Serdengeçti
1cbdf76df6
logger updates (#31)
* Log for failed login attempts

* Logger configuration for logging to file

* interface fixes

* login log fix, added logged in too

* bootstrap icons setup

* font-awesome icons replaced with bootstrap icons

* replaced i-tags with django_bootstrap_icons

* removed icons library from project

* bug fix

---------

Co-authored-by: catborise <catborise@gmail.com>
2023-08-09 09:20:18 +03:00
catborise
c0513f7c6b change progress bar color & fix typo 2023-05-12 11:18:17 +03:00
cserma
2941840f0d 'create new instance' screen improvements 2023-05-12 10:15:01 +03:00
cserma
3cd4212cdd modified 'create new instance' screen with compute details 2023-05-10 13:59:13 +03:00
cserma
3403d21fea log i18n fixes 2023-05-10 13:57:01 +03:00
cserma
907d47ab78 snapshots tab improvements 2023-05-10 13:57:01 +03:00
catborise
012bc97a59 add showPleasewait dialog while starting instance. 2023-04-24 14:39:22 +03:00
catborise
f4aa925e2a experimental: external snapshot fixes 2 2023-04-14 16:11:13 +03:00
catborise
33d49a68a7 experimental: external snapshot fixes 2023-04-13 12:25:42 +03:00
cserma
68b0494350 external snapshot logs and bug fixes 2023-04-13 12:25:42 +03:00
cserma
fd6b2ec4bf external snapshot implementation 2023-04-13 12:25:42 +03:00
catborise
bea6b1454b fix grouped non grouped instance view 2023-03-13 11:22:40 +03:00
catborise
e3fb820b50 update bootstrap&bootswatch 5.0.2 -> 5.2.2. Seperate bootswatch overrides for future update easiness 2023-01-23 08:25:44 +03:00
catborise
a1eab70e2d reorg imports and black format 2022-11-02 16:05:41 +03:00
catborise
fcd4b79431
Merge branch 'master' into master 2022-11-02 15:59:19 +03:00
catborise
217e106c8b format python code with black 2022-11-02 08:54:35 +03:00
catborise
7b33f511cf
Merge pull request #542 from catborise/master
add description to snapshots. Stress out live snapshot risks
2022-09-26 11:03:05 +03:00
catborise
c9f1a7d7c5 add description to snapshots. Stress out live snapshot risks 2022-09-19 15:44:57 +03:00
catborise
2dc4048053
Merge pull request #538 from catborise/master
make cd-rom and input devices optional while instance creating
2022-09-08 09:07:50 +03:00
catborise
481c110f01 make adding input devices optional. give bus control for input devices whie instance creating 2022-09-08 08:02:49 +03:00
catborise
5f5bd379af make adding cd-rom optional while vm creating. Add default value for cd-rom bus 2022-09-07 13:46:50 +03:00