Active Directory operation failed… the object already exists” when installing Exchange Server

Mô tả lỗi

Exchange server 2019 /PrepareAD or installing Cumulative Updates [ CUxx ] fail with the error,

while running Organization Preparation

Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareAD

The following error was generated when “$error.Clear();
install-AdministrativeGroup -DomainController $RoleDomainController

” was run: “Active Directory operation failed on Servername.domain.com. The object

‘CN=Folder Hierarchies, CN=Exchange Administrative Group (FYDIBOHF23SPDLT),

CN=Administrative Groups, CN=Exchange Organization,CN=Microsoft Exchange,

CN=Services,CN=Configuration, DC=Domain,DC=Com’ already exists.”

The Exchange Server setup operation didn’t complete. More details can be found in ExchangeSetup.log

located in the <SystemDrive>:\ExchangeSetupLogs folder. Exchange Server setup encountered an error.

Root Case

This error occur when the “CN= Public Folders” container underneath ‘CN=Folder Hierarchies has been

deleted from Active Directory. use the ADSI Edit, or a similar tool (LDP), to determine whether the Public

Folders container exists. The Public folder object can be found at:

CN=Configuration,CN=Services,CN=Microsoft Exchange,CN=Your Exchange Organization,

CN=Administrative Groups,CN=Administrative group,CN=Exchange Administrative Group

(FYDIBOHF23SPDLT), CN=Folder Hierarchies

Thủ tục xử lý

The workaround is to manually create a new msExchPFTree object in the Folder Hierarchy and set the msExchPFTreeType value to 1.  Here’s how to do that:

  • Run ADSIEdit.msc on a domain server with the AD Directory Services Tools (RSAT-ADDS) installed.  Your Exchange 2013 server should do fine.
  • Expand the following path:
    • Configuration [<domainController>.contoso.com]
    • CN=Configuration,DC=contoso,DC=com
    • CN=Services
    • CN=Microsoft Exchange
    • CN=<OrganizationName>
    • CN=Administrative Groups
    • CN=Exchange Administrative Group (FYDIBOHF23SPDLT)
    • CN=Folder Hierarchies
  • Right-click Folder Hierarchies and select New Object.
  • Select the msExchPFTree class object and click Next.
  • Enter any value for the cn (Common Name) value, such as PF.
  • Right-click the newly created msExchPFTree object and select Properties.
  • On the Attribute Editor tab, click msExchPFTreeType, and then click Edit.
  • In the Value box type 1, and then click OK two times.
  • Exit the ADSI Edit tool.

Good luck

Source: 1. Exchange Server 2013 /PrepareAd or Cumultive update installation fails. | Microsoft Learn

Exchange Server CU14 2019

Nghỉ Tết cũng cập nhật thông tin cho ae:

Ngày 13/02/2024 MS đang công bố tính khả dụng của Bản cập nhật tích lũy H1 2024 (CU) cho Exchange Server 2019 (hay còn gọi là CU14). CU14 bao gồm các bản sửa lỗi cho các sự cố được khách hàng báo cáo, thay đổi bảo mật và tất cả các Bản cập nhật bảo mật (SU) đã phát hành trước đó.

Cài đặt Bản cập nhật tích lũy ngay lập tức để giải quyết các vấn đề được tìm thấy trong Exchange Server 2019 và bảo vệ môi trường của bạn.

1. Với Exchange 2019 CU14 khi cài mặt định enable Extended Protection hoặc chúng ta không muốn bật thêm tham số /DoNotEnableEP or /DoNotEnableEPFEEWS trong quá trình setup

2. Hỗ trợ .NET Framework 4.8.1 trên Windows Server 2022

3. TLS 1.3 dự kiến EX2019CU15

4. Lưu ý sau phiên bản sẽ không hỗ trợ bản vá bảo mật trong tương lai: EX2019CU12, EX2016CU22.

CVE dưới đây được giải quyết bằng Bản cập nhật tích lũy:

🛡️ CVE-2024-21410 – Microsoft Exchange Server nâng cao lỗ hổng đặc quyền

Xin lưu ý rằng CVE-2024-21410 cũng áp dụng cho Exchange Server 2016. Đối với các máy chủ Exchange 2016, hãy làm theo Cấu hình Bảo vệ Mở rộng Windows trong Máy chủ Trao đổi nếu Bảo vệ Mở rộng chưa được bật trong tổ chức của bạn

Lưu ý rằng Exchange Server 2013 KHÔNG được hỗ trợ và bạn phải nâng cấp lên Exchange Server 2019 hoặc Exchange Online càng sớm càng tốt

Lưu ý rằng Exchange Server 2013 KHÔNG được hỗ trợ và bạn phải nâng cấp lên Exchange Server 2019 hoặc Exchange Online càng sớm càng tốt.

P/s: Khuyến cáo Quản trị viên cần triển khai cập nhật trong môi trường Lab trước khi thực hiện triển khai update trong môi trường Production

#jsisen

#phuongit

#exchangeserver

#exchangeserver24H1

#exchangeserver2019CU14

#exchangecu

#sharing

Thông tin bản cập nhật bảo mật(SU) Tháng 11/2023 Exchange Server

Ngày 14/11/2023 Microsoft đã phát hành Bản cập nhật bảo mật(SU) cho các lỗ hổng được tìm thấy:

  • Exchange Server 2016 CU22, CU23 (KB5032147)
  • Exchange Server 2019 CU13 (KB5032146)

Giải Quyết

