that holds the close button/link. No styling is required, but you'll likely want some. */
32 | #tipped-closer-wrapper {
33 | display:none;
34 | text-align:center;
35 | margin: 0px;
36 | }
37 |
38 | /* The that is the close button/link. No styling is required, but you'll likely want some. */
39 | #tipped-closer {
40 | display:none;
41 | border:2px outset #999;
42 | background-color:#CCC;
43 | }
44 |
--------------------------------------------------------------------------------
/docker-compose.yml:
--------------------------------------------------------------------------------
1 | # Develop phpvirtualbox in docker
2 | #
3 | # 1) Get virtualbox host-only interface IP used by docker machine:
4 | # docker-machine inspect default -f '{{.Driver.HostOnlyCIDR}}' | sed -e 's#/.*##'
5 | # 2) Start vboxwebsrv on the IP returned from the above command:
6 | # vboxwebsrv -H 192.168.99.1 # or edit vboxwebsrv startup config
7 | # 3) Edit config.php to use the IP
8 | # 4) docker-compose up
9 | # 5) Get docker machine ip:
10 | # docker-machine ip default
11 | # 6) phpVirtualBox should be available at http://
12 | #
13 | phpvirtualbox:
14 | build: .
15 | ports:
16 | - "80:80"
17 | volumes:
18 | - .:/var/www/html
--------------------------------------------------------------------------------
/endpoints/config.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Endpoint configuration for phpVirtualBox
3 | */
4 | var vboxEndpointConfig = {
5 | api: 'endpoints/api.php',
6 | screen: 'endpoints/screen.php',
7 | rdpGen: 'endpoints/rdp.php',
8 | filebrowser: 'endpoints/jqueryFileTree.php',
9 | require: ['endpoints/language.php']
10 | }
--------------------------------------------------------------------------------
/endpoints/index.html:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/trasherdk/phpvirtualbox/294145c3c21ad07fbd275688b774fbc9fcfcb53e/endpoints/index.html
--------------------------------------------------------------------------------
/endpoints/language.php:
--------------------------------------------------------------------------------
1 |
38 |
39 |
40 | // Failsafe wrapper
41 | function trans(s,c,n,h) {
42 |
43 | if(s && c && c.constructor === Array) {
44 | o = c.shift();
45 | n = c.shift();
46 | h = c.shift();
47 | c = o;
48 | }
49 | if(!c) c = 'VBoxGlobal';
50 |
51 | var r = transreal(s,c,n,h);
52 |
53 | if(typeof r != 'string') {
54 | // console.log('Could not translate ' + s + ' with ' + c);
55 | return s;
56 | }
57 |
58 | return r;
59 | }
60 |
61 | function transreal(w,context,number,comment) {
62 |
63 | try {
64 |
65 | if(__vboxLangData['contexts'][context]['messages'][w]['translation']) {
66 |
67 | if(__vboxLangData['contexts'][context]['messages'][w]['translation']['numerusform']) {
68 |
69 | var t = __vboxLangData['contexts'][context]['messages'][w]['translation']['numerusform'];
70 |
71 | if(!number) number = 1;
72 |
73 | if(number <= 1 && t[0]) return t[0];
74 | if(number > 1 && t[1]) return t[1];
75 | if(t[0]) return t[0];
76 | return t[1];
77 | }
78 | /*
79 | if (__vboxLangData['contexts'][context]['messages'][w] && __vboxLangData['contexts'][context]['messages'][w]['translation_attr'] && __vboxLangData['contexts'][context]['messages'][w]['translation_attr']['type'] == 'obsolete') {
80 | console.log(w + ' in ' + context + ' is obsolete');
81 | }
82 | */
83 | return __vboxLangData['contexts'][context]['messages'][w]['translation'];
84 |
85 | } else if(__vboxLangData['contexts'][context]['messages'][w][0]) {
86 |
87 | if(comment) {
88 | for(var i in __vboxLangData['contexts'][context]['messages'][w]) {
89 | if(__vboxLangData['contexts'][context]['messages'][w][i]['comment'] == comment) {
90 | /*
91 | if (__vboxLangData['contexts'][context]['messages'][w][i]['translation_attr'] && __vboxLangData['contexts'][context]['messages'][w][i]['translation_attr']['type'] == 'obsolete') {
92 | console.log(w + ' ' + ' and ' + comment + ' is obsolete');
93 | }
94 | */
95 |
96 | return __vboxLangData['contexts'][context]['messages'][w][i]['translation'];
97 | }
98 | }
99 | }
100 | /*
101 | if (__vboxLangData['contexts'][context]['messages'][w][0] && __vboxLangData['contexts'][context]['messages'][w][0]['translation_attr'] && __vboxLangData['contexts'][context]['messages'][w][0]['translation_attr']['type'] == 'obsolete') {
102 | console.log(w + ' in ' + context + ' is obsolete');
103 | }
104 | */
105 |
106 | return __vboxLangData['contexts'][context]['messages'][w][0]['translation'];
107 |
108 | } else {
109 | return w;
110 | }
111 |
112 | } catch(err) {
113 | // console.log(w + ' - ' + context + ': ' + err);
114 | return w;
115 | }
116 | }
117 |
118 |
--------------------------------------------------------------------------------
/endpoints/lib/auth/LDAP.php:
--------------------------------------------------------------------------------
1 | false,
12 | 'canLogout' => true
13 | );
14 |
15 | var $config = array(
16 | 'host' => '127.0.0.1', // LDAP server ip
17 | 'bind_dn' => 'uid=%s, ou=admins, dc=internal, dc=local', // %s will be replaced with login username
18 | 'adminUser' => ''
19 | );
20 |
21 | function phpvbAuthLDAP($userConfig = null) {
22 | if($userConfig) $this->config = array_merge($this->config,$userConfig);
23 | }
24 |
25 | function login($username, $password)
26 | {
27 | global $_SESSION;
28 |
29 | // Check for LDAP functions
30 | if(!function_exists('ldap_connect')) {
31 |
32 | $ex = 'LDAP support is not enabled in your PHP configuration.';
33 |
34 | if(strtolower(substr(PHP_OS, 0, 3)) == 'win') {
35 |
36 | ob_start();
37 | phpinfo(INFO_GENERAL);
38 | $phpinfo = ob_get_contents();
39 | ob_end_clean();
40 | preg_match('/Loaded Configuration File <\/td>(.*?)\s*', $phpinfo, $phpinfo);
41 |
42 | $ex .= ' You probably just need to uncomment the line ;extension=php_ldap.dll in php.ini'.
43 | (count($phpinfo) > 1 ? ' (' .trim($phpinfo[1]).')' : '') . ' by removing the ";" and restart your web server.';
44 |
45 | } else if(strtolower(substr(PHP_OS, 0, 5)) == 'Linux') {
46 |
47 | $ex .= ' You probably need to install the php5-ldap (or similar depending on your distribution) package.';
48 |
49 | }
50 | throw new Exception($ex);
51 | }
52 |
53 | $auth = ldap_connect($this->config['host']);
54 |
55 | if(!$auth) return false;
56 |
57 | ldap_set_option($auth,LDAP_OPT_PROTOCOL_VERSION, 3);
58 |
59 | if(!@ldap_bind($auth, sprintf($this->config['bind_dn'], $username), $password))
60 | return false;
61 |
62 |
63 | $_SESSION['valid'] = true;
64 | $_SESSION['user'] = $username;
65 | $_SESSION['admin'] = (!$this->config['adminUser']) || ($_SESSION['user'] == $this->config['adminUser']);
66 | $_SESSION['authCheckHeartbeat'] = time();
67 |
68 | }
69 |
70 |
71 | function heartbeat($vbox)
72 | {
73 | global $_SESSION;
74 |
75 | $_SESSION['valid'] = true;
76 | $_SESSION['authCheckHeartbeat'] = time();
77 | }
78 |
79 | function changePassword($old, $new)
80 | {
81 | }
82 |
83 | function logout(&$response)
84 | {
85 | global $_SESSION;
86 | if(function_exists('session_destroy')) session_destroy();
87 | else unset($_SESSION['valid']);
88 | $response['data']['result'] = 1;
89 | }
90 |
91 | function listUsers()
92 | {
93 |
94 | }
95 |
96 | function updateUser($vboxRequest, $skipExistCheck)
97 | {
98 |
99 | }
100 |
101 | function deleteUser($user)
102 | {
103 |
104 | }
105 | }
106 |
--------------------------------------------------------------------------------
/endpoints/lib/auth/OpenMediaVault.php:
--------------------------------------------------------------------------------
1 | getCode().": ". str_replace("\n", " ",$e->__toString()));
22 | }
23 |
24 | class phpvbAuthOpenMediaVault implements phpvbAuth {
25 |
26 | static $session = null;
27 |
28 | var $capabilities = array(
29 | 'canChangePassword' => false,
30 | 'sessionStart' => 'sessionStart',
31 | 'canLogout' => true
32 | );
33 |
34 | var $config = array(
35 | 'allowNonAdmin' => false
36 | );
37 |
38 | function __construct($userConfig = null) {
39 | if($userConfig) $this->config = array_merge($this->config,$userConfig);
40 | }
41 |
42 | function login($username, $password)
43 | {
44 | # Try / catch so that we don't expose
45 | # usernames / passwords
46 | require_once("rpc/authentication.inc");
47 | $a = new AuthenticationRpc();
48 | try {
49 |
50 | $auth = $a->login(array('username'=>$username,'password'=>$password));
51 |
52 | self::$session = &OMVSession::getInstance();
53 |
54 | if(@$auth["authenticated"] &&
55 | (self::$session->getRole() !== OMV_ROLE_USER || $this->config['allowNonAdmin'])) {
56 | $_SESSION['admin'] = (self::$session->getRole() !== OMV_ROLE_USER);
57 | $_SESSION['user'] = $_SESSION['username'];
58 | $_SESSION['valid'] = ($_SESSION['admin'] || $this->config['allowNonAdmin']);
59 | $_SESSION['authCheckHeartbeat'] = time();
60 |
61 | }
62 |
63 | if(!@$_SESSION['valid']) {
64 | return false;
65 | }
66 | return true;
67 |
68 | } catch (Exception $e) {
69 | return false;
70 | }
71 | return false;
72 | }
73 |
74 | function sessionStart($keepopen) {
75 |
76 | self::$session = &OMVSession::getInstance();
77 | self::$session->start();
78 |
79 |
80 | if (self::$session->isAuthenticated() && !self::$session->isTimeout()) {
81 |
82 | self::$session->validate();
83 | self::$session->updateLastAccess();
84 |
85 | $_SESSION['admin'] = (self::$session->getRole() !== OMV_ROLE_USER);
86 | $_SESSION['user'] = $_SESSION['username'];
87 | $_SESSION['valid'] = (self::$session->getRole() !== OMV_ROLE_USER || $this->config['allowNonAdmin']);
88 |
89 | } else {
90 |
91 | $_SESSION['admin'] = $_SESSION['user'] = $_SESSION['valid'] = null;
92 |
93 | }
94 |
95 | if(!$keepopen)
96 | session_write_close();
97 |
98 | }
99 |
100 |
101 | function logout(&$response)
102 | {
103 | require_once("rpc/authentication.inc");
104 | $a = new AuthenticationRpc();
105 | $a->logout();
106 | $response['data']['result'] = 1;
107 | }
108 |
109 | /* Defined for compatibility with implemented interface */
110 | function heartbeat($vbox){}
111 | function changePassword($old, $new){}
112 | function listUsers(){}
113 | function updateUser($vboxRequest, $skipExistCheck){}
114 | function deleteUser($user){}
115 | }
116 |
--------------------------------------------------------------------------------
/endpoints/lib/auth/WebAuth.php:
--------------------------------------------------------------------------------
1 | false,
10 | 'canLogout' => false
11 | );
12 |
13 | var $config = array(
14 | 'serverUserKey' => 'REMOTE_USER'
15 | );
16 |
17 | function phpvbAuthWebAuth($userConfig = null) {
18 | if($userConfig) $this->config = array_merge($this->config,$userConfig);
19 | }
20 |
21 | function login($username, $password)
22 | {
23 | }
24 |
25 | function autoLoginHook()
26 | {
27 | global $_SESSION;
28 | // WebAuth passthrough
29 | if ( isset($_SERVER[$this->config['serverUserKey']]) )
30 | {
31 | $_SESSION['valid'] = true;
32 | $_SESSION['user'] = $_SERVER[$this->config['serverUserKey']];
33 | $_SESSION['admin'] = (!$this->config['adminUser']) || ($_SESSION['user'] == $this->config['adminUser']);
34 | $_SESSION['authCheckHeartbeat'] = time();
35 | }
36 | }
37 |
38 | function heartbeat($vbox)
39 | {
40 | global $_SESSION;
41 | if ( isset($_SERVER[$this->config['serverUserKey']]) )
42 | {
43 | $_SESSION['valid'] = true;
44 | $_SESSION['authCheckHeartbeat'] = time();
45 | }
46 | }
47 |
48 | function changePassword($old, $new)
49 | {
50 | }
51 |
52 | function logout(&$response)
53 | {
54 | $response['data']['result'] = 1;
55 | if ( isset($this->config['logoutURL']) )
56 | {
57 | $response['data']['url'] = $this->config['logoutURL'];
58 | }
59 | }
60 |
61 | function listUsers()
62 | {
63 |
64 | }
65 |
66 | function updateUser($vboxRequest, $skipExistCheck)
67 | {
68 |
69 | }
70 |
71 | function deleteUser($user)
72 | {
73 |
74 | }
75 | }
76 |
--------------------------------------------------------------------------------
/endpoints/lib/auth/index.html:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/trasherdk/phpvirtualbox/294145c3c21ad07fbd275688b774fbc9fcfcb53e/endpoints/lib/auth/index.html
--------------------------------------------------------------------------------
/endpoints/lib/authinterface.php:
--------------------------------------------------------------------------------
1 | true,
21 | * 'canModifyUsers' => true,
22 | * 'canLogout' => true
23 | * );
24 | *
25 | * The implementing class may also define a public autoLoginHook
26 | * method that auto-populates $_SESSION. This would automatically
27 | * log the user in, bypassing the login() function.
28 | *
29 | * E.g.
30 | *
31 | * function autoLoginHook()
32 | * {
33 | * global $_SESSION;
34 | *
35 | * // HTTP Authentication passthrough
36 | * if ( isset($_SERVER['HTTP_X_WEBAUTH_USER']) )
37 | * {
38 | * $_SESSION['valid'] = true;
39 | * $_SESSION['user'] = $_SERVER['HTTP_X_WEBAUTH_USER']];
40 | * $_SESSION['admin'] = ($_SESSION['user'] === 'bob');
41 | * $_SESSION['authCheckHeartbeat'] = time();
42 | * }
43 | * }
44 | *
45 | * Implementing classes should be prefixed with phpvbAuth. E.g.
46 | * phpvbAuthMySiteAuth. authLib in config.php would then be set
47 | * to 'MySiteAuth'
48 | */
49 | interface phpvbAuth {
50 |
51 | /**
52 | *
53 | * Log in function. Populates $_SESSION
54 | * @param string $username user name
55 | * @param string $password password
56 | */
57 | function login($username, $password);
58 |
59 | /**
60 | *
61 | * Change password function.
62 | * @param string $old old password
63 | * @param string $new new password
64 | * @return boolean true on success
65 | */
66 | function changePassword($old, $new);
67 |
68 | /**
69 | *
70 | * Revalidate login info and set authCheckHeartbeat session variable.
71 | * @param vboxconnector $vbox vboxconnector object instance
72 | */
73 | function heartbeat($vbox);
74 |
75 | /**
76 | *
77 | * Log out user present in $_SESSION
78 | * @param array $response response passed byref by API and populated within function
79 | */
80 | function logout(&$response);
81 |
82 | /**
83 | *
84 | * Return a list of users
85 | * @return array list of users
86 | */
87 | function listUsers();
88 |
89 | /**
90 | *
91 | * Update user information such as password and admin status
92 | * @param array $vboxRequest request passed from API representing the ajax request. Contains user, password and administration level.
93 | * @param boolean $skipExistCheck Do not check that the user exists first. Essentially, if this is set and the user does not exist, it is added.
94 | */
95 | function updateUser($vboxRequest, $skipExistCheck);
96 |
97 |
98 | /**
99 | *
100 | * Remove the user $user
101 | * @param string $user Username to remove
102 | */
103 | function deleteUser($user);
104 |
105 |
106 |
107 | }
--------------------------------------------------------------------------------
/endpoints/lib/index.html:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/trasherdk/phpvirtualbox/294145c3c21ad07fbd275688b774fbc9fcfcb53e/endpoints/lib/index.html
--------------------------------------------------------------------------------
/endpoints/lib/utils.php:
--------------------------------------------------------------------------------
1 | auth->capabilities['sessionStart']) {
27 | call_user_func(array($settings->auth, $settings->auth->capabilities['sessionStart']), $keepopen);
28 | return;
29 | }
30 |
31 | // No session support? No login...
32 | if(@$settings->noAuth || !function_exists('session_start')) {
33 | global $_SESSION;
34 | $_SESSION['valid'] = true;
35 | $_SESSION['authCheckHeartbeat'] = time();
36 | $_SESSION['admin'] = true;
37 | return;
38 | }
39 |
40 | // Session not is auto-started by PHP
41 | if(!ini_get('session.auto_start')) {
42 |
43 | ini_set('session.use_trans_sid', 0);
44 | ini_set('session.use_only_cookies', 1);
45 |
46 | // Session path
47 | if(isset($settings->sessionSavePath)) {
48 | session_save_path($settings->sessionSavePath);
49 | }
50 |
51 | if(isset($settings->session_name)) {
52 | $session_name = $settings->session_name;
53 | } else {
54 | $session_name = md5($_SERVER['DOCUMENT_ROOT'].$_SERVER['HTTP_USER_AGENT'].dirname(__FILE__));
55 | }
56 | session_name($session_name);
57 | session_start();
58 | }
59 |
60 | if(!$keepopen)
61 | session_write_close();
62 |
63 | }
64 |
65 |
66 | /**
67 | * Clean (strip slashes from if applicable) $_GET and $_POST and return
68 | * an array containing a merged array of both.
69 | * @return array
70 | */
71 | function clean_request() {
72 |
73 | if($_SERVER['HTTP_X_REQUESTED_WITH'] == 'XMLHttpRequest') {
74 | $json = json_decode(file_get_contents('php://input'), true);
75 | if(!is_array($json))
76 | $json = array();
77 | } else {
78 | $json = array();
79 | }
80 | $req = array_merge_recursive($_GET, $_POST);
81 | return array_merge_recursive($req, $json);
82 |
83 | }
84 |
85 | if(!function_exists('hash')) {
86 | // Lower security, but better than nothing
87 | /**
88 | * Return a hash of the passed string. Mimmics PHP's hash() params
89 | * @param unused $type
90 | * @param string $str string to hash
91 | */
92 | function hash($type,$str='') {
93 | return sha1(json_encode($str));
94 | }
95 | }
--------------------------------------------------------------------------------
/endpoints/lib/vboxwebService-5.2.wsdl:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/endpoints/lib/vboxwebService-6.0.wsdl:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/endpoints/lib/vboxwebService-6.1.wsdl:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/endpoints/rdp.php:
--------------------------------------------------------------------------------
1 | =1.3?0:1};k.window=function(a){return d(window)._scrollable()};d.fn._scrollable=function(){return this.map(function(){var a=this,i=!a.nodeName||d.inArray(a.nodeName.toLowerCase(),['iframe','#document','html','body'])!=-1;if(!i)return a;var e=(a.contentWindow||a).document||a.ownerDocument||a;return d.browser.safari||e.compatMode=='BackCompat'?e.body:e.documentElement})};d.fn.scrollTo=function(n,j,b){if(typeof j=='object'){b=j;j=0}if(typeof b=='function')b={onAfter:b};if(n=='max')n=9e9;b=d.extend({},k.defaults,b);j=j||b.speed||b.duration;b.queue=b.queue&&b.axis.length>1;if(b.queue)j/=2;b.offset=p(b.offset);b.over=p(b.over);return this._scrollable().each(function(){var q=this,r=d(q),f=n,s,g={},u=r.is('html,body');switch(typeof f){case'number':case'string':if(/^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(f)){f=p(f);break}f=d(f,this);case'object':if(f.is||f.style)s=(f=d(f)).offset()}d.each(b.axis.split(''),function(a,i){var e=i=='x'?'Left':'Top',h=e.toLowerCase(),c='scroll'+e,l=q[c],m=k.max(q,i);if(s){g[c]=s[h]+(u?0:l-r.offset()[h]);if(b.margin){g[c]-=parseInt(f.css('margin'+e))||0;g[c]-=parseInt(f.css('border'+e+'Width'))||0}g[c]+=b.offset[h]||0;if(b.over[h])g[c]+=f[i=='x'?'width':'height']()*b.over[h]}else{var o=f[h];g[c]=o.slice&&o.slice(-1)=='%'?parseFloat(o)/100*m:o}if(/^\d+$/.test(g[c]))g[c]=g[c]<=0?0:Math.min(g[c],m);if(!a&&b.queue){if(l!=g[c])t(b.onAfterFirst);delete g[c]}});t(b.onAfter);function t(a){r.animate(g,j,b.easing,a&&function(){a.call(this,n,b)})}}).end()};k.max=function(a,i){var e=i=='x'?'Width':'Height',h='scroll'+e;if(!d(a).is('html,body'))return a[h]-d(a)[e.toLowerCase()]();var c='client'+e,l=a.ownerDocument.documentElement,m=a.ownerDocument.body;return Math.max(l[h],m[h])-Math.min(l[c],m[c])};function p(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery);
--------------------------------------------------------------------------------
/languages/en.xml:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/languages/source/en.dat:
--------------------------------------------------------------------------------
1 | a:1:{s:8:"contexts";a:4:{s:19:"UIGChooserItemGroup";a:1:{s:8:"messages";a:3:{s:13:"%n machine(s)";a:1:{s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:10:"%n machine";i:1;s:11:"%n machines";}}}s:11:"%n group(s)";a:1:{s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:8:"%n group";i:1;s:9:"%n groups";}}}s:0:"";a:2:{s:7:"numerus";s:3:"yes";s:11:"translation";s:0:"";}}}s:10:"VBoxGlobal";a:1:{s:8:"messages";a:7:{s:11:"%n month(s)";a:1:{s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:8:"%n month";i:1;s:9:"%n months";}}}s:9:"%n day(s)";a:1:{s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:6:"%n day";i:1;s:7:"%n days";}}}s:0:"";a:2:{s:7:"numerus";s:3:"yes";s:11:"translation";s:0:"";}s:12:"%n minute(s)";a:1:{s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:9:"%n minute";i:1;s:10:"%n minutes";}}}s:12:"%n second(s)";a:1:{s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:9:"%n second";i:1;s:10:"%n seconds";}}}s:10:"%n hour(s)";a:1:{s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:7:"%n hour";i:1;s:8:"%n hours";}}}s:10:"%n year(s)";a:1:{s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:7:"%n year";i:1;s:8:"%n years";}}}}}s:19:"VBoxTakeSnapshotDlg";a:1:{s:8:"messages";a:1:{s:213:"Warning: You are taking a snapshot of a running machine which has %n immutable image(s) attached to it. As long as you are working from this snapshot the immutable image(s) will not be reset to avoid loss of data.";a:1:{s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:207:"Warning: You are taking a snapshot of a running machine which has %n immutable image attached to it. As long as you are working from this snapshot the immutable image will not be reset to avoid loss of data.";i:1;s:209:"Warning: You are taking a snapshot of a running machine which has %n immutable images attached to it. As long as you are working from this snapshot the immutable images will not be reset to avoid loss of data.";}}}}}s:15:"UIMessageCenter";a:1:{s:8:"messages";a:1:{s:212:"
The %n following virtual machine(s) are currently in a saved state: %1
If you continue the runtime state of the exported machine(s) will be discarded. The other machine(s) will not be changed.
";a:2:{s:7:"comment";s:221:"This text is never used with n == 0. Feel free to drop the %n where possible, we only included it because of problems with Qt Linguist (but the user can see how many machines are in the list and doesn't need to be told).";s:11:"translation";a:1:{s:11:"numerusform";a:2:{i:0;s:197:"
The virtual machine %1 is currently in a saved state.
If you continue the runtime state of the exported machine will be discarded. Note that the existing machine is not changed.
";i:1;s:202:"
The virtual machines %1 are currently in a saved state.
If you continue the runtime state of the exported machines will be discarded. Note that the existing machines are not changed.
11 |
12 | <p>Please select a virtual optical disk file or a physical optical drive containing a disk to start your new virtual machine from.</p><p>The disk should be suitable for starting a computer from and should contain the operating system you wish to install on the virtual machine if you want to do that now. The disk will be ejected from the virtual drive automatically next time you switch the virtual machine off, but you can also do this yourself if needed using the Devices menu.</p>
13 | <p>Please select a virtual optical disk file or a physical optical drive containing a disk to start your new virtual machine from.</p><p>The disk should be suitable for starting a computer from. As this virtual machine has no hard drive you will not be able to install an operating system on it at the moment.</p>
14 |
15 |
16 |
17 |
19 |
20 |
21 |
22 |
23 |
24 |
79 |
--------------------------------------------------------------------------------
/phpvirtualbox.conf:
--------------------------------------------------------------------------------
1 | Alias /phpvirtualbox /usr/share/phpvirtualbox
2 |
3 |
4 |
5 |
6 | DirectoryIndex index.html index.php
7 |
8 | AllowOverride None
9 |
10 | # Only allow connections from localhost:
11 | Require local
12 |
13 |
14 | php_flag magic_quotes_gpc Off
15 | php_flag track_vars On
16 | #php_value include_path .
17 |
18 |
19 |
20 |
21 | AddType application/x-httpd-php .php
22 | Action application/x-httpd-php /cgi-bin/php
23 |
24 |
25 | AddType application/x-httpd-php .php
26 | Action application/x-httpd-php /cgi-bin/php
27 |
28 |
29 |
30 |
31 |
32 |
--------------------------------------------------------------------------------
/rdpweb/RDPClientUI.swf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/trasherdk/phpvirtualbox/294145c3c21ad07fbd275688b774fbc9fcfcb53e/rdpweb/RDPClientUI.swf
--------------------------------------------------------------------------------
/rdpweb/license_3rd.txt:
--------------------------------------------------------------------------------
1 | 3rd party components used by the RDP Web Control:
2 |
3 |
4 | 1) RDP Web Control contains SWFObject library
5 | which is released under the MIT License
6 |
7 |
8 | 2) RDP Web Control contains code from as3crypto library which is
9 | covered under the following copyright:
10 |
11 | /*
12 | * Copyright (c) 2007 Henri Torgemane
13 | * All Rights Reserved.
14 | *
15 | * BigInteger, RSA, Random and ARC4 are derivative works of the jsbn library
16 | * (http://www-cs-students.stanford.edu/~tjw/jsbn/)
17 | * The jsbn library is Copyright (c) 2003-2005 Tom Wu (tjw@cs.Stanford.EDU)
18 | *
19 | * MD5, SHA1, and SHA256 are derivative works (http://pajhome.org.uk/crypt/md5/)
20 | * Those are Copyright (c) 1998-2002 Paul Johnston & Contributors (paj@pajhome.org.uk)
21 | *
22 | * SHA256 is a derivative work of jsSHA2 (http://anmar.eu.org/projects/jssha2/)
23 | * jsSHA2 is Copyright (c) 2003-2004 Angel Marin (anmar@gmx.net)
24 | *
25 | * AESKey is a derivative work of aestable.c (http://www.geocities.com/malbrain/aestable_c.html)
26 | * aestable.c is Copyright (c) Karl Malbrain (malbrain@yahoo.com)
27 | *
28 | * BlowFishKey, DESKey and TripeDESKey are derivative works of the Bouncy Castle Crypto Package (http://www.bouncycastle.org)
29 | * Those are Copyright (c) 2000-2004 The Legion Of The Bouncy Castle
30 | *
31 | * Base64 is copyright (c) 2006 Steve Webster (http://dynamicflash.com/goodies/base64)
32 | *
33 | * Redistribution and use in source and binary forms, with or without modification,
34 | * are permitted provided that the following conditions are met:
35 | *
36 | * Redistributions of source code must retain the above copyright notice, this list
37 | * of conditions and the following disclaimer. Redistributions in binary form must
38 | * reproduce the above copyright notice, this list of conditions and the following
39 | * disclaimer in the documentation and/or other materials provided with the distribution.
40 | *
41 | * Neither the name of the author nor the names of its contributors may be used to endorse
42 | * or promote products derived from this software without specific prior written permission.
43 | *
44 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
45 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
46 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
47 | *
48 | * IN NO EVENT SHALL TOM WU BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
49 | * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
50 | * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
51 | * THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT
52 | * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
53 | *
54 | */
55 |
56 | Address all questions regarding this license to:
57 |
58 | Henri Torgemane
59 | henri_torgemane@yahoo.com
60 |
61 |
62 | Additionally, the MD5 algorithm is covered by the following notice:
63 |
64 | /* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All rights reserved.
65 | *
66 | * License to copy and use this software is granted provided that it
67 | * is identified as the "RSA Data Security, Inc. MD5 Message-Digest
68 | * Algorithm" in all material mentioning or referencing this software
69 | * or this function.
70 | *
71 | * License is also granted to make and use derivative works provided
72 | * that such works are identified as "derived from the RSA Data
73 | * Security, Inc. MD5 Message-Digest Algorithm" in all material
74 | * mentioning or referencing the derived work.
75 | *
76 | * RSA Data Security, Inc. makes no representations concerning either
77 | * the merchantability of this software or the suitability of this
78 | * software for any particular purpose. It is provided "as is"
79 | * without express or implied warranty of any kind.
80 | *
81 | * These notices must be retained in any copies of any part of this
82 | * documentation and/or software.
83 | */
84 |
--------------------------------------------------------------------------------
/recovery.php-disabled:
--------------------------------------------------------------------------------
1 | skipSessionCheck = true;
39 | $vbox->connect();
40 |
41 | $vbox->vbox->setExtraData('phpvb/users/admin/pass', hash('sha512', 'admin'));
42 | $vbox->vbox->setExtraData('phpvb/users/admin/admin', '1');
43 | echo("Admin account updated. Please rename this file to recovery.php-disabled. phpVirtualBox will refuse to run if this has not been done.");
44 |
45 | } catch (Exception $e) {
46 | echo("