Questions tagged [mimekit]

A cross-platform .NET MIME creation and parser library with support for S/MIME, PGP, TNEF and Unix mbox spools.

A cross-platform .NET MIME creation and parser library with support for S/MIME, PGP, TNEF and Unix mbox spools.

MimeKit is a C# library which may be used for the creation and parsing of messages using the Multipurpose Internet Mail Extension (MIME), as defined by numerous IETF specifications.

303 questions
6
votes
1 answer

How to access embedded attachments?

I am using MailKit/MimeKit 1.2.7 (latest NuGet version). I am using ImapClient to receive emails that can have diverse attachments (images, text files, binary files, etc). MimeMessage's Attachment property helps me access all these attachments ---…
Ingmar
  • 1,525
  • 6
  • 34
  • 51
5
votes
2 answers

Sending email via C# Mailkit / Mimekit but server certificate error comes in

0 Code in Visual Studio 2015 1 I am using Mailkit latest version (1.18.1.1) for sending an email from my own email server. 2 The email server is having a self signed certificate, which is not TRUSTED. 3 I have added both of the following lines in…
Fuzed Mass
  • 414
  • 1
  • 3
  • 10
5
votes
1 answer

MailKit: How to download all attachments locally from a MimeMessage

I have looked at other examples online, but I am unable to figure out how to download and store ALL the attachments from a MimeMessage object. I did look into the WriteTo(), but I could not get it to work. Also wondering whether attachments will be…
user5736662
5
votes
1 answer

how modify message body - Mimekit Message

i'm using mimekit for receive and send mail for my project. I'm sending received mails with some modifications (to & from parts). And now i need to modify in body section. I'll replace specific word with asterix chars. Specific text different for…
Ercument Eskar
  • 132
  • 3
  • 15
5
votes
1 answer

Mimekit/mailkit download message body?

I have been making my own mail client recently and added a receive option, I used mimekit and mailkit as plugins and was able to download most of my mails with a reader that is supposed to show content(right now it shows subject, to, from, date) The…
user265889
  • 667
  • 1
  • 10
  • 24
5
votes
1 answer

Sign and Encrypt on MimeKit

I was required to send signed and encrypted mails to our customers, however, this is my first time with the fight of sign and encrypt (I want to highlight this point). I have tried with OpaqueMail, and MimeKit. Because I really don't understand…
Nekeniehl
  • 1,633
  • 18
  • 35
4
votes
2 answers

Is it possible to get raw HTML from Razor/Blazor components?

I'd like to set up a "mailer/newsletter" using MailKit. My site stack is based off of Blazor web assembly and uses .Razor components. I'm wondering if there is a way to consume a razor component I've written to output HTML into the MimeMessage…
Taylor C. White
  • 836
  • 1
  • 12
  • 30
4
votes
1 answer

MailKit IMAP fetch only new, not downloaded messages

i'm using MailKit to implement an IMAP email client. In the various examples i've seen that the code to fetch message headers is this one: var messages = client.Inbox.Fetch (0, -1, MessageSummaryItems.Full |…
ʞᴉɯ
  • 5,376
  • 7
  • 52
  • 89
4
votes
1 answer

DKIM signing fails with body hash did not verify for Mimekit 1.10.1.0 , Mailkit 1.10.2.0

I see a strange problem while DKIM signing the headers with Mailkit & Mimekit, Gmail reports the error "dkim=neutral (body hash did not verify)". Am I doing something wrong here?.Please find my code below and screenshots of the actual received…
4
votes
1 answer

Missing attachments using Mailkit

When I receive a mail with attahcment(s) from Exchange via IMAP protocol using MailKit, it's missing the attachment. When I do: string.Format("Mail has {0} attachments", mime.Attachments.Count()) It report "0", even tho that the mail itself contain…
grmihel
  • 784
  • 3
  • 15
  • 40
4
votes
2 answers

Export EML from Email using MailKit

I need to export an EML file from IMAP using Mailkit, however there are no methods to export the emails. I didn't find any documentation either in MimeKit - Mailkit Documentation. Is it possible to export EML files using Mailkit?
BrunoMartinsPro
  • 1,646
  • 1
  • 24
  • 48
4
votes
1 answer

Deserialising mimekit.MimeMessage Object

I am having some issues deserialising a mimeKit.mimeMessage that I serialised to a JSON string and stored in a redis key-value cache. I am able to serialise and store the mimeMessage successfully using either json.NET or Jil, however when I go to…
Corey
  • 1,733
  • 4
  • 18
  • 26
3
votes
1 answer

c# Sending Email with Mailkit with an HTML template file that has images imbedded

I would like to send an email using MailKit by linking to an html template that has images imbedded, for the C# part I use this code : var email = new MimeMessage(); var bodyBuilder = new BodyBuilder(); var image= bodyBuilder .LinkedResources …
Hitchb
  • 33
  • 3
3
votes
2 answers

C# MailKit HTML email received as plain text

I have a complex email template that contains many div, section and other HTML elements. The HTML template has reference to CSS(uploaded to server). I am using the below code to send HTML email via MailKit : var message = new MimeMessage(); var…
Software Dev
  • 5,368
  • 5
  • 22
  • 45
3
votes
1 answer

How you parse a collection of email addresses with mimekit?

With .NET's MailAddressCollection you call .Add(addresses) where addresses is a comma separated list of email addresses. Does Mimekit has an equivalent? I don't want to just call String.Split because that doesn't take into account commas inside…
Jonathan Allen
  • 68,373
  • 70
  • 259
  • 447
1
2
3
20 21