1/ Certificate signing of PowerShell serialization payload được bật mặt định.
2/ Fix Lỗi hổng Exchange Server 2016 & Exchange Server 2019 :
CVE-2023-36439 – Microsoft Exchange Server Remote Code Execution Vulnerability
CVE-2023-36050 – Microsoft Exchange Server Spoofing Vulnerability
CVE-2023-36039 – Microsoft Exchange Server Spoofing Vulnerability
CVE-2023-36035 – Microsoft Exchange Server Spoofing Vulnerability
3/ Fix lỗi Exchange Server 2019
Lỗi khi chạy lệnh RBAC trên CMD liên quan Serialization payload signing
Unable to migrate mailbox as communication error parameter exception occurs
4/ Fix lỗi Exchange Server 2016
InvalidResponseException when you try to run Export-UMPrompt


Một số lỗi sau khi vá bản SU tháng 11 này:


Một số lệnh ghép sẽ bị lỗi trên máy remote có công cụ Management Tools nhưng không phải MBX như:

Get-MailboxDatabase | Get-MailboxStatistics

Get-MailboxDatabase | Get-Mailbox

Get-MailboxDatabase | Test-ExchangeSearch

Get-Mailbox | Get-CalendarDiagnosticLog

Get-PublicFolderClientPermission | Remove-PublicFolderClientPermission


Chạy lệnh RedistributeActiveDatabases.ps1 or StartDagServerMaintenance.ps1 trong môi trường DAG sẽ bị lỗi, MS hứa chưa có bản vá 🙂 chờ bản sau.
Có thể gây lỗi chạy lệnh EMS trong Exchange Powershell.

Khuyến Nghị


Nên Test kỹ lab trước khi chạy môi trường Production cân nhắc giữa bảo mật và an toàn.
Hiện tại chưa khuyến cáo cập nhật với các lỗi trên. Vì theo ghi nhận nhiều ae bị lỗi :).
Nếu bắt buộc cập nhật hãy đảm bảo rằng Exchange Auth Certificate hợp lệ trước khi cài đặt bản cập nhật bảo mật (SU). Bạn có thể sử dụng tập lệnh MonitorExchangeAuthCertificate.ps1 để thực hiện kiểm tra nhanh.

Cài đặt bản vá

Lưu ý rằng Exchange Server 2013 KHÔNG được hỗ trợ và bạn phải nâng cấp lên Exchange Server 2019 hoặc Exchange Online càng sớm càng tốt!

Tham khảo link comment
https://techcommunity.microsoft.com/t5/exchange-team-blog/released-november-2023-exchange-server-security-updates/ba-p/3980209
https://aka.ms/MonitorExchangeAuthCertificate

Description of the security update for Microsoft Exchange Server 2016: November 14, 2023 (KB5032147) – Microsoft Support

Description of the security update for Microsoft Exchange Server 2019 and 2016: November 14, 2023 (KB5032146) – Microsoft Support

jsisen

viettechgroupvn

phuongit

exchangeserver

MỘT SỐ BIỆN PHÁP NGĂN NGỪA VÀ CHỐNG SPAM EMAIL SERVER EXCHANGE

MỘT SỐ BIỆN PHÁP NGĂN NGỪA HỆ THỐNG CHỐNG SPAM EMAIL SERVER EXCHANGE

Hệ thống Email Server Exchange Server Nhà làm (On-Premises) Để ngăn chặn spam trên máy chủ Exchange Server, bạn có thể thực hiện một số biện pháp phòng ngừa và bảo mật. Dưới đây là một số gợi ý mà Phương Nguyễn chia sẻ từ kinh nghiệm thực tế nhé:

Sử dụng các bộ lọc chống spam:

  • Kích hoạt và cấu hình các tính năng chống spam tích hợp của Exchange. Bật Antispam nội tại của Exchange sẵn có cũng quét khá ok.
  • Cấu hình thêm 1 số tính năng của Antispam protection: Content filter, Sender Filter, sender id, Recipient, attachment,…
  • Nếu có tiền thì nên xem xét việc triển khai các giải pháp bộ lọc chống spam bên ngoài phần cứng hay appliance phần mềm: SpamAssassin, Barracuda, hoặc Proofpoint, FortiMail,
  • Giải pháp mail gateway đối tác thứ 3:
    • Microsoft Exchange Server 2019.
    • Paubox.
    • Mimecast Email Security with Targeted Threat Protection.
    • Cisco Secure Email Threat Defense.
    • FortiMail.
    • Symantec Email Security.Cloud.
    • Cloudflare Area 1 Security.
    • Barracuda Email Security Gateway.

Cập nhật phần mềm và bảo mật:

  • Đảm bảo bạn đang sử dụng phiên bản Exchange Server mới nhất và đã áp dụng tất cả các bản vá bảo mật (CU, SU), bằng cách theo dõi thường xuyên trên trang Microsoft Exchange check bản vá.
  • Theo dõi và thường xuyên cập nhật phần mềm chống virus và bảo mật trên máy chủ chạy Exchange.

Cấu hình xác thực người gửi bằng cách cấu hình bảo mật DNS cho Email:

  • Kích hoạt các cơ chế xác thực như SPF (Sender Policy Framework), DKIM (DomainKeys Identified Mail), và DMARC (Domain-based Message Authentication, Reporting, and Conformance), IP resever (PTR)
  • Xác minh và thiết lập các quy tắc xác thực người gửi trong các bộ lọc spam.
  • Nếu tự làm email không có email gateway nên tìm IP sạch tí.

Quản lý danh sách đen (blacklist) và trắng (whitelist):

  • Thiết lập các quy tắc để tự động thêm địa chỉ email vào danh sách đen hoặc trắng dựa trên các tiêu chí cụ thể.
  • Kiểm tra định kỳ và cập nhật danh sách đen và trắng của bạn.
  • Ngoài ra 1 số hãng dbspam hoặc trang Spam phải mua thêm gở spam blocklist hoặc add ip mail server vào Whitelist (nhất là ông UCEPROTECT phải mua gở), nếu trang spam free thì email gở spam,
  • Thường xuyên dùng các công cụ kiểm tra xem IP có spam không nhé: Mxtoolbox, dnschecker, Testtls, spamhaus, Barracuda, Spamcop,..Dĩ nhiên phổ biến thôi còn nhiều các bạn có thể tìm thêm.

