![]()
Figure 1 : Représentation DODS
| # apt-get install openssl |
| $ openssl dgst -algo fichier |
| $ openssl enc -algo -in fic.txt -out fic.enc |
| $ openssl enc -d -algo -in fic.enc -out fic.dec |
| $ openssl base64 -in fichier |
| $ openssl rand -base64 128 |
| $ openssl dhparam -2 1024 -out dhparam.pem |
| $ openssl dsaparam 1024 -out dsaparam.pem |
| $ openssl gendsa dsaparam.pem -out dsa.priv |
| $ openssl dsa -in dsa.priv -pubout -out dsa.pub |
| $ openssl genrsa -out rsa.priv |
| $ openssl rsa -in rsa.priv -pubout -out rsa.pub |
|
$ openssl rsautl -encrypt -pubin -inkey rsa.pub -in fic.txt -out fic.enc |
|
$ openssl rsautl -decrypt -inkey rsa.priv -in fic.enc -out fic.dec |
|
$ openssl rsautl -sign -inkey rsa.priv -in fic.txt -out fic.sig |
|
$ openssl rsautl -verify -pubin -inkey rsa.pub -in fic.sig |
|
[ req ] default_bits = 1024 default_keyfile = privkey.pem distinguished_name = req_distinguished_name attributes = req_attributes x509_extensions = v3_ca [ req_distinguished_name ] countryName = Country Name (2 letter code) countryName_default = FR countryName_min = 2 countryName_max = 2 stateOrProvinceName = State or Province Name (full name) stateOrProvinceName_default = Bouches-du-Rhone localityName = Locality Name (eg, city) localityName_default = Marseille 0.organizationName = Organization Name (eg, company) 0.organizationName_default = Evolix commonName = Common Name (eg, YOUR name) commonName_default = COLPART Gregory commonName_max = 64 emailAddress = Email Address emailAddress_default = reg@gcolpart.com emailAddress_max = 64 [ req_attributes ] challengePassword = A challenge password challengePassword_min = 4 challengePassword_max = 20 |
|
$ openssl req -x509 -newkey rsa:1024 -keyout rsa.priv -out ca.pem |
| $ openssl x509 -text -in ca.pem |
|
$ openssl smime -encrypt -in mess.txt -out mess.enc ca.pem |
|
$ openssl smime -decrypt -in mess.enc -out mess.dec -recip ca.pem -inkey rsa.priv |
|
$ openssl smime -sign -in mess.txt -out mess.sig -signer ca.pem -inkey rsa.priv |
| $ openssl smime -verify -CAfile ca.pem -in mess.sig |
| # apt-get install stunnel |
| # stunnel -d 443 -r 80 tunnel-http -p ca.pem |
| # apt-get install ssh |
|
Port 22 Protocol 2 HostKey /etc/ssh/ssh_host_rsa_key HostKey /etc/ssh/ssh_host_dsa_key KeyRegenerationInterval 3600 ServerKeyBits 768 SyslogFacility AUTH LogLevel INFO LoginGraceTime 600 PermitRootLogin yes StrictModes yes RSAAuthentication yes PubkeyAuthentication yes RhostsAuthentication no IgnoreRhosts yes RhostsRSAAuthentication no HostbasedAuthentication no PermitEmptyPasswords no PasswordAuthentication yes PAMAuthenticationViaKbdInt yes PAMAuthenticationViaKbdInt yes X11Forwarding yes X11DisplayOffset 10 PrintMotd no KeepAlive yes Subsystem sftp /usr/lib/sftp-server |
| $ ssh login@host |
| $ ssh login@host |
| $ vncserver |
| $ ssh -L 5901:localhost:5901 login@serveur |
| $ vncviewer localhost:1 |
| # make menugo |
| # /etc/init.d/ipsec start |
|
# ifconfig ipsec0 Link encap:Ethernet HWaddr 00:E0:7D:D2:00:10 inet addr:192.168.1.1 Mask:255.255.255.0 UP RUNNING NOARP MTU:16260 Metric:1 RX packets:364 errors:0 dropped:25 overruns:0 TX packets:1696 errors:0 dropped:89 overruns:0 collisions:0 RX bytes:27438 (26.7 KiB) TX bytes:267228 (260.9 KiB) |
Ce document a été traduit de LATEX par HEVEA.