mirror of
https://github.com/mailcow/mailcow-dockerized.git
synced 2025-01-10 04:18:10 +02:00
[Web] DNS check: only look for v=dkim1, k=rsa and p=key
This commit is contained in:
parent
240eb3abce
commit
76c747041d
@ -368,8 +368,9 @@ foreach ($records as $record) {
|
||||
elseif ($current['type'] == 'TXT' &&
|
||||
stripos($current['txt'], 'v=dkim') === 0 &&
|
||||
stripos($record[2], 'v=dkim') === 0) {
|
||||
$current['txt'] = str_replace(' ', '', $current['txt']);
|
||||
if ($current[$data_field[$current['type']]] == $record[2]) {
|
||||
preg_match('/v=DKIM1;.*k=rsa;.*p=(.*)/i', $current[$data_field[$current['type']]], $dkim_matches_current);
|
||||
preg_match('/v=DKIM1;.*k=rsa;.*p=(.*)/i', $record[2], $dkim_matches_good);
|
||||
if ($dkim_matches_current[1] == $dkim_matches_good[1]) {
|
||||
$state = state_good;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user