Quản lý và đào tạo người dùng cuối:

  • Các giải pháp công nghệ tốt đến đâu thì con người vận hành và sử dụng cũng là users nên yếu tố con người cũng quyết định thành công trong việc góp phần ngăn ngừa.
  • Cung cấp hướng dẫn và đào tạo người dùng về cách nhận biết và xử lý email spam, fishing email.
  • Khuyến khích họ không mở các đính kèm từ nguồn không rõ, click link nặc danh dẫn tới spam hoặc mã hoá dữ liệu.

Kiểm soát đồng bộ hóa (synchronization):

  • Hạn chế quá trình đồng bộ hóa với các danh bạ không tin cậy và ngăn chặn các kết nối không mong muốn từ các nguồn không rõ.

Giám sát log và thống kê:

  • Thường xuyên theo dõi các log và bản thống kê để phát hiện các hoạt động bất thường từ Log của Exchange transport, Ngoài các công cụ sẵn có của Exchange Server: Message tracking. Có thể dùng ManageEngine Exchange Reporter Plus khá ok dĩ nhiên phải tốn phí 😊
  • Thực hiện giám sát thời gian thực để nhanh chóng phát hiện và xử lý các vấn đề liên quan đến spam.

Sử dụng các giải pháp chống thấp hóa (greylisting):

  • Cài đặt các giải pháp chống thấp hóa để tạm thời chặn các email từ nguồn chưa được xác minh, và chỉ chấp nhận chúng khi được gửi lại từ cùng một nguồn. Này gần giống mục 3, dùng thêm các giải pháp tốn tiền

Rules Transport Exchange Server

Có thể tận dụng tạo các bộ lộc rules sẵn có của Exchange vẫn có khả năng ngănn chặn được nhiều đó, Mình nghỉ bộ công cụ này khá mạnh mọi người cần khai thác triệt để vì miễn phí mà có sẵn tận dụng có gì sài nấy trước khi đầu tư.

Lời Kết cho bài post

Bảo mật email là câu chuyện muôn thuở và nhiều tầng nhiều lớp, dĩ nhiên tuỳ thuộc vào nhu cầu và ngân sách doanh nghiệp nếu lên Cloud Email Online (Google Workspace, MS365-Microsoft Defender for Office 365 công nghệ mới XDR..) thì khá tốt rồi.

Bài post này chỉ đề cập đến giải pháp email Server Exchange nhà làm (On-Premise). Chúng ta đi từ trong ra ngoài theo các tầng thì có thể gôm lại các cách phòng chống spam cho Email như sau:

  • Tầng 1: Nội tại email Exchange Server có Antispam and antimalware sẵn có free, dĩ nhiên phải cấu hình và bật lên (Content filter, Sender, IP reputation,..).
  • Tầng 2: Rules transport Exchange có sẵn free chỉ tốn cơm suy nghĩ, spam đâu block đó
  • Tầng 3: tầng cài thêm phần mềm thứ ba nếu không nhiều tiền mua phần cứng: Antispam của ESET Mail Security, Symantec tích họp email security, McAFee,..
  • Tầng 4 tường lửa nếu có sẵn: Forgiate mua tính năng hoặc sài hẵn phần cứng mail gateway như của Baracuda, Sophos, Fortimail, hoặc đẩy thẳng mail relay Cloud Online: Microsoft, GG, Amazon SES, SendinBlue, DNSexit,..Nhiều lắm mà tốn tiền 😊

..

Lưu ý rằng không có biện pháp nào là hoàn toàn hiệu quả 100% trong việc ngăn chặn spam, vì vậy việc kết hợp nhiều biện pháp cùng một lúc là quan trọng.

Bài Post mang tính chất chủ quan tham khảo va chắc lọc từ kinh nghiệm cá nhân, anh em nào có khác hãy comment để thảo luận nhé.

Phương Nguyễn

HƯỚNG DẪN SETUP EXCHANGE 2019 ON WINDOWS SERVER 2019 CORE STANDARD

Microsoft_Exchange_(2019-present).svg

HƯỚNG DẪN SETUP EXCHANGE 2019 ON WINDOWS SERVER 2019 CORE STANDARD

Mô hình

D:\DOCUMENTS\EXCHANGE2019\SoDo-DAG 2019.jpg

Lab

ServerName

IP Address

SM

GW

DNS

Roles

DC2019-01

10.10.11.1

24

10.10.11.254

10.10.11.1

Domain Controller 2019

EX2019-01

10.10.11.3

24

10.10.11.254

10.10.11.1

Exchange 2019

Tài nguyên

ServerName

RAM

CPU

HDD

VMLSRVAD19-01

4G

1

127G

EX19

10G

2

127G

Cài đặt WS server 2019 core

Xem tài liệu tạo máy ảo tại đây 2018-11-05-HUONG DAN TAO VM TREN HYPER-V ON WINDOWS SERVER 2016.pdf

Chuẩn bị Domain controller 2019

Task Description

Screenshot

Logon

Change password

Change thành công

 

Cấu hình

Scconfig

Cấu hình tên máy tính=> 2=>DC2019-01

Cấu hình tên máy tính=> 2=>DC2019-01

Khởi động lại DC2019-01

CẤU HÌNH NETWORKING

Add thêm Card net10

Add thêm card mạng

Chọn Tagg VLAN 11

Cấu hình IP

NET11

10.10.11.1

  

Rename

Rename-Computer -ComputerName <new_name>

