Skip to content

Commit 847caff

Browse files
authored
Merge branch 'develop' into update_language_contexts
2 parents e550473 + 934f1ed commit 847caff

64 files changed

Lines changed: 42908 additions & 153657 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.dockerignore

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,3 @@
66
.DS_Store
77
.SD_Store?
88
.swp
9-
10-
config.php

CHANGELOG.txt

Lines changed: 47 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,53 @@
11
-------------------------------------
2-
6.0-0
2+
7.1-2
33
-------------------------------------
4-
Upgrade to Virtualbox 6.0
4+
Fixed https://github.com/phpvirtualbox/phpvirtualbox/issues/350
5+
Clonig VMs causes an error - Vm clonig is unuseable in phpvirtualbox
6+
7+
https://github.com/phpvirtualbox/phpvirtualbox/issues/341
8+
AD Auth broken in PHP 8
9+
10+
Fixed MySQL Auth library
11+
12+
Updated install script
13+
14+
Updated to jQuery 3.7.1 and jQuery-UI 1.14.1
15+
16+
PHP 8.0-8.4 compatibility
17+
18+
Added Subtype OS filter in VM settings.
19+
20+
Updated Encryption settings tab to match Disk Encryption wording
21+
in VirtualBox 7.1.
22+
23+
Fixed bug when pressing escape to close dialog that would cause
24+
subsequent dialogs to malfunction until the page was reloaded.
25+
26+
Implement TPM settings.
27+
28+
Removed WSDL files from older versions.
29+
30+
-------------------------------------
31+
7.1-1 2025-04-24
32+
-------------------------------------
33+
Project relocated back to phpvirtualbox github org
34+
35+
-------------------------------------
36+
7.1-0 2024-10-15
37+
-------------------------------------
38+
Virtualbox 7.1 support
39+
40+
-------------------------------------
41+
7.0-0 from Beta 1 to RC 1
42+
-------------------------------------
43+
Support for VirtualBox 7.0 and PHP8.2
44+
Fixed clone option and encryption/decryption
45+
Fixes for few small bugs
546

47+
-------------------------------------
48+
6.0-0
49+
-------------------------------------
50+
Upgrade to Virtualbox 6.0
651

752
-------------------------------------
853
5.2-1 2018-11-09
@@ -15,7 +60,6 @@ Russian translation fixes - @SvetlanaTkachenko
1560
Viewport and URL fixes - @krzysztof113
1661
Convert to unix file format to reduce size
1762

18-
1963
-------------------------------------
2064
5.2-0 2018-02-16
2165
-------------------------------------

Dockerfile

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
FROM php:5.6-apache
1+
FROM php:8.4-apache
22
RUN apt-get update && \
33
apt-get install -y \
44
libxml2 \
5-
libxml2-dev && \
6-
docker-php-ext-install soap
7-
COPY . /var/www/html
5+
libxml2-dev
6+
RUN docker-php-ext-install soap pdo_mysql

README.md

Lines changed: 42 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,37 @@
11
# About
22

3-
phpVirtualBox is from 2017 maintained by Smart Guide Pty Ltd (tudor at smartguide dot com dot au)
3+
April 2025
44

