Sunday, April 19, 2026
The BLOCKCHAIN Page
No Result
View All Result
  • Home
  • Cryptocurrency
  • Blockchain
  • Bitcoin
  • Market & Analysis
  • Altcoins
  • DeFi
  • Ethereum
  • Dogecoin
  • XRP
  • Regulations
  • NFTs
The BLOCKCHAIN Page
No Result
View All Result
Home Blockchain

Securely record SSH sessions on RHEL in a private VPC network

by admin
September 15, 2023
in Blockchain
0
Securely record SSH sessions on RHEL in a private VPC network
0
SHARES
13
VIEWS
Share on FacebookShare on Twitter


On this weblog publish, you’ll learn to document SSH periods on a Crimson Hat Enterprise Linux (RHEL) VSI in a personal VPC community utilizing in-built packages. The VPC non-public community is provisioned by Terraform and the RHEL packages are put in utilizing Ansible automation. Moreover, you’ll learn to arrange a extremely out there bastion host.

What’s session recording and why is it required?

A bastion host and a leap server are each safety mechanisms utilized in community and server environments to regulate and improve safety when connecting to distant methods. They serve comparable functions however have some variations of their implementation and use instances. The bastion host is positioned in entrance of the non-public community to take SSH requests from public site visitors and move the request to the downstream machine. Bastion host and leap servers are susceptible to intrusion as a result of they’re uncovered to public site visitors.

Session recording helps an administrator of a system to audit person SSH periods and ensure they adjust to regulatory necessities. Within the occasion of a safety breach, the administrator will need to audit and analyze the person periods. That is vital for a security-sensitive system.

What’s a personal VPC community?

A virtual private cloud is totally non-public if there isn’t a public ingress or outgress community site visitors. In easy technical phrases, it’s non-public if there are not any public gateways on the subnets (non-public subnets) and no floating IPs on the Digital Server Cases (VSIs).

How do I hook up with the non-public VPC community?

Shopper-to-site VPN for VPC is without doubt one of the two VPN choices out there on IBM Cloud, and it permits customers to hook up with IBM Cloud assets by safe, encrypted connections.

The client-to-site VPN is extremely out there, with two VPN servers which can be created in two totally different availability zones in the identical area. The bastions are extremely out there as properly.

Conditions

Provision the non-public VPC community utilizing Terraform

  • After getting the IBM Cloud Secrets Manager secret with the certificates, launch your terminal and set the next Terraform variables:
export TF_VAR_ibmcloud_api_key=<IBM_CLOUD_API_KEY>

export TF_VAR_secrets_manager_certificate_crn=<SECRET_CRN>
git clone https://github.com/VidyasagarMSC/private-vpc-network

cd terraform
  • Run the Terraform instructions to provision the VPC assets (e.g., subnets, bastion hosts (VSIs), VPN, and many others.):
terraform init

terraform plan

terraform apply

Connect with client-to-site VPN

  • As soon as the VPC assets are efficiently provisioned, you could obtain the VPN consumer profile by navigating to VPN servers page on IBM Cloud.
  • Click on the Shopper-to-site servers tab after which on the title of the VPN:
  • Obtain the profile from the Shoppers tab.
  • The VPN provisioned by Terraform makes use of certificates. Observe the instructions here to hook up with the OpenVPN Shopper.
  • You must see the profitable connection in your OpenVPN Shopper:

Confirm the SSH connection

  • On a terminal, add the SSH non-public key to the SSH agent with the next command:
ssh-add <LOCATION_OF_PRIVATE_SSH_KEY> 
  • Instance: ssh-add ~/.ssh/<NAME_OF_THE_PRIVATE_KEY>
  • Run the next command to SSH into the RHEL VSI by a bastion host. You can be utilizing the non-public IP tackle of the bastion in Zone 1:
ssh -J root@10.10.0.13 root@10.10.128.13
  • Bear in mind, try to be related to the client-to-site VPN to entry the RHEL VSI by the bastion host.
  • After SSH, You must see directions to allow SSH session recording utilizing the TLOG bundle on RHEL.

Deploy session recording utilizing Ansible

To deploy the session recording answer, you could have the next packages put in on the RHEL VSI:

  • tlog
  • SSSD
  • cockpit-session-recording

The packages can be put in by Ansible automation on all of the VSIs—each bastion hosts and RHEL VSI.

  • Transfer to the Ansible folder:
