PowerShell์ ์ฌ์ฉํ์ฌ Office 365 / Exchange Online์ ์ฐ๊ฒฐํ ์ ์์ต๋๋ค.
๋ถ๋ช
ํ ๋ค๋ฅธ ์ฌ๋๋ค์ ์ต์ ๋ฒ์ ์ ํธ์๋ฅผ ์ฌ์ฉํ ์ ์์ง๋ง pwsh 6.0.0-rc๋ฅผ ์ฌ์ฉํ๋ macOS 10.12 ๋๋ 10.13์์๋ ์๋ํ์ง ์์ต๋๋ค.
New-PSSession์ ๋ง๋๋ ๋์ ์ค๋ฅ๊ฐ ๋ฐ์ํฉ๋๋ค. ์ฌ์ฉ์ค์ธ ๋ช ๋ น์ ์ ํํ ๊ตฌ๋ฌธ์ ๋ฐ๋ผ New-PSSession :์ด ๋งค๊ฐ ๋ณ์ ์งํฉ์๋ WSMan์ด ํ์ํ๋ฉฐ ์ง์๋๋ WSMan ํด๋ผ์ด์ธํธ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๊ฐ ๋ฐ๊ฒฌ๋์ง ์์๊ฑฐ๋ PowerShell์ด โโ์ฒ๋ฆฌ๋์ง ์์ ์์ธ์ ํจ๊ป ์ข ๋ฃ๋๊ณ ํธ๋ฉ 6์ด ์ค๋จ๋ฉ๋๋ค.
macOS 10.12 ๋๋ 10.13์ PowerShell 6.0.0-rc๋ฅผ ์ค์นํฉ๋๋ค.
Get-Credential์ ์ฌ์ฉํ์ฌ Office 365 ๊ด๋ฆฌ์ ์๊ฒฉ ์ฆ๋ช
์ ์ป์ ๋ค์ New-PSSession์ ์ฌ์ฉํ์ฌ ์ ์ธ์
์ ๋ง๋ญ๋๋ค.
[kai<strong i="11">@blackmac</strong> ~]$ pwsh
PowerShell v6.0.0-rc
Copyright (c) Microsoft Corporation. All rights reserved.
https://aka.ms/pscore6-docs
Type 'help' to get help.
PS /Users/kai> $PSVersionTable
Name Value
---- -----
PSVersion 6.0.0-rc
PSEdition Core
GitCommitId v6.0.0-rc
OS Darwin 16.7.0 Darwin Kernel Version 16.7.0: T...
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
PS /Users/kai> $UserCredential = Get-Credential
PowerShell credential request
Enter your credentials.
User: [email protected]
Password for user [email protected]: ***********
PS /usr/local/microsoft> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
New-PSSession : This parameter set requires WSMan, and no supported WSMan client library was found. WSMan is either not installed or unavailable for this system.
At line:1 char:12
+ $Session = New-PSSession -ConfigurationName Microsoft.Exchange -Conne ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ResourceUnavailable: (:) [New-PSSession], PSRemotingTransportException
+ FullyQualifiedErrorId : System.Management.Automation.Remoting.PSRemotingDataStructureException,Microsoft.PowerShell.Commands.NewPSSessionCommand
PS /Users/kai> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid -Credential $UserCredential -Authentication Basic -AllowRedirection
An error has occurred that was not properly handled. Additional information is shown below. The PowerShell process will exit.
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at System.Management.Automation.Remoting.PrioritySendDataCollection.Clear()
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.CloseAsync()
at System.Management.Automation.Remoting.Client.WSManClientSessionTransportManager.CloseAsync()
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.Finalize()
Abort trap: 6
[kai<strong i="12">@blackmac</strong> ~]$
์์ ๋ง์ง๋ง ์ค์ ํ๋กฌํํธ์์ bash ์ ธ๋ก ๋ค์ ๋จ์ด ์ก๋ค๋ ๊ฒ์ ์ ์ ์์ต๋๋ค.
New-PSSession์ด macOS์์ ์๋ ํ ๊ฒ์ผ๋ก ์์๋ฉ๋๋ค.
๋ช
๋ น์ ์ ํํ ๊ตฌ๋ฌธ์ ๋ฐ๋ผ New-PSSession์ ์ค๋ฅ ๋ฉ์์ง๋ฅผ ๋ฐํํฉ๋๋ค.
New-PSSession :์ด ๋งค๊ฐ ๋ณ์ ์ธํธ์๋ WSMan์ด ํ์ํ๋ฉฐ ์ง์๋๋ WSMan ํด๋ผ์ด์ธํธ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฐพ์ ์ ์์ต๋๋ค.
๋๋ New-PSSession์ ์ฒ๋ฆฌ๋์ง ์์ ์์ธ๊ฐ ์๊ณ PowerShell์ด โโ์ค๋จ ํธ๋ฉ 6๊ณผ ํจ๊ป ์ข
๋ฃ๋ฉ๋๋ค.
๊ตฌ๋ฌธ์ ์ฐจ์ด์ ์ ConnectionUri์ ์์ต๋๋ค. uri์ ํํ ์ฌ๋์๊ฐ ์๋์ง ์ฌ๋ถ์ ๊ด๊ณ์์ด ์ฐจ์ด๊ฐ์๋ ๊ฒ ๊ฐ์ต๋๋ค. ํํ ์ฌ๋์๋ก WSMan ๋๋ฝ์ ๋ํ ์ค๋ฅ๊ฐ ๋ฐ์ํฉ๋๋ค. ํํ ์ฌ๋์๊ฐ ์์ผ๋ฉด PowerShell ์ธ์ ์ด ์ค๋จ๋ฉ๋๋ค.
ํํ ์ฌ๋์ ์ฌ์ฉ :
PS /Users/kai> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
New-PSSession : This parameter set requires WSMan, and no supported WSMan client library was found. WSMan is either not installed or unavailable for this system.
At line:1 char:12
+ $Session = New-PSSession -ConfigurationName Microsoft.Exchange -Conne ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ResourceUnavailable: (:) [New-PSSession], PSRemotingTransportException
+ FullyQualifiedErrorId : System.Management.Automation.Remoting.PSRemotingDataStructureException,Microsoft.PowerShell.Commands.NewPSSessionCommand
ํํ ์ฌ๋์ ์์ :
PS /Users/kai> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid -Credential $UserCredential -Authentication Basic -AllowRedirection
An error has occurred that was not properly handled. Additional information is shown below. The PowerShell process will exit.
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at System.Management.Automation.Remoting.PrioritySendDataCollection.Clear()
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.CloseAsync()
at System.Management.Automation.Remoting.Client.WSManClientSessionTransportManager.CloseAsync()
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.Finalize()
Abort trap: 6
PS /Users/kai> $PSVersionTable Name Value
---- -----
PSVersion 6.0.0-rc
PSEdition Core
GitCommitId v6.0.0-rc
OS Darwin 16.7.0 Darwin Kernel Version 16.7.0: Thu Jun 15 17:36:27 PDT ...
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
์ด๊ฒ์ 10.13.1์์ ๋๋ฅผ ์ํด ์ผํ๊ณ ์์ต๋๋ค. $ PSHome์ libpsrpclient.dylib
๊ฐ ์๋์ง ํ์ธํ ์ ์์ต๋๊น?
PowerShell v6.0.0-rc
Copyright (c) Microsoft Corporation. All rights reserved.
https://aka.ms/pscore6-docs
Type 'help' to get help.
PS /Users/kai> cd $PSHome
PS /usr/local/microsoft/powershell/6.0.0-rc> ls -al *.dylib
-rw-r--r-- 1 root wheel 70224 31 Oct 17:27 System.Globalization.Native.dylib
-rw-r--r-- 1 root wheel 13484 31 Oct 17:27 System.IO.Compression.Native.dylib
-rw-r--r-- 1 root wheel 61460 31 Oct 17:27 System.Native.dylib
-rw-r--r-- 1 root wheel 16932 31 Oct 17:27 System.Net.Http.Native.dylib
-rw-r--r-- 1 root wheel 15132 31 Oct 17:27 System.Net.Security.Native.dylib
-rw-r--r-- 1 root wheel 46016 31 Oct 17:27 System.Security.Cryptography.Native.Apple.dylib
-rw-r--r-- 1 root wheel 75708 31 Oct 17:27 System.Security.Cryptography.Native.OpenSsl.dylib
-rw-r--r-- 1 root wheel 2571480 31 Oct 17:27 libclrjit.dylib
-rw-r--r-- 1 root wheel 6894904 31 Oct 17:27 libcoreclr.dylib
-rw-r--r-- 1 root wheel 883740 31 Oct 17:27 libdbgshim.dylib
-rw-r--r-- 1 root wheel 869664 31 Oct 17:27 libhostfxr.dylib
-rw-r--r-- 1 root wheel 1006336 31 Oct 17:27 libhostpolicy.dylib
-rw-r--r-- 1 root wheel 843792 14 Nov 11:37 libmi.dylib
-rw-r--r-- 1 root wheel 3081760 31 Oct 17:27 libmscordaccore.dylib
-rw-r--r-- 1 root wheel 2021168 31 Oct 17:27 libmscordbi.dylib
-rw-r--r-- 1 root wheel 20568 4 Nov 09:08 libpsl-native.dylib
-rw-r--r-- 1 root wheel 224784 15 Nov 07:39 libpsrpclient.dylib
-rw-r--r-- 1 root wheel 553360 31 Oct 17:27 libsos.dylib
PS /usr/local/microsoft/powershell/6.0.0-rc>
@ kai-h ๋น์ ์ ์ฌ๋ฐ๋ฅธ ํ์ผ ํฌ๊ธฐ์ ๊ถํ์ ๊ฐ์ง ์ฌ๋ฐ๋ฅธ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ๊ฐ์ง๊ณ ์์ต๋๋ค. DYLD_LIBRARY_PATH๊ฐ ์ ์๋์ด ์์ต๋๊น? $env:DYLD_LIBRARY_PATH
์ ๊ฒฐ๊ณผ๋ ๋ฌด์์
๋๊น?
์ ์๋์ง ์์์ต๋๋ค.
```ํ์ ์
PowerShell v6.0.0-rc
์ ์๊ถ (c) Microsoft Corporation. ํ๊ถ ์์ .
https://aka.ms/pscore6-docs
๋์์ ๋ฐ์ผ๋ ค๋ฉด 'help'๋ฅผ ์
๋ ฅํ์ญ์์ค.
PS / Users / kai> $ env : DYLD_LIBRARY_PATH
PS / ์ฌ์ฉ์ / kai>
````
[System.Environment]::Is64BitProcess
๋ ๋ฌด์์ ๋ฐํํฉ๋๊น?
PS /Users/kai> [System.Environment]::Is64BitProcess
True
@ kai-h try (pwsh๋ฅผ ์์ํ๊ธฐ ์ ์ ํฐ๋ฏธ๋์์) :
export DYLD_LIBRARY_PATH=/usr/local/microsoft/powershell/6.0.0-rc:${DYLD_LIBRARY_PATH}
pwsh
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
์ด์ ๋ํ ๊ทํ์ ๋๊ธฐ์ ๊ฐ์ฌ๋๋ฆฝ๋๋ค. ๊ทธ๋๋ ์ฌ์ ํ ๊ฐ์ ์ค๋ฅ๊ฐ ๋ฐ์ํฉ๋๋ค.
[kai<strong i="6">@hobbes</strong> ~]$ export DYLD_LIBRARY_PATH=/usr/local/microsoft/powershell/6.0.0-rc:${DYLD_LIBRARY_PATH}
[kai<strong i="7">@hobbes</strong> ~]$ pwsh
PowerShell v6.0.0-rc
Copyright (c) Microsoft Corporation. All rights reserved.
https://aka.ms/pscore6-docs
Type 'help' to get help.
PS /Users/kai> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
PowerShell credential request
Enter your credentials.
User: [email protected]
Password for user [email protected]: ********
An error has occurred that was not properly handled. Additional information is shown below. The PowerShell process will exit.
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at System.Management.Automation.Remoting.PrioritySendDataCollection.Clear()
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.CloseAsync()
at System.Management.Automation.Remoting.Client.WSManClientSessionTransportManager.CloseAsync()
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.Finalize()
Abort trap: 6
[kai<strong i="8">@hobbes</strong> ~]$
Mac์์ ์๋ํ๋ ๊ฒ๊ณผ ๋๊ฐ์ ์ธ๋ถ ์ ๋ณด๋ฅผ ์ฌ์ฉํ์ฌ Azure Ubuntu ๊ฐ์ ๋จธ์ ์์ ํธ์คํ ๋๋ PowerShell์์ Office 365์ ์ฑ๊ณต์ ์ผ๋ก ์ฐ๊ฒฐํ ์ ์๋์ง ํ์ธํ๊ณ ์ถ์ต๋๋ค.
PowerShell v6.0.0-rc
Copyright (c) Microsoft Corporation. All rights reserved.
https://aka.ms/pscore6-docs
Type 'help' to get help.
PS /home/kai> $PSVersionTable
Name Value
---- -----
PSVersion 6.0.0-rc
PSEdition Core
GitCommitId v6.0.0-rc
OS Linux 4.4.0-22-generic #40-Ubuntu SMP Thu May 12 22:03:46 UTC 2016
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
PS /home/kai> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
PowerShell credential request
Enter your credentials.
User: [email protected]
Password for user [email protected]: ********
PS /home/kai> Import-PSSession $Session
(at this point PowerShell starts loading remote modules etc and preparing the session)
์ด ๋ฌธ์ ์ ์ถฉ๋ํ๋ ๋ด Mac์์ ๋ฌด์ธ๊ฐ๋ฅผ ์กฐ์ ํ์ ๋ ๋ฐ์ํ ์์๋ ๋ฌธ์ ๋ฅผ ์ ๊ฑฐํ๊ธฐ ์ํด ๋ด๊ฐ ํ ์ผ์ macOS 10.12๋ฅผ ์๋ก ์ค์น ํ ๋ค์ PowerShell 6.0.0-rc๋ฅผ ์๋ก ์ค์นํ๊ณ ํ ์คํธํ๋ ๊ฒ์ ๋๋ค. ์ค๋ ๋ฐค ์๋ํ๋ค๋ฉด.
# 3606์ ๋๋ค.
๋ฌธ์ # 3606์ ์ผ์ข ์ ์ค๋ณต์ด์ง๋ง ๋ด ํ ์คํธ์์ ๋ด๊ฐ ๋ณด์ง ๋ชปํ ์ค๋ฅ๊ฐ ๋ฐ์ํ๋ ๊ฒ๋ ํ์ธํ์ต๋๋ค.
New-PSSession : Unable to load DLL 'libpsrpclient':...
macOS 10.12.6์ ์๋ก ์ค์นํ๊ณ PowerShell 6.0.0-rc๋ฅผ ์๋ก ์ค์นํ์ฌ์ด๋ฅผ ์ฌํ ํ ์์์์ต๋๋ค. ๋ชจ๋ ๊ฒ์ด ๊ธฐ๋ณธ ์ค์ , ์ฒซ ๋ฒ์งธ ๋ถํ ์ ์์ฑ ๋ ์ ๊ด๋ฆฌ์ ๊ณ์ ๋ฐ ํฐ๋ฏธ๋ ์ฑ์ ๋ํ ์ค์ ๋ณ๊ฒฝ์ด ์์ต๋๋ค.
Last login: Thu Nov 30 08:11:57 on ttys000
Administrators-Mac-mini:~ admin$ pwsh
PowerShell v6.0.0-rc
Copyright (c) Microsoft Corporation. All rights reserved.
https://aka.ms/pscore6-docs
Type 'help' to get help.
PS /Users/admin> $PSVersionTable
Name Value
---- -----
PSVersion 6.0.0-rc
PSEdition Core
GitCommitId v6.0.0-rc
OS Darwin 16.7.0 Darwin Kernel Version 16.7.0: T...
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
PS /Users/admin> $env:DYLD_LIBRARY_PATH
PS /Users/admin> [System.Environment]::Is64BitProcess
True
PS /Users/admin> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
PowerShell credential request
Enter your credentials.
User: [email protected]
Password for user [email protected]: *********
An error has occurred that was not properly handled. Additional information is shown below. The PowerShell process will exit.
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at System.Management.Automation.Remoting.PrioritySendDataCollection.Clear()
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.CloseAsync()
at System.Management.Automation.Remoting.Client.WSManClientSessionTransportManager.CloseAsync()
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.Finalize()
Abort trap: 6
Administrators-Mac-mini:~ admin$
10.12.6 ์๋ก ์ค์น ํ ๊ฒฐ๊ณผ๋ ๋ค์๊ณผ ๊ฐ์ต๋๋ค.
Last login: Thu Nov 30 08:48:11 on ttys000
Administrators-Mac-mini:~ admin$ pwsh
PowerShell v6.0.0-rc
Copyright (c) Microsoft Corporation. All rights reserved.
https://aka.ms/pscore6-docs
Type 'help' to get help.
PS /Users/admin> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
PowerShell credential request
Enter your credentials.
User: [email protected]
Password for user [email protected]: ********
An error has occurred that was not properly handled. Additional information is shown below. The PowerShell process will exit.
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at System.Management.Automation.Remoting.PrioritySendDataCollection.Clear() in /PowerShell/src/System.Management.Automation/engine/remoting/fanin/PriorityCollection.cs:line 158
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.CloseAsync() in /PowerShell/src/System.Management.Automation/engine/remoting/fanin/BaseTransportManager.cs:line 949
at System.Management.Automation.Remoting.Client.WSManClientSessionTransportManager.CloseAsync() in /PowerShell/src/System.Management.Automation/engine/remoting/fanin/WSManTransportManager.cs:line 1219
at System.Management.Automation.Remoting.Client.BaseClientTransportManager.Finalize() in /PowerShell/src/System.Management.Automation/engine/remoting/fanin/BaseTransportManager.cs:line 998
Abort trap: 6
Administrators-Mac-mini:~ admin$
์ด๊ฒ์ # 4029์ ๋ฌธ์ํ ๋ ๋ฌธ์ ์ ๊ด๋ จ์ด์์ ์ ์์ต๋๋ค.
ํ์ฌ PowerShell 6.0.0-rc์๋ Homebrew์์ ์ค์น ํ OpenSSL ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฌ์ฉํด์ผํฉ๋๋ค.
๋์์ฃผ๊ธฐ ์ํด.
Debian 9 ๋์ปค ์ปจํ ์ด๋์์ ๋์ผํ ๋ฌธ์ ๊ฐ ๋ฐ์ํ์ต๋๋ค. ์์ ์ฃผ์์ ์ฝ์ ํ ๊นจ์ง ๋งํฌ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๊ฐ ์์๊ณ ์์คํ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๊ฐ ์์๋ณด๋ค ์ต์ ์ด๊ธฐ ๋๋ฌธ์ด์์ต๋๋ค. ๊ทธ๋ฐ ๋ค์ ์ผ๋ถ ์ฌ๋ณผ๋ฆญ ๋งํฌ๋ฅผ ๋ง๋ค์๊ณ ๋ชจ๋ ๊ฒ์ด ์ ์์ ์ผ๋ก ์คํ๋์์ต๋๋ค.
root @ db70f6f67c51 : / usr / lib / x86_64-linux-gnu # ldd /opt/microsoft/powershell/6.0.1/libmi.so
_linux-vdso.so.1 (0x00007ffd4b7fd000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f86cb670000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f86cb46c000)
libpam.so.0 => /lib/x86_64-linux-gnu/libpam.so.0 (0x00007f86cb25e000)
**libssl.so.1.0.0 => not found
libcrypto.so.1.0.0 => not found**
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f86cac56000)
/lib64/ld-linux-x86-64.so.2 (0x00007f86cb88d000)
libaudit.so.1 => /lib/x86_64-linux-gnu/libaudit.so.1 (0x00007f86caa2e000)
libcrypto.so.1.0.2 => /usr/lib/x86_64-linux-gnu/libcrypto.so.1.0.2 (0x00007f86ca5ca000)
libcap-ng.so.0 => /lib/x86_64-linux-gnu/libcap-ng.so.0 (0x00007f86ca3c4000)_
root @ db70f6f67c51 : /opt/microsoft/powershell/6.0.1# cd / usr / lib / x86_64-linux-gnu /
root @ db70f6f67c51 : / usr / lib / x86_64-linux-gnu # ln -s libssl.so.1.0.2 libssl.so.1.0.0
root @ db70f6f67c51 : / usr / lib / x86_64-linux-gnu # ls -l libssl *
_-rw-r--r-- 1 ๋ฃจํธ ๋ฃจํธ 738444 11 ์ 2 ์ผ 11:29 libssl.a
lrwxrwxrwx 1 ๋ฃจํธ ๋ฃจํธ 13 Nov 2 11:29 libssl.so-> libssl.so.1.1
lrwxrwxrwx 1 ๋ฃจํธ ๋ฃจํธ 21 2 ์ 15 ์ผ 17:27 libssl.so.1.0.0-> libssl.so.1.0.2
-rw-r--r-- 1 ๋ฃจํธ ๋ฃจํธ 431232 12 ์ 13 ์ผ 22:09 libssl.so.1.0.2
-rw-r--r-- 1 ๋ฃจํธ ๋ฃจํธ 442920 11 ์ 2 ์ผ 11:29 libssl.so.1.1_
root @ db70f6f67c51 : / usr / lib / x86_64-linux-gnu # ln -s libcrypto.so.1.0.2 libcrypto.so.1.0.0
root @ db70f6f67c51 : / usr / lib / x86_64-linux-gnu # ldd /opt/microsoft/powershell/6.0.1/libmi.so
_linux-vdso.so.1 (0x00007ffdde3b4000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f4e51539000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f4e51335000)
libpam.so.0 => /lib/x86_64-linux-gnu/libpam.so.0 (0x00007f4e51127000)
libssl.so.1.0.0 => /usr/lib/x86_64-linux-gnu/libssl.so.1.0.0 (0x00007f4e50ebe000)
libcrypto.so.1.0.0 => /usr/lib/x86_64-linux-gnu/libcrypto.so.1.0.0 (0x00007f4e50a5a000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f4e506bb000)
/lib64/ld-linux-x86-64.so.2 (0x00007f4e51756000)
libaudit.so.1 => /lib/x86_64-linux-gnu/libaudit.so.1 (0x00007f4e50493000)
libcap-ng.so.0 => /lib/x86_64-linux-gnu/libcap-ng.so.0 (0x00007f4e5028d000)_
๋น์ทํ ๋ฌธ์ ๊ฐ ์์์ง๋ง ๋ฌธ์ ๋ -AllowRedirection ๋งค๊ฐ ๋ณ์์ ์์ต๋๋ค.
๋ด๊ฐ ๋ฆฌ๋ ์ค์์ ์๋ํ๋ค๋ฉด.
$Session = $O365Session = New-PSSession โConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell -Credential $O365Cred -Authentication Basic -AllowRedirection
New-PSSession : [ps.outlook.com] Connecting to remote server ps.outlook.com failed with the following error message : Basic Authorization failed for user [email protected] For more information, see the about_Remote_Troubleshooting Help topic.
At line:1 char:12
+ $Session = New-PSSession -ConfigurationName Microsoft.Exchange -Conne ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotingTransportException
+ FullyQualifiedErrorId : 2,PSSessionOpenFailed
๋ด Powershell ๋ฒ์
PS /> $PSVersionTable
Name Value
---- -----
PSVersion 6.0.2
PSEdition Core
GitCommitId v6.0.2
OS Linux 4.13.0-37-generic #42-Ubuntu SMP Wed Mar 7 14:13:23 UTC 2018
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
Windows 10์ Powershell์์๋ ๋ง์ฐฌ๊ฐ์ง์ ๋๋ค.
PS C:\Users\user> $O365Session = New-PSSession โConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell -Credential $O365Cred -Authentication Basic -AllowRedirection
WARNING: Your connection has been redirected to the following URI: "https://ps.outlook.com/PowerShell-LiveID?PSVersion=5.1.16299.251 "
๋ฆฌ๋๋ ์ ์ ๋ํ ๊ฒฝ๊ณ ๊ฐ ํ์๋์ง๋ง ์ฑ๊ณต์ ์ผ๋ก ์ฐ๊ฒฐ๋ฉ๋๋ค.
Windows 10์ ๋ด PSversion
PS C:\Users\user> $PSVersionTable
Name Value
---- -----
PSVersion 5.1.16299.251
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.16299.251
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
์ด์ Linux์์ ๋์ผํ ๋ช ๋ น์ ์คํํ์ง๋ง Windows์์๋ ๋ฆฌ๋๋ ์ ๋ URI๋ฅผ ์ฌ์ฉํฉ๋๋ค.
PS /> $O365Session = New-PSSession โConfigurationName Microsoft.Exchange -ConnectionUri "https://ps.outlook.com/PowerShell-LiveID?PSVersion=5.1.16299.251" -Credential $O365Cred -Authentication Basic -AllowRedirection
PS /> $O365Session
Id Name ComputerName ComputerType State ConfigurationName Availability
-- ---- ------------ ------------ ----- ----------------- ------------
6 WinRM6 ps.outlook.com RemoteMachine Opened Microsoft.Exchange Available
์ด๊ฒ์ ๋์๊ฒ ๋ฌธ์ ๋ allowredirection paratemer๊ฐ ์ ๋๋ก ์๋ํ์ง ์๋๋ค๋ ๊ฒ์ ๋๋ค.
์ต์ PowerShell (v6.0.2)์ ์ค์นํ๋ฉด ๋ ์ด์ ์๋ํ์ง ์์ต๋๋ค.
[kai<strong i="6">@blackmac</strong> ~]$ pwsh
PowerShell v6.0.2
Copyright (c) Microsoft Corporation. All rights reserved.
https://aka.ms/pscore6-docs
Type 'help' to get help.
PS /Users/kai> $PSVersionTable
Name Value
---- -----
PSVersion 6.0.2
PSEdition Core
GitCommitId v6.0.2
OS Darwin 17.5.0 Darwin Kernel Version 17.5.0: Mon Mar 5 22:24:32 PST 2018; root:xnu-4570.51.1~1/RELEASE_X...
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
PS /Users/kai> $UserCredential = Get-Credential
PowerShell credential request
Enter your credentials.
User: [email protected]
Password for user [email protected]: ***********
PS /Users/kai> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
New-PSSession : [outlook.office365.com] Connecting to remote server outlook.office365.com failed with the following error message : Client did not get proper response from server. For more information, see the about_Remote_Troubleshooting Help topic.
At line:1 char:12
+ $Session = New-PSSession -ConfigurationName Microsoft.Exchange -Conne ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotingTransportException
+ FullyQualifiedErrorId : 1,PSSessionOpenFailed
PS /Users/kai>
@ SteveL-MSFT ์ด๊ฒ์ ๋ถ์์ ํ๊ฑฐ๋ ๋์ UX ๋๋ ๋ฌธ์ํ ๋ ๊ฒ์ผ๋ก ๊ฐ์ฃผํด์ผํฉ๋๊น?
์ด๊ฒ์ด ์ต์ ๋ฒ์ ์์ ๋ณ๊ฒฝ๋์ด ๊ธฐ๋ณธ ์ธ์ฆ์ด ์๋ํ์ง ์๋ ๊ฒ์ ๋๊น, ์๋๋ฉด ๊ทธ ์ด์์ ๋๊น? ํ์ํ ๊ฒฝ์ฐ ๋ ๋ง์ ํ ์คํธ๋ฅผ ์ํํ๊ฒ๋์ด ๊ธฐ์ฉ๋๋ค.
6.0.0์ ๋ํ ์๋น์ค ์ ๋ฐ์ดํธ์๋ ์ด์ ์ํฅ์ ๋ฏธ์น๋ ๋ณ๊ฒฝ ์ฌํญ์ด ์์ต๋๋ค. ์๋ฒ ์ธก์ ๋ณ๊ฒฝ ์ฌํญ์ด ์๋์ง ํ์คํ์ง ์์ต๋๋ค. cc @dantraMSFT
MacOS์์๋ 6.0.1์์ ์ผ๊ด๋ ERROR_WSMAN_INVALID_SELECTORS ์ค๋ฅ์ ํจ๊ป ํ๊ท๊ฐ ๋ฐ์ํฉ๋๋ค. 6.0.0 ๋ฐ 6.0.2์์ ๋ฌธ์ ๊ฐ ๋ฐ์ํ์ง ์์ผ๋ฉฐ libpsrpclient๊ฐ์ด ๋ฆด๋ฆฌ์ค์์ ๋ณ๊ฒฝ๋์ง ์์์ต๋๋ค. ๊ธฐ๊ณ๋ ์์ง High Sierra๋ก ์ ๊ทธ๋ ์ด๋๋์ง ์์์ผ๋ฏ๋ก ๊ธฐ์ฌํ ์ ์์ต๋๋ค.
๋ด ํ ์คํธ๋ ์ต๊ทผ์ macOS 10.12 Sierra์์ 10.13 High Sierra๋ก ์ ๊ทธ๋ ์ด๋ ๋ Mac์์ ์ด๋ฃจ์ด์ก์ต๋๋ค. ๋ํ ์ด์ ์ ์ฌ์ฉํ๋ ๋ฒ์ (6.0.0 ๋๋ 6.0.1)์์ ์ต์ ๋ฒ์ 6.0.2๋ก PowerShell์ ์ ๊ทธ๋ ์ด๋ํ์ต๋๋ค. ๋ํ MacPorts ์ค์น๋ฅผ ์ต์ ๋ฒ์ ์ผ๋ก ์ ๋ฐ์ดํธํ๊ณ ๋ชจ๋ ํฌํธ๋ฅผ ์ ๋ฐ์ดํธํ์ต๋๋ค. Homebrew์ ์ํด ์ค์น๋ OpenSSL ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฐพ์ ๊ฒ์ผ๋ก ์์๋๋ ๊ณณ์์ MacPorts์ ์ํด ์ค์น๋ ์์น๋ก PowerShell์ ๋ํ ์ฌ๋ณผ๋ฆญ ๋งํฌ๊ฐ ์์ผ๋ฉฐ ์ด๋ Office 365์ ์ฐ๊ฒฐํ๊ธฐ์ํ ์ ๊ทธ๋ ์ด๋ ์ด์ ์ ๋ชจ๋ ์๋ํ์ต๋๋ค.
powershell 6.0.2๊ฐ ์ค์น๋์ด ์์ต๋๋ค. MacPorts๋ฅผ ์ค์นํ๊ณ OpenSSL pkg๋ฅผ ๋ง๋ค๊ณ ์ค์นํ์ต๋๋ค. $ Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionURI https://outlook.office365.com/powershell-liveid/ -Credential $ O365Cred -Authenticatin Basic -Allowredirection์ ๋ง๋ค๋ ค๊ณ ํ ๋ New์ ๋์ผํ ์ค๋ฅ๊ฐ ๋ฐ์ํฉ๋๋ค. -PSSession :์ด ๋งค๊ฐ ๋ณ์ ์ธํธ์๋ WSMan์ด ํ์ํ๋ฉฐ ์ง์๋๋ WSMan ํด๋ผ์ด์ธํธ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฐพ์ ์ ์์ต๋๋ค.
$ Psversiontable
์ด๋ฆ ๊ฐ
---- -----
PS ๋ฒ์ 6.0.2
PSEdition ์ฝ์ด
GitCommitId v6.0.2
OS Darwin 17.5.0 Darwin Kernel ๋ฒ์ 17.5.0 : Fri Apr 13 19:32:32 PDT 2018; ๋ฃจํธ : x ...
ํ๋ซํผ ์ ๋์ค
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0 ...}
PSRemotingProtocol ๋ฒ์ โโ2.3
SerializationVersion 1.1.0.1
WSManStack ๋ฒ์ 3.0
WSMan ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ๋ ค๋ฉด ์ด๋ป๊ฒํด์ผํฉ๋๊น?
Mac์์ O365 ๋ฐ PS๋ฅผ ์ฒ์ ์ฌ์ฉํฉ๋๋ค. ์ฌ๊ธฐ์ ๋์ผํ ์ค๋ฅ ๋ฉ์์ง๊ฐ ํ์๋ฉ๋๋ค. ๋์์ ์ฃผ์๋ฉด ๊ฐ์ฌํ๊ฒ ์ต๋๋ค.
์ด๋ฆ ๊ฐ
---- -----
PS ๋ฒ์ 6.0.2
PSEdition ์ฝ์ด
GitCommitId v6.0.2
OS Darwin 17.6.0 Darwin Kernel ๋ฒ์ 17.6.0 : 2018 ๋
5 ์ 8 ์ผ ํ์์ผ 15:22:16 PDT; ๋ฃจํธ : xnu-4570.61.1 ~ ...
ํ๋ซํผ ์ ๋์ค
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0 ...}
PSRemotingProtocol ๋ฒ์ โโ2.3
SerializationVersion 1.1.0.1
WSManStack ๋ฒ์ 3.0
PS / Users / AdityaBhasin> $ Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.protection.outlook.com/powershell-liveid/ -Credential $ UserCredential -Authentication Basic -AllowRedirection
New-PSSession :์ด ๋งค๊ฐ ๋ณ์ ์ธํธ์๋ WSMan์ด ํ์ํ๋ฉฐ ์ง์๋๋ WSMan ํด๋ผ์ด์ธํธ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฐพ์ ์ ์์ต๋๋ค. WSMan์ด ์ค์น๋์ง ์์๊ฑฐ๋์ด ์์คํ
์ ์ฌ์ฉํ ์ ์์ต๋๋ค.
์ค : 1 char : 12
PS / ์ฌ์ฉ์ / AdityaBhasin>
์์คํ ๋ฒ์ : macOS 10.13.5 (17F77)
Homebrew์ ํจ๊ป OpenSSL์ด ์ค์น๋์ด ์์ต๋๊น? ๋๋ MacPort๋ฅผ ์ฌ์ฉํ๋ ๊ฒฝ์ฐ (๊ถ์ฅ) OpenSSL ๋ผ์ด๋ธ๋ฌ๋ฆฌ ๋๋ ํฐ๋ฆฌ๋ฅผ PowerShell์ด โโ์์ด์ผํ๋ค๊ณ ์๊ฐํ๋ ์์น์ ์ฐ๊ฒฐ ํ์ต๋๊น?
sudo ln -s /opt/local/lib /usr/local/opt/openssl/lib
์! @ kai-h ๊ฐ์ฌํฉ๋๋ค. Homebrew๋ก ๊ฐ๋ฐฉํ SSL์ ์ ๋ฐ์ดํธํ๋ ๋ช ๋ น์ ์คํํ๋๋ฐ ์ด์ ์ ์๊ฒ ์๋ํ๋ ๊ฒ ๊ฐ์ต๋๋ค. ์๋ก์ด ๋์ ์ ์ง๋ฉดํ๋ฉด ์ฌ๊ธฐ์์ ์ ๋ฐ์ดํธํ๊ฒ ์ต๋๋ค. ๋ค์ ํ ๋ฒ ๊ฐ์ฌ๋๋ฆฝ๋๋ค!
OSX 10.13.3์ PowerShell v6.0.4๋ฅผ ์ค์นํ๋ฉด ๋ฌธ์ ๊ฐ ํด๊ฒฐ๋์์ต๋๋ค.
๋งํฌ ์ค์น :
https://github.com/PowerShell/PowerShell/releases/download/v6.0.4/powershell-6.0.4-osx.10.12-x64.pkg
@ kai-h ํ์ธํ ์ ์์ต๋๊น?
์ด ๋ฌธ์ ๋ค์ ์ด๊ธฐ : Mojave์ ๋ฒ์ 6.1.0์ Office 365์ ์ฐ๊ฒฐ์ ์๋ ํ ๋ ๋์ผํ ๋ฌธ์ ๊ฐ ๋ฐ์ํฉ๋๋ค.
์ด๊ฒ์ ๋ํ Mojave๋ก ๋๋ฅผ ์ํด ์ฌํํ๊ณ ์์ต๋๋ค.
์ด๊ฒ์ Homebrew๊ฐ ์๋ MacPorts๋ฅผ ํตํด OpenSSL ๋ผ์ด๋ธ๋ฌ๋ฆฌ๊ฐ ์ค์น๋ Mojave์ 6.0.4์์ ์๋ํฉ๋๋ค.
````ํ์ ์
[ kai @ blackmac ~] $ pwsh
PowerShell v6.0.4
์ ์๊ถ (c) Microsoft Corporation. ํ๊ถ ์์ .
https://aka.ms/pscore6-docs
๋์์ ๋ฐ์ผ๋ ค๋ฉด 'help'๋ฅผ ์
๋ ฅํ์ญ์์ค.
PS / Users / kai> $ PSVersionTable
์ด๋ฆ ๊ฐ
---- -----
PS ๋ฒ์ 6.0.4
PSEdition ์ฝ์ด
GitCommitId v6.0.4
OS Darwin 18.0.0 Darwin Kernel ๋ฒ์ 18.0.0 : 2018 ๋
8 ์ 22 ์ผ ์์์ผ 20:13:40 PDT 2018; ๋ฃจํธ : xnu-4903.201.2 ~ 1 / RELEASE_X86_64
ํ๋ซํผ ์ ๋์ค
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0 ...}
PSRemotingProtocol ๋ฒ์ โโ2.3
SerializationVersion 1.1.0.1
WSManStack ๋ฒ์ 3.0
PS / Users / kai> office365.ps1
PowerShell ์๊ฒฉ ์ฆ๋ช
์์ฒญ
์๊ฒฉ ์ฆ๋ช
์ ์
๋ ฅํ์ญ์์ค.
์ฌ์ฉ์ : [email protected]
[email protected] ์ฌ์ฉ์์ * *
๊ฒฝ๊ณ : ๋ชจ๋ 'tmp_nlc54neg.nu0'์์ ๊ฐ์ ธ์จ ์ผ๋ถ ๋ช ๋ น์ ์ด๋ฆ์๋ ๊ฒ์ ๊ฐ๋ฅ์ฑ์ ๋จ์ด ๋จ๋ฆด ์์๋ ์น์ธ๋์ง ์์ ๋์ฌ๊ฐ ํฌํจ๋์ด ์์ต๋๋ค. ์น์ธ๋์ง ์์ ๋์ฌ๊ฐ์๋ ๋ช ๋ น์ ์ฐพ์ผ๋ ค๋ฉด Verbose ๋งค๊ฐ ๋ณ์๋ฅผ ์ฌ์ฉํ์ฌ Import-Module ๋ช ๋ น์ ๋ค์ ์คํํ์ญ์์ค. ์น์ธ ๋ ๋์ฌ ๋ชฉ๋ก์ ๋ณด๋ ค๋ฉด Get-Verb๋ฅผ ์ ๋ ฅํฉ๋๋ค. ModuleType ๋ฒ์ ์ด๋ฆ ExportedCommands ---------- ------- ---- ---------------- ์คํฌ๋ฆฝํธ 1.0 tmp_nlc54neg.nu0 {Add-AvailabilityAddressSpace , Add-DistributionGroupMember, Add-MailboxFolderPermission, Add-MailboxLocation ...}
PS / ์ฌ์ฉ์ / kai>
````
์ด๊ฒ์ Mojave์์ 6.1.0์ผ๋ก ์
๊ทธ๋ ์ด๋ํ์ ๋๋ ์๋ํฉ๋๋ค.
๋ค์ ๋งํด์ ์ ๋ MacPorts์ OpenSSH ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฌ์ฉํ๊ณ ์์ผ๋ฉฐ PowerShell์ด โโ๋ณผ ๊ฒ์ผ๋ก ์์ํ๋ ์์น์ ์ฐ๊ฒฐํ์ต๋๋ค.
sudo ln -s /opt/local/lib /usr/local/opt/openssl/lib
๊ทธ๋ฐ ๋ค์ pwsh๋ฅผ ์คํํ๋ฉด
````ํ์ ์
[ kai @ blackmac ~] $ pwsh
PowerShell 6.1.0
์ ์๊ถ (c) Microsoft Corporation. ํ๊ถ ์์ .
https://aka.ms/pscore6-docs
๋์์ ๋ฐ์ผ๋ ค๋ฉด 'help'๋ฅผ ์
๋ ฅํ์ญ์์ค.
PS / Users / kai> $ PSVersionTable
์ด๋ฆ ๊ฐ
---- -----
PS ๋ฒ์ 6.1.0
PSEdition ์ฝ์ด
GitCommitId 6.1.0
OS Darwin 18.0.0 Darwin Kernel ๋ฒ์ 18.0.0 : 2018 ๋
8 ์ 22 ์ผ ์์์ผ 20:13:40 PDT 2018; ๋ฃจํธ : xnu-4903.201.2 ~ 1 / RELEASE_X86_64
ํ๋ซํผ ์ ๋์ค
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0 ...}
PSRemotingProtocol ๋ฒ์ โโ2.3
SerializationVersion 1.1.0.1
WSManStack ๋ฒ์ 3.0
PS / Users / kai> office365.ps1
PowerShell ์๊ฒฉ ์ฆ๋ช
์์ฒญ
์๊ฒฉ ์ฆ๋ช
์ ์
๋ ฅํ์ญ์์ค.
์ฌ์ฉ์ : [email protected]
[email protected] ์ฌ์ฉ์์ * *
๊ฒฝ๊ณ : ๋ชจ๋ 'tmp_kllnlbam.5cg'์์ ๊ฐ์ ธ์จ ์ผ๋ถ ๋ช ๋ น์ ์ด๋ฆ์๋ ๊ฒ์ ๊ฐ๋ฅ์ฑ์ ๋จ์ด ๋จ๋ฆด ์์๋ ์น์ธ๋์ง ์์ ๋์ฌ๊ฐ ํฌํจ๋์ด ์์ต๋๋ค. ์น์ธ๋์ง ์์ ๋์ฌ๊ฐ์๋ ๋ช ๋ น์ ์ฐพ์ผ๋ ค๋ฉด Verbose ๋งค๊ฐ ๋ณ์๋ฅผ ์ฌ์ฉํ์ฌ Import-Module ๋ช ๋ น์ ๋ค์ ์คํํ์ญ์์ค. ์น์ธ ๋ ๋์ฌ ๋ชฉ๋ก์ ๋ณด๋ ค๋ฉด Get-Verb๋ฅผ ์ ๋ ฅํฉ๋๋ค. ModuleType ๋ฒ์ ์ด๋ฆ ExportedCommands ---------- ------- ---- ---------------- Script 1.0 tmp_kllnlbam.5cg {Add-AvailabilityAddressSpace , Add-DistributionGroupMember, Add-MailboxFolderPermission, Add -...
PS / ์ฌ์ฉ์ / kai>
````
MacPorts ๋ฒ์ ์ OpenSSL์ ์ฌ์ฉํ๋ฉด ์ ์๊ฒ ํจ๊ณผ์ ์ด์์ต๋๋ค.
Macports OpenSSL์ ์ฌ์ฉํ์ฌ Mojave์์ ์ด๊ฒ์ ์ฌํํ๊ณ ์์ต๋๋ค.
Mac OS Mojave 10.14.5
Powershell 6.2.3
xcode ๋๊ตฌ๊ฐ ์ค์น๋ฉ๋๋ค. homebrew์ ํจ๊ป powershell์ ์ค์นํ์ต๋๋ค.
Name Value
---- -----
PSVersion 6.2.3
PSEdition Core
GitCommitId 6.2.3
OS Darwin 18.6.0 Darwin Kernel Version 18.6.0: Thuโฆ
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0โฆ}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
MacPorts๋ฅผ ํตํด MS ๋ฌธ์ ์ง์นจ ์ ์ฌ์ฉํ์ฌ openssl์ ์ค์นํ์ต๋๋ค.
ws2784:~ travis.brackett$ port installed
The following ports are currently installed:
openssl @1.1.1d_0 (active)
zlib @1.2.11_0 (active)
์ฌ๋ณผ๋ฆญ ๋งํฌ๋ฅผ ๋ง๋ค์์ต๋๋ค.
sudo mkdir -p /usr/local/opt/openssl
sudo ln -s /opt/local/lib /usr/local/opt/openssl/lib
wsnnnn:~ travbrack$ ls -lha /usr/local/opt/openssl/lib/
total 14496
drwxr-xr-x 16 root wheel 512B Nov 22 14:39 .
drwxr-xr-x 11 root wheel 352B Nov 22 13:58 ..
-rw-r--r-- 1 root wheel 0B Oct 20 13:21 .turd_MacPorts
drwxr-xr-x 4 root admin 128B Nov 22 14:39 engines-1.1
lrwxr-xr-x 1 root wheel 14B Nov 22 14:28 lib -> /opt/local/lib
-rwxr-xr-x 1 root admin 2.1M Sep 15 05:22 libcrypto.1.1.dylib
-rw-r--r-- 1 root admin 3.7M Sep 15 05:22 libcrypto.a
lrwxr-xr-x 1 root admin 19B Sep 15 05:22 libcrypto.dylib -> libcrypto.1.1.dylib
-rwxr-xr-x 1 root admin 479K Sep 15 05:22 libssl.1.1.dylib
-rw-r--r-- 1 root admin 704K Sep 15 05:22 libssl.a
lrwxr-xr-x 1 root admin 16B Sep 15 05:22 libssl.dylib -> libssl.1.1.dylib
-rwxr-xr-x 1 root admin 79K Oct 1 2018 libz.1.2.11.dylib
lrwxr-xr-x 1 root admin 17B Oct 1 2018 libz.1.dylib -> libz.1.2.11.dylib
-rw-r--r-- 1 root admin 95K Oct 1 2018 libz.a
lrwxr-xr-x 1 root admin 17B Oct 1 2018 libz.dylib -> libz.1.2.11.dylib
drwxr-xr-x 6 root admin 192B Nov 22 14:39 pkgconfig
wsnnnn:~ travbrack$ ls -lha /usr/local/opt/openssl/lib
lrwxr-xr-x 1 root admin 14B Nov 22 14:02 /usr/local/opt/openssl/lib -> /opt/local/lib
ํฐ๋ฏธ๋์ ๋ค์ ์์ํ๊ณ enter-pssession์ ์๋ํ์ต๋๋ค.
```
PS / Users / travbrack> enter-pssession ์ปดํจํฐ ์ด๋ฆ
enter-pssession :์ด ๋งค๊ฐ ๋ณ์ ์งํฉ์๋ WSMan์ด ํ์ํ๋ฉฐ ์ง์๋๋ WSMan ํด๋ผ์ด์ธํธ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฐพ์ ์ ์์ต๋๋ค. WSMan์ด ์ค์น๋์ง ์์๊ฑฐ๋์ด ์์คํ
์ ์ฌ์ฉํ ์ ์์ต๋๋ค.
์ค : 1 char : 1
์ด๋ค ๋์์ด๋ผ๋ ๋๋จํ ๊ฐ์ฌํ๊ฒ ์ต๋๋ค.
# 10600์์ ๋๊ธ ๋ฌ๊ธฐ
๋๋ ๊ฐ์ ๋ฌธ์ ๊ฐ ์์๊ณ brew์ ์ด์ openssl ๋ฒ์ ์ brew ์ค์์น openssl 1.0.2s์ ์ฐ๊ฒฐํ์ฌ ํด๊ฒฐํ์ต๋๋ค.
๋๋ฅผ ์ํด openssl 1.0.2r๋ก ์ ํํ๋ ๊ฒ๋ ํจ๊ณผ์ ์ด์์ต๋๋ค. ๊ธฐ๋ณธ์ ์ผ๋ก brew๋ฅผ ํตํด openssl 1.1์ ์ค์นํ์ง๋ง ์๋ํ์ง ์์์ต๋๋ค.
์๋ ํ์ธ์ ์ฌ๋ฌ๋ถ,
openssl ๋ฒ์ ๊ณผ ๊ด๋ จํ์ฌ brew๊ฐ ver 1.02๋ฅผ ์ฌ์ฉํ๋๋ก ๊ฐ์ํ์ผ๋ฉฐ ์ด๊ฒ์ pwsh O365 ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ์ต๋๋ค. ๋ด๊ฐ ์คํ ํ ๋ช ๋ น์ ...
brew uninstall openssl;
brew uninstall openssl; (์๋ฌด๊ฒ๋ ๋จ์ ์์ง ์๋๋กํ๊ธฐ ์ํด)
์์กฐ ์ค์น https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb
ํฌ๋ ๋ง : @kensoh
๊ฐ์ฌ.
pwsh 6.0.4๋ก mojave๋ฅผ ์คํํ๋ ๋๋ฅผ ์ํด ์ผํ @leeharrison. ๋๋ ์ด์ ์ ๋ชจ๋ ์ ์์ ์๋ํ์ง๋ง ๋ค๋ฅธ ๊ฒ์ ๋๋ฅผ ์ํด ์ผํ์ง ์์์ต๋๋ค.
๊ฐ์ฌํฉ๋๋ค @leeharrison ๋๋ ๋ํ pwsh 6.0.4๋ฅผ ์ฌ์ฉํ์ฌ High Sierra ์์์ด ๋ฌธ์ ๋ฅผ ๊ฒช์์ผ๋ฉฐ ๊ทํ์ ์ ์๋ ์ ์๊ฒ ํด๊ฒฐ๋์์ต๋๋ค.
macOS์ PowerShell์ด โโ์ด์ ์ ์์ ํ์ง ์์ OpenSSL ๋ผ์ด๋ธ๋ฌ๋ฆฌ ๋ฒ์ ์ ๋ํ ์๊ฒฉํ ์ข ์์ฑ์ด ์๋์ง ํ์ธํด ์ฃผ์๊ฒ ์ต๋๊น? ๋ผ์ด๋ธ๋ฌ๋ฆฌ๊ฐ ํ๋ ์ฝ๋ฉ ๋ ๊ฒฝ๋ก๋ก Homebrew์ ์ํด ์ค์น๋๋๋ก ๋ช ์ ์ ์ผ๋ก ์๊ตฌํ๋ ๊ฒ๋ ๋์ ์ต๊ด์ ๋๋ค.
https://github.com/PowerShell/PowerShell/issues/11216#issuecomment -608221120๋ ์ฐธ์กฐ
์๋ ํ์ธ์ ์ฌ๋ฌ๋ถ,
openssl ๋ฒ์ ๊ณผ ๊ด๋ จํ์ฌ brew๊ฐ ver 1.02๋ฅผ ์ฌ์ฉํ๋๋ก ๊ฐ์ํ์ผ๋ฉฐ ์ด๊ฒ์ pwsh O365 ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ์ต๋๋ค. ๋ด๊ฐ ์คํ ํ ๋ช ๋ น์ ...
brew uninstall openssl;
brew uninstall openssl; (์๋ฌด๊ฒ๋ ๋จ์ ์์ง ์๋๋กํ๊ธฐ ์ํด)
์์กฐ ์ค์น https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rbํฌ๋ ๋ง : @kensoh
๊ฐ์ฌ.
์ด๊ฒ์ ํ์คํ ์ ์๋ํฉ๋๋ค! ๊ฐ์ฌํฉ๋๋ค.
์๋ ํ์ธ์ ์ฌ๋ฌ๋ถ,
openssl ๋ฒ์ ๊ณผ ๊ด๋ จํ์ฌ brew๊ฐ ver 1.02๋ฅผ ์ฌ์ฉํ๋๋ก ๊ฐ์ํ์ผ๋ฉฐ ์ด๊ฒ์ pwsh O365 ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ์ต๋๋ค. ๋ด๊ฐ ์คํ ํ ๋ช ๋ น์ ...
brew uninstall openssl;
brew uninstall openssl; (์๋ฌด๊ฒ๋ ๋จ์ ์์ง ์๋๋กํ๊ธฐ ์ํด)
์์กฐ ์ค์น https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rbํฌ๋ ๋ง : @kensoh
๊ฐ์ฌ.
์ด๊ฒ์ Catalina 10.15.4์์ ์๋ํฉ๋๋ค.
์๋ ํ์ธ์ ์ฌ๋ฌ๋ถ,
openssl ๋ฒ์ ๊ณผ ๊ด๋ จํ์ฌ brew๊ฐ ver 1.02๋ฅผ ์ฌ์ฉํ๋๋ก ๊ฐ์ํ์ผ๋ฉฐ ์ด๊ฒ์ pwsh O365 ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ์ต๋๋ค. ๋ด๊ฐ ์คํ ํ ๋ช ๋ น์ ...
brew uninstall openssl;
brew uninstall openssl; (์๋ฌด๊ฒ๋ ๋จ์ ์์ง ์๋๋กํ๊ธฐ ์ํด)
์์กฐ ์ค์น https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb
ํฌ๋ ๋ง : @kensoh
๊ฐ์ฌ.์ด๊ฒ์ Catalina 10.15.4์์ ์๋ํฉ๋๋ค.
๋ค๋ฅธ Brew ์ค์น ๋๊ตฌ๋ฅผ ์์์ํค์ง ์๊ณ ์ด๋ป๊ฒ ์๋ํฉ๋๊น ??
๋๋ ๊ทธ๊ฒ์ ์๋ํ์ ๋ ๋๋ ๋ ์ค ํ๋๋ง ๊ฐ์ง ์ ์์ต๋๋ค.
openssl ๋ฒ์ ์ ๋กค๋ฐฑํ๋ฉด pwsh๋ ์๋ํ์ง๋ง iperf3์ ์๋ฅผ ๋ค์ด ์ค๋จ๋ฉ๋๋ค.
์ด๋ฆ ๊ฐ
---- -----
PS ๋ฒ์ 7.0.1
PSEdition ์ฝ์ด
GitCommitId 7.0.1
OS Darwin 19.4.0 Darwin Kernel ๋ฒ์ 19.4.0 : Wed Mar 4 22:28:40 PST 2020; root : xnu-6153.101.6 ~ 15 / RELEASE_X8โฆ
ํ๋ซํผ ์ ๋์ค
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0โฆ}
PSRemotingProtocol ๋ฒ์ โโ2.3
SerializationVersion 1.1.0.1
WSManStack ๋ฒ์ 3.0
์ค๋๋๊ณ ๋ ์ด์ ์ฌ์ฉ๋์ง ์๋ OpenSSL ๋ฒ์ ์ผ๋ก ๋ค์ด ๊ทธ๋ ์ด๋ํ๋ ๊ฒ์ด ์ค์ ์๋ฃจ์ ์ด ์๋๋ผ๋ ์ ์ ์๋ ค์ฃผ์ธ์.
Apple์ ์ด๋ฏธ macOS์ ์ค์น๋ ์ฌ๋ฌ ๋ฒ์ ์ OpenSSL ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ๊ฐ์ง๊ณ ์์ต๋๋ค.
macOS์ PowerShell์ ์์คํ ๋ผ์ด๋ธ๋ฌ๋ฆฌ ๊ฒฝ๋ก๋ฅผ ๊ฒ์ํ๋ ๋์ ๋ผ์ด๋ธ๋ฌ๋ฆฌ์ ๋ํ ํ๋ ์ฝ๋ฉ ๋ ๊ฒฝ๋ก๊ฐ์๋ ์ด์ ๋ ๋ฌด์์ ๋๊น?
/ usr / lib ํด๋์๋ ์ฌ์ฉ์ ๊ธฐ๋ค๋ฆฌ๊ณ ์๋ 6 ๊ฐ์ ๋ค๋ฅธ ๋ฒ์ ์ด ์์ต๋๋ค.
/usr/lib/libssl.0.9.8.dylib
/usr/lib/libssl.dylib
/usr/lib/libssl.35.dylib
/usr/lib/libssl.0.9.7.dylib
/usr/lib/libssl.43.dylib
/usr/lib/libssl.46.dylib
/usr/lib/libssl.44.dylib
์ค๋๋๊ณ ๋ ์ด์ ์ฌ์ฉ๋์ง ์๋ OpenSSL ๋ฒ์ ์ผ๋ก ๋ค์ด ๊ทธ๋ ์ด๋ํ๋ ๊ฒ์ด ์ค์ ์๋ฃจ์ ์ด ์๋๋ผ๋ ์ ์ ์๋ ค์ฃผ์ธ์.
Apple์ ์ด๋ฏธ macOS์ ์ค์น๋ ์ฌ๋ฌ ๋ฒ์ ์ OpenSSL ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ๊ฐ์ง๊ณ ์์ต๋๋ค.
macOS์ PowerShell์ ์์คํ ๋ผ์ด๋ธ๋ฌ๋ฆฌ ๊ฒฝ๋ก๋ฅผ ๊ฒ์ํ๋ ๋์ ๋ผ์ด๋ธ๋ฌ๋ฆฌ์ ๋ํ ํ๋ ์ฝ๋ฉ ๋ ๊ฒฝ๋ก๊ฐ์๋ ์ด์ ๋ ๋ฌด์์ ๋๊น?
/ usr / lib ํด๋์๋ ์ฌ์ฉ์ ๊ธฐ๋ค๋ฆฌ๊ณ ์๋ 6 ๊ฐ์ ๋ค๋ฅธ ๋ฒ์ ์ด ์์ต๋๋ค.
/usr/lib/libssl.0.9.8.dylib
/usr/lib/libssl.dylib
/usr/lib/libssl.35.dylib
/usr/lib/libssl.0.9.7.dylib
/usr/lib/libssl.43.dylib
/usr/lib/libssl.46.dylib
/usr/lib/libssl.44.dylib
OpenSSL์ ์ด์ ๋ฆด๋ฆฌ์ค์์ ์ดํดํ์๊ธฐ ๋ฐ๋๋๋ค. ์ ๋ฆด๋ฆฌ์ค๋ 2016 ๋ 8 ์ 25 ์ผ ๋ฆด๋ฆฌ์ค ๋ v1.1.0์ ๋๋ค. ๋ฒ์ 0.9.8์ 2005 ๋ 7 ์ 5 ์ผ์ ๋ฆด๋ฆฌ์ค๋์์ต๋๋ค. ๋๋ฌด ๋ง์ Windows ์๋ฒ์์ OpenSSH ๊ตฌํ์ ์ฒ๋ฆฌํ๊ณ ์ ์ง ๊ด๋ฆฌ ํ ์ โโ์๊ธฐ ๋๋ฌธ์ ์ด์จ๋ Linux๋ก ์ ํํ์ต๋๋ค. ๊ทธ๋ฌ๋ ํฅํ ๋ฆด๋ฆฌ์ค์์ PSCore์ ๋ํด kerberos๊ฐ ์ด๋ป๊ฒ ์ง์ ๋ ์ง, ๊ทธ๋ฆฌ๊ณ macOS์์ ์ด์ ๋ํ ๊ด์ฌ์ด ์๋์ง ์ฌ์ ํ ๊ธฐ๋ํ๊ณ ์์ต๋๋ค.
@mikeyjoel ์ ๋ฌธ์ ๋ฅผ ๋ง๋ค๊ณ ์์ ํ๋ ค๋ ์๊ฒฉ ์๋๋ฆฌ์ค๋ฅผ ์ค๋ช ํ์ญ์์ค.
@mikeyjoel ์ ๋ฌธ์ ๋ฅผ ๋ง๋ค๊ณ ์์ ํ๋ ค๋ ์๊ฒฉ ์๋๋ฆฌ์ค๋ฅผ ์ค๋ช ํ์ญ์์ค.
์ด์๊ฐ ์ด๋ฏธ ์์ฑ๋์์ผ๋ฏ๋ก ์๋ก์ด ์ด์๋ฅผ ์์ฑ ํ ํ์๊ฐ ์์ต๋๋ค. # 3708
RHEL / Centos ๋๋ Debian / Ubuntu ๋ฐฐํฌ์๋ ๋ค์ ํจํค์ง๊ฐ ํ์ํฉ๋๋ค.
krb5- ์ํฌ ์คํ
์ด์
krb5-devel
gssntlmssp (์ฌ์ ์ epel-release๋ฅผ ์ค์นํด์ผ ํจ)
ํ์ ์
๊ฐ Linux ๋ฐฐํฌ์ ๋ํด ๊ธฐ๋ณธ์ ์ผ๋ก ์ฌ์ฉํ ์ ์์ต๋๋ค. Office365๋ฟ๋ง ์๋๋ผ ํ๊ฒฝ์์ Windows Server๋ ๊ด๋ฆฌํ๋ ๊ฒ์ด ๋งค์ฐ ์ผ๋ฐ์ ์ด๊ธฐ ๋๋ฌธ์์ด ๋ฌธ์ ๋ฅผ ์ ๊ธฐํฉ๋๋ค.
์ค๋๋๊ณ ๋ ์ด์ ์ฌ์ฉ๋์ง ์๋ OpenSSL ๋ฒ์ ์ผ๋ก ๋ค์ด ๊ทธ๋ ์ด๋ํ๋ ๊ฒ์ด ์ค์ ์๋ฃจ์ ์ด ์๋๋ผ๋ ์ ์ ์๋ ค์ฃผ์ธ์.
Apple์ ์ด๋ฏธ macOS์ ์ค์น๋ ์ฌ๋ฌ ๋ฒ์ ์ OpenSSL ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ๊ฐ์ง๊ณ ์์ต๋๋ค.
macOS์ PowerShell์ ์์คํ ๋ผ์ด๋ธ๋ฌ๋ฆฌ ๊ฒฝ๋ก๋ฅผ ๊ฒ์ํ๋ ๋์ ๋ผ์ด๋ธ๋ฌ๋ฆฌ์ ๋ํ ํ๋ ์ฝ๋ฉ ๋ ๊ฒฝ๋ก๊ฐ์๋ ์ด์ ๋ ๋ฌด์์ ๋๊น?
/ usr / lib ํด๋์๋ ์ฌ์ฉ์ ๊ธฐ๋ค๋ฆฌ๊ณ ์๋ 6 ๊ฐ์ ๋ค๋ฅธ ๋ฒ์ ์ด ์์ต๋๋ค.
/usr/lib/libssl.0.9.8.dylib
/usr/lib/libssl.dylib
/usr/lib/libssl.35.dylib
/usr/lib/libssl.0.9.7.dylib
/usr/lib/libssl.43.dylib
/usr/lib/libssl.46.dylib
/usr/lib/libssl.44.dylibOpenSSL์ ์ด์ ๋ฆด๋ฆฌ์ค์์ ์ดํดํ์๊ธฐ ๋ฐ๋๋๋ค. ์ ๋ฆด๋ฆฌ์ค๋ 2016 ๋ 8 ์ 25 ์ผ ๋ฆด๋ฆฌ์ค ๋ v1.1.0์ ๋๋ค. ๋ฒ์ 0.9.8์ 2005 ๋ 7 ์ 5 ์ผ์ ๋ฆด๋ฆฌ์ค๋์์ต๋๋ค. ๋๋ฌด ๋ง์ Windows ์๋ฒ์์ OpenSSH ๊ตฌํ์ ์ฒ๋ฆฌํ๊ณ ์ ์ง ๊ด๋ฆฌ ํ ์ โโ์๊ธฐ ๋๋ฌธ์ ์ด์จ๋ Linux๋ก ์ ํํ์ต๋๋ค. ๊ทธ๋ฌ๋ ํฅํ ๋ฆด๋ฆฌ์ค์์ PSCore์ ๋ํด kerberos๊ฐ ์ด๋ป๊ฒ ์ง์ ๋ ์ง, ๊ทธ๋ฆฌ๊ณ macOS์์ ์ด์ ๋ํ ๊ด์ฌ์ด ์๋์ง ์ฌ์ ํ ๊ธฐ๋ํ๊ณ ์์ต๋๋ค.
๋๋ ์ด๊ฒ์ด ์ค๋๋ OpenSSL ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ผ๋ ๊ฒ์ ์ ์๊ณ ์์ง๋ง pwsh๋ ํ์ฌ ์ค๋๋ ๋ผ์ด๋ธ๋ฌ๋ฆฌ์์๋ง ์๋ํ๋ฏ๋ก ์ด๋ฏธ macOS์ ์ค์น๋์ด ์์ต๋๋ค.
๊ทธ๋์ ์ด๊ฒ์ ์ด๋์์ ๊ณต์ ํด์ผํ ์ง ๋ชจ๋ฅด๊ฒ ์ง๋ง ์ต๊ทผ์ OMI๋ฅผ ์ฌ์ฉํ์ฌ ์ต์ ๋ฒ์ ์ OpenSSL (1.1.0)๊ณผ Kerberos ์ธ์ฆ (๊ทธ๋ฆฌ๊ณ ํฌ๋ง์ ์ผ๋ก๋ NTLM)์ ๋ํด ์๋ํ๋๋ก ์๋ํ์ต๋๋ค. Mac. ๋ก์ปฌ ๋น๋์์ ์์ ํ ๋ช ๊ฐ์ง ๋ฒ๊ทธ๊ฐ ์์ง๋ง ํ์คํ ์๋ํ๋๋ก ํ ์ ์์ผ๋ฉฐ ์ฌ๋๋ค์ด ๋น Windows์์ WinRM์ ํตํด PSRemoting์ ์ป์ ์ ์๋๋ก ๋์์ฃผ๋ ๋ธ๋ก๊ทธ ๊ฒ์๋ฌผ / ๊ฐ์ด๋๋ฅผ ๋ง๋ค ๊ณํ์ ๋๋ค. ํธ์คํธ.
PowerShell ํ์ด ์ด๋ฌํ ๋ณ๊ฒฝ ์ฌํญ์ ๋ฆด๋ฆฌ์ค์ ํฌํจ ๋ OMI์ ์ปดํ์ผ ๋ ๋น๋์ ํตํฉํ๋ ๋ฐ ์ผ๋ง๋ ๊ด์ฌ์ด ์๋์ง ๊ถ๊ธํฉ๋๋ค. ๋๋ ๊ทธ๊ฒ๋ค์ OMI ๋ฆฌํฌ์งํ ๋ฆฌ์ ๋ณํฉํ๋ ค๊ณ ๊ณํํ๊ณ ์์ง๋ง ๊ทธ๋ค์ด ์ค์ ๋ก ๊ทธ๊ฒ์ ๋ง๋ค ๊ฒ์ด๋ผ๊ณ ๋๊ดํ์ง ์์ต๋๋ค. OpenSSL ์์ ์ ๋ํ ๊ทธ๋ค์ด ์ค์น ๋จ๊ณ์์ ๋ฌธ์ํ ํ OpenSSL 1.0.0์ ๋ํ ์๊ตฌ ์ฌํญ์ ์ญ์ ํ ์ ์๋๋กํด์ผํฉ๋๋ค. ๊ทธ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๊ฐ ํ์ํ ๊ฒ์ PSRP ํด๋ผ์ด์ธํธ ๋ฟ์ธ ๊ฒ์ฒ๋ผ ๋ณด์ ๋๋ค.
์ด๊ฒ์ ๋ด๊ฐ์ด ๋ฌธ์ ์ ๋ํด ์ฐพ์ ์์๋ ๊ฐ์ฅ ๊ธด ์ค๋ ๋ ์ธ ๊ฒ์ฒ๋ผ ๋ณด์์ผ๋ฏ๋ก ์ฌ๊ธฐ์ ๊ฒ์ํ๋ ๊ฒ์ด ๊ฐ์ฅ ์ข๋ค๊ณ ์๊ฐํ์ต๋๋ค. ๋ด๊ฐ ์ฐพ์ ๋ค์ํ ๋ฌธ์ ์ ํด๊ฒฐ ๋ฐฉ๋ฒ / ์์ ์ ์ปดํ์ผํ๋ ์๋ก์ด ๋ฌธ์ ๋ฅผ ๋ง๋ค์ด์ ๋ค๋ฅธ ์ฌ๋๋ค์ด ์๋ํด๋ณด๊ณ ์ํ๋ ์ฌ๋๋ค์ ์ํด ์ ์ ํ๊ฒ ๋ฌธ์ํ ํ ์์๊ฒ๋์ด ๊ธฐ์ฉ๋๋ค.
์๋ ํ์ธ์ ์ฌ๋ฌ๋ถ,
openssl ๋ฒ์ ๊ณผ ๊ด๋ จํ์ฌ brew๊ฐ ver 1.02๋ฅผ ์ฌ์ฉํ๋๋ก ๊ฐ์ํ์ผ๋ฉฐ ์ด๊ฒ์ pwsh O365 ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ์ต๋๋ค. ๋ด๊ฐ ์คํ ํ ๋ช ๋ น์ ...
brew uninstall openssl;
brew uninstall openssl; (์๋ฌด๊ฒ๋ ๋จ์ ์์ง ์๋๋กํ๊ธฐ ์ํด)
์์กฐ ์ค์น https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rbํฌ๋ ๋ง : @kensoh
๊ฐ์ฌ.
์ฝ๊ณ ์์์ ์ธ ํด๊ฒฐ ๋ฐฉ๋ฒ์ ์ฐพ์์ต๋๋ค. ์ ๋ฅผ ์ฌ๋ฐ๋ฅธ ๋ฐฉํฅ์ผ๋ก ์๋ด ํด์ค @kensoh ์ @leeharrison ์๊ฒ ๊ฐ์ฌ๋๋ฆฝ๋๋ค.
1.) ์ด์ ๋ฒ์ ์ด ์์ง ์ค์น๋์ง ์์๋์ง ํ์ธ
ls -al /usr/local/Cellar/openssl*
2.) ์ด์ ๋ฒ์ ์ค์น (์ง๊ธ 1.0.2t)
brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb
3.) ์ด์ ๋ฒ์ ์ผ๋ก ์ ํ
brew switch openssl 1.0.2t
4.) Powershell ํ์๋ฆฌ ์ํ
5.) ์ OpenSSL ๋ฒ์ ์ผ๋ก ๋ค์ ์ ํ (์ ๊ฒฝ์ฐ์๋ 1.1.1g, ๋ฒ์ ๋ฐ Cellar ํด๋๋ฅผ ์ฐพ์ผ๋ ค๋ฉด 1 ๋จ๊ณ ํ์ธ)
brew switch [email protected] 1.1.1g
์ฆ๊ธฐ์ธ์ ๐
์ ์ด๊ฒ์ด ๋ซํ๋์ง ์ฌ์ ํ ๋ฌธ์ ์ ๋๋ค. Enter-AzWebAppContainerPSSession์ ์คํํ๋ ค๊ณ ํ์ง๋ง WSMan ์ค๋ฅ๊ฐ ๋ฐ์ํ์ผ๋ฉฐ 1.1.1g๊ฐ ์ค์น๋์ด์๋ ๋์ OpenSSL 1.0.0์ด ํ์ํ Mac์ PowerShell ๋ฌธ์ ์ธ ๊ฒ ๊ฐ์ต๋๋ค.
์
๋ฐ์ดํธ-WSMan์ ๋ ์ด์ ์ฌ์ฉ๋์ง ์๊ณ ๋จ๊ฒจ๋๊ณ ์์ง๋ง ๋ถํํ๋ ์ฌ์ฉ ๊ฐ๋ฅํ ํ์ ๋ผ์ธ์ด ์์ต๋๋ค.
https://github.com/PowerShell/PowerShell/issues/10600#issuecomment -610565488
๊ทธ๋์ ์ด๊ฒ์ ์ด๋์์ ๊ณต์ ํด์ผํ ์ง ๋ชจ๋ฅด๊ฒ ์ง๋ง ์ต๊ทผ์ OMI๋ฅผ ์ฌ์ฉํ์ฌ ์ต์ ๋ฒ์ ์ OpenSSL (1.1.0)๊ณผ Kerberos ์ธ์ฆ (๊ทธ๋ฆฌ๊ณ ํฌ๋ง์ ์ผ๋ก๋ NTLM)์ ๋ํด ์๋ํ๋๋ก ์๋ํ์ต๋๋ค. Mac. ๋ก์ปฌ ๋น๋์์ ์์ ํ ๋ช ๊ฐ์ง ๋ฒ๊ทธ๊ฐ ์์ง๋ง ํ์คํ ์๋ํ๋๋ก ํ ์ ์์ผ๋ฉฐ ์ฌ๋๋ค์ด ๋น Windows์์ WinRM์ ํตํด PSRemoting์ ์ป์ ์ ์๋๋ก ๋์์ฃผ๋ ๋ธ๋ก๊ทธ ๊ฒ์๋ฌผ / ๊ฐ์ด๋๋ฅผ ๋ง๋ค ๊ณํ์ ๋๋ค. ํธ์คํธ.
PowerShell ํ์ด ์ด๋ฌํ ๋ณ๊ฒฝ ์ฌํญ์ ๋ฆด๋ฆฌ์ค์ ํฌํจ ๋ OMI์ ์ปดํ์ผ ๋ ๋น๋์ ํตํฉํ๋ ๋ฐ ์ผ๋ง๋ ๊ด์ฌ์ด ์๋์ง ๊ถ๊ธํฉ๋๋ค. ๋๋ ๊ทธ๊ฒ๋ค์ OMI ๋ฆฌํฌ์งํ ๋ฆฌ์ ๋ณํฉํ๋ ค๊ณ ๊ณํํ๊ณ ์์ง๋ง ๊ทธ๋ค์ด ์ค์ ๋ก ๊ทธ๊ฒ์ ๋ง๋ค ๊ฒ์ด๋ผ๊ณ ๋๊ดํ์ง ์์ต๋๋ค. OpenSSL ์์ ์ ๋ํ ๊ทธ๋ค์ด ์ค์น ๋จ๊ณ์์ ๋ฌธ์ํ ํ OpenSSL 1.0.0์ ๋ํ ์๊ตฌ ์ฌํญ์ ์ญ์ ํ ์ ์๋๋กํด์ผํฉ๋๋ค. ๊ทธ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๊ฐ ํ์ํ ๊ฒ์ PSRP ํด๋ผ์ด์ธํธ ๋ฟ์ธ ๊ฒ์ฒ๋ผ ๋ณด์ ๋๋ค.
์ด๊ฒ์ ๋ด๊ฐ์ด ๋ฌธ์ ์ ๋ํด ์ฐพ์ ์์๋ ๊ฐ์ฅ ๊ธด ์ค๋ ๋ ์ธ ๊ฒ์ฒ๋ผ ๋ณด์์ผ๋ฏ๋ก ์ฌ๊ธฐ์ ๊ฒ์ํ๋ ๊ฒ์ด ๊ฐ์ฅ ์ข๋ค๊ณ ์๊ฐํ์ต๋๋ค. ๋ด๊ฐ ์ฐพ์ ๋ค์ํ ๋ฌธ์ ์ ํด๊ฒฐ ๋ฐฉ๋ฒ / ์์ ์ ์ปดํ์ผํ๋ ์๋ก์ด ๋ฌธ์ ๋ฅผ ๋ง๋ค์ด์ ๋ค๋ฅธ ์ฌ๋๋ค์ด ์๋ํด๋ณด๊ณ ์ํ๋ ์ฌ๋๋ค์ ์ํด ์ ์ ํ๊ฒ ๋ฌธ์ํ ํ ์์๊ฒ๋์ด ๊ธฐ์ฉ๋๋ค.
์๋ ํ์ธ์ @ jborean93 ์ฃผ๋ณ ์ผ์ด ๋ญ์ฃ . ์ ๋ Fedora 32๋ฅผ ์ฌ์ฉํ๊ณ ์์ผ๋ฉฐ OpenSSL 1.0.0 ์๊ตฌ ์ฌํญ์ผ๋ก ์ธํด bejesus๋ฅผ ์ง์ฆ๋๊ฒํฉ๋๋ค.
@alaurie macOS๋ฅผ ์ฌ์ฉํ์ง ์๋๋ค๋ฉด ์ด์ด ์ข์ ๊ฒ์
๋๋ค. omi
์ ์ฅ์๋ ์ค์ ๋ก ๋ฆด๋ฆฌ์ค ํ์ด์ง ์์ OpenSSL 1.0.0 ๋ฐ OpenSSL 1.1.0 ๋ฒ์ฉ ํจํค์ง๋ฅผ ๋ชจ๋
ssl_110.ulinux.x64.rpm ํจํค์ง๋ฅผ ๋ค์ด๋ก๋ํ๊ณ RPM์ ์ค์นํ๊ฑฐ๋ ์ถ์ถํ์ญ์์ค. ๋ค์์ผ๋ก /opt/omi/lib/libmi.so
๋ฅผ /opt/microsoft/powershell/7/libmi.so
๋ก ๋ณต์ฌํ๊ฑฐ๋ ์ฌ๋ณผ๋ฆญ ๋งํฌํด์ผํฉ๋๋ค. ์ฌ๊ธฐ์์ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๊ฐ ldd
์ฐ๊ฒฐ๋์ด ์๋์ง ํ์ธํ ์ ์์ต๋๋ค.
# Before (what's included with PowerShell)
jborean:~/dev/$ ldd /opt/microsoft/powershell/7/libmi.so
ldd: warning: you do not have execution permission for `/opt/microsoft/powershell/7/libmi.so'
linux-vdso.so.1 (0x00007ffff6fa8000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fc517d50000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007fc517d49000)
libpam.so.0 => /lib64/libpam.so.0 (0x00007fc517d37000)
libssl.so.1.0.0 => /opt/microsoft/powershell/7/libssl.so.1.0.0 (0x00007fc517cc5000)
libcrypto.so.1.0.0 => /opt/microsoft/powershell/7/libcrypto.so.1.0.0 (0x00007fc517a5a000)
libc.so.6 => /lib64/libc.so.6 (0x00007fc517890000)
/lib64/ld-linux-x86-64.so.2 (0x00007fc517f6b000)
libaudit.so.1 => /lib64/libaudit.so.1 (0x00007fc517862000)
libz.so.1 => /lib64/libz.so.1 (0x00007fc517848000)
libcap-ng.so.0 => /lib64/libcap-ng.so.0 (0x00007fc517840000)
# After (once you symlink libmi.so)
jborean:~/dev/$ ldd /opt/microsoft/powershell/7/libmi.so
linux-vdso.so.1 (0x00007fffcffec000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fee443ed000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007fee443e6000)
libpam.so.0 => /lib64/libpam.so.0 (0x00007fee443d4000)
libssl.so.1.1 => /lib64/libssl.so.1.1 (0x00007fee4433d000)
libcrypto.so.1.1 => /lib64/libcrypto.so.1.1 (0x00007fee44050000)
libc.so.6 => /lib64/libc.so.6 (0x00007fee43e86000)
/lib64/ld-linux-x86-64.so.2 (0x00007fee44707000)
libaudit.so.1 => /lib64/libaudit.so.1 (0x00007fee43e58000)
libz.so.1 => /lib64/libz.so.1 (0x00007fee43e3e000)
libcap-ng.so.0 => /lib64/libcap-ng.so.0 (0x00007fee43e36000)
์ด์ /lib64/libssl.so.1.1
๋ฐ /lib64/libcrypto.so.1.1
์ฐ๊ฒฐ๋์์์ ์ ์ ์์ต๋๋ค. 1.1.0์ด "๊ณต์์ ์ผ๋ก"์ฌ์ฉ ๊ฐ๋ฅํ ๋ PowerShell ํจํค์ง๊ฐ ์ฌ์ ํ OpenSSL 1.0.0 ๋ฒ์ฉ ํจํค์ง๋ฅผ ์ฌ์ฉํ๋ ์ด์ ๋ฅผ ๋ชจ๋ฅด๊ฒ ์ต๋๋ค. ๊ณผ๊ฑฐ์ ๋ฌธ์ ๊ฐ ์์์ ์๋ ์์ง๋ง ๊ธฐ๋ณธ ํ
์คํธ๊ฐ ์ ์๋ํฉ๋๋ค. ์ด ๋ชจ๋ ๊ฒ์ ๋งํ๋ฉด์ libmi์ ๊ฐ์ ๋ช ๊ฐ์ง ๋ฌธ์ ๊ฐ ์ฌ์ ํ ๋ฐ์ํ ๊ฒ์
๋๋ค.
-SessionOption (New-PSSessionOption -SkipCACheck -SkipCNCheck)
๋ฅผ ์ถ๊ฐํด์ผํฉ๋๋ค.๋ฐ๋น์ ๊ธฐ๋ฐ ๋ฐฐํฌํ์ ๊ฒฝ์ฐ, ํ๋ก์ธ์ค๋ ๊ทธ๋ฅ ํ ํ์๊ฐ ์ ์ฌํฉ๋๋ค libmi
์ผ๋ก๋ถํฐ .deb
๊ฐ ์๋๋ผ .rpm
. ๋ํ ๊ฒฝ๋ก๊ฐ ๋ค๋ฅผ ์ ์์์ ๋ช
์ฌํ์ญ์์ค. macOS ์ฌ์ฉ์๋ฅผ ์ํด ์ฌ์ฉ ๊ฐ๋ฅํ ๊ณต์ ํจํค์ง๊ฐ ์๊ธฐ ๋๋ฌธ์ ํญ์ ์ง์ omi๋ฅผ ๋น๋ํด์ผํ๋ค๋ ๊ฒ์ ์์์ต๋๋ค. ๋ด omi ํฌํฌ ์๋ ์ต์ macOS ๋ฒ์ ์์ ๋น๋ ํ ์์๋ ์ฝ๋ ๋ณ๊ฒฝ ์ฌํญ์ด ํฌํจ๋์ด ์์ต๋๋ค. ์ฌ๊ธฐ ์ macOS ์์ต๋๋ค .
@ jborean93 PowerShell-Docs
@iSazonov ๊ทธ๋ค์ ํ ๋จ๊ณ ๋ ๋์๊ฐ 1.1.0 OMI ๋ฆด๋ฆฌ์ค์ libmi
๋ฅผ ์ค์ ๋ก ๋ฒ๋ค๋ก ์ ๊ณต ํ ์ ์์ผ๋ฏ๋ก์ด ์ ์ฒด ํ๋ก์ธ์ค๋ Linux ๋ฐฐํฌํ์ ํ์ํ์ง ์์ต๋๋ค.
๋น Windows์์ WSMan์ด EOL์ด๋ผ๋ ๊ณตํต๋ ํฉ์๊ฐ ์๊ธฐ ๋๋ฌธ์ ๊ณต์์ ์ผ๋ก ์ด๊ฒ์ ๋ ์๋ํ๊ณ ์ถ๊ตฌํ๊ธฐ๋ฅผ ๊บผ๋ฆฝ๋๋ค. macOS ๋๋ ์ผ๋ฐ์ ์ธ GSSAPI ์ธ์ฆ ๋ฌธ์ ์์ ๋น๋ ํ ๋ ๋ช ๊ฐ์ง ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ๊ธฐ ์ํด ๊ณต์์ ์ผ๋ก OMI์ ๋ณ๊ฒฝ ์ฌํญ์ ๋์ ํ๋ ค๊ณ ํ ๋ ์ค์ ๋ก ๊ฐ์ฌํ์ง ์๋๋ค๊ณ ๋งํ์ต๋๋ค. PowerShell ํ์ ๋๊ตฐ๊ฐ๊ฐ์ด ๋ฌธ์ ๋ฅผ ์ถ๊ฐ๋ก ์กฐ์ฌ ํ ์ํฅ์ด์๋ ๊ฒฝ์ฐ macOS์ ๋ํด ์ํ ํ ์์ ์ ๊ณต์ ํ๊ณ PowerShell๊ณผ ํจ๊ป ๋ฒ๋ค๋ก ์ ๊ณต๋๋ libmi ๋ฒ์ ์ ์ ๋ฐ์ดํธํ๋ ๊ฒ์ ๊ฒํ ํ๊ฒ๋์ด ๊ธฐ์ฉ๋๋ค.
@ jborean93 ๋๋ ๊ทธ๋ค์ด OMI 1.6 https://github.com/PowerShell/MMI/blob/master/build.sh#L4 ๋ก ์ด๋ ํ ๊ฒ์ ๋ณด์๊ณ MMI 2.0์ด OpenSSL 1.1.0์ ์ง์ํ ๊ฒ์ผ๋ก ๊ธฐ๋ํฉ๋๋ค.
PSRP ํจํค์ง๋ ์ฌ์ ํ OMI 1.5์ ์์ง๋ง nuget ํจํค์ง ๋ฒ์ 1.4 https://github.com/PowerShell/psl-omi-provider/blob/master/omi.version-OMI ํจํค์ง ์ง์ 1.1.0์ผ๋ก ๋ณด์ด์ง๋ง ์ฌ์ ํ ์ฐ๊ฒฐ๋์ด ์์ต๋๋ค. OpenSSL 1.0.0์ผ๋ก-์? ๊ทธ๋ฆฌ๊ณ OpenSSL 1.1.0์ ์ฐ๊ฒฐ๋ ๋ ๋ง์ ์๋ก์ด nuget ํจํค์ง์ ๋ํ MSFT ์
๋ฐ์ดํธ๋ฅผ ์์ฒญํด์ผํฉ๋๋ค.
(OpenSSL 1.1.0์ ์ง์ํ๋ ์ฒซ ๋ฒ์งธ OMI๋ 1.4.0-6 https://github.com/microsoft/omi/releases/tag/v1.4.0-6์ ๋๋ค.)
GitHubGitHub์์ ๊ณ์ ์ ๋ง๋ค์ด PowerShell / MMI ๊ฐ๋ฐ์ ๊ธฐ์ฌํ์ธ์.
GitHubPSRP Linux ์ง์ ๋ผ์ด๋ธ๋ฌ๋ฆฌ. GitHub์์ ๊ณ์ ์ ๋ง๋ค์ด PowerShell / psl-omi-provider ๊ฐ๋ฐ์ ๊ธฐ์ฌํ์ธ์.
GitHubOpen Management Infrastructure v1.4.0-6 ๋ฆด๋ฆฌ์ค ์ ๋ณด์ด ๋ฆด๋ฆฌ์ค์์ ์์ ๋ ๋ฌธ์ ๋ฉ๋ชจ๋ฆฌ ๋์๊ฐ ์ ๋ฆฌ๋์์ต๋๋ค. ์๋ก์ด ๊ธฐ๋ฅ ๋๋ถ๋ถ์ OMI๋ฅผ ๋ฃจํธ๊ฐ ์๋ ์ฌ์ฉ์๋ก ์คํํฉ๋๋ค. ๋ณด์์์ ์ด์ ๋ก ์ฐ๋ฆฌ๋ ...
ํ๋ฃจ๊ฐ ๋ฆ์ด ์ง๋ ๋ด์ผ ๋ค์ ๋ณด๋๋กํ๊ฒ ์ต๋๋ค. ๊ทธ๋๋ ๋ช ๊ฐ์ง ์ง๋ฌธ์ด ์์ต๋๋ค.
MMI๋ ์ค์ ๋ก ๋ค์ดํฐ๋ธ WSMan ํด๋ผ์ด์ธํธ์ ์ฌ์ฉ๋ฉ๋๋ค. AFAIK ์ค์ WSMan ๋ค์ดํฐ๋ธ dll์ Unix์ libpsrpclient ๋ฅผ ํตํด ํธ์ถ๋ฉ๋๋ค. MMI๋ ์ค์ ๋ก OMI๋ฅผ ํตํด libmi
๋ฅผ ์ฌ์ฉํ์ง๋ง ๋ค์ํ CIM ๊ตฌ์ฑ ์์์์ ์ฌ์ฉ๋๋ Microsoft.Management.Infrastructure.dll
๋ฅผ ๋ง๋๋ ๋ฐ repo๊ฐ โโ์ฌ์ฉ๋๋ ๊ฒ์ฒ๋ผ ๋ณด์
๋๋ค. ์ด์ฉ๋ฉด ๊ทธ๋ค์ ์ฌ์ ํ โโ์ด๋ป๊ฒ ๋ ์ฐ๊ฒฐ๋์ด ์์ง๋ง Enter-PSSession
๊ฒฝ์ฐ libpsrpclient
์์ ๋ฉ์๋๋ฅผ ํธ์ถ ํ ๋ค์ libmi
์์ ๋ค์ํ ๋ฉ์๋๋ฅผ ํธ์ถํฉ๋๋ค. ๋น๋ ํ๋ก์ธ์ค๋ฅผ ์ดํด๋ณด๊ณ ๋น๋ ํ๋ก์ธ์ค ์ค์ ์ค์ ๋ก libmi๊ฐ ์์ง๋๋ ๋ฐฉ์์ ํ์ธํ๋ ๋ฐ ํ์ํ libmi ์ฉ ์ต์ ๋ฐ์ด๋๋ฆฌ๋ฅผ ํ๋ณดํ๋ ๊ฒ ๊ฐ์ต๋๋ค.
psl-omi-provider AFAIK๋ ์๋ฒ ํ๋ฌ๊ทธ์ธ์ด๋ฉฐ ํด๋ผ์ด์ธํธ ๊ธฐ๋ฐ ํ๋๊ณผ ๊ด๋ จ์ด ์์ต๋๋ค. ๋๋ ์ผํ๋ ๊ฒ์ด ์ข์ ๊ฒ์ด๋ผ๊ณ ํ์ ํ์ง๋ง ์์งํ ๋๋ ํด๋ผ์ด์ธํธ ์ธก ์ด์ด ์ด์ผ๊ธฐ์์ ๊ฐ์ฅ ์ค์ํ ๋ถ๋ถ์ด๋ผ๊ณ ์๊ฐํฉ๋๋ค.
๋น๋ ํ๋ก์ธ์ค๋ฅผ ์ดํด๋ณด๊ณ ๋น๋ ํ๋ก์ธ์ค ์ค์ libmi๊ฐ ์ค์ ๋ก ์์ง๋๋ ๋ฐฉ์์ ํ์ธํด์ผํฉ๋๋ค.
@PaulHigin PowerShell ๋ฐฐํฌ์์ libmi๋ฅผ ์ป๋ ๋ฐฉ๋ฒ์ ์ค๋ช ํด ์ฃผ์๊ฒ ์ต๋๊น? PSPR ํจํค์ง์์ ๊ฐ์ ธ์จ ๊ฒฝ์ฐ ํจํค์ง๋ฅผ ๋ ์๋ก์ด OMI ๋ฒ์ (1.5 ๋๋ 1.6์ผ๋ก)์ผ๋ก ์ ๋ฐ์ดํธ ํ ์ ์์ต๋๊น?
๋ ์ด์ WinRM / OMI๋ฅผ ์ง์ํ์ง ์์ต๋๋ค. ๊ทธ ์ด์ ์ค ์ผ๋ถ๋ OMI ์์ฒด๊ฐ ๋ ์ด์ ์ง์๋์ง ์๊ธฐ ๋๋ฌธ์ด๋ผ๊ณ ์๊ฐํฉ๋๋ค. @ TravisEz13์์ ๋ ๋ง์ ์ ๋ณด๋ฅผ ์ ๊ณต ํ ์ ์์ต๋๋ค.
๋ด ์ง๋ฌธ์ ์ด๋ฏธ ๋ถ์ผ์น๊ฐ ์๋ค๋ ์ฌ์ค์์ ๋น๋กฏ๋ฉ๋๋ค. MMI๋ ๋ช ๋ฌ ์ ์ ์ ๋ฒ์ ์ผ๋ก ์ด๋๋์์ง๋ง PSPR์ ๊ทธ๋ ์ง ์์์ผ๋ฉฐ ๋ ๋ค libmi๋ฅผ ์ฐธ์กฐํฉ๋๋ค. MSFT๊ฐ PSPR ํจํค์ง์ ๋ํ _minor_ ์ ๋ฐ์ดํธ๋ฅผ ๋ง๋ค๊ณ ๋ฌธ์ ์ ๋ํ ๋ง์ ์ง๋ฌธ์ ๋ซ์ ๊ฒ์ผ๋ก ๊ธฐ๋ํฉ๋๋ค.
@PaulHigin PowerShell ๋ฐฐํฌํ์์
libmi
๋ฅผ ์ป๋ ๋ฐฉ๋ฒ์ ์ค๋ช ํด ์ฃผ์๊ฒ ์ต๋๊น? PSPR ํจํค์ง์์ ๋์จ ๊ฒฝ์ฐ ํจํค์ง๋ฅผ ์ต์ OMI ๋ฒ์ (1.5 ๋๋ 1.6์ผ๋ก)์ผ๋ก ์ ๋ฐ์ดํธ ํ ์ ์์ต๋๊น?
์ด์ ๋ํด OMI ํ์ ์์ฒญํด์ผํ๋ฉฐ PowerShell์ ๋ณ๊ฒฝํ๊ฑฐ๋ ๋ฆด๋ฆฌ์คํ์ง ์์ ๊ฒ์ด๋ผ๊ณ ๋งํ์ต๋๋ค.
@ TravisEz13 https://github.com/PowerShell/psl-omi-provider/blob/master/omi.version ์์ OMI ๋ฒ์ ์ ๋ฐ์ดํธ์ ๋ํ ์ง๋ฌธ
GitHubPSRP Linux ์ง์ ๋ผ์ด๋ธ๋ฌ๋ฆฌ. GitHub์์ ๊ณ์ ์ ๋ง๋ค์ด PowerShell / psl-omi-provider ๊ฐ๋ฐ์ ๊ธฐ์ฌํ์ธ์.
@ TravisEz13 OMI ํ์ ๋ ์ด์ ๋ฆด๋ฆฌ์ค๋ฅผ ์์ฑํ์ง ์์ ์ ์์ง๋ง ๊ธฐ์กด ๋ฆด๋ฆฌ์ค ์ค ํ๋๋ฅผ ์ง์ ์ฌ์ฉํ์ง ์ด์ ๋ ๋ฌด์์ ๋๊น? ํ์ฌ MMI์ ๋ํด์ด ์์ ์ ์ํํ๋ ๊ฒ์ฒ๋ผ ๋ณด์ด๋ฏ๋ก WSMan ํด๋ผ์ด์ธํธ๊ฐ ๋ค๋ฅธ ์ด์ ๋ ๋ฌด์์ ๋๊น? ๋ถ๋ช ํ OpenSSL 1.1.x์ ํธํ๋๋ ์ต์ ๋ฆด๋ฆฌ์ค ์ค ํ๋๋ฅผ ์ฌ์ฉํ๊ณ ์ค๋๋๊ณ ์์ ํ์ง ์์ OpenSSL 1.0.x์ ๋ํ ์๊ตฌ ์ฌํญ์ ์ญ์ ํ ์ ์์ต๋๋ค.
์ด ์ ์ฒด ์ค์ ์ ๋ ์ด์ ์ฌ์ฉ๋์ง ์์ ์ ์์ง๋ง WSMan ์ฌ์ฉ์ ๋ํ ์ฌ์ฉ ์ฌ๋ก๊ฐ ์ฌ์ ํ ์์์ด ๋ถ๋ช ํฉ๋๋ค. Windows๊ฐ ์๋ ํ๋ซํผ์์ PowerShell์ ๋ ์ ์ฉํ๊ฒ ์ฌ์ฉํด๋ณด์ญ์์ค.
๋ถ๋ช ํ OpenSSL 1.1.x์ ํธํ๋๋ ์ต์ ๋ฆด๋ฆฌ์ค ์ค ํ๋๋ฅผ ์ฌ์ฉํ๊ณ ์ค๋๋๊ณ ์์ ํ์ง ์์ OpenSSL 1.0.x์ ๋ํ ์๊ตฌ ์ฌํญ์ ์ญ์ ํ ์ ์์ต๋๋ค.
@ jborean93 ์ด๊ฒ์ clear์ ๋ฐ๋์ ๋๋ค. OMI๋ ๊ทผ๋ณธ์ ์ผ๋ก ์์๋์์ต๋๋ค. 1.1๋ก ์ด๋ํ๋ฉด 1.0์ ์ฌ์ฉํ๋ ๋ฐฐํฌํ (segfault pwsh)์ด ์ค๋จ๋ฉ๋๋ค. ๋น ์คํํฐ์ ๋๋ค. OMI๋ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฌ๋ฐ๋ฅด๊ฒ๋ก๋ํ์ง ์์ segfault๋ฅผ ์ ๋ฐํ๋ ๊ทผ๋ณธ์ ์ธ ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ์ง ์์ต๋๋ค.
1.1๋ก ์ด๋ํ๋ฉด 1.0์ ์ฌ์ฉํ๋ ๋ฐฐํฌํ (segfault pwsh)์ด ์ค๋จ๋ฉ๋๋ค.
๊ทธ๋ ๋ค๋ฉด ์ค์ ๋ก OpenSSL 1.1๊ณผ ํจ๊ป ์ ๊ณต๋๋ ๋ฐฐํฌํ์๋ OpenSSL 1.1์ ๋ํด ์ปดํ์ผ ๋ libmi ๋ง ์ฌ์ฉํฉ๋๊น? ๋๋ ๋ ์ข์ ๋ฐฉ๋ฒ์ OpenSSL 1.1 ๋น๋๋ฅผ ๊ธฐ๋ณธ๊ฐ์ผ๋กํ๊ณ 1.1์ด์๋ ๊ฒฝ์ฐ ๊ธฐ์กด OpenSSL 1.0์ ์ฌ์ฉํ๋ ๊ฒ์ ๋๋ค. ์ต์ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ํ์ฉํ ์์๋ ์ต์ ๋ฐฐํฌํ ๋น๋๋ฅผ ๋ฐฉํดํด์ผํ๋ ์ด์ ๋ ๋ฌด์์ ๋๊น? PowerShell์์ ์ง์ํ๋ ๋ ์ค๋๋ ๋ฐฐํฌํ ์ค ์ผ๋ถ๋ ์ด๋ค ํํ ๋ ํํ๋ก ๋ OpenSSL ๋ฒ์ ์ ๋ชจ๋ ์ ๊ณตํฉ๋๋ค.
OMI๋ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฌ๋ฐ๋ฅด๊ฒ๋ก๋ํ์ง ์์ segfault๋ฅผ ์ ๋ฐํ๋ ๊ทผ๋ณธ์ ์ธ ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ์ง ์์ต๋๋ค.
๊ธฐ์ ์ ์ผ๋ก ๋ ๋ง์ ์์ ์ ์ํํ๊ณ ์ถ์ง ์๋ค๋ ๊ฒ์ ์์ ํ ์ดํดํ์ง๋ง ์ง์ ์์ ํ๊ณ PowerShell์ ์ํด ํน๋ณํ ์ปดํ์ผํ๋ ๊ฒ์ ๋ง์ ์๋ ์์ต๋๋ค.
๋ํ OpenSSL๊ณผ ๊ด๋ จ์ด์๋ ์๋ ค์ง ๋ฌธ์ ์ ๊ด๋ จ๋ seg ์ค๋ฅ ๋๋ ํ์ํ ๋ผ์ด๋ธ๋ฌ๋ฆฌ์์ด๋ก๋ํ๋ ค๊ณ ํ๋ฉด ์คํจ ํ ๊ฒ์ด๋ผ๋ ์ฃผ์์ด ์์ต๋๊น? libs๋ฅผ ์ฌ์ฉํ ์์๋ ๊ฒฝ์ฐ OpenSSL 1.0.x์ ํจ๊ป ์ ๊ณต๋์ง ์๋ ์ต์ ๋ฐฐํฌํ์ ์ด๋ฏธ ํด๋น ๋ฌธ์ ๊ฐ์๋ ๊ฒ์ ๋๋ค. ํจํค์ง๊ฐ ์ ๋ฐ์ดํธ๋๋ฉด ์ด์ ๋ฐฐํฌํ์ด ๋ฐฉํด ๋ฐ๋๋ค๋ ๊ฒ๊ณผ ๋์ผํ ๋ฐฉ์์ผ๋ก ์ต์ ๋ฐฐํฌํ์ด ๋ฐฉํด ๋ฐ์์ผํ๋ ์ด์ ๋ ๋ฌด์์ ๋๊น?
PowerShell ์๋น์๋ Windows ํธ์คํธ ์ธ๋ถ์์ ์ธ์ด์ ์ค์ํ ๊ตฌ์ฑ ์์๋ฅผ ์ฌ์ฉํ ์ ์๋ค๋ ์ฌ์ค์ ์๊ณ ๋งค์ฐ ์ค๋ง ์ค๋ฝ์ต๋๋ค. WSMan์ ํด๋ผ์ด์ธํธ๋ก ์ฌ์ฉํ ์ ์๊ธฐ ๋๋ฌธ์ Linux๊ฐ ์๋ ํธ์คํธ์์ ๊ธฐ์กด Windows ํธ์คํธ๋ฅผ ๊ด๋ฆฌ ํ ์์์๋ฟ๋ง ์๋๋ผ์ด ๋ฌธ์ ์ ์ ๋ชฉ์์ PowerShell์ ์ฌ์ฉํ์ฌ O365 ๋๋ Exchange Online๊ณผ ๊ฐ์ ์จ๋ผ์ธ ์๋น์ค๋ฅผ ๊ด๋ฆฌ ํ ์ โโ์๊ฒ๋ฉ๋๋ค. ์ด๋ฌํ ์๋น์ค๋ฅผ ๊ด๋ฆฌํ๊ธฐ ์ํด Windows๋ฅผ ์คํํ๋๋ก ๊ฐ์๋นํ๋ ๊ฒ์ PowerShell์ด โโ์ผ๋ฐ์ ์ผ๋ก ์ ๊ณตํ๋ ๊ต์ฐจ ํ๋ซํผ ์ง์์ ์ง๋ฉด ํด ์์ต๋๋ค. ๋๋ ๊ทธ๊ฒ์ด ๋ชจ๋ ๋ ์ด์ ์ฌ์ฉ๋์ง ์๋๋ค๋ ๊ฒ์ ์๊ณ ์์ง๋ง ๋์์ด ์์ผ๋ฉด ์ฌ๋๋ค์ด ๊ณ์ํด์ ๊ทธ๊ฒ์ ์๋ํ๊ณ ์๋ํ๊ฒํ๊ณ ๊ทธ๋ ์ง ์๋ค๋ ๊ฒ์ ์ข์ ๊ฐ์ ๋๋ ๊ฒ์ ๋๋ค. ๋๋ฅผ ์ ๋ง ์ง์ฆ๋๊ฒํ๋ ๊ฒ์ ์ค์ ๋ก ์๋ ํ ์ ์์ง๋ง PowerShell ํ์ด ์ค์ ๋ก ๊ทธ๋ ๊ฒํ๋ ค๋ ์๊ตฌ๊ฐ ๊ฑฐ์ ๋๋ ์ ํ ์๋ค๋ ๊ฒ์ ๋๋ค. ํ์ ํ์ฌ ๊ณ ์ฅ๋ ์ํ๋ก ์ ์งํ๊ณ ์ด๋ฌํ ์ํฉ์์ ์๋ํ์ง ์๋ ssh์ ๊ฐ์ ์ต์ ์ ์ก์ ์ฌ์ฉํ๋ ๊ฒ์ ๋ง์กฑํ๋ ๊ฒ ๊ฐ์ต๋๋ค.
์์งํ๊ฒ ๋งํด์ ๋ฏธ์ํฉ๋๋ค. ์ฌ๋ฌ๋ถ๊ณผ ํ์ด์ด ์ธ์ด๋ก ๋ง๋ ์๊ฐ๊ณผ ๋ ธ๋ ฅ์ ์ ๋ง ๊ฐ์ฌ๋๋ฆฝ๋๋ค. ์ด๊ฒ์ ์ต์ข ์ฌ์ฉ์๊ฐ ๊ธฐ๋ณธ ์ค์ ์ ๋ ์ ์ฉํ๊ฒ ์ฌ์ฉํ๊ธฐ์ํ ๋ง์ง๋ง ์๋๊ฐ ๋ ๊ฒ์ ๋๋ค. ํฉ์๊ฐ ์ฌ์ ํ ์๋์ค ์ธ ๊ฒฝ์ฐ ๋ค๋ฅธ ์ฌ๋๋ค์ด ์ํ ๊ฒฝ์ฐ ์์ ๋กญ๊ฒ ๋ฐ๋ฅผ ์์๋ ์์ฒด ํด๊ฒฐ ๋ฐฉ๋ฒ์ ๊ณ์ ์ฌ์ฉํ ๊ฒ์ ๋๋ค.
@ jborean93 ๊ทํ์ ์ง๋ฌธ์ ์ด์ ์์ด ์ค๋ ๋์์ ์ง๋ฌธ ๋ฐ ๋ต๋ณ๋์์ต๋๋ค.
https://github.com/MicrosoftDocs/PowerShell-Docs/issues/6491 ์ ์ ์ถํ์ฌ PowerShell์์ OMI ( libmi
)๋ฅผ ์ง์ํ ์ ์์์ ๋ฌธ์ํํ์ต๋๋ค.
Linux / macOS์์ OMI๋ฅผ ์ฌ์ฉํ๋ ๋ฐ ์ฌ์ ํ ๊ด์ฌ์ด์๋ ๋ชจ๋ ์ฌ๋์์ํ ์ฐธ๊ณ ์๋ฃ์ ๋๋ค. PowerShell์์ ์ ๋๋ก ์๋ํ๋๋ก ๋ค์ํ ์์ ์ฌํญ์ด ํฌํจ ๋ OMI ์ ์ฅ์์ ํฌํฌ๋ฅผ ๋ฐฉ๊ธ ์ด์์ต๋๋ค. ์ํ๋ ๊ฒฝ์ฐ ๋๋ฌ๋ณด๊ณ ๋ ์ ์์ต๋๋ค. ๋ํ Linux ์์
์ด๋ Microsoft ๋๋ PowerShell / OMI ํ๊ณผ ์ด๋ค ์ ์ผ๋ก๋ ๊ด๋ จ์ด ์์ต๋๋ค. ๋ณ๊ฒฝ ์ฌํญ์ ๋ณธ์ธ์ ๊ฒ์ด๋ฉฐ ์ง์ ๋ณด์ฅ์ ๋ํ ๋ณด์ฆ์ด ์์ต๋๋ค. ํฌํฌ์ ์ฌ์ ํ ๋ฌธ์ ๊ฐ ์๋ค๋ฉด ๊ฑฐ๊ธฐ์์ ์ด๋ฆฐ ๋ชจ๋ ๋ฌธ์ ๋ฅผ ๋๊ธฐ ์ํด ์ต์ ์ ๋คํ ๊ฒ์ ๋๋ค.
์ค๋์ ์ฒ์์ผ๋ก PowerShell์ ์ฌ์ฉํ๊ณ ์ด๋ฏธ ์ค๋งํ์ต๋๋ค.
3 ๋
๋ง์ ๊ณ ์น์ง ์๊ณ ...
PowerShell 7.0.3
Warning: [email protected] 1.1.1g is already installed and up-to-date
To reinstall 1.1.1g, run `brew reinstall [email protected]`
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
New-PSSession :์ด ๋งค๊ฐ ๋ณ์ ์งํฉ์๋ WSMan์ด ํ์ํ๋ฉฐ ์ง์๋๋ WSMan ํด๋ผ์ด์ธํธ ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ฐพ์ ์ ์์ต๋๋ค. WSMan์ด ์ค์น๋์ง ์์๊ฑฐ๋์ด ์์คํ ์ ์ฌ์ฉํ ์ ์์ต๋๋ค.
PowerShell ์ข ์์ฑ์ด ๋ ์ด์ ์ฌ์ฉ๋์ง ์์ง๋ง Exchange 365์์ DKIM์ ๊ตฌ์ฑํ๋ ๋ฐ์ด ์ข ์์ฑ์ด ํ์ํ๋ค๊ณ ๋งํ๋ ๊ฒฝ์ฐ ์์๋ ์ํํธ์จ์ด๋ฅผ ์ฌ์ฉํ๋ ๋ค์ ๋ชจ๋ ๋ฌธ์๋ฅผ ํฌํจํ์ฌ Exchange 365๊ฐ ๋ ์ด์ ์ฌ์ฉ๋์ง ์๋๋ค๋ ์๋ฏธ์ ๋๋ค.
Exchange์ DKIM ํค๋ฅผ ๊ฐ์ ธ ์ค๊ธฐ ์ํด Windows ์ปดํจํฐ๋ฅผ ๊ตฌ์ ํด์ผํฉ๋๊น?
3 ๋ ์ ์ฌ์ ํ โโ๋ฒ๊ทธ์ด๋ฉฐ Microsoft๊ฐ ์๋ฃจ์ ์ ์ ๊ณตํ๊ณ ์ข ์์ฑ์ ์ ๋ฐ์ดํธํ๋ ๋์ Microsoft๊ฐ ์๋ ์ฌ๋๋ค์ ํฌํฌ์ ํด๊ฒฐ ๋ฐฉ๋ฒ์ ์ ๊ณตํด์ผํฉ๋๋ค.
๋ฌด๋ฅ๋ ฅ์ ์ฆ๊ฑฐ.
๊ฐ์ฅ ์ ์ฉํ ๋๊ธ
์๋ ํ์ธ์ ์ฌ๋ฌ๋ถ,
openssl ๋ฒ์ ๊ณผ ๊ด๋ จํ์ฌ brew๊ฐ ver 1.02๋ฅผ ์ฌ์ฉํ๋๋ก ๊ฐ์ํ์ผ๋ฉฐ ์ด๊ฒ์ pwsh O365 ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ์ต๋๋ค. ๋ด๊ฐ ์คํ ํ ๋ช ๋ น์ ...
brew uninstall openssl;
brew uninstall openssl; (์๋ฌด๊ฒ๋ ๋จ์ ์์ง ์๋๋กํ๊ธฐ ์ํด)
์์กฐ ์ค์น https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb
ํฌ๋ ๋ง : @kensoh
๊ฐ์ฌ.