Commit e7d7368e authored by ng's avatar ng

Merge branch 'paz/update-mail-to-2.7.1' into 'master'

Update mail to 2.7.1, pin sqlite3

See merge request !260
parents 1b791266 9954f223
Pipeline #22559 passed with stages
in 15 minutes and 57 seconds
......@@ -30,7 +30,7 @@ Gem::Specification.new do |s|
}
s.required_ruby_version = ">= 2.1.0"
s.add_runtime_dependency 'gpgme', '~> 2.0', '>= 2.0.13' # Explicitly include to force a version.
s.add_runtime_dependency 'mail', '~> 2.6.0'
s.add_runtime_dependency 'mail', '~> 2.7.1'
s.add_runtime_dependency 'mail-gpg', '~> 0.3', '>= 0.3.3'
s.add_runtime_dependency 'activerecord', '~> 4.2'
# TODO: Drop this once we cease to support ruby 2.1, see #310
......
......@@ -9,7 +9,7 @@ FactoryBot.define do
openpgp_header_preference { "signencrypt" }
internal_footer { nil }
public_footer { nil }
headers_to_meta { ["from", "to", "cc", "date"] }
headers_to_meta { ["from", "to", "cc", "date", "sig", "enc"] }
bounces_drop_on_headers { { "x-spam-flag" => true } }
keywords_admin_only { ["subscribe", "unsubscribe", "delete-key"] }
keywords_admin_notify { ["add-key"] }
......
-----BEGIN PGP PUBLIC KEY BLOCK-----
mQINBEyKRU4BEADHgQONUfSJzP6fTDN+YkQFHvYSewcyZeOfbnjjiFkroy30lCks
OfQaULGmQJwPF6sofvdLHcCm491PbK6IcmfpGhsQIroIfkDh305CqM/vZFcuzd0M
4Mf3aZTlsqns9ah4uO2/Pu3rjLXvPH4rhwKNcQZ2BceGICM0TJhR7J+e2ScqgJ3e
PpZpN7LNwQFzr7kn0a0oMC4vdJjZKmEWp5FL4mYfMDbwuB9vxPglYNP7Mxmi2/yB
LhNm1h1u4bAC3pcv/GwDkcLevYmRqX/DWJd9fOQF6bgO3UppEG+DHMmuB/oLR5aq
t/ZOH7PvsVWbYbiZ3aCnyRlK6EOONjKXScut0EI/QirUzWwfxZnFYMc+ZbR1mfNU
cEWro5N/jc1uuQCKdU6nYsCzSN7jJz3yaEisLlB13hBvpLkQ8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FNm8xK5Sp8rkvwQadYrJ80wOPGI773l2mBXflETr0zSWChMWOpVT+lKynxfn+s
+hBxYBFagPRwrpcLYD4fT00uewmDKNUZ0eUk/E5v3Kmy1e4xHdPTdQgg2vqI1XQ5
79zQruhmKprHpcVgDfKw8uVzeuhHGlLZIReYVhu9wZR4kITbtNGL91T+KtqVkTK+
sTxOa6tIDhMffkW6t/1MAjEy5BdsRe65qxa9eyhweZGkuoL5I33VNVwY5n7vkH+o
u/WUm70Ix9hUejA6Pn8Gn5UFOTcBYX34/yzdXk3+XMZAg+qGwPfZ+D0V/cPOoxkC
/QYGLdjp8dZP921NTPLRZiWviN0cYXY0IBV0+TBSCGo2kvOQgFk0qbQjQ57ePwTt
u8qeiNGrv6iwIjNsLJpf4tpwWrYGL/tczYAUxD8wnC7vDVY0kjfEX3Al+Mpou2Qi
nyRAUuvGT7Lx
=wHia
-----END PGP PUBLIC KEY BLOCK-----
......@@ -1838,7 +1838,7 @@ EOS
sign_as: list.admins.first.fingerprint
}
mail.gpg(gpg_opts)
content_body = "Hello again! ¡Hola!\n"
content_body = "Hello again! ¡Hola!\r\n"
mail.charset = 'iso-8859-1'
mail.body = "x-list-name: #{list.email}\nX-resend: someone@example.org\n#{content_body}".encode('iso-8859-1')
mail.deliver
......@@ -1880,7 +1880,7 @@ EOS
sign_as: list.admins.first.fingerprint
}
mail.gpg(gpg_opts)
content_body = "This is a test\nAnd here are some umlauts:ÄäÖöÜüß"
content_body = "This is a test\r\nAnd here are some umlauts:ÄäÖöÜüß"
mail.charset = 'utf-8'
mail.body = "x-list-name: #{list.email}\nX-resend: someone@example.org\n#{content_body}".encode('utf-8')
mail.deliver
......
......@@ -7,18 +7,23 @@ describe "user sends a plain text message" do
'signed-mime',
].each do |t|
it "from thunderbird being #{t}" do
start_smtp_daemon
list = create(:list)
list = create(:list, send_encrypted_only: false)
list.subscribe("admin@example.org", nil, true)
message_path = "spec/fixtures/mails/#{t}/thunderbird.eml"
list.import_key(File.read('spec/fixtures/openpgpkey_52507B0163A8D9F0094FFE03B1A36F08069E55DE.asc'))
mail = Mail.read("spec/fixtures/mails/#{t}/thunderbird.eml")
error = nil
error = run_schleuder(:work, list.email, message_path)
mails = Dir.glob("#{smtp_daemon_outputdir}/mail-*")
begin
Schleuder::Runner.new().run(mail.to_s, list.email)
rescue SystemExit => exc
error = exc
end
mails = Mail::TestMailer.deliveries
expect(error).to be_empty
expect(error).to be_nil
expect(mails.size).to eq 1
stop_smtp_daemon
content = mails.first.parts[0].parts[1].to_s
expect(content).not_to include("-----BEGIN PGP SIGNATURE-----")
end
end
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment