mirror of
https://github.com/dockur/windows.git
synced 2026-08-24 07:39:00 +01:00
feat: Import driver certificate on Windows 2003 (#2169)
This commit is contained in:
+14
-3
@@ -304,9 +304,12 @@ addDisplayDriver() {
|
|||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
local files="qbochs.inf qbochs.sys"
|
||||||
|
[[ "$driver" == "2k3" ]] && files+=" qbochs.cat qbochs.cer"
|
||||||
|
|
||||||
local file
|
local file
|
||||||
|
|
||||||
for file in qbochs.inf qbochs.sys; do
|
for file in $files; do
|
||||||
|
|
||||||
if [ ! -f "$source/$file" ]; then
|
if [ ! -f "$source/$file" ]; then
|
||||||
error "Failed to locate required QBochs display driver file: $file"
|
error "Failed to locate required QBochs display driver file: $file"
|
||||||
@@ -316,8 +319,10 @@ addDisplayDriver() {
|
|||||||
done
|
done
|
||||||
|
|
||||||
mkdir -p "$destination" || return 1
|
mkdir -p "$destination" || return 1
|
||||||
cp -L "$source/qbochs.inf" "$destination/qbochs.inf" || return 1
|
|
||||||
cp -L "$source/qbochs.sys" "$destination/qbochs.sys" || return 1
|
for file in $files; do
|
||||||
|
cp -L "$source/$file" "$destination/$file" || return 1
|
||||||
|
done
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
@@ -641,6 +646,12 @@ writeSIF() {
|
|||||||
" AdminPassword=\"$sifPassword\"" \
|
" AdminPassword=\"$sifPassword\"" \
|
||||||
" TimeZone=$timezone"
|
" TimeZone=$timezone"
|
||||||
|
|
||||||
|
if [[ "$driver" == "2k3" ]]; then
|
||||||
|
printf '%s\n' \
|
||||||
|
' DetachedProgram="%SystemRoot%\System32\cmd.exe"' \
|
||||||
|
' Arguments="/Q /C certutil.exe -f -addstore Root C:\Drivers\QBochs\qbochs.cer && certutil.exe -f -addstore TrustedPublisher C:\Drivers\QBochs\qbochs.cer"'
|
||||||
|
fi
|
||||||
|
|
||||||
if disabled "$AUTOLOGIN"; then
|
if disabled "$AUTOLOGIN"; then
|
||||||
printf '%s\n' \
|
printf '%s\n' \
|
||||||
' AutoLogon=No'
|
' AutoLogon=No'
|
||||||
|
|||||||
Reference in New Issue
Block a user