Discuz! Board

 找回密码
 立即注册
搜索
热搜: 活动 交友 discuz
查看: 2820|回复: 5
打印 上一主题 下一主题

LibEtPan

[复制链接]

165

主题

269

帖子

957

积分

认证用户组

Rank: 5Rank: 5

积分
957
跳转到指定楼层
楼主
发表于 2017-4-21 09:21:38 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
LibEtPan

The purpose of this mail library is to provide a portable, efficient framework for different kinds of mail access: IMAP, SMTP, POP and NNTP.

It provides an API for C language.

It's the low-level API used by MailCore and MailCore 2.

http://www.etpan.org/
http://www.etpan.org/libetpan.html


回复

使用道具 举报

1272

主题

2067

帖子

7962

积分

认证用户组

Rank: 5Rank: 5

积分
7962
沙发
发表于 2020-1-12 22:34:04 | 只看该作者
[color=rgba(0, 0, 0, 0.9)]Open Source project that I initiated. Mail library focusing on being cross-platform: Linux, *BSD, Solaris, Mac OS X, Windows. More than 30 contributors.

[color=rgba(0, 0, 0, 0.9)]- It implements most of the standard email protocols : SMTP, POP3 and IMAP. Standard mail storage : RFC 822, MIME, mbox, MH and maildir. Berkeley DB cache storage. A first functional version has been delivered in 2002.
[color=rgba(0, 0, 0, 0.9)]- Mail application for Linux, text user interface : etpan, http://www.etpan.org/etpan.
[color=rgba(0, 0, 0, 0.9)]- Integrated libetpan in Claws Mail http://www.claws-mail.org.
[color=rgba(0, 0, 0, 0.9)]- Mail application for Linux, graphic user interface, prototype : etpanX, http://www.etpan.org/etpanX (2006).
[color=rgba(0, 0, 0, 0.9)]- EtPanKit framework for Mac OS X: Objective-C, asynchronous API for IMAP and SMTP access, mail parsing. Based on libetpan. Refined API. An alpha version has been completed in one month and delivered in 2010.

[color=rgba(0, 0, 0, 0.9)]In this experience, I focused on delivering a fully functional and reusable software component. I have learned to build a clean and extensible API. I maintain it until now without breaking compatibility. It has been used in some open source projects, as well as in industry, for example: at Bell Canada for their Voice Mail system, and in some commercial software, for example: Notify 2, http://vibealicious.com/apps/notify and reMail, http://www.remail.com.
[color=rgba(0, 0, 0, 0.9)]

[color=rgba(0, 0, 0, 0.901960784313726)]https://www.linkedin.com/in/dinhvh/
回复 支持 反对

使用道具 举报

1272

主题

2067

帖子

7962

积分

认证用户组

Rank: 5Rank: 5

积分
7962
板凳
发表于 2020-1-19 22:39:40 | 只看该作者
基于etpan的smtpsend使用命令行下输入如下命令

smtpsend.exe -f firemail_wang@126.com -u firemail_wang@126.com -v password -s smtp.126.com -p 25 rec1@163.com rec2@189.cn  ------------回车后,再一起输入如下绿色内容
Date: Fri, 08 Dec 2017 10:28:32 +0800
To: 15313159857@163.com
From: firemail_wang@126.com
Subject: test Fri, 08 Dec 2017 10:28:32 +0800
Message-Id: <20171208102831.010808@qq.com>
X-Mailer: swaks v20170101.0 jetmore.org/john/code/swaks/


This is a test mailing                                   ----------- 回车后按Ctrl+Z再回车
^Z
Sent ok.                     


回复 支持 反对

使用道具 举报

1272

主题

2067

帖子

7962

积分

认证用户组

Rank: 5Rank: 5

积分
7962
地板
发表于 2020-1-21 23:04:22 | 只看该作者
本帖最后由 Qter 于 2020-1-27 16:10 编辑


readmsg.exe  d:s:p:txu:v:l:aoc:f

