⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.23
Server IP:
178.33.27.10
Server:
Linux cpanel.dev-unit.com 3.10.0-1160.108.1.el7.x86_64 #1 SMP Thu Jan 25 16:17:31 UTC 2024 x86_64
Server Software:
Apache/2.4.57 (Unix) OpenSSL/1.0.2k-fips
PHP Version:
8.2.11
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
usr
/
share
/
doc
/
dovecot-2.2.36
/
wiki
/
View File Name :
Migration.Vm-pop3d.txt
Vm-pop3d ======== *WARNING: Badly done migration will cause your IMAP and/or POP3 clients to re-download all mails. Read <Migration.txt> page first carefully.* Vm-pop3d uses the Message-ID: header data for UIDL, Dovecot does not support this as it is not unique enough. The following Perl script will take the Message-ID: data from all mails in a mbox and put the data into the X-UIDL: header which Dovecot can use with the 'pop3_reuse_xuidl' setting: ---%<------------------------------------------------------------------------- #!/usr/bin/env perl use Email::Simple; my @totalmail=<STDIN>; my $mail = join("",@totalmail); my $email = Email::Simple->new($mail); my $msg_id = $email->header("Message-Id"); $msg_id =~ s#<##g; $msg_id =~ s#>##g; $email->header_set("X-UIDL", $msg_id); print $email->as_string; ---%<------------------------------------------------------------------------- Requires email::simple, though the default setting in email::simple is to wrap headers at 77 characters, which then causes problems when Outlook clients issue UIDL, the workaround for this is to edit the Perl module, on Debian Etch this involves editing '/usr/share/perl5/Email/Simple.pm', find "sub _fold" and change {0,77} to a suitably higher value. On more recent versions of email::simple, you may need to edit 'Headers.pm' instead, with the line to look for being "_default_fold_at" You then run the script like so: ---%<------------------------------------------------------------------------- formail -q- -s perl script.pl < inbox > newinbox ---%<------------------------------------------------------------------------- When Dovecot now looks at newinbox, it will use the X-UIDL: header and clients will not redownload mail. (This file was created from the wiki on 2018-05-23 04:42)