line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Mail::DKIM::Canonicalization::nowsp; |
2
|
14
|
|
|
14
|
|
110
|
use strict; |
|
14
|
|
|
|
|
40
|
|
|
14
|
|
|
|
|
451
|
|
3
|
14
|
|
|
14
|
|
83
|
use warnings; |
|
14
|
|
|
|
|
40
|
|
|
14
|
|
|
|
|
673
|
|
4
|
|
|
|
|
|
|
our $VERSION = '1.20230911'; # VERSION |
5
|
|
|
|
|
|
|
# ABSTRACT: nowsp canonicalization |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
# Copyright 2005 Messiah College. All rights reserved. |
8
|
|
|
|
|
|
|
# Jason Long |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
# This program is free software; you can redistribute it and/or |
11
|
|
|
|
|
|
|
# modify it under the same terms as Perl itself. |
12
|
|
|
|
|
|
|
|
13
|
14
|
|
|
14
|
|
104
|
use base 'Mail::DKIM::Canonicalization::DkimCommon'; |
|
14
|
|
|
|
|
31
|
|
|
14
|
|
|
|
|
6506
|
|
14
|
14
|
|
|
14
|
|
113
|
use Carp; |
|
14
|
|
|
|
|
39
|
|
|
14
|
|
|
|
|
3806
|
|
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
sub canonicalize_header { |
17
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
18
|
0
|
0
|
|
|
|
|
croak 'wrong number of parameters' unless ( @_ == 1 ); |
19
|
0
|
|
|
|
|
|
my ($line) = @_; |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
# remove all whitespace |
22
|
0
|
|
|
|
|
|
$line =~ s/[ \t\015\012]//g; |
23
|
|
|
|
|
|
|
|
24
|
0
|
0
|
|
|
|
|
if ( $line =~ /^([^:]+):(.*)$/ ) { |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
# lowercase field name |
27
|
0
|
|
|
|
|
|
$line = lc($1) . ":$2"; |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
|
30
|
0
|
|
|
|
|
|
return $line; |
31
|
|
|
|
|
|
|
} |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
sub canonicalize_body { |
34
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
35
|
0
|
|
|
|
|
|
my ($multiline) = @_; |
36
|
|
|
|
|
|
|
|
37
|
0
|
|
|
|
|
|
$multiline =~ s/[ \t\015\012]//g; |
38
|
0
|
|
|
|
|
|
return $multiline; |
39
|
|
|
|
|
|
|
} |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
sub finish_body { |
42
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
43
|
0
|
|
|
|
|
|
$self->SUPER::finish_body; |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
1; |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
__END__ |