mirror of
https://github.com/PowerShell/openssh-portable.git
synced 2025-07-30 09:14:59 +02:00
add libcrypto-41.dll in payload (#169)
This commit is contained in:
parent
067a352c81
commit
b323223b1f
@ -303,7 +303,8 @@ function Package-OpenSSH
|
|||||||
if($NativeHostArch -ieq 'x86')
|
if($NativeHostArch -ieq 'x86')
|
||||||
{
|
{
|
||||||
$folderName = "Win32"
|
$folderName = "Win32"
|
||||||
}
|
}
|
||||||
|
|
||||||
$buildDir = Join-Path $repositoryRoot ("bin\" + $folderName + "\" + $Configuration)
|
$buildDir = Join-Path $repositoryRoot ("bin\" + $folderName + "\" + $Configuration)
|
||||||
$payload = "sshd.exe", "ssh.exe", "ssh-agent.exe", "ssh-add.exe", "sftp.exe"
|
$payload = "sshd.exe", "ssh.exe", "ssh-agent.exe", "ssh-add.exe", "sftp.exe"
|
||||||
$payload += "sftp-server.exe", "scp.exe", "ssh-shellhost.exe", "ssh-keygen.exe", "ssh-keyscan.exe"
|
$payload += "sftp-server.exe", "scp.exe", "ssh-shellhost.exe", "ssh-keygen.exe", "ssh-keyscan.exe"
|
||||||
@ -311,7 +312,7 @@ function Package-OpenSSH
|
|||||||
$payload +="FixHostFilePermissions.ps1", "FixUserFilePermissions.ps1", "OpenSSHUtils.psm1", "OpenSSHUtils.psd1", "ssh-add-hostkey.ps1"
|
$payload +="FixHostFilePermissions.ps1", "FixUserFilePermissions.ps1", "OpenSSHUtils.psm1", "OpenSSHUtils.psd1", "ssh-add-hostkey.ps1"
|
||||||
|
|
||||||
$packageName = "OpenSSH-Win64"
|
$packageName = "OpenSSH-Win64"
|
||||||
if ($NativeHostArch -eq 'x86') {
|
if ($NativeHostArch -ieq 'x86') {
|
||||||
$packageName = "OpenSSH-Win32"
|
$packageName = "OpenSSH-Win32"
|
||||||
}
|
}
|
||||||
while((($service = Get-Service ssh-agent -ErrorAction Ignore) -ne $null) -and ($service.Status -ine 'Stopped'))
|
while((($service = Get-Service ssh-agent -ErrorAction Ignore) -ne $null) -and ($service.Status -ine 'Stopped'))
|
||||||
@ -344,6 +345,10 @@ function Package-OpenSSH
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#copy libcrypto-41 dll
|
||||||
|
$libreSSLSDKPath = Join-Path $PSScriptRoot $script:libreSSLSDKStr
|
||||||
|
Copy-Item -Path $(Join-Path $libreSSLSDKPath "$NativeHostArch\libcrypto-41.dll") -Destination $packageDir -Force -ErrorAction Stop
|
||||||
|
|
||||||
if ($DestinationPath -ne "") {
|
if ($DestinationPath -ne "") {
|
||||||
if (Test-Path $DestinationPath) {
|
if (Test-Path $DestinationPath) {
|
||||||
Remove-Item $DestinationPath\* -Force -Recurse -ErrorAction SilentlyContinue
|
Remove-Item $DestinationPath\* -Force -Recurse -ErrorAction SilentlyContinue
|
||||||
@ -535,17 +540,6 @@ function Install-OpenSSH
|
|||||||
|
|
||||||
Set-Service sshd -StartupType Automatic
|
Set-Service sshd -StartupType Automatic
|
||||||
Set-Service ssh-agent -StartupType Automatic
|
Set-Service ssh-agent -StartupType Automatic
|
||||||
|
|
||||||
#copy libcrypto-41 dll
|
|
||||||
$libreSSLSDKPath = Join-Path $PSScriptRoot $script:libreSSLSDKStr
|
|
||||||
if( $NativeHostArch -ieq "x86" )
|
|
||||||
{
|
|
||||||
Copy-Item -Path $(Join-Path $libreSSLSDKPath "x86\libcrypto-41.dll") -Destination $OpenSSHDir -Force -ErrorAction Stop
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
Copy-Item -Path $(Join-Path $libreSSLSDKPath "x64\libcrypto-41.dll") -Destination $OpenSSHDir -Force -ErrorAction Stop
|
|
||||||
}
|
|
||||||
|
|
||||||
Pop-Location
|
Pop-Location
|
||||||
Write-Log -Message "OpenSSH installed!"
|
Write-Log -Message "OpenSSH installed!"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user