mirror of
https://gitee.com/gfdgd-xi/deep-wine-runner
synced 2025-12-14 19:12:04 +08:00
完善虚拟机连接
This commit is contained in:
17
VM/novnc/utils/b64-to-binary.pl
Executable file
17
VM/novnc/utils/b64-to-binary.pl
Executable file
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env perl
|
||||
use MIME::Base64;
|
||||
|
||||
for (<>) {
|
||||
unless (/^'([{}])(\d+)\1(.+?)',$/) {
|
||||
print;
|
||||
next;
|
||||
}
|
||||
|
||||
my ($dir, $amt, $b64) = ($1, $2, $3);
|
||||
|
||||
my $decoded = MIME::Base64::decode($b64) or die "Could not base64-decode line `$_`";
|
||||
|
||||
my $decoded_escaped = join "", map { "\\x$_" } unpack("(H2)*", $decoded);
|
||||
|
||||
print "'${dir}${amt}${dir}${decoded_escaped}',\n";
|
||||
}
|
||||
Reference in New Issue
Block a user