winzip icon

vServe

Email
Submitted on: 2/10/2015 12:07:00 PM
By: V2 (from psc cd)  
Level: Intermediate
User Rating: By 6 Users
Compatibility: VB 6.0
Views: 1311
 
     vServe v0.1 We Serve All What Is vServe vServe is a plugin based Open Source Server Written Entirely In Microsoft® Visual Basic® 6.0, as this application use plugins for all the work it does, so it can virtually serve any service if there is a plugin available for that. At this time vServe supports only two kinds of plugins: 1) PROTOCOL HANDLER 2) SCRIPT HANDLER PROTOCOL HANDLER Protocol handler is used to handle request coming from clients protocol handler intercept the data coming from client and act accordingly. For Example , I have given sample plugins for HTTP And FTP handler though these are very basic handlers but can be extended to get full functionality of those protocols. SCRIPT HANDLER Script handler is used to intercept data and perform server side scripting before sending data to client. You can create your own scripting language or can create handlers to support already available scripting languages like ASP or PHP for web. How It Works vServe when started scans for all the plugins or filters in the FILTERS directory it is smart enough to distinguished between protocol handler and script handler and load them appropriately. Once the plugins are loaded into memory your server is ready to go. Architecture Of Plugins Every plugin is a ActiveX DLL File which has four Procedures: 1) GetInfo 2) Parser 3) Configure 4) About 1) GetInfo GetInfo function is used to get the information of plugin to determine what kind of plugin is it GetInfo Function is of string type and return following values Name = Plugin Name Description = Plugin Description Version = Plugin Version Type = Plugin Type (Protocol Or Script) Port = Port To Listen ( Required If Type Is Protocol ) 2) Parser Parser function is used to parse the data and is main function without which plugin is incomplete. Parser function is defined as Public Function Parser(ByVal strInput As String, Optional ByVal LongReserved As Long, Optional ByVal StrReserved As String) As String strInput is the data being sent by vServe To Plugin LongReserved And StrReserved are reserved for future use so can be ignored. This function return the data back to the Server ie. vServe which is then send to client. Note: If the plugin type is protocol then the data being sent back to vServe by plugin is once again sent to all the filters loaded to support server side scripting. 3) Configure This function can be used to configure the plugin for various reasons and return BOOLEAN a TRUE value indicates that plugin configuration has been updated so that vServe can update itself accordingly. 4) About This function is used to display plugin information. Assumptions Every plugin in the FILTERS folder should follow naming convention .[ANYTHING] Eg: HTTP.DLL or HTTP.plg or HTTP.ANYTHING The Future I have initiated this project as I always interested in Plugin based architecture and this Is my one of favorite area of Development after Client / Server based applications and as this application has both my interests so all I can say is that this is just a beginning and I need support of all you lovely and intelligent people to work with me to take this journey to its destination. Contact Info Email: v2Softwares@yahoo.com Y! Chat: v2Softwares

 
winzip iconDownload code

Note: Due to the size or complexity of this submission, the author has submitted it as a .zip file to shorten your download time. Afterdownloading it, you will need a program like Winzip to decompress it.Virus note:All files are scanned once-a-day by Planet Source Code for viruses, but new viruses come out every day, so no prevention program can catch 100% of them. For your own safety, please:
  1. Re-scan downloaded files using your personal virus checker before using it.
  2. NEVER, EVER run compiled files (.exe's, .ocx's, .dll's etc.)--only run source code.
  3. Scan the source code with Minnow's Project Scanner

If you don't have a virus scanner, you can get one at many places on the net including:McAfee.com


Other 6 submission(s) by this author

 


Report Bad Submission
Use this form to tell us if this entry should be deleted (i.e contains no code, is a virus, etc.).
This submission should be removed because:

Your Vote

What do you think of this code (in the Intermediate category)?
(The code with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor (See voting log ...)
 

Other User Comments


 There are no comments on this submission.
 

Add Your Feedback
Your feedback will be posted below and an email sent to the author. Please remember that the author was kind enough to share this with you, so any criticisms must be stated politely, or they will be deleted. (For feedback not related to this particular code, please click here instead.)
 

To post feedback, first please login.