Sha256: 7c011c1aef2f53fabfcfe849031b0339864f19978e9446f4f07e4b79611e4aad

Contents?: true

Size: 876 Bytes

Versions: 57

Compression:

Stored size: 876 Bytes

Contents

# encoding: utf-8
# author: Christoph Hartmann
# author: Dominik Richter

require 'helper'
require 'inspec/resource'

describe 'Inspec::Resources::SshConf' do

  describe 'ssh_config' do
    it 'check ssh config parsing' do
      resource = load_resource('ssh_config')
      _(resource.Host).must_equal '*'
      _(resource.Tunnel).must_equal nil
      _(resource.SendEnv).must_equal 'LANG LC_*'
      _(resource.HashKnownHosts).must_equal 'yes'
    end
  end

  describe 'sshd_config' do
    it 'check protocol version' do
      resource = load_resource('sshd_config')
      _(resource.Port).must_equal '22'
      _(resource.UsePAM).must_equal 'yes'
      _(resource.ListenAddress).must_equal nil
      _(resource.HostKey).must_equal [
        '/etc/ssh/ssh_host_rsa_key',
        '/etc/ssh/ssh_host_dsa_key',
        '/etc/ssh/ssh_host_ecdsa_key',
      ]
    end
  end
end

Version data entries

57 entries across 57 versions & 1 rubygems

Version Path
inspec-0.30.0 test/unit/resources/ssh_conf_test.rb
inspec-0.29.0 test/unit/resources/ssh_conf_test.rb
inspec-0.28.1 test/unit/resources/ssh_conf_test.rb
inspec-0.28.0 test/unit/resources/ssh_conf_test.rb
inspec-0.27.1 test/unit/resources/ssh_conf_test.rb
inspec-0.27.0 test/unit/resources/ssh_conf_test.rb
inspec-0.26.0 test/unit/resources/ssh_conf_test.rb
inspec-0.25.0 test/unit/resources/ssh_conf_test.rb
inspec-0.24.0 test/unit/resources/ssh_conf_test.rb
inspec-0.23 test/unit/resources/ssh_conf_test.rb
inspec-0.22.1 test/unit/resources/ssh_conf_test.rb
inspec-0.22.0 test/unit/resources/ssh_conf_test.rb
inspec-0.21.6 test/unit/resources/ssh_conf_test.rb
inspec-0.21.5 test/unit/resources/ssh_conf_test.rb
inspec-0.21.4 test/unit/resources/ssh_conf_test.rb
inspec-0.21.3 test/unit/resources/ssh_conf_test.rb
inspec-0.21.2 test/unit/resources/ssh_conf_test.rb
inspec-0.21.1 test/unit/resources/ssh_conf_test.rb
inspec-0.21.0 test/unit/resources/ssh_conf_test.rb
inspec-0.20.1 test/unit/resources/ssh_conf_test.rb