-d
enum {
  POP3_STORAGE = 0,
  IMAP_STORAGE,
  NNTP_STORAGE,
  MBOX_STORAGE,
  MH_STORAGE,
  MAILDIR_STORAGE,
  FEED_STORAGE
};

-t
enum {
  CONNECTION_TYPE_PLAIN,        /* when the connection is plain text */
  CONNECTION_TYPE_STARTTLS,     /* when the connection is first plain,
                                   then, we want to switch to
                                   TLS (secure connection) */
  CONNECTION_TYPE_TRY_STARTTLS, /* the connection is first plain,
                                   then, we will try to switch to TLS */
  CONNECTION_TYPE_TLS,          /* the connection is over TLS */
  CONNECTION_TYPE_COMMAND,      /* the connection is over a shell command */
  CONNECTION_TYPE_COMMAND_STARTTLS, /* the connection is over a shell
                                       command and STARTTLS will be used */
  CONNECTION_TYPE_COMMAND_TRY_STARTTLS, /* the connection is over
                                           a shell command and STARTTLS will
                                           be tried */
  CONNECTION_TYPE_COMMAND_TLS  /* the connection is over a shell
                                  command in TLS */
};

{"driver",   1, 0, 'd'},
    {"server",   1, 0, 's'},
    {"port",     1, 0, 'p'},
    {"tls",      0, 0, 't'},
    {"starttls", 0, 0, 'x'},
    {"user",     1, 0, 'u'},
    {"password", 1, 0, 'v'},
    {"path",     1, 0, 'l'},
    {"apop",     0, 0, 'a'},
    {"oauth",    0, 0, 'o'},
    {"cache",    1, 0, 'c'},
    {"flags",    1, 0, 'f'},
        {"debug-stream", 0, 0, 'D'},
        
static struct storage_name storage_tab[] = {
  {POP3_STORAGE, "pop3"},
  {IMAP_STORAGE, "imap"},
  {NNTP_STORAGE, "nntp"},
  {MBOX_STORAGE, "mbox"},
  {MH_STORAGE, "mh"},
  {MAILDIR_STORAGE, "maildir"},
  {FEED_STORAGE, "feed"},
};


readmsg.exe -d imap -s imap.139.com -p 143 -u 15313159857@139.com -v 9857139i94 -l INBOX 2445 2446
蓝色为uid
回复 支持 反对

使用道具 举报

1272

主题

2067

帖子

7962

积分

认证用户组

Rank: 5Rank: 5

积分
7962
5#
发表于 2020-1-27 15:40:08 | 只看该作者
本帖最后由 Qter 于 2020-1-27 15:43 编辑



telnet imap.163.com 143
* OK Coremail System IMap Server Ready(163com[10774b260cc7a37d26d71b52404dcf5c])
1 capability
* CAPABILITY IMAP4rev1 XLIST SPECIAL-USE ID LITERAL+ STARTTLS XAPPLEPUSHSERVICE
UIDPLUS X-CM-EXT-1
1 OK CAPABILITY completed
2 login "xxx" "xxx"
2 OK LOGIN completed
3 select INBOX
3 NO SELECT Unsafe Login. Please contact kefu@188.com for help
4 SELECT INBOX
回复 支持 反对

使用道具 举报

1272

主题

2067

帖子

7962

积分

认证用户组

Rank: 5Rank: 5