5-
with support from various contributors (see https://github.com/phpvirtualbox/phpvirtualbox/graphs/contributors)
5+
Project adopted by Anonie Muss. Updated from https://github.com/studnitskiy/phpvirtualbox where
6+
it had been modified to work with VirtualBox 7.1. Thanks to studnitskiy for his work, and now that
7+
he is a member of the github project, I hope he will continue to contribute.
68

7-
Originally Copyright (C) 2015 Ian Moore (imoore76 at yahoo dot com)
9+
## Roadmap
10+
11+
- [ ] ~~Use Guacamole instead of Flash RDP client~~ Not possible without some gateway server
12+
- [ ] Ensure feature parity with VirtualBox 7.1 minus Oracle Cloud features
13+
- [x] PHP 8.4 compatibility
14+
- [x] jQuery and jQuery UI updates
15+
- [ ] Create a release process where javascript and CSS are minified and releses do not contain unnecessary build artifacts
16+
- [ ] UI parity with VirtualBox 7.1 minus Oracle Cloud features
17+
18+
## History
19+
20+
October 2024
21+
22+
VirtualBox 7.1 support for x86 hosts only, no ARM hosts support.
23+
I've basically made it stop complaining and allow my existing environment to work.
24+
Minimally tested with PHP 8.2 (PHP-FPM + nginx).
25+
26+
Original text follows
27+
28+
This repository is a continuation of phpVirtualBox, which is no longer supported by the official authors (last commit on thier repository was sent on Jan 27, 2021 - written on Jan 18, 2023).
29+
30+
Right now (from 2022), this software is updated by *[Bartek Sz.](https://github.com/BartekSz95)* and various contributors (see https://github.com/BartekSz95/phpvirtualbox/graphs/contributors).
31+
32+
phpVirtualBox was from 2017 to 2021 maintained by Smart Guide Pty Ltd (tudor at smartguide dot com dot au) with support from various contributors.
33+
34+
Originally Copyright © 2010-2015 by Ian Moore (imoore76 at yahoo dot com).
835

936
FREE, WITHOUT WARRANTY:
1037

@@ -16,24 +43,29 @@ the license file, or do not agree with its conditions, please cease using
1643
this software immediately and remove any copies you may have in your
1744
possession.
1845

19-
# Installation from Zip file
46+
# Requirements
47+
48+
- PHP 8.X - **Older versions are not considered.**
49+
50+
- Webserver (eg. Apache HTTPD, nginx)
2051

21-
1) Download zip file from GitHub project site: https://github.com/phpvirtualbox/phpvirtualbox/archive/master.zip
52+
- VirtualBox 7.1.x
2253

23-
2) Unzip the zipfile into a folder accessible by your web server
54+
# Installation from ZIP file
2455

56+
1) Download ZIP file from GitHub project site: https://github.com/phpvirtualbox/phpvirtualbox/archive/master.zip.
57+
2) Unzip the ZIP file into a folder accessible by your web server.
2558
3) Rename config.php-example to config.php and edit as needed.
2659

2760
Read the wiki for more information : https://github.com/phpvirtualbox/phpvirtualbox/wiki
2861

2962
# Post installation
3063

31-
Default login is username: admin password: admin
64+
Default login is (**username**/**password**): *admin*/*admin*
3265

33-
Please report bugs / feature requests to GitHub
66+
Please report bugs/feature requests to GitHub:
3467
https://github.com/phpvirtualbox/phpvirtualbox/issues
3568

3669
# Password Recovery
3770

38-
Rename the file recovery.php-disabled to recovery.php, navigate to it in
39-
your web browser, and follow the instructions presented.
71+
Rename the file recovery.php-disabled to recovery.php, navigate to it in your web browser, and follow the instructions presented.

docker-compose.yml

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,24 @@
1-
# Develop phpvirtualbox in docker
1+
# Develop phpvirtualbox in docker container
22
#
33
# 1) Get virtualbox host-only interface IP used by docker machine:
4-
# docker-machine inspect default -f '{{.Driver.HostOnlyCIDR}}' | sed -e 's#/.*##'
4+
# docker network inspect bridge -f '{{ (index .IPAM.Config 0).Gateway }}'
5+
# - or -
6+
# docker run busybox:1.37 busybox ash -c 'ip route | grep default | awk "{ print \$3 }"'
7+
#
58
# 2) Start vboxwebsrv on the IP returned from the above command:
69
# vboxwebsrv -H 192.168.99.1 # or edit vboxwebsrv startup config
7-
# 3) Edit config.php to use the IP
10+
#
11+
# 3) Edit config.php $location to use the IP
12+
#
813
# 4) docker-compose up
9-
# 5) Get docker machine ip:
10-
# docker-machine ip default
11-
# 6) phpVirtualBox should be available at http://<ip returned from above command>
1214
#
13-
phpvirtualbox:
14-
build: .
15-
ports:
16-
- "80:80"
17-
volumes:
18-
- .:/var/www/html
15+
# 5) phpVirtualBox should be available at http://localhost
16+
#
17+
services:
18+
19+
phpvirtualbox:
20+
build: .
21+
ports:
22+
- "80:80"
23+
volumes:
24+
- .:/var/www/html

endpoints/api.php

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616

1717
# Turn off PHP errors
18-
error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT & ~E_WARNING);
18+
@error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT & ~E_WARNING);
1919

2020

2121
//Set no caching
@@ -334,6 +334,9 @@
334334

335335
// Just append to $vbox->errors and let it get
336336
// taken care of below
337+
if(!isset($vbox)) {
338+
$vbox = new stdClass();
339+
}
337340
if(!$vbox || !$vbox->errors) {
338341
$vbox->errors = array();
339342
}
@@ -342,7 +345,7 @@
342345

343346

