Software

[howto] Accesso SSH con certificato via Putty

Innanzitutto è necessario configurare il server per accettare l’autenticazione via RSA, modificando il file di configurazione che si trova in /etc/ssh/sshd_config

nano -w /etc/ssh/sshd_config

In particolare, occorre verificare che siano presenti (e non commentate) la righe:

AuthorizedKeysFile      %h/.ssh/authorized_keys
RhostsRSAAuthentication yes

A questo punto, occorre generae una coppia di chiavi (pubblica e privata) attraverso il tool puttygen scaricabile a questo link. Il tool consente la creazione di una chiave pubblica (chiave.pub) e di una chiave privata (chiave.ppk). La chiave privata dovrà essere necessariamente fornita dal client che vorrà ottenere l’accesso via SSH, mentre la chiave pubblica dovrà essere installata nel server a cui si vorrà accedere.

Una volta dunque copiata la chiave pubblica nel server, occorre convertirla in formato openssh attraverso questa istruzione

ssh-keygen -if chiave.pub > chiave.openssh

La chiave così ottenuta andrà aggiunta al file .ssh/authorized_keys e .ssh/authorized_keys2 nella cartella home dell’utente con cui si vuole accedere al server (~/.ssh/authorized_keys e ~/.ssh/authorized_keys2) in questo modo

cat chiave.openssh >> /root/.ssh/authorized_keys
cat chiave.openssh >> /root/.ssh/authorized_keys2

Dopo aver riavviato il servizio server ssh attraverso il comando

/etc/init.d/ssh restart

sarà possibile accedere al server utilizzando la chiave privata chiave.ppk e immettendo la sola username.

Un ulteriore sicurezza consiste nel disabilitare il login con password, modificando il file /etc/ssh/sshd_config in questo modo

PasswordAuthentication no

03/02/2009 How-To
No Comments

[asp] Forzare il download di un documento da una pagina ASP

[howto] Apache 2 e SSL - verifica del client attraverso l'uso dei certificati

Lascia un commento

Devi essere connesso per inviare un commento.

Giugno 2025
L M M G V S D
 1
2345678
9101112131415
16171819202122
23242526272829
30  
« Giu    

Categorie

  • Access
  • Asp
  • Cyberoam
  • Dell
  • ESX / vmWare
  • Exchange
  • Exchange 2007
  • How-To
  • IIS
  • iPhone
  • Linux
  • Mac
  • Office 365
  • Outlook
  • plesk
  • Sophos XG
  • SQL Server
  • TeamSystem
  • Tips
  • Trend Micro
  • Vb.NET
  • VB6
  • Windows 10
  • Windows 7
  • Windows SBS
  • Windows Server
  • Windows Vista
  • Windows XP
  • WSUS

How-To

  • Configure SMTP O365 Migration Using TLS 1.2 For SQL Database Mail
  • Debian anti-spam and anti-virus e-mail gateway
  • How to install Small Business Server 2003 in an existing Active Directory domain
  • Sophos XG Firewall and Firebox Branch Office VPN Integration Guide
  • Squid, SquidGard, NTLM Authentication con Samba 3.x su Debian Sarge
  • Troubleshoot high-CPU-usage issues in SQL Server

Utili

  • Chip Grafici per portatili – Benchmark
  • Il blog su Microsoft Access
  • Processori per portatili – Benchmark
  • Sophos Wireless: Wi-Fi Fundamentals
  • Zentyal – Linux Small Business Server

Meta

  • Accedi
  • Feed dei contenuti
  • Feed dei commenti
  • WordPress.org
Proudly powered by WordPress | Theme: Neblue by NEThemes.