line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
# |
2
|
|
|
|
|
|
|
# This file is part of Config-Model-OpenSsh |
3
|
|
|
|
|
|
|
# |
4
|
|
|
|
|
|
|
# This software is Copyright (c) 2008-2022 by Dominique Dumont. |
5
|
|
|
|
|
|
|
# |
6
|
|
|
|
|
|
|
# This is free software, licensed under: |
7
|
|
|
|
|
|
|
# |
8
|
|
|
|
|
|
|
# The GNU Lesser General Public License, Version 2.1, February 1999 |
9
|
|
|
|
|
|
|
# |
10
|
3
|
|
|
3
|
|
53906
|
use strict; |
|
3
|
|
|
|
|
10
|
|
|
3
|
|
|
|
|
103
|
|
11
|
3
|
|
|
3
|
|
18
|
use warnings; |
|
3
|
|
|
|
|
42
|
|
|
3
|
|
|
|
|
192
|
|
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
package Config::Model::Backend::OpenSsh::Sshd ; |
14
|
|
|
|
|
|
|
$Config::Model::Backend::OpenSsh::Sshd::VERSION = '2.9.4.1'; |
15
|
3
|
|
|
3
|
|
22
|
use Mouse ; |
|
3
|
|
|
|
|
7
|
|
|
3
|
|
|
|
|
36
|
|
16
|
|
|
|
|
|
|
extends "Config::Model::Backend::Any" ; |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
with ( |
19
|
|
|
|
|
|
|
'Config::Model::Backend::OpenSsh::Role::Reader', |
20
|
|
|
|
|
|
|
'Config::Model::Backend::OpenSsh::Role::Writer', |
21
|
|
|
|
|
|
|
); |
22
|
|
|
|
|
|
|
|
23
|
3
|
|
|
3
|
|
1908
|
use Carp ; |
|
3
|
|
|
|
|
7
|
|
|
3
|
|
|
|
|
247
|
|
24
|
3
|
|
|
3
|
|
926
|
use IO::File ; |
|
3
|
|
|
|
|
3862
|
|
|
3
|
|
|
|
|
409
|
|
25
|
3
|
|
|
3
|
|
28
|
use Log::Log4perl; |
|
3
|
|
|
|
|
7
|
|
|
3
|
|
|
|
|
23
|
|
26
|
3
|
|
|
3
|
|
159
|
use File::Copy ; |
|
3
|
|
|
|
|
7
|
|
|
3
|
|
|
|
|
146
|
|
27
|
3
|
|
|
3
|
|
17
|
use File::Path ; |
|
3
|
|
|
|
|
8
|
|
|
3
|
|
|
|
|
438
|
|
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
my $logger = Log::Log4perl::get_logger("Backend::OpenSsh"); |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
# now the write part |
32
|
|
|
|
|
|
|
sub write { |
33
|
4
|
|
|
4
|
1
|
1268654
|
my $self = shift; |
34
|
4
|
|
|
|
|
37
|
$self->ssh_write(@_) ; |
35
|
|
|
|
|
|
|
} |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
sub _write_line { |
38
|
0
|
|
|
0
|
|
|
return sprintf("%-20s %s\n",@_) ; |
39
|
|
|
|
|
|
|
} |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
|
42
|
3
|
|
|
3
|
|
24
|
no Mouse; |
|
3
|
|
|
|
|
16
|
|
|
3
|
|
|
|
|
25
|
|
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
1; |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
# ABSTRACT: Backend for sshd configuration files |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
__END__ |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
=pod |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
=encoding UTF-8 |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
=head1 NAME |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
Config::Model::Backend::OpenSsh::Sshd - Backend for sshd configuration files |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=head1 VERSION |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
version 2.9.4.1 |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
=head1 SYNOPSIS |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
None |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
=head1 DESCRIPTION |
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
This class provides a backend to read and write sshd client configuration files. |
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
This class is a plugin for L<Config::Model::BackendMgr>. |
71
|
|
|
|
|
|
|
|
72
|
|
|
|
|
|
|
=head1 SEE ALSO |
73
|
|
|
|
|
|
|
|
74
|
|
|
|
|
|
|
L<cme>, L<Config::Model>, |
75
|
|
|
|
|
|
|
|
76
|
|
|
|
|
|
|
=head1 AUTHOR |
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
Dominique Dumont |
79
|
|
|
|
|
|
|
|
80
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
81
|
|
|
|
|
|
|
|
82
|
|
|
|
|
|
|
This software is Copyright (c) 2008-2022 by Dominique Dumont. |
83
|
|
|
|
|
|
|
|
84
|
|
|
|
|
|
|
This is free software, licensed under: |
85
|
|
|
|
|
|
|
|
86
|
|
|
|
|
|
|
The GNU Lesser General Public License, Version 2.1, February 1999 |
87
|
|
|
|
|
|
|
|
88
|
|
|
|
|
|
|
=cut |