Winwebmail is a lightweight email server system suitable for small and medium-sized enterprises. It has complete functions. For more information, see the official website: 3.7.6.1 Enterprise Edition, during installation, it automatically generates website file directories, all of which are ASP pages. in IIS, create a virtual directory pointing to the web folder and Configure permissions according to some of its instructions, in this way, we can use its email service on the webpage.
Its Web Client is relatively simple, but all of its functions are available. the first time you use admin to add a domain, and then add another user, we will have the mailbox for this domain name. NOTE: If your machine does not have an independent network IP address or the domain name is not resolved to you, you can also add a domain, for example, I add a Microsoft.com domain, and then add a user jonllen to it, then I log into the jonllen@microsoft.com user, I can also send out the mail with its user name, haha, but the other party should see in the spam, generally, the email server checks whether the email domain name and the source of the email are in the same place. If it is not in the same place, it deems the email as a fake spam and you cannot receive the reply from the recipient, because Microsoft.com is not resolved to you, let's take a look at a winwebmail post-login.
It is often not enough to send emails only on Web pages. for example, the system automatically sends emails, scheduled group emails, and so on. These operations cannot be manually sent to its page. Instead, you mustProgramAnd may need to develop a set of OA recently, which requires enterprise mail. To register an account in OA, you need to open an email account and create an enterprise employee address book, emails communicate with each other internally and can be directly sent to external mailboxes. However, winwebmail seems to provide interfaces in the form of web page access, but opens ASP pages in it, we can see some ofCode.
Dim EI
Set EI = Server. Createobject ( " Easymail. infolist " )
Username = Session ( " Wem " )
EI. loadmailbox username, Trim (Request ( " Mode " ))
' -----------------------------------------
Anyone familiar with ASP knows that it uses server. createobject is used to create an object. For example, server is used for data connection operations. createobject, while the variables in ASP are weak variable types that can be used without being declared, the above Code contains server. createobject ("easymail. infolist ") What object is created? Suddenly, winwebmail has a C/S client interface, but the operation can be seen only when it is on the server. The function is relatively simple, and users and configuration domains can be added, you can also modify some system settings, open task management, and view all processes. You can see that it is actually a program, you can also close it, but there is also a process named emsvr, it is the background service of the webwinweb mail system. The core is here! So how do they implement mutual calls? Careful programmers will soon think of using COM components, because COM components can conveniently call and communicate with each other through interfaces, or even add references to vs for different languages, and select COM components, there are components of winwebmail, such.
So, the above server. createobject can be interpreted as creating the called COM component object. since the COM component interface can be called, it is easy to do. because the COM component interface can be called across any language, if it is a standard DLL component, we can also reference it using an unmanaged dynamic link library method, but it seems that you must all know some of its method names and parameters. can't I find them one by one on those ASP pages? In addition, if you do not have relevant documents, you must first understand the entire page logic. Even if you have found them, it is not necessarily the method name you want. How should we change it? Didn't vs be used to reference com above? That's right! We add the COM component of webeasymail to the project. Vs will automatically generate an InterOP. easymaillib. DLL file to the bin directory, which is opened in the object browser. The interface attribute classes in the directory are listed as follows.
We need to call the COM interface, so the class we call it to generate is so simple and convenient. when writing code, we first instantiate the class in it. We can see that there are many methods and attributes in the class. at the beginning, you may not understand some of its attributes and methods. however, you can open the code on its ASP page and take a look at the entire process of calling it. Maybe you have some thoughts. for general purposes, I used C # To write some common operations as the WebService method. here I post a method to return the user's Folder Information (including name, total quantity, and number of new mails.
[Webmethod (Description = " The Returned mail box contains the name, number, size, and other information. " )]
[System. xml. serialization. xmlinclude ( Typeof (Mailbox)]
[Soapheader ( " Usheader " , Direction = Soapheaderdirection. In)]
Public Mailbox [] getmailboxes ( String Username)
{
Infolistclass Infos = New Infolistclass ();
If ( ! Username. Contains ( " @ " ))
Username + = System. configuration. configurationmanager. configurettings [ " Emailpostfix " ];
Infos. loadsizeinfo (username );
System. Collections. Generic. List < Mailbox > List = New System. Collections. Generic. List < Mailbox > ();
List. Add ( New Mailbox ( " Inbox " , " In " , Infos. inboxmailcount, Infos. newinboxmailcount, Infos. inboxmailsize ));
List. Add ( New Mailbox ( " Draft box " , " Out " , Infos. outboxmailcount, Infos. newoutboxmailcount, Infos. outboxmailsize ));
List. Add ( New Mailbox ( " Sender " , " Sed " , Infos. sendboxmailcount, Infos. newsendboxmailcount, Infos. sendboxmailsize ));
List. Add ( New Mailbox ( " Waste bin " , " Del " , Infos. delboxmailcount, Infos. newdelboxmailcount, Infos. delboxmailsize ));
For ( Int I = 0 ; I < Infos. perfoldercount; I ++ )
{
Mailbox box = New Mailbox ();
Infos. getperfolderinfo (I, Ref Box. Name, Ref Box. mailcount, Ref Box. size, Ref Box. newmailcount );
Box. Code = Box. Name. tostring ();
List. Add (box );
}
List. Add (NewMailbox ("Total","All", Infos. allmailcount, Infos. allnewmailcount, Infos. allmailsize ));
ReturnList. toarray ();
}
Other domains, users, and emails can also be written by analogy. However, you may need to refer to some methods on its ASP page to obtain the results only after correct calls. note: There is no entity object model in its interface, and all the results in it are assigned values using ref. Multiple results are obtained through the for loop, it seems that the ASP page is also called like this. debugging is also depressing. because it is a local LAN in the company, I can't even call the methods I wrote above, and no error is reported, that is, no result is returned, but you can do anything in its ASP Website! I have been depressed for a long time. later, I uploaded the code to the server and accessed it directly using WebService. that proves that the methods I wrote are correct. Is there a problem? I still don't quite understand.
However, since it can run on the server, it is OK, because the mail server will eventually be deployed on the server, in this way, we can also provide WebService methods for adding users, enterprise address book, and sending and receiving emails, if the company also has OA, ERP, human resources management systems, and so on can be easily called, and unified user management under the domain can be achieved, mail communication between enterprise users and employees. if you want to use the email system, consider using winwebmail. here is a cracked version of winwebmailv3.7.6.1, which is only for non-commercial use for learning and testing. If you are interested, you can download it. For official use, please go to the official website to purchase a paid version.
Download winwebmailv3.7.6.1 cracked Enterprise Edition
Note: Unless otherwise stated, this article is original to jonllen and the copyright is owned by the original author. Article The original text connection is clearly displayed on the page. Otherwise, the legal liability is retained.