Thursday, December 27, 2018

Security Recommendation and Hardening on Virtual Environments - Chapter One

 Today I want to start a series of discussions about some security tips and prospective best practices. I will start with some simple steps on ESXi configuration as the main asset between vCenter objects. At each post there is 4 or 5 security recommendation titles about VMware security hardening and are absolutely consistent with VMware published checklists:

1. ‌Built-in firewall rules:
As one of the first steps for ESXi hardening you can start from a limitation of permitted connections "To / From" the host and restricting unused transmit or blocking suspected traffics. So you may need to revision firewall rules and control what is permitted and what is not? or are their usage permanent or temporary for a specific time duration? Check your list again and for example, if you always want to have permanently SSH access to your hosts, limit allowed IP addresses to only your management system IP address.

2. Using SNMP version 3:
Because of the security nature of SNMP protocol on version3 in comparison with older versions 1 & 2 (based on the support of encryption, authentication & hashing algorithms), it's strongly recommended to use SNMPv3. Old versions are using only a community string for SNMP communication that is clear-text data and certainly is a security breach. So for monitoring ESXi hosts, it's better to configure only SNMPv3 settings by "esxcli system snmp set --v3targets ... (I will explain how to do it in another post)

3. VIB Verification:
VIB or vSphere Installation Bundle is a package file (like a ZIP) contains some installation files related to the ESXi. As the Kyle said there are 3 main parts of VIBs: Archive (Payload), XML (Descriptor) and a Signature file for trust level verification and you can configure it to each of 4 below-mentioned acceptance level depends on your system management policies:
I.   Partner: VIB creating and testing will be done by a partner and there is no VMware verification.
II.  VMware Certified: All processes will be done by VMware itself.
III. VMware Accepted: Testing will be done by partners but result verification relies on VMware. 
IV. Community: All processes executed outside of the VMware partner program and are not supported.
It's a good suggestion to don't trust to all community VIB packages

4. NTP configuration:
Time, Time and Time ... This is so important to remember to set it before doing every other configuration on your hosts. It's recommended to set at least one NTP server outside of your virtual infrastructure (like a router) for all of the hosts. ( I described it before on this post how to do it by CLI)

5. Versions of TLS:
It's always a real problem, Which version of TLS we should use on our managed hosts? and what version must be disabled? It's strongly recommended to use only TLS 1.2 but somehow maybe some of the associated management products to the ESXi host can only communicate with an older version. So before disable versions of 1.0 or 1.1, check this matter out.

I think it will be my last post in 2018, so I hope to have a great and perfect year in 2019. 
Happy New Year guys :)


Saturday, December 22, 2018

Welcome to the CloudCred



So at last i decide to take steps to VMware vExpert seriously :)
Thanks to CloudCred for helping improving our knowledge about virtualization & cloud computing,
and sharing our experiences in this massive area. Today is a new day, for learning, understanding, reviewing and teaching to us and other good people of the world who are eager to learn about every corner of unlimited virtual universe.

Thursday, December 20, 2018

Clustering & VM Monitoring

Shall we enable VM (and APP) Monitoring in the cluster settings? It's a big challenge for all virtual admins and countermeasures for answering to this big question, is a real matter.
VMware Tools is an important part of VM setup and for some reason it's necessary to install it on every guest OS (Windows, Linux and etc), because of it's role for time synchronization, better device detection and sending heartbeats. When you decide to enable VM monitoring in the cluster level, it will check heartbeat recieving from each VM. If there is no heartbeats or any network/storage traffics from VM (after default 2 min by clustering advanced options "das.iostatsInterval") VM will be restart but for confronting fault VM restarting, it will do it ONLY 3 times for each hour.
So we should ask ourselves in what situations it can be happened? and why VMware Tools shouldn't work? Generally Blue Screen states or any system faults can cause it. so it's better to reset the VM. As the VMware said, there is 3 states (Low/ Medium/ High) options that will configure 4 below custom settings:
1. Failure interval: It's about heartbeat recieving interval, so after this time HA will restart the VM.
2. Minimum Uptime: HA waiting time before VM startup and it's actions. (any heartbeat, storage, network traffics)
3. Maximum per-VM resets: I explained it before ;)
4. Maximum resets time window: Settings 3 will be executed on this time duration. (per hour)

Thanks to GS Khalsa for his related post on VMware.

Sunday, December 2, 2018

ESXi 6.7 & WinSrv 2012R2

Whenever we don't care about servers updating, it can became a big problem. When you update your hosts, naturally you can see a new tip on your console like this: "vmware tools running out of date".  If you update to VMware ESXi 6.7 and there is  many virtual machines running on Windows Server 2012 R2  (he-he, yea exactly as i mentioned before without any regular update procedures or sadly WSUS server to do that on your environment) you will encounter with a great challenge. Because there is a series of prerequisites for installation of VMware Tools (VM version14) on this type of windows server:
VMware Tools ==> DotNet Framework 4.6 (or higher versions) ==> Update KB2919355

But the problem arises when you want to install this update manually (remember it's included some another update files and you need consider their order) it will warn "is not applicable with your system". So to fix that you need to install two hotfixes: KB2939087 and KB2975061 then try again for KB2919355. After successfully installation you can continue your setup procedure and at last install VMware Tools on your VMs.


 

I will start a new journey soon ...