cd ansible
  • Create hosts.ini from the template file:
cp hosts_template.ini hosts.ini
  • Run the Ansible playbook to put in the packages from an IBM Cloud non-public mirror/repository:
ansible-playbook main_playbook.yml -i hosts.ini --flush-cache

You possibly can see in Determine 1 that after you SSH into the RHEL machine, you will notice a be aware saying: ATTENTION! Your session is being recorded!

Verify the session recordings, logs and studies

For those who carefully observe the messages post-SSH, you will notice a URL to the online console that may be accessed utilizing the machine title or non-public IP over port 9090. To permit site visitors on port 9090, within the Terraform code, change the worth of allow_port_9090 variable to true and run terraform apply. The most recent terraform apply will add ACL and safety group guidelines to permit site visitors on port 9090.

  • Now, open a browser and navigate to http://10.10.128.13:9090. To entry utilizing the VSI title, you could arrange a personal DNS (out of scope for this text). You want a root password to entry the online console:
  • Navigate to Session Recording on the left-hand facet to see the record of session recordings. Together with session recordings, you’ll be able to test the logs, diagnostic studies, and many others.:

Beneficial studying

Conclusion

This text coated why session recording is required in bastion hosts for auditing and compliance and the way session recording could be arrange with the built-in RHEL packages utilizing Ansible Automation.

Whereas designing a secured digital non-public cloud community, you discovered the perfect practices in architecting a VPC non-public community. We additionally coated the necessity to construct extremely out there VPN servers and bastion hosts. With the provisioning of cloud infrastructure utilizing Terraform and Ansible for session recording, you bought hands-on expertise.

Learn more about IBM Cloud VPC

When you’ve got any queries, be at liberty to achieve out to me on Twitter or on LinkedIn. 

Sr. Options Architect & Cloud Deployment Chief





Source link

Tags: NetworkPrivaterecordRHELSecurelysessionsSSHVPC
admin

admin

Recommended

2023 Best Black Friday/Cyber Monday Crypto Deals & Discounts (Mega Sale)

2023 Best Black Friday/Cyber Monday Crypto Deals & Discounts (Mega Sale)

2 years ago
Will the Bulls Stage a Comeback?

Will the Bulls Stage a Comeback?

2 years ago

Popular News

  • Protocol-Owned Liquidity: A Sustainable Path for DeFi

    Protocol-Owned Liquidity: A Sustainable Path for DeFi

    0 shares
    Share 0 Tweet 0
  • Cryptocurrency for College: Exploring DeFi Scholarship Models

    0 shares
    Share 0 Tweet 0
  • What are rebase tokens, and how do they work?

    0 shares
    Share 0 Tweet 0
  • What is Velodrome Finance (VELO): why it’s a next-gen AMM

    0 shares
    Share 0 Tweet 0
  • $10 XRP Price Envisioned By Fund Manager As Ripple Mounts Trillion-Dollar Payment Markets ⋆ ZyCrypto

    0 shares
    Share 0 Tweet 0

Latest

The best TV antennas to buy in 2024

The best TV antennas to buy in 2024

April 18, 2026
The best Android tablets of 2025: Lab tested, expert recommended

Your old iPad or Android tablet can be your new smart home panel – here’s how

April 18, 2026

Categories

  • Altcoins
  • Bitcoin
  • Blockchain
  • Cryptocurrency
  • DeFi
  • Dogecoin
  • Ethereum
  • Market & Analysis
  • NFTs & Metaverse
  • Regulations
  • XRP

Follow us

Recommended

  • The best TV antennas to buy in 2024
  • Your old iPad or Android tablet can be your new smart home panel – here’s how
  • T-Mobile will give you an iPad for $99 when you sign up for a new line – here’s how
  • Meet3D founder returns with AI-powered OpenSim grid – Hypergrid Business
  • I traded my Sonos Era 300 for Denon’s new home speaker – and see no reason to go back
  • About us
  • Privacy Policy
  • Terms & Conditions

© 2023 TheBlockchainPage | All Rights Reserved

No Result
View All Result
  • Home
  • Cryptocurrency
  • Blockchain
  • Bitcoin
  • Market & Analysis
  • Altcoins
  • DeFi
  • Ethereum
  • Dogecoin
  • XRP
  • Regulations
  • NFTs

© 2023 TheBlockchainPage | All Rights Reserved