New-NetIPAddress -InterfaceIndex 6 -IPAddress 192.168.12.123 -PrefixLength 24 -DefaultGateway 192.168.12.100

Enable để copy file từ host vật lý vào trong máy ảo

Enable-VMIntegrationService -name Guest* -VMName Server2019 -Passthru

Copy-VMFile “DC2019-01” -SourcePath “C:\Users\Administrator.VFC\WindowsAdminCenter1809.msi” -DestinationPath “C:\temp\ WindowsAdminCenter1809.msi” -CreateFullPath -FileSource Host

msiexec /i C:\temp\WindowsAdminCenter1804.msi /qn /L*v log.txt SME_PORT=443 SSL_CERTIFICATE_OPTION=generate

Đăng nhập nhé

Có thể cài SSH (https://github.com/PowerShell/Win32-OpenSSH/releases )

Install-Module -Name Posh-SSH

Nâng cấp DC 2019 nhé

Using PowerShell

PowerShell Command to start creating Domain Controller

Get-WindowsFeature AD-Domain-Service | Install-WindowsFeature

Import-Module ADDSDeplyoment

Install-ADDSForest

Install-ADDSDomainController -Credential (Get-Credential) `

-NoGlobalCatalog:$false `

-CreateDnsDelegation:$false `

-CriticalReplicationOnly:$false `

-DatabasePath “C:\Windows\NTDS” `

-DomainName ‘nvp.info’ `

-InstallDns:$true `

-LogPath “C:\Windows\NTDS” `

-NoRebootOnCompletion:$false `

-SiteName “Default-First-Site-Name” `

-SysvolPath “C:\Windows\SYSVOL” `

-Force:$true

2018-03-22 08_35_22-RDCB01 on HYPER - Virtual Machine Connection.png

Reboot

Nâng cấp thành công

New-ADUser –Name “Helpdesk” –GivenName Help –Surname Desk –SamAccountName Helpdesk –UserPrincipalName Helpdesk@nvp.info

Set-ADAccountPassword ‘CN=Helpdesk,CN=users,DC=nvp,DC=info’ -Reset -NewPassword (ConvertTo-SecureString -AsPlainText “Test@123” -Force)

Get-ADUser Helpdesk

Enable the AD user

Enable-ADAccount -Identity Helpdesk

Add the user to Domain Admins group  

Add-AdGroupMember ‘Domain Admins’ Helpdesk

CÀI ĐẶT WINDOWS SERVER CORE EXCHANGE 2019

Tạo máy ảo tương tự như trên

Chỉ phần setup nhé

Đặt Tên : EX2019-01

Kiểm tra setup ngày giờ Get-Timezone

Timedate.cpl

Đặt IP

New-NetIPAddress -InterfaceIndex 10 -IPAddress 10.10.11.2 -PrefixLength 24 -DefaultGateway 10.10.11.254

Configure a DNS Server

Set-DNSClientServerAddress -InterfaceIndex 10 -ServerAddress “10.10.11.1”

Enable Remote Desktop:

cscript C:\Windows\System32\Scregedit.wsf /ar 0

Hoặc sài Sconfig đặt nhé

Update

Join Domain nvp.info

Add-Computer -DomainName nvp.info -DomainCredential nvp\administrator

Cài đặt Windows Admin Center

Copy từ Host vào VM
Copy-VMFile “EX2019-01” -SourcePath “C:\Users\Administrator.VFC\WindowsAdminCenter1809.msi” -DestinationPath “C:\temp\WindowsAdminCenter1809.msi” -CreateFullPath -FileSource Host

Windows features

Use the following PowerShell command to install the OS component required for Microsoft UCMA 4.0 and the OS component required for Active Directory Preparation.

Install-WindowsFeature Server-Media-Foundation, RSAT-ADDS

Download các phần mềm cần thiết

Copy source vào Windows Server Core 2019 Exchange:

Có 2 cách 1:

  1. Copy từ host vật lý

Logon máy ảo tạo cây thư mục

C:\mkdir Exchange2019

Vào Host Hyper-V chạy lệnh

Copy-VMFile “EX2019-01” -SourcePath “D:\VFC Resource\Exchange2019\NDP471-KB4033342-x86-x64-AllOS-ENU.exe” -DestinationPath “C:\Exchange2019\NDP471-KB4033342-x86-x64-AllOS-ENU.exe” -CreateFullPath -FileSource Host

Copy-VMFile “EX2019-01” -SourcePath “D:\VFC Resource\Exchange2019\SW_DVD9_Exchange_Svr_2019_MultiLang_Std_Ent_.iso_MLF_X21-88195.ISO” -DestinationPath “C:\Exchange2019\SW_DVD9_Exchange_Svr_2019_MultiLang_Std_Ent_.iso_MLF_X21-88195.ISO” -CreateFullPath -FileSource Host

Copy-VMFile “EX2019-01” -SourcePath “D:\VFC Resource\Exchange2019\vcredist_x64.exe” -DestinationPath “C:\Exchange2019\vcredist_x64.exe” -CreateFullPath -FileSource Host

Copy-VMFile “EX2019-01” -SourcePath “D:\VFC Resource\Exchange2019\UcmaRuntimeSetup4.exe” -DestinationPath “C:\Exchange2019\UcmaRuntimeSetup4.exe” -CreateFullPath -FileSource Host

Copy nhiều máy ảo

https://cdn.ttgtmedia.com/rms/editorial/sSV_PowerShell_script_011818.png

Kiểm tra lại máy Exchange 2019 nhé

  1. Dùng Windows Admin Center

Vào https://ipexchange để upload nhé. vào file=>update file nhé

Chọn vào Upload nhé để đưa source lên nhé

Cài đặt thư viện

Cài đặt Install Visual C++ 2013 Redistributable

Tại CMD gỏ lệnh:

Install UCMA (Microsoft Unified Communications Managed API 4.0)

UCMA có thể download trực tiếp hoặc có sẵn trong đĩa ISO nhé tốt nhất download luôn cho roài. E:\Exchange2019\EX…\UCMARedist

Mount disk

The UCMA installable is present on the Exchange Server 2019 media itself. Use the following PowerShell command to mount the Exchange Server media:

Mount-DiskImage C:\Exchange2019\SW_DVD9_Exchange_Svr_2019_MultiLang_Std_Ent_.iso_MLF_X21-88195.ISO

The UCMA installable is located under the “UCMARedist” folder on the Exchange Server 2019 .ISO. Start the UCMA installation:

CD E:\

CD UCMARedist

Cài Install .Net 4.7.1

Kiểm tra xem cài chưa

Regedt32 chưa cài nhé

If you are not on .Net version 4.7.1 already, use the following command to install the .Net 4.7.1 (not required on Windows Server 2019 Server Core

.\NDP471-KB4033342-x86-x64-AllOS-ENU.exe /q /log c:\temp\ndp.log

Vì windows Server 2019 đã tích hợp sẵn 4.7.1

Restart-Computer –Force

CÀI ĐẶT EXCHANGE 2019 INSTALLATION

Sau khi reboot logon domain administrator

Start powershell gỏ lệnh để mount disk exchange 2019

Mount-DiskImage C:\Exchange2019\SW_DVD9_Exchange_Svr_2019_MultiLang_Std_Ent_.iso_MLF_X21-88195.ISO

CD e:

Gỏ lệnh:

E:\Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareSchema

E:\Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareAD /OrganizationName:”NVP”

E:\Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareAllDomains

E:\Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareDomain

3 Lệnh trên có thể gôm lại 1 lệnh bên dưới nhé

.\Setup.exe /Mode:Install /Roles:Mailbox /IAcceptExchangeServerLicenseTerms /InstallWindowsComponents

.\Setup.exe /m:install /roles:m /IAcceptExchangeServerLicenseTerms /OrganizationName:NVP /InstallWindowsComponents

Chờ hơi lâu 14:23

16:00

16:24

17:20

Nếu cài trên Windows Server 2019 Desktop GUI thì có giao diện nhé

Tiến hành reboot lại nhé

Logon vào giao diện nhé

Start web trên local server core hơi khó nhe phải cài thêm feature. Tuy nhiên Server Core không khả năng cài GUI nhé

Cài phần mềm chrome nhé

“C:\Program Files (x86)\Google\Chrome\Application\Chrome.exe”

Có thể quản lý bằng công cụ Explorer++ nhé

Load Exchange management Shell nhé

Gỏ lệnh LaunchEMS 

https://localhost/ecp/?ExchClientVer=15

Đúng là thật khó để start web giao diện trên local host vì đang bị xung đột với windows Admin Center

Đành tháo cái admin center ra vì trùng 443

exchange 2019

Cấu hình DNS trên Domain Controller nữa

Có thể quản lý DC trên administrator tools nhé

Join xong cài administrator tools

Remote IIS để quản lý IIS Exchange 2019 từ máy chủ khác nhé.

netsh advfirewall firewall add rule name=”IIS Remote Management” dir=in action=allow service=WMSVC

Như vậy là phương nguyễn đã hướng dẫn setup thành công cách cài đặt Exchange Server 2019 trên Windows Server Core, Còn việc cấu hình thì tương tự nhé. Chúng ta mốc vào web để quản trị

Chúc các bạn thành công

Phương Nguyễn Viết

Microsoft Outlook Zero-Day Vulnerability- Elevation of Privilege Vulnerability CVE-2023-23397

Microsoft Outlook Zero-Day Vulnerability- Elevation of Privilege Vulnerability CVE-2023-23397

Tóm tắt:

Microsoft giải thích: CVE-2023-23397 là một lỗ hổng EoP nghiêm trọng trong Microsoft Outlook, được kích hoạt khi kẻ tấn công gửi thư có thuộc tính MAPI mở rộng với đường dẫn UNC đến chia sẻ SMB (TCP 445) trên máy chủ do tác nhân đe dọa kiểm soát. Không cần tương tác người dùng,”

Cơ chế

Kẻ tấn công đã khai thác thành công lỗ hổng này có thể truy cập hàm băm Net-NTLMv2 của người dùng, có thể được sử dụng làm cơ sở cho một cuộc tấn công Chuyển tiếp NTLM chống lại một dịch vụ khác để xác thực là người dùng.

Preview Pane

Hacker tận dụng tính Preview Pane của email Outlook Email được chế tạo đặc biệt sẽ tự động kích hoạt khi nó được ứng dụng khách Outlook truy xuất và xử lý, cung cấp một vectơ tấn công lén lút để tin tặc khai thác. “Kẻ tấn công có thể khai thác lỗ hổng này bằng cách gửi một email được chế tạo đặc biệt, email này sẽ tự động kích hoạt khi nó được ứng dụng khách Outlook truy xuất và xử lý. Điều này có thể dẫn đến việc khai thác TRƯỚC KHI email được xem trong Preview Pane,”

Các phiên bản ảnh hưởng

Tất cả các phiên bản được hỗ trợ của Microsoft Outlook (2010, 2013,2016,2019, 365Apps)cho Windows đều bị ảnh hưởng.

Các phiên bản khác của Microsoft Outlook như Android, iOS, Mac, cũng như Outlook trên web và các dịch vụ M365 khác không bị ảnh hưởng.

Biện pháp làm khắc phục:

Thêm người dùng vào Nhóm bảo mật người dùng được bảo vệ (Protected Users Security Group), ngăn việc sử dụng NTLM làm cơ chế xác thực. Việc thực hiện giảm thiểu này giúp khắc phục sự cố dễ dàng hơn so với các phương pháp vô hiệu hóa NTLM khác.

Chặn TCP 445/SMB gửi đi từ mạng của bạn bằng cách sử dụng tường lửa vành đai(DMZ), tường lửa cục bộ và thông qua cài đặt VPN. Điều này sẽ ngăn việc gửi thông báo xác thực NTLM tới chia sẻ tệp từ xa.

Máy trạm Client

Yêu cầu tất cả máy trạm của Người dùng cuối cần upgrade Microsoft Outlook cho các Phiên bản:

Microsoft Outlook 2013 (64-bit edition):https://www.microsoft.com/en-us/download/details.aspx?id=105070

Microsoft Outlook 2016 (64-bit edition):https://www.microsoft.com/en-us/download/details.aspx?id=105058

Microsoft Office LTSC 2019/2021/365 for 64-bit editions:=> Cick upgrade

Server Exchange và Exchange Online

Chạy Script CVE-2023-23397: CVE-2023-23397.ps1

Thông tin tham khảo:

https://msrc.microsoft.com/update-guide/vulnerability/CVE-2023-23397

https://msrc.microsoft.com/blog/2023/03/microsoft-mitigates-outlook-elevation-of-privilege-vulnerability/

https://microsoft.github.io/CSS-Exchange/Security/CVE-2023-23397/

Anh em sysadmin tập trung cập nhật bản vá Outlook cho máy trạm người dùng nhé.

Làm trên cả server và client tường lửa cứng mềm

#jsisen

#viettechgroupvn

#phuongit

#outlookzerodays

#phuongnguyenit

HƯỚNG DẪN CÀI EXCHANGE SERVER 2019 CU12 TRÊN WINDOWS SERVER 2022

Microsoft_Exchange_(2019-present).svg

HƯỚNG DẪN CÀI EXCHANGE SERVER 2019 CU12 TRÊN WINDOWS SERVER 2022

Thông tin

Domain invoice.local

Chuẩn bị source

Setup

Logon domain Administrator

Run as administrator

Cài đặt thư viện powershell

Install-WindowsFeature Server-Media-Foundation, NET-Framework-45-Features, RPC-over-HTTP-proxy, RSAT-Clustering, RSAT-Clustering-CmdInterface, RSAT-Clustering-Mgmt, RSAT-Clustering-PowerShell, WAS-Process-Model, Web-Asp-Net45, Web-Basic-Auth, Web-Client-Auth, Web-Digest-Auth, Web-Dir-Browsing, Web-Dyn-Compression, Web-Http-Errors, Web-Http-Logging, Web-Http-Redirect, Web-Http-Tracing, Web-ISAPI-Ext, Web-ISAPI-Filter, Web-Lgcy-Mgmt-Console, Web-Metabase, Web-Mgmt-Console, Web-Mgmt-Service, Web-Net-Ext45, Web-Request-Monitor, Web-Server, Web-Stat-Compression, Web-Static-Content, Web-Windows-Auth, Web-WMI, Windows-Identity-Foundation, RSAT-ADDS

Cài đặt các Thư viện cần thiết runtime

Cài dotnet 4.8

Microsoft Unified Communications Managed API 4.0, Core Runtime 64-bit

Cài Url Rewrite mode

Chuẩn bị Active Directory

Run as Administrator CMD

Step 1: Extend the Active Directory schema

C:\EX2019CU12\EX2019CU12>Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareSchema

Microsoft Exchange Server 2019 Cumulative Update 12 Unattended Setup

Copying Files...

File copy complete. Setup will now collect additional information needed for installation.

Performing Microsoft Exchange Server Prerequisite Check

Prerequisite Analysis COMPLETED

Configuring Microsoft Exchange Server

Extending Active Directory schema COMPLETED

The Exchange Server setup operation completed successfully.

C:\EX2019CU12\EX2019CU12>

Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareAD /OrganizationName:”Services Invoice”

C:\EX2019CU12\EX2019CU12>Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareAD /OrganizationName:"Services Invoice"

Microsoft Exchange Server 2019 Cumulative Update 12 Unattended Setup

Copying Files...

File copy complete. Setup will now collect additional information needed for installation.

Performing Microsoft Exchange Server Prerequisite Check

Prerequisite Analysis 100%

Setup will prepare the organization for Exchange Server 2019 by using 'Setup /PrepareAD'. No Exchange Server 2016 roles

have been detected in this topology. After this operation, you will not be able to install any Exchange Server 2016

roles.

For more information, visit: https://docs.microsoft.com/Exchange/plan-and-deploy/deployment-ref/readiness-checks?view=exchserver-2019

Setup will prepare the organization for Exchange Server 2019 by using 'Setup /PrepareAD'. No Exchange Server 2013 roles

have been detected in this topology. After this operation, you will not be able to install any Exchange Server 2013

roles.

For more information, visit: https://docs.microsoft.com/Exchange/plan-and-deploy/deployment-ref/readiness-checks?view=exchserver-2019

Configuring Microsoft Exchange Server

Organization Preparation COMPLETED

The Exchange Server setup operation completed successfully.

C:\EX2019CU12\EX2019CU12>
C:\EX2019CU12\EX2019CU12>Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareDomain

Microsoft Exchange Server 2019 Cumulative Update 12 Unattended Setup

Copying Files...

File copy complete. Setup will now collect additional information needed for installation.

Performing Microsoft Exchange Server Prerequisite Check

Prerequisite Analysis COMPLETED

Configuring Microsoft Exchange Server

Prepare Domain Progress COMPLETED

The Exchange Server setup operation completed successfully.

C:\EX2019CU12\EX2019CU12>

CÀI ĐẶT EXCHANGE 2019 CU12

Đến khi cài xong nhé.

Phương Nguyễn Viết

The WinRM client cannot process the request. It cannot determine the content type of the EMS Exchange Shell

Microsoft_Exchange_(2019-present).svg

The WinRM client cannot process the request. It cannot determine the content type of the

Mã lỗi:

VERBOSE: Connecting to LAB-EX2013.phuongit.lab.

New-PSSession : [lab-ex2013.phuongit.lab] Connecting to remote server lab-ex2013.phuongit.lab failed with the

following error message : The WinRM client cannot process the request. It cannot determine the content type of the

HTTP response from the destination computer. The content type is absent or invalid. For more information, see the

about_Remote_Troubleshooting Help topic.

At line:1 char:1

+ New-PSSession -ConnectionURI “$connectionUri” -ConfigurationName Microsoft.Excha …

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+ CategoryInfo : OpenError: (System.Manageme….RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotin

gTransportException

+ FullyQualifiedErrorId : -2144108297,PSSessionOpenFailed

VERBOSE: Connecting to LAB-EX2013.phuongit.lab.

New-PSSession : [lab-ex2013.phuongit.lab] Connecting to remote server lab-ex2013.phuongit.lab failed with the

following error message : The WinRM client cannot process the request. It cannot determine the content type of the

HTTP response from the destination computer. The content type is absent or invalid. For more information, see the

about_Remote_Troubleshooting Help topic.

At line:1 char:1

+ New-PSSession -ConnectionURI “$connectionUri” -ConfigurationName Microsoft.Excha …

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+ CategoryInfo : OpenError: (System.Manageme….RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotin

gTransportException

+ FullyQualifiedErrorId : -2144108297,PSSessionOpenFailed

VERBOSE: Connecting to LAB-EX2013.phuongit.lab.

New-PSSession : [lab-ex2013.phuongit.lab] Connecting to remote server lab-ex2013.phuongit.lab failed with the

following error message : The WinRM client cannot process the request. It cannot determine the content type of the

HTTP response from the destination computer. The content type is absent or invalid. For more information, see the

about_Remote_Troubleshooting Help topic.

At line:1 char:1

+ New-PSSession -ConnectionURI “$connectionUri” -ConfigurationName Microsoft.Excha …

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+ CategoryInfo : OpenError: (System.Manageme….RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotin

gTransportException

+ FullyQualifiedErrorId : -2144108297,PSSessionOpenFailed

VERBOSE: Connecting to LAB-EX2013.phuongit.lab.

New-PSSession : [lab-ex2013.phuongit.lab] Connecting to remote server lab-ex2013.phuongit.lab failed with the

following error message : The WinRM client cannot process the request. It cannot determine the content type of the

HTTP response from the destination computer. The content type is absent or invalid. For more information, see the

about_Remote_Troubleshooting Help topic.

At line:1 char:1

+ New-PSSession -ConnectionURI “$connectionUri” -ConfigurationName Microsoft.Excha …

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+ CategoryInfo : OpenError: (System.Manageme….RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotin

gTransportException

+ FullyQualifiedErrorId : -2144108297,PSSessionOpenFailed

VERBOSE: Connecting to LAB-EX2013.phuongit.lab.

New-PSSession : [lab-ex2013.phuongit.lab] Connecting to remote server lab-ex2013.phuongit.lab failed with the

following error message : The WinRM client cannot process the request. It cannot determine the content type of the

HTTP response from the destination computer. The content type is absent or invalid. For more information, see the

about_Remote_Troubleshooting Help topic.

At line:1 char:1

+ New-PSSession -ConnectionURI “$connectionUri” -ConfigurationName Microsoft.Excha …

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+ CategoryInfo : OpenError: (System.Manageme….RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotin

gTransportException

+ FullyQualifiedErrorId : -2144108297,PSSessionOpenFailed

Failed to connect to an Exchange server in the current site.

Enter the server FQDN where you want to connect.:

YÊU CẦU

  • Set PowerShell Execution Policies
  • Verify WinRM IIS Extensions
  • Enable Windows Authentication for PowerShell Virtual Directory
  • Verify SSL setting for PowerShell Virtual Directory
  • Verify the application pool for PowerShell Virtual Directory
  • Verify the Security in for PowerShell Virtual Directory

Kiểm tra

  • Set PowerShell Execution Policies

  • Verify WinRM IIS Extensions => Nếu chưa cài phải cài

  • Enable Windows Authentication for PowerShell Virtual Directory
  • Verify SSL setting for PowerShell Virtual Directory

  • Verify the application pool for PowerShell Virtual Directory

Also, under Powershell Virtual Directory → Basic Settings → Make sure you have the Correct application pool (MSExchangePowerShellAppPool or MSExchangePowerShellFrontEndAppPool) and Physical path (C:\Program Files\Microsoft\Exchange Server\V<Exchange Version>\ClientAccess\PowerShell) selected to access the PowerShell virtual directory on the host under IIS root as shown:

  • Verify the Security in for PowerShell Virtual Directory
  • Also make sure the Exchange user has read permissions on the Physical path specified. To do this go to PowerShell Virtual Directory → Edit Permissions → Security tab → Assign read permissions to user performing the scan as shown:

Add-PSSnapin Microsoft.Exchange.Management.PowerShell.snapin;

Set-User “Administrator” -RemotePowerShellEnabled $true

Get-User -Identity “Administrator” | Format-List RemotePowerShellEnabled

KHỞI ĐỘNG SERVER LẠI NHÉ

TEST

TEST NEW USER FOR EMS

  • Add new user account in Active Directory
  • Add Roles/Group membership for new created user account
  • Enable Remote PowerShell for new created user account

NGUYÊN NHÂN

Có thể 1 trong các nguyên nhân sau

This problem occurs because one or more of the following conditions are true:

  • There is a configuration issue on the Exchange server with the Authentication Providers set on the PowerShell website.
  • The Kerbauth module is configured incorrectly in Internet Information Services (IIS) in one of the following ways:
    • The Kerbauth module is displayed as a Managed module instead of as a Native module.
    • The Kerbauth module has been loaded on the Default website level (instead of, or in addition to, the PowerShell virtual directory).
  • The user does not have Remote PowerShell Enabled status.
  • The WSMan module entry is missing from the Global modules section of the ApplicationHost.config file that is in the following location:
    C:\Windows\System32\Inetsrv\config\ApplicationHost.config

This causes the WSMan module to be displayed as a Managed module in the PowerShell virtual directory.

RESOLUTION OTHER

The Kerberos authentication needs to be configured on the PowerShell website on the Exchange Mailbox Server:

  1. Establish a remote connection to the Exchange server in question.
  2. Click Run and enter inetmgr.
  3. Expand the server in the left-hand pane.
  4. Expand the Sites and Default Web Site trees, and then click PowerShell.
  5. Double-click Authentication under the IIS section.

  1. Chọn enable Windows Authentication-> Providers

  1. Right-click on Windows Authentication, and then select Providers.

  1. If the Negotiate:Kerberos item is not present, add it through the Available Providers dialog box.


The AppInsight for Exchange data will be populated during the next SAM polling process. You can also click on Poll Now to obtain results immediately.

Test-WsMan

In IIS Manager, Kerbauth should be listed as a Native module in the PowerShell virtual directory. The DLL location for this module should point to

C:\Program Files\Microsoft\Exchange Server\v15\Bin\kerbauth.dll.

Make sure that the WSMan module is registered but not enabled at the Server level. Also make sure that the WSMan module is enabled for the PowerShell virtual directory. Then, verify that the following WSMan module entry is included in the <globalModules> section of the C:\Windows\System32\Inetsrv\config\ApplicationHost.config file as follows:

XMLCopy

<globalModules>

<add name=”WSMan” image=”C:\Windows\system32\wsmsvc.dll” />

Kiểm tra thiếu chưa cài WinRM IIS Extension feature

Khởi động lại IIS hoặc máy chủ để test lại

Kiểm tra lại: C:\Windows\System32\Inetsrv\config\ApplicationHost.config

Đảm bảo có dòng này

<add name=”WSMan” image=”%windir%\system32\wsmsvc.dll” />

Những lưu ý đối với bản vá Exchange Server ngày 10 tháng 01 năm 2023

Microsoft_Exchange_(2019-present).svg

Các Chú ý liên quan bản cập nhật vá lổ hổng (SU) của Exchange Server ngày 10/01/2023

Thông tin

Exchange 2019:
Exchange 2019CU12-KB5022193 (SU5)
Exchange 2019CU11-KB5022193 (SU9)
Exchange 2016:
Exchange2016-KB50221431(SU5)

Tính năng được giới thiệu mới:

Certificate signing of PowerShell serialization payload in Exchange Server, lưu ý khi cài đặt update bản vá thì sẽ bật tính năng này


Cập nhật các vá lỗ hổng:


Vấn đề vá lỗi:

  • Store Worker Process stops and returns “System.NullReferenceExceptions” lặp lại nhiều lần.
  • Không ghi âm và play được Exchange Unified Messaging
  • Log Exchange Application bị tràn liên quan có mã event ID: 6010

Các lỗi khi update có thể gặp phải:

  • Dịch vụ Microsoft Exchange AD Topology service có thể không start tự động hoặc lỗi treo làm die hệ thống (Đối với Exchange server 2016 chạy trên Windows Server 2012R2)
  • Bản xem trước trang web cho các URL được chia sẻ trong Outlook trên web (OWA) không được hiển thị chính xác.
  • Không thể mở công cụ quản lý Exchange Toolbox MMC snapin


Khuyến cáo Phương nguyễn:


Hiện bản này đang có nhiều lỗi liên quan khuyến cáo mạnh mẽ anh em IT System chưa hãy update nhé để ăn tết vui vẻ chờ MS confirm các bản vá trong tương lai. Vì có rất nhiều người bị lỗi rồi.
Khuyến cáo đặc biệt: Tuyệt đối không chạy bản vá này cho Exchange 2013

Phương nguyễn

Exchange Server 2013 sắp kết thúc hỗ trợ

Microsoft_Exchange_(2019-present).svg

Exchange Server 2013 End of Support Coming Soon
Vào ngày 11 tháng 4 năm 2023, tức là chưa đầy 90 ngày kể từ hôm nay, Exchange Server 2013 sẽ kết thúc Hỗ trợ!
Sau ngày đó, Microsoft sẽ không còn cung cấp:
Hỗ trợ kỹ thuật cho các sự cố có thể xảy ra liên quan Exchange 2013
Bản vá sửa lỗi cho các sự cố được phát hiện và có thể ảnh hưởng đến tính ổn định cũng như khả năng sử dụng của máy chủ Exchange Server 2013
Các bản sửa lỗi bảo mật (SU, CU) cho các lỗ hổng (,vulnerabilities ) được phát hiện và có thể khiến máy chủ dễ bị xâm phạm bảo mật
Cập nhật múi giờ

Tất nhiên, Exchange Server 2013 sẽ tiếp tục chạy sau ngày 11/04/2023; tuy nhiên, do những rủi ro được liệt kê ở trên, Microsoft thực sự khuyên khuyến cáo AE System nên di chuyển khỏi Exchange Server 2013 càng sớm càng tốt. Hãy bắt đầu ngay bây giờ lên plan để migration.
Để tiếp tục được hỗ trợ Sản phẩm liên quan Exchange, bạn có thể:
Upgrade to Exchange Server 2019 hoặc
Migrate to Exchange Online

jsisen

phuongit

exchange2013_eos