344347
// Add any messages
345-
if($vbox && count($vbox->messages)) {
348+
if($vbox && isset($vbox->messages)?count($vbox->messages):false) {
346349
foreach($vbox->messages as $m)
347350
$response['messages'][] = 'vboxconnector('.$request['fn'] .'): ' . $m;
348351
}
@@ -360,7 +363,7 @@
360363
if($e->getCode() == vboxconnector::PHPVB_ERRNO_CONNECT && isset($vbox->settings))
361364
$d .= "\n\nLocation:" . $vbox->settings->location;
362365

363-
$response['messages'][] = htmlentities($e->getMessage()).' ' . htmlentities($details);
366+
$response['messages'][] = htmlentities($e->getMessage()). htmlentities(' '. $details);
364367

365368
$response['errors'][] = array(
366369
'error'=> ($e->getCode() & vboxconnector::PHPVB_ERRNO_HTML ? $e->getMessage() : htmlentities($e->getMessage())),

endpoints/jqueryFileTree.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,14 @@
2222
//
2323

2424
# Turn off PHP notices
25-
error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT & ~E_WARNING);
25+
@error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT & ~E_WARNING);
2626

2727
global $vbox, $localbrowser, $allowed;
2828

2929
require_once(dirname(__FILE__).'/lib/config.php');
3030
require_once(dirname(__FILE__).'/lib/utils.php');
3131
require_once(dirname(__FILE__).'/lib/vboxconnector.php');
3232

33-
error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT & ~E_WARNING);
34-
3533
session_init();
3634
if(!$_SESSION['valid']) return;
3735

@@ -223,6 +221,8 @@ function get_windows_drives() {
223221
*/
224222
function getdir($dir, $dirsOnly=false, $recurse=array()) {
225223

224+
global $allowed_exts;
225+
226226
if(!$dir) $dir = DSEP;
227227

228228
$entries = getDirEntries($dir, $dirsOnly);
@@ -251,9 +251,9 @@ function getdir($dir, $dirsOnly=false, $recurse=array()) {
251251
// Push file on to stack
252252
} else {
253253

254-
$ext = strtolower(preg_replace('/^.*\./', '', $file));
254+
$ext = strtolower(preg_replace('/^.*\./', '', $path));
255255

256-
if(count($allowed) && !$allowed['.'.$ext]) continue;
256+
if(count($allowed_exts) && !$allowed_exts['.'.$ext]) continue;
257257

258258
array_push($dirents, file_entry($path));
259259
}

endpoints/language.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99

1010

11-
error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT);
11+
@error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT);
1212

1313
require_once(dirname(__FILE__).'/lib/language.php');
1414

endpoints/lib/auth/ActiveDirectory.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class phpvbAuthActiveDirectory implements phpvbAuth {
2424
* Constructor
2525
* @param array $userConfig - user configuration for this module
2626
*/
27-
function phpvbAuthActiveDirectory($userConfig = null) {
27+
function __construct($userConfig = null) {
2828
// Merge user config
2929
if($userConfig) {
3030
$this->config = array_merge($this->config,$userConfig);
@@ -101,7 +101,7 @@ function login($username, $password)
101101
$this->config['container'] . ',DC=' . join(',DC=', explode('.', $this->config['domain'])),
102102
$filter, array("memberof","useraccountcontrol"));
103103

104-
if(!result) throw new Exception ("Unable to search Active Directory server: " . ldap_error($auth));
104+
if(!$result) throw new Exception ("Unable to search Active Directory server: " . ldap_error($auth));
105105
@list($entries) = @ldap_get_entries($auth, $result);
106106
@ldap_unbind($auth);
107107
if(!$entries) {

endpoints/lib/auth/LDAP.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class phpvbAuthLDAP implements phpvbAuth {
1818
'adminUser' => ''
1919
);
2020

21-
function phpvbAuthLDAP($userConfig = null) {
21+
function __construct($userConfig = null) {
2222
if($userConfig) $this->config = array_merge($this->config,$userConfig);
2323
}
2424

@@ -44,7 +44,7 @@ function login($username, $password)
4444

4545
} else if(strtolower(substr(PHP_OS, 0, 5)) == 'Linux') {
4646

47-
$ex .= ' You probably need to install the php5-ldap (or similar depending on your distribution) package.';
47+
$ex .= ' You probably need to install the php-ldap (or similar depending on your distribution) package.';
4848

4949
}
5050
throw new Exception($ex);

0 commit comments

Comments
 (0)