• DevOps
    Case Study

    How we built a resilient multi-account, multi-cloud solution for a Health Tech service provider!

    READ CASESTUDY
    icon

    24/7 DevOps as a Service

    Round-the-clock DevOps for uninterrupted efficiency.

    icon

    Infrastructure as a Code

    Crafting infrastructure with ingenious code.

    icon

    CI/CD Pipeline

    Automated CI/CD pipeline for seamless deployments.

    icon

    DevSecOps

    Integrated security in continuous DevOps practices.

    icon

    Hire DevOps Engineers

    Level up your team with DevOps visionaries.

    icon

    Consulting Services

    Navigate success with expert DevOps consulting.

  • TechOps
    Case Study

    How we built a scalable Odoo solution for a Travel Tech service provider!

    READ CASESTUDY

    WEB HOSTING SUPPORT

    icon

    HelpDesk Support

    Highly skilled 24/7 HelpDesk Support

    icon

    Product Support

    Boost your product support with our expertise.

    MANAGED SERVICES

    icon

    Server Management

    Don’t let server issues slow you down. Let us manage them for you.

    icon

    Server Monitoring

    Safeguard your server health with our comprehensive monitoring solutions.

    STAFF AUGMENTATION

    icon

    Hire an Admin

    Transform your business operations with our expert administrative support.

    icon

    Hire a Team

    Augment your workforce with highly skilled professionals from our diverse talent pool.

  • CloudOps
    Case Study

    How we helped a Private Deemed University in India, save US $3500/m on hosting charges!

    READ CASESTUDY
    icon

    AWS Well Architected Review

    Round-the-clock for uninterrupted efficiency

    icon

    Optimize

    Efficient CloudOps mastery for seamless cloud management

    icon

    Manage

    Automated CI/CD pipeline for seamless deployments

    icon

    Migrate

    Upgrade the journey, Migrate & Modernize seamlessly

    icon

    Modernize

    Simplify compliance complexities with our dedicated services

    icon

    FinOps as a Service

    FinOps as a Service

  • SecOps
    Case Study

    How we built a scalable Odoo solution for TravelTech service provider!

    READ CASESTUDY
    icon

    VAPT

    Vulnerability Assessment and Penetration Testing

    icon

    Source Code Review

    Ensuring source code security ans safe practices to reduce risks

    icon

    Security Consultation

    On demand services for improving server security

    icon

    System Hardening

    Reduced vulnerability and proactive protection

    icon

    Managed SoC

    Monitors and maintains system security. Quick response on incidents.

    icon

    Compliance as a Service

    Regulatory compliance, reduced risk

  • Insights
    Case Study

    How we helped a Private Deemed University in India, save US $3,500/m on hosting charges!

    READ CASESTUDY
    icon

    Blog

    Explore our latest articles and insights

    icon

    Case Studies

    Read about our client success stories

    icon

    Flipbook

    Explore our latest Flipbook

    icon

    Events

    Join us at upcoming events and conferences

    icon

    Webinars

    Watch our educational webinar series

  • Our Story
  • Contact Us

Interested to collaborate?

Get in touch with us!

Ready to elevate your business with certified cloud expertise? Contact us today to learn how our team can help you leverage cloud technology to drive growth, streamline operations, and enhance security.

  • AWSAWS
  • Azure CloudAzure Cloud
  • Google CloudGoogle Cloud
  • Akamai CloudAkamai Cloud
  • OVHOVH
  • Digital OceanDigital Ocean
  • HetznerHetzner
  • Kubernetes Consultancy Services
  • K8s & Cloud native Solutions
  • 24/7 Infrastructure Monitoring
  • DevOps as a Service
  • Cloud CI/CD Solutions
  • White Labeled MSP Support
  • Our story
  • Life@SupportSages
  • Insights
  • Careers
  • Events
  • Contact Us

Connect with us!


LinkedInFacebookXInstagramYouTube

aws partneraws advanced partner
SupportSages

Copyright © 2008 – 2026 SupportSages Pvt Ltd. All Rights Reserved.
Privacy PolicyLegal TermsData ProtectionCookie Policy
How to secure SSH access to your server using TORʼs hidden service ?

How to secure SSH access to your server using TORʼs hidden service ?

Daniel Wren

  • 3 min read
How to secure SSH access to your server using TORʼs hidden service ?

Generating audio, please wait...

TOR in a first glance, is used to browse the darknet or to by-pass the firewall restriction. i.e if your firewall blocks certain website you can use TOR browsers to access them. Its really tough to block access to TOR network when your users are using TOR bridges. I know of a few firewalls which will block known TOR relays, but I am yet to discover a firewall which could block even the TOR Bridge relays.

Good part is that TOR can be used to secure or access any service on a server where the TOR server is installed. So lets see how you can secure your SSH service using TOR. By securing using TOR, it does not mean that we are using TOR to secure the server. We are disabling the SSH access for the public by making it listen only on port localhost and then access it using TOR. This method is not highly recommended though, and is here for academic interest (I don’t have a specific reason other than that TOR is generally considered as bad).

Steps to follow

  • Install TOR

  • Setup and change the /etc/ssh/sshd_config to listen only on 127.0.0.1

  • Open /etc/tor/torrc. Please change the value

       HiddenServiceDir /var/lib/tor/sagesssh

       HiddenServicePort 22 127.0.0.1:22
  • Create a folder by the name /var/lib/tor/sagesssh and change the ownership to the same user who runs the tor server.

  • Restart the tor daemon and make sure that you see two files in that folder: hostname and private_key. If not, check the log files for error messages. Most probably it could be because of the permissions / ownership issues. In hostname you’ll find your public onion address and you have to use to access your service like 32rfckwuorlf4dlv.onion

  • You can use the below SSH command to access the above ssh server like

        ssh -o ProxyCommand=’nc -x localhost:9150 %h %p’ 

        xxxxxxxxxxx.onion

       (xxxxxxxxxx.onion like 32rfckwuorlf4dlv.onion)
  • To ease the SSH command instead of entering the above command, you can enter the below snippet in your $HOME/.ssh/config (with necessary changes. You may use nc or socat depending on whichever you have installed)

         Host this-server

         HostName xxxxxxxxxx.onion

         ProxyCommand socat STDIO

         SOCKS4A:127.0.0.1:%h:%p,socksport=9050                  

Now you just have to enter “ssh this-server” and you should be inside your server through the TOR network. You are done with securing SSH using TOR…

Get rid of all the hassles of server management. Let us take care of it. 

  • Linux

Everything about SWAP in Linux – why do we need swapping ?

Everything about SWAP in Linux – why do we need swapping ?
  • Linux
  • server
  • Sever management
logo

How to install node.js on your shared server?

How to install node.js on your shared server?
  • server
  • Sever management
logo

How to stand out from the crowd by providing 24*7 customer support?

How to stand out from the crowd by providing 24*7 customer support?
  • Customer Care
logo

Init v/s Systemd

Init v/s Systemd
  • Linux
logo

Posts by Daniel Wren

An innovative and dedicated IT professional who is very curious to solve and find solutions to seemingly difficult tasks.