积分
7962
6#
发表于 2020-1-27 16:05:14 | 只看该作者
* OK RICHINFO System IMap Server Ready (caixuns[37425e2e9764fa8-00000])
1 capability
* CAPABILITY IMAP4rev1 XLIST ID RM_MAIL_TYPE UIDPLUS
8 login "xxx@139.com" "xx"
8 OK login completed
9 select INBOX
* 33 EXISTS
* 0 RECENT
* OK [UIDVALIDITY 1] UIDs valid
* FLAGS (\Answered \Seen \Deleted \Draft \Flagged)
* OK [PERMANENTFLAGS (\Answered \Seen \Deleted \Draft \Flagged)] Limited
9 OK [READ-WRITE] select completed
11 UID fetch 1:* (FLAGS)
* 1 FETCH (UID 2445 FLAGS (\Seen))
* 2 FETCH (UID 2446 FLAGS (\Seen))
* 3 FETCH (UID 2447 FLAGS (\Seen))
* 4 FETCH (UID 2448 FLAGS (\Seen))
* 5 FETCH (UID 2449 FLAGS (\Seen))
* 6 FETCH (UID 2450 FLAGS (\Seen))
* 7 FETCH (UID 2451 FLAGS (\Seen))
* 8 FETCH (UID 2452 FLAGS (\Seen))
* 9 FETCH (UID 2453 FLAGS (\Seen))
* 10 FETCH (UID 2454 FLAGS (\Seen))
* 11 FETCH (UID 2455 FLAGS (\Seen))
* 12 FETCH (UID 2456 FLAGS (\Seen))
* 13 FETCH (UID 2457 FLAGS (\Seen))
* 14 FETCH (UID 2458 FLAGS (\Seen))
* 15 FETCH (UID 2459 FLAGS (\Seen))
* 16 FETCH (UID 2460 FLAGS (\Seen))
* 17 FETCH (UID 2461 FLAGS (\Seen))
* 18 FETCH (UID 2462 FLAGS (\Seen))
* 19 FETCH (UID 2463 FLAGS (\Seen))
* 20 FETCH (UID 2464 FLAGS (\Seen))
* 21 FETCH (UID 2465 FLAGS (\Seen))
* 22 FETCH (UID 2466 FLAGS (\Seen))
* 23 FETCH (UID 2467 FLAGS (\Seen))
* 24 FETCH (UID 2468 FLAGS (\Seen))
* 25 FETCH (UID 2469 FLAGS (\Seen))
* 26 FETCH (UID 2470 FLAGS (\Seen))
* 27 FETCH (UID 2471 FLAGS (\Seen))
* 28 FETCH (UID 2472 FLAGS (\Seen))
* 29 FETCH (UID 2538 FLAGS (\Seen))
* 30 FETCH (UID 2561 FLAGS (\Seen))
* 31 FETCH (UID 2675 FLAGS (\Seen))
* 32 FETCH (UID 2676 FLAGS (\Seen))
* 33 FETCH (UID 2736 FLAGS (\Seen))
11 OK Fetch completed
20 UID fetch 2445 (UID RFC822.SIZE FLAGS BODY.PEEK[HEADER.FIELDS (From To Cc Bcc Subject Date Message-ID Received Priority X-Priority References Newsgroups In-Reply-To Content-Type X-CLIENT-INFO)])
* 1 FETCH (UID 2445 FLAGS (\Seen) RFC822.SI
ZE 4663 BODY[HEADER.FIELDS (From To Cc Bcc Subject Date Message-ID Received Prio
rity X-Priority References Newsgroups In-Reply-To Content-Type X-CLIENT-INFO)] {
470}
From: =?UTF-8?B?5Lit5Zu956e75Yqo5ZKM6YCa6KGM6K+B?= <umc_service@139.com>
To: 15313159857@139.com
Subject: =?UTF-8?B?5ZKM6YCa6KGM6K+BLeWvhueggeWPmOabtA==?=
Date: Thu, 16 Mar 2017 16:22:46 +0800 (CST)
Message-ID: <813132157.69863.1489652566778.JavaMail.api@umc-api4>
Received: from umc-api4 (unknown[211.136.10.139])by rmsmtp-rmapp-09-12025 (RichM
ail) with SMTP id 2ef958ca4b56a9e-30ac3;Thu, 16 Mar 2017 16:22:47 +0800 (CST)
Content-Type: text/html;charset=utf-8

)
20 OK Fetch completed


回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|Archiver|手机版|小黑屋|firemail ( 粤ICP备15085507号-1 )

GMT+8, 2024-11-26 07:10 , Processed in 0.062269 second(s), 18 queries .

Powered by Discuz! X3

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表