2020/12/14 16:19:37 entity = {{[0xc00005a680 0xc00005a640 0xc00005a600 0xc00005a5c0 0xc00005a580 0xc00005a540 0xc00005a500 0xc00005a4c0 0xc00005a480 0xc00005a440 0xc00005a400 0xc00005a3c0 0xc00005a380 0xc00005a340 0xc00005a300 0xc00005a2c0 0xc00005a280 0xc00005a240 0xc00005a200 0xc00005a1c0] map[Authentication-Results:[0xc00005a340] Content-Type:[0xc00005a640] Date:[0xc00005a5c0] Dkim-Signature:[0xc00005a300] From:[0xc00005a480] Message-Id:[0xc00005a600] Mime-Version:[0xc00005a540] Received:[0xc00005a440 0xc00005a280 0xc00005a200 0xc00005a1c0] Return-Path:[0xc00005a680] Subject:[0xc00005a500] To:[0xc00005a4c0] X-Mailer:[0xc00005a580] X-Yandex-Internal:[0xc00005a240] X-Yandex-Sender-Uid:[0xc00005a400] X-Yandex-Spam:[0xc00005a3c0] X-Yandex-Suid-Status:[0xc00005a380] X-Yandex-Timemark:[0xc00005a2c0]]}}
for _, r := range msg.Body {
entity, err := message.Read(r)
if err != nil {
log.Fatal(err)
}
log.Println("entity = ",entity.Header)
log.Printf("entity: %+v\n", entity.Header)
log.Printf("entity: %+v\n", entity.Header.Get("From"))
log.Printf("entity: %+v\n", entity.Header.Values("To"))