<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- Start of accounts.htm --><!-- delayed after doctype-->
<html>
<head>
<link rel="stylesheet" type="text/css" href="template/css2/netwin.css">
	<script type="text/javascript" src="template/js2/netwin.js"></script>
<!--
	<script type="text/javascript" src="template/js2/dbg.js"></script>
-->

<!--
	<link rel="stylesheet" type="text/css" href="template/css2/netwin.css">

	<link rel="stylesheet" type="text/css" href="template/css2/test.css">
	<link rel="stylesheet" type="text/css" href="template/css2/sw.css">
	<link id ="cnr_css" rel="stylesheet" type="text/css" href="template/css2/cnr4.css">
-->

<!--[if lt IE 7]>
	<link rel="stylesheet" href="template/css2/ie6.css" type="text/css" />
<![endif]-->


<!-- Back to accounts.htm -->

<!-- #BeginEditable "Headerstuff"-->
<title>Managing accounts</title>
<META NAME="keywords" CONTENT="">
<META NAME="description" CONTENT="">
<meta http-equiv="Content-Type" content="text/html;">


<!-- #EndEditable -->
</head>
<body class="s_body">


<div id="width_limit_div" class="width_limit" style="padding-bottom:0;">

<!-- HEADER CONTENT -->
<div class="header">
  <div class="search_box"><table valign="center" cellSpacing="0" cellPadding="0" border="0">
	<form id="form1" name="form1" method="GET" action="http://www.google.com/custom">

	  <input type=hidden name=domains id=search_domains value="netwinsite.com">
	  <input type=hidden name=sitesearch id=search_sitesearch value="netwinsite.com">
	  <input type=hidden name=cof VALUE="LW:135;L:http://www.netwinsite.com/img2/logo_med_onwhite.png;LH:44;AH:center;S:http://www.netwinsite.com;AWFID:773914251fd85055;">

	  <tr valign="center">
		<td valign="center" style="padding-right:5px;"><span id="search_description" style="font-family:Verdana,Arial,Helvetica; font-size:9pt; ">Search website:</span>
		</td>
		<td valign="center">
			<input size="15" maxLength="80" name="q" style="font-family: Tahoma, Arial; font-size: 8pt">
		</td>
		<td valign="center">
			<input TYPE="image" src="template/img2/search.gif" alt="Search Netwinsite.com!" Name="I1" style="width:17px;height:17px;margin-left:5px;border:0;">
		</td>
	  </tr>
	</form>
  </table></div>

  <div class="page_logo"><table valign="center" border="0" cellpadding="0" cellspacing="10" >
	  <tr>
		<td style="padding-left:20px;">
		  <a href=""><img border="0" src="template/img2/logo_med_onwhite.png" height="44px" vspace="5" id="main_logo"> </a>
		</td>
		<td>
		  <div style="padding-top:14px;">
			<span class="s_header_text">Advanced Server Software<span>
		  </div>
		</td>
	  </tr>
  </table></div>
</div>

<!-- MENU CONTENT -->
<div class="bar_padding" onmousemove="stopEvent(event);return false;">
	<div class="bar" style="text-align:center">
		<table id="page_menu" class="t menu" onmousemove="menu_handler(event);" style="margin:auto"><tr>
	<td valign=top><table class="top_item" mid="menu_home"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/index.htm" class="pad">Home</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_products"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/products.htm" class="pad">Products</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_download"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/download.htm" class="pad">Download</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_buy"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/prices.htm" class="pad">Buy&nbsp;Now</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_support"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/support.htm" onmouseup="x()" class="pad">Support</a><td class="btn_r"></table>
	<td valign=top><table class="top_item" mid="menu_company"><tr><td class="btn_l"><td class="btn_c"><a href="http://netwinsite.com/company.htm" onmouseup="x()" class="pad">Company</a><td class="btn_r"></table>
		</table>
	</div>

	<div id="menu_home" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_home')" onmouseout="menu_action_mouseout(event,'menu_home')" onmouseover="menu_action_mouseover(event,'menu_home')" style="width:220px; display:none;">
	</div>

	<div id="menu_products" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_products')" onmouseout="menu_action_mouseout(event,'menu_products')" onmouseover="menu_action_mouseover(event,'menu_products')" style="width:220px;">
		<a href="http://netwinsite.com/surgemail/" class="menu_row pad2"><div class="menu_icon_surgemail"></div>
			SurgeMail<span class="menu_extra"></span><br><span class="menu_info">Fully featured email server </span></a>
		<a href="http://netwinsite.com/surgeftp/" onmouseup="x()" class="menu_row pad2 divider"><div class="menu_icon_surgeftp"></div>
			SurgeFTP<span class="menu_extra"></span><br><span class="menu_info">High performance FTP server </span></a>
		<a href="http://netwinsite.com/dbabble/index.html" onmouseup="x()" class="menu_row pad2"><div class="menu_icon_dbabble"></div>
			DBabble <span class="menu_extra"></span><br><span class="menu_info">Instant messenging server </span></a>
		<a href="http://netwinsite.com/surgeweb/" onmouseup="x()" class="menu_row pad2 divider"><div class="menu_icon_surgeweb"></div>
			SurgeWeb<br><span class="menu_info">Modern Ajax web email client</span></a>
		<a href="http://netwinsite.com/products.htm" onmouseup="x()" class="menu_row divider">
			All products...</a>
	</div>

	<div id="menu_download" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_download')" onmouseout="menu_action_mouseout(event,'menu_download')" onmouseover="menu_action_mouseover(event,'menu_download')" style="width:220px">
		<a href="/cgi-bin/keycgi.exe?cmd=download&product=surgemail&" onmouseup="x()" class="menu_row"><div class="menu_icon_surgemail"></div>
			Surgemail<span class="menu_extra"></span></a>
		<a href="/cgi-bin/keycgi.exe?cmd=download&product=surgeftp&" onmouseup="x()" class="menu_row"><div class="menu_icon_surgeftp"></div>
			SurgeFTP<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/dbabble/download.htm" onmouseup="x()" class="menu_row"><div class="menu_icon_dbabble"></div>
			DBabble <span class="menu_extra"></span></a>
		<a href="/cgi-bin/keycgi.exe?cmd=download&product=surgemail&" onmouseup="x()" class="menu_row divider"><div class="menu_icon_surgeweb"></div>
			SurgeWeb</a>
		<a href="http://netwinsite.com/surgemail/help/install.htm" onmouseup="x()" class="menu_row">
			Installing Surgemail</a>
		<a href="http://netwinsite.com/download.htm" onmouseup="x()" class="menu_row">
			Download any product...</a>
	</div>

	<div id="menu_buy" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_buy')" onmouseout="menu_action_mouseout(event,'menu_buy')" onmouseover="menu_action_mouseover(event,'menu_buy')" style="width:220px">
		<a href="http://netwinsite.com/prices.htm" onmouseup="x()" class="menu_row divider">
			Pricing</a>
		<a href="http://netwinsite.com/https://netwinsite.com/cgi-bin/keycgi.exe?cmd=buy_new&product=surgemail" onmouseup="x()" class="menu_row"><div class="menu_icon_surgemail"></div>
			Surgemail<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/https://netwinsite.com/cgi-bin/keycgi.exe?cmd=buy_new&product=surgeftp" onmouseup="x()" class="menu_row"><div class="menu_icon_surgeftp"></div>
			SurgeFTP<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/https://netwinsite.com/cgi-bin/keycgi.exe?cmd=buy_new&product=dbabble" onmouseup="x()" class="menu_row"><div class="menu_icon_dbabble"></div>
			DBabble <span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/https://netwinsite.com/cgi-bin/keycgi.exe?cmd=buy_new&product=surgemail" onmouseup="x()" class="menu_row divider"><div class="menu_icon_surgeweb"></div>
			SurgeWeb</a>
		<a href="http://netwinsite.com/activate.htm" onmouseup="x()" class="menu_row">
			Activation guide</a>
		<a href="http://netwinsite.com/prices.htm" onmouseup="x()" class="menu_row">
			Purchase any product...</a>
	</div>

	<div id="menu_support" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_support')" onmouseout="menu_action_mouseout(event,'menu_support')" onmouseover="menu_action_mouseover(event,'menu_support')" style="width:220px">
		<a href="http://netwinsite.com/documentation.htm" onmouseup="x()" class="menu_row divider">
			Online documentation<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/surgemail/post.htm" onmouseup="x()" class="menu_row">
			Contact support<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/support.htm#email_list" onmouseup="x()" class="menu_row">
			Standard email support<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/http://news.netwinsite.com:8119/webnews?group=netwin.surgemail&cmd=list" onmouseup="x()"  class="menu_row divider">
			Community forum <span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/support.htm" onmouseup="x()" class="menu_row">
			Support overview...</a>
	</div>

	<div id="menu_company" class="xmenu hidden" onmouseup="menu_hide_ex(event,'menu_company')" onmouseout="menu_action_mouseout(event,'menu_company')" onmouseover="menu_action_mouseover(event,'menu_company')" style="width:220px">
		<a href="http://netwinsite.com/company.htm" onmouseup="x()" class="menu_row">
			About us<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/surgemail/customers.htm" onmouseup="x()" class="menu_row">
			Customers<span class="menu_extra"></span></a>
		<a href="http://netwinsite.com/support.htm#sales_questions" onmouseup="x()" class="menu_row divider">
			Contact us</a>
	</div>
	<div style="background:url(template/img2/white_small.png);height:8px;font-size:1px;"></div>
</div>
<!-- Back to accounts.htm -->

<div class="content_outer">


<!-- Back to accounts.htm -->
<div class="L2C2_column_left">
<!-- Back to accounts.htm -->
<div style="width:160px;">
  <div id="floating_index" class="floating_index nav-menu _document_index" style="width:160px;">
	<h2 class="menu_top">Help Index</h2>
	<ul class="level-0">

		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">Getting Started</a><ul class="level-1">
			<li id="idx_surgemail.htm"><a href="surgemail.htm" target="_top">SurgeMail in a nutshell</a><ul class="level-2"></ul></li>
			<li id="idx_startingoff.htm"><a href="startingoff.htm" target="_top">Before you install</a><ul></ul></li>
			<li id="idx_install.htm"><a href="install.htm" target="_top">Installation &amp; Upgrading</a><ul></ul></li>
			<li id="idx_migration.htm"><a href="migration.htm" target="_top">Migration to SurgeMail</a><ul></ul></li>
			<li id="idx_updates.htm"><a href="updates.htm" target="_top">Change history</a><ul></ul></li>
			<li id="idx_postinstall.htm"><a href="postinstall.htm" target="_top">Post Installation</a><ul></ul></li>
			<li id="idx_faq.htm"><a href="faq.htm" target="_top">FAQ</a><ul></ul></li>
			<li id="idx_support.htm"><a href="support.htm" target="_top">Customer Support</a><ul></ul></li>
		</ul></li>

		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">Anti Spam / Virus</a><ul class="level-1">
			<li id="idx_protected.htm"><a href="protected.htm#virusscanner">Virus Protection</a></li>
			<li id="idx_spam.htm"><a href="spam.htm">Spam Prevention</a></li>
			<li id="idx_protected.htm"><a href="protected.htm#mfilter">Mail Filtering</a> </li>
			<li id="idx_protected.htm"><a href="protected.htm#friends">Friendly Relations System</a></li>
			<li id="idx_rbl.htm"><a href="rbl.htm">Realtime Blackhole Lists</a></li>
		</ul></li>

		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">Server Management </a><ul class="level-1">
			<li id="idx_status.htm"><a href="status.htm">Server Status</a></li>
			<li id="idx_log.htm"><a href="log.htm">Searching the log files</a></li>
			<li id="idx_report.htm"><a href="report.htm">Report generation</a></li>
			<li id="idx_accounts.htm"><a href="accounts.htm">Managing accounts</a></li>
			<li id="idx_tellmail.htm"><a href="tellmail.htm">Using the tellmail utility.</a></li>
		</ul></li>
		
		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">SurgeMail Settings</a><ul class="level-1">
			<li id="idx_domain.htm"><a href="domain.htm">Domain specific settings</a></li>
			<li id="idx_global.htm"><a href="global.htm">Global settings</a></li>
			<li id="idx_webmail.htm"><a href="webmail.htm">WebMail settings</a></li>
		</ul></li>

		<li class="group_hidden"><a href="#" onclick="index_toggle(event)">Configuration Guides</a><ul class="level-1">
			<li id="idx_authent.htm"><a href="authent.htm">Authentication  Modules</a></li>
			<li id="idx_domains.htm"><a href="domains.htm">Virtual  Domains</a></li>
			<li id="idx_clustering.htm"><a href="clustering.htm">Clustering</a></li>
			<li id="idx_mirror.htm"><a href="mirror.htm">Mirror the server</a></li>
			<li id="idx_scalable.htm"><a href="scalable.htm">Performance &amp; Scalability</a></li>
			<li id="idx_lookandfeel.htm"><a href="lookandfeel.htm">Custom look and feel</a></li>
			<li id="idx_internal_email.htm"><a href="internal_email.htm">Custom internal emails </a></li>
			<li id="idx_language.htm"><a href="language.htm">Language translation</a></li>
			<li id="idx_redirection.htm"><a href="redirection.htm">Mail Redirection</a></li>
			<li id="idx_surgewall.htm"><a href="surgewall.htm">SurgeWall</a></li>
			<li id="idx_sms.htm"><a href="sms.htm">SMS</a></li>
			<li id="idx_lists.htm"><a href="lists.htm">Mailing lists and bulletins</a></li>
			<li id="idx_secure.htm"><a href="secure.htm">Securing the server</a></li>
			<li id="idx_incoming.htm"><a href="incoming.htm">Incoming MX servers</a></li>
			<li id="idx_load_balance.htm"><a href="load_balance.htm">Load balancing</a></li>
			<li id="idx_ndb.htm"><a href="ndb.htm">NDB NetWin folder format</a></li>
			<li id="idx_domainkeys.htm"><a href="domainkeys.htm">DomainKeys Support</a></li>
			<li id="idx_ipv6.htm"><a href="ipv6.htm">IPV6 Support</a></li>
			<li id="idx_examples.htm"><a href="examples.htm">Example configurations</a></li>
		</ul></li>
	</ul>
  </div>
  &nbsp;	<!-- required to render div -->
</div>
<script>window.do_scroll_menu=false</script>
<!-- Back to accounts.htm -->
</div>

<!-- Back to accounts.htm -->

<div class="L2C2_column_content">
<!-- Back to accounts.htm -->
<!-- #BeginEditable "Body" -->
 
<script language="JavaScript"> search_details('Search SurgeMail Manual:','http://netwinsite.com/surgemail/help'); </script>
<script language="JavaScript"> display_crumbs_doc(['Home','Documentation','SurgeMail Help Index','Managing Accounts'],3); </script>
<script language="JavaScript"> index_select('idx_accounts.htm'); </script>
<h1>Managing Accounts</h1>
<h2>Account Creation</h2>
<h3><a name="user"></a>Account Creation - User Self Creation</h3>
<p><font face="Arial, Helvetica, sans-serif">Users can optionally create or sign-up 
  for accounts via the web interface on the user port ie:</font></p>
<p><font face="Arial, Helvetica, sans-serif"><a href="https://localhost:7443/cgi/user.cgi?cmd=user_check">https://localhost:7443/cgi/user.cgi?cmd=user_check</a></font></p>
<p><font face="Arial, Helvetica, sans-serif">There are several different methods, 
  the method being used is specified per domain using the domain setting <a href="domain.htm#create_user">create 
  user</a>.</font> </p>
<h3><a name="manager"></a>Account Creation - Manager</h3>
<p><font face="Arial, Helvetica, sans-serif" >User administration is done via 
  the &quot;User accounts&quot; option in the web admin contents. </font></p>
<p><font face="Arial, Helvetica, sans-serif"><a href="https://localhost:7025/cgi/admin.cgi">https://localhost:7025/cgi/admin.cgi</a></font></p>
<p><font face="Arial, Helvetica, sans-serif" >This will display a page that allows 
  you to lookup, create, modify and search for users. </font><font face="Arial, Helvetica, sans-serif">Once 
  you have looked up an existing user you can change a user's password, edit any 
  of the user's information including forwarding or delete them. </font></p>
<p><font face="Arial, Helvetica, sans-serif">Domain administrators, configured 
  by the <a href="domain.htm#manager_username">manager_username</a> setting, log 
  in to the user self management interface:</font></p>
<p><font face="Arial, Helvetica, sans-serif"><a href="https://localhost:7443/cgi/user.cgi?cmd=user_check">https://localhost:7443/cgi/user.cgi</a></font></p>
<p><font face="Arial, Helvetica, sans-serif"> and have access to this users page 
  for all the domains they manage.</font></p>
<h2><a name="interface"></a>Interfacing with the user management system</h2>
<p><font face="Arial, Helvetica, sans-serif">The user management system is an 
  HTTP based system using GET and POST commands to perform actions. If you want 
  to provide some or all of these options elsewhere you can do so by interfacing 
  with it using these HTTP commands. For example here is a simple HTTP form which 
  will add a user.</font></p>
<p><font face="Arial, Helvetica, sans-serif">However you should also consider 
  the other two methods available to interface with accounts, which method you 
  choose will depend on your precise needs.</font></p>
<p><font face="Arial, Helvetica, sans-serif">1) the authent module can be talked 
  to directly using the authent protocol <a href="http://netwinsite.com/authent">http://netwinsite.com/authent</a><br>
  2) if the authent module is using a back end database (ldap, sql, etc...) then 
  the backend database can be used directly.</font></p>
<p><font face="Arial, Helvetica, sans-serif">To use the following examples to 
  experiment with save them as htm files and open them in your browser. To use 
  from a program you need to send the form as an http POST using tcpip. Many programming 
  languages have a mechanism for easily sending web 'forms' from a program so 
  will find this quite easy in some cases. <br>
  </font></p>
<p> <b>A form to 'add' a user:</b></p>
<blockquote> 
  <pre>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 3.2 Final//EN&quot;&gt;
&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;FORM NAME=&quot;Main&quot;      METHOD=&quot;POST&quot; ACTION=&quot;https://localhost:7443/cgi/user.cgi&quot;&gt;
&lt;br&gt; Fieldsd normally set to type Hidden to tell it what to do.
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;cmd&quot; VALUE=&quot;cmd_user_login&quot;&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;lcmd&quot; VALUE=&quot;user_create&quot;&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;show&quot; VALUE=&quot;simple_msg.xml&quot;&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;user_fields&quot; VALUE=&quot;user_id,quota,alias_quota,sms_quota,smsto&quot;&gt;
&lt;br&gt; Domain admin user: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;username&quot;      VALUE=&quot;X&quot;&gt;&lt;br&gt;
Domain Admin Pass: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;password&quot;      VALUE=&quot;Y&quot;&gt;&lt;br&gt;
Name &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;lusername&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;
Pass &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;lpassword&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;
uid &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;user_id&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;
SMS Phone Number &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;smsto&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;
Disk Quota&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;quota&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;
Alias Quota&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;alias_quota&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;
SMS Quota&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;sms_quota&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;
&lt;INPUT TYPE=&quot;submit&quot; NAME=&quot;Submit&quot; VALUE=&quot;Add      user&quot;&gt;
&lt;/FORM&gt;
&lt;/BODY&gt;
&lt;/HTML&gt;
</pre>
</blockquote>
<p><b>A form to 'delete' a user:</b></p>
<blockquote> 
  <pre>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 3.2 Final//EN&quot;&gt;<br>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;FORM NAME=&quot;Main&quot; METHOD=&quot;POST&quot; ACTION=&quot;https://localhost:7443/cgi/user.cgi&quot;&gt;
&lt;br&gt;Fields normally set to type Hidden to tell it what to do.
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;cmd&quot; VALUE=&quot;cmd_user_login&quot;&gt;<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;lcmd&quot; VALUE=&quot;user_delete&quot;&gt;<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;show&quot; VALUE=&quot;simple_msg.xml&quot;&gt;<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;user_fields&quot; VALUE=&quot;user_id,quota,alias_quota,sms_quota,smsto&quot;&gt;
&lt;br&gt;Domain admin user: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;username&quot; VALUE=&quot;X&quot;&gt;&lt;br&gt;
Domain Admin Pass: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;password&quot; VALUE=&quot;Y&quot;&gt;&lt;br&gt;<br>Name &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;lusername&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>Pass &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;lpassword&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>uid &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;user_id&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>SMS Phone Number &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;smsto&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>Disk Quota&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;quota&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>Alias Quota&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;alias_quota&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>SMS Quota&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;sms_quota&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>&lt;INPUT TYPE=&quot;submit&quot; NAME=&quot;Submit&quot; VALUE=&quot;Del User&quot;&gt;<br>&lt;/FORM&gt;<br>&lt;/BODY&gt;<br>&lt;/HTML&gt;<b>
</b>
</pre>
</blockquote>
<p><b>A form to Modify/Save changes to a user:</b></p>
<blockquote> 
  <pre>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 3.2 Final//EN&quot;&gt;<br>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;FORM NAME=&quot;Main&quot; METHOD=&quot;POST&quot; ACTION=&quot;https://localhost:7443/cgi/user.cgi&quot;&gt;<br>&lt;br&gt;Fields normally set to type Hidden to tell it what to do.<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;cmd&quot; VALUE=&quot;cmd_user_login&quot;&gt;<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;lcmd&quot; VALUE=&quot;user_updatex&quot;&gt;<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;show&quot; VALUE=&quot;simple_msg.xml&quot;&gt;<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;user_fields&quot; VALUE=&quot;user_id,quota,alias_quota,sms_quota,smsto&quot;&gt;<br>&lt;br&gt;Domain admin user: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;username&quot; VALUE=&quot;X&quot;&gt;&lt;br&gt;<br>Domain Admin Pass: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;password&quot; VALUE=&quot;Y&quot;&gt;&lt;br&gt;<br>Name &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;lusername&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>Pass &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;lpassword&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>uid &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;user_id&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>SMS Phone Number &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;smsto&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>Disk Quota&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;quota&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>Alias Quota&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;alias_quota&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>SMS Quota&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;sms_quota&quot; VALUE=&quot;&quot;&gt;&lt;br&gt;<br>&lt;INPUT TYPE=&quot;submit&quot; NAME=&quot;Submit&quot; VALUE=&quot;Modify User&quot;&gt;<br>&lt;/FORM&gt;<br>&lt;/BODY&gt;<br>&lt;/HTML&gt;</pre>
</blockquote>
<p><b>Example to create a domain (note this uses manager port):</b></p>
<pre>
&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 3.2 Final//EN&quot;&gt;<br>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;FORM NAME=&quot;Main&quot; METHOD=&quot;POST&quot; ACTION=&quot;https://localhost:7025/cgi/admin.cgi&quot;&gt;
<p>&lt;br&gt; Fields normally set to type Hidden to tell it what to do.<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;cmd&quot; VALUE=&quot;global_misc_save&quot;&gt; &lt;br&gt;<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;misc_settings&quot; VALUE=&quot;domain_name,url_host,manager_email,manager_username,manager_password,create_user,create_max&quot;&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;misc_cmd&quot; VALUE=&quot;special&quot;&gt; 
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;domainid&quot; VALUE=&quot;-1&quot;&gt;<br>&lt;p&gt;</p><p>(mx) Domain: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;name&quot; VALUE=&quot;new.domain&quot;&gt;&lt;br&gt;<br>(A) Host Name: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;url_host&quot; VALUE=&quot;mail.new.domain&quot;&gt;&lt;br&gt;<br> Manager email: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;manager_email&quot; VALUE=&quot;test@new.domain&quot;&gt;&lt;br&gt;<br> Manager account: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;manager_username&quot; VALUE=&quot;test@new.domain&quot;&gt;&lt;br&gt;<br> Manager password: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;manager_password&quot;  VALUE=&quot;secret&quot;&gt;&lt;br&gt;<br>&lt;p&gt;<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;force_page&quot; VALUE=&quot;simple_msg.xml&quot;&gt;<br>&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;doframes&quot; VALUE=&quot;false&quot;&gt;<br>&lt;INPUT TYPE=&quot;submit&quot; NAME=&quot;Submit&quot; VALUE=&quot;Add Domain&quot;&gt;<br>&lt;/FORM&gt;<br>&lt;/BODY&gt;<br>&lt;/HTML&gt;<br></pre>
<p><b>Delete a domain:</b></p>
<p>&nbsp;</p>
<blockquote> 
  <pre>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 3.2 Final//EN&quot;&gt;
&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;FORM NAME=&quot;Main&quot;      METHOD=&quot;POST&quot; ACTION=&quot;https://localhost:7025/cgi/admin.cgi&quot;&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;cmd&quot; VALUE=&quot;domain_delete&quot;&gt;      &lt;br&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;domainid&quot; VALUE=&quot;-1&quot;&gt;
&lt;p&gt;</pre>
  <pre>Domain: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;domain&quot; VALUE=&quot;new.domain&quot;&gt;&lt;br&gt;
Delete users&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;delete_users&quot;      VALUE=&quot;true&quot;&gt;&lt;br&gt;
Delete files&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;delete_files&quot;      VALUE=&quot;true&quot;&gt;&lt;br&gt;
&lt;p&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;force_page&quot; VALUE=&quot;simple_msg.xml&quot;&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;doframes&quot; VALUE=&quot;false&quot;&gt;
&lt;INPUT TYPE=&quot;submit&quot; NAME=&quot;Submit&quot; VALUE=&quot;Delete      Domain&quot;&gt;
&lt;/FORM&gt;
&lt;/BODY&gt;
&lt;/HTML&gt;
   </pre>
</blockquote>
<p><b>Check if a domain exists</b></p>
<p>&nbsp;</p>
<blockquote> 
  <pre>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 3.2 Final//EN&quot;&gt;
&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;FORM NAME=&quot;Main&quot;      METHOD=&quot;POST&quot; ACTION=&quot;https://localhost:7025/cgi/admin.cgi&quot;&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;cmd&quot; VALUE=&quot;domain_exists&quot;&gt;      &lt;br&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;domainid&quot; VALUE=&quot;-1&quot;&gt;
&lt;p&gt;</pre>
  <pre>Domain: &lt;INPUT TYPE=&quot;text&quot; NAME=&quot;domain&quot; VALUE=&quot;new.domain&quot;&gt;&lt;br&gt;
Delete users&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;delete_users&quot;      VALUE=&quot;true&quot;&gt;&lt;br&gt;
Delete files&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;delete_files&quot;      VALUE=&quot;true&quot;&gt;&lt;br&gt;
&lt;p&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;force_page&quot; VALUE=&quot;simple_msg.xml&quot;&gt;
&lt;INPUT TYPE=&quot;text&quot; NAME=&quot;doframes&quot; VALUE=&quot;false&quot;&gt;
&lt;INPUT TYPE=&quot;submit&quot; NAME=&quot;Submit&quot; VALUE=&quot;Check Domain&quot;&gt;
&lt;/FORM&gt;
&lt;/BODY&gt;
&lt;/HTML&gt;
   </pre>
</blockquote>
<p>&nbsp;</p>
<p><b>For responses you can setup an xml file, something like this: simple_msg.xml 
  </b><b>contains (this is placed in the surgemail/web folder)</b> </p>
<blockquote> 
  <pre>&lt;?xml version=&quot;1.0&quot; ?&gt;
       &lt;rss version=&quot;2.0&quot;&gt;
       &lt;xml_status&gt;&lt;/xml_status&gt;
       &lt;response&gt;&lt;/response&gt;
       &lt;response2&gt;&lt;/response2&gt;
       &lt;/rss&gt;</pre>
  <pre>&nbsp;</pre>
</blockquote>
<p><font face="Arial, Helvetica, sans-serif"><b>NOTE:</b></font></p>
<ul>
  <li><font face="Arial, Helvetica, sans-serif">The username and password fields, 
    these should contain the username and password of a domain admin user (see 
    <a href="domain.htm#manager_username">manager_username</a>).</font> </li>
  <li><font face="Arial, Helvetica, sans-serif">The user_fields field specifies 
    the names of the fields containing user information to add.</font></li>
  <li><font face="Arial, Helvetica, sans-serif">The new users name and password 
    are supplied in the lusername and lpassword fields.</font></li>
  <li><font face="Arial, Helvetica, sans-serif">The show field is used to select 
    the output page. This file must exist in the surgemail web directory. It is 
    not required to be XML, that was just used as an example of a format you might 
    easily be able to parse. The content of the file may be absolutely anything 
    you require.</font></li>
</ul>
<p><font face="Arial, Helvetica, sans-serif">Essentially what happens above is 
  that SurgeMail carries out the cmd &quot;cmd_user_login&quot; using the username 
  and password given. Once complete it looks for an lcmd, in this case user_create, 
  it then copies all variables in the format &quot;l&lt;variable&gt;&quot; to 
  &quot;&lt;variable&gt;&quot; so lusername is copied to username and lpassword 
  is copied to password and then it executes user_create creating the new user.</font></p>
<p><font face="Arial, Helvetica, sans-serif">This same process can be used with 
  any lcmd value, provided you supply the fields required either directly (as 
  is done with user_id, smsto, quota, alias_quota, ans sms_quota) or using l&lt;variable&gt; 
  when they collide with variables required for the previous command i.e. lusername 
  and lpassword above.</font></p>
<p><font face="Arial, Helvetica, sans-serif">Because the show field allows you 
  to control the format of the replies you can interface the user management system 
  programatically, in other words write a complete custom user interface or add 
  to an existing user interface. SurgeMail outputs a number of values which will 
  aid in this, for example cmd_result which is equal to &quot;success&quot; or 
  &quot;failure&quot;. SurgeMail returns a <a href="#using_utoken">utoken</a> 
  variable when a domain admin logs in, this utoken can be passed to carry out 
  additional commands, instead of logging in for every request. Alternatively 
  you can send requests to the <a href="#using_webadmin">web admin interface</a>, 
  this method is often cleaner, easier and more flexible. To find out the values 
  required for each command consider using <a href="#using_dspy">DSpy</a>.</font></p>
<h3><a name="using_utoken"></a>Using utoken</h3>
<p><font face="Arial, Helvetica, sans-serif">The above form essentially piggy 
  backs a user_create command on a login command, required because you have to 
  authenticate to create users. If you intend to send and receive the data using 
  a program instead of a fixed html form then you have some better, and often 
  simpler alternatives. The first is that you could send the login command by 
  itself and store the resulting authentication token AKA &quot;utoken&quot;. 
  You can pass this utoken with another command instead of piggy backing every 
  command on a login command.</font></p>
<h3><a name="using_webadmin"></a>Using the web admin instead</h3>
<p><font face="Arial, Helvetica, sans-serif">Another</font><font face="Arial, Helvetica, sans-serif"> 
  option uses the web admin interface instead of the domain admin one. You would 
  connect to the web admin port 7026 (non https port) and send your request to 
  /cgi/admin.cgi. This interface uses basic HTTP authentication, so instead of 
  performing a login you simply need to send a special HTTP header with every 
  request. This header contains the encoded username and password for the web 
  admin interface, it's value is fixed, it does not change unless you change the 
  username and/or password, so, find out the value and simply send that with every 
  request. To find out the value consider using <a href="#using_dspy">DSpy</a>.</font></p>
<h2><a name="using_dspy"></a>Using DSpy</h2>
<p><font face="Arial, Helvetica, sans-serif">DSpy (<a href="ftp://netwinsite.com/pub/surgemail/util/dspy.zip">download</a>) 
  is a simple windows application which listens on a specified port for connections. 
  When it accepts a connection it also connects to another specified ip and port. 
  It reads data from each connection and passes it all through to the other while 
  logging the entire conversation to disk. This allows you to &quot;spy&quot; 
  on the data going from one port to the other. It <b>cannot</b> be used with 
  HTTPS ports to spy on encrypted conversations. For example you might tell it 
  to listen on port 8080 and connect to 127.0.0.1 on port 7026, eg:</font></p>
<p><font face="Arial, Helvetica, sans-serif">c:\&gt;dspy -port 8080 -to 127.0.0.1:7026</font></p>
<p><font face="Arial, Helvetica, sans-serif">Then you would type the following 
  url into your browser:</font></p>
<p><font face="Arial, Helvetica, sans-serif">http://127.0.0.1:8080/cgi/admin.cgi</font></p>
<p><font face="Arial, Helvetica, sans-serif">and you should see the web admin 
  interface. Perform the action you want your interface to be able to carry out, 
  and look in the dspy.log file for the http headers and request data required 
  to do it, duplicate the authentication header (if required) and the form content 
  to perform this action with your own interface.</font></p>
<p><font face="Arial, Helvetica, sans-serif">You can download dspy.zip <a href="ftp://netwinsite.com/pub/surgemail/util/dspy.zip">here</a>.</font></p>
<p><font face="Arial, Helvetica, sans-serif">If you need more information on this 
  subject please contact <a href="mailto:surgemail-support@netwinsite.com">surgemail-support@netwinsite.com</a>.</font></p>
<h2><a name="advanced"></a>Advanced Per User Services</h2>
<p><font face="Arial, Helvetica, sans-serif" >Access to the SurgeMail's POP / 
  IMAP / SMTP facilities can be controlled on a per user basis by defining a series 
  of access groups (<a href="global.htm#g_access_group">g_access_group</a>). Users 
  can belong to one or more access groups. Each access group has a IP based wildcarded 
  limitation of POP, IMAP and SMTP access and is defined in surgemail.ini. The 
  domain manager is able to change these settings for the user accounts within 
  their domain.</font></p>
<p><font face="Arial, Helvetica, sans-serif">Note that the groups defined by these 
  settings can be used by many others settings to define those settings for users 
  in these groups, eg. <a href="global.htm#g_user_access">g_user_access</a>, <a href="global.htm#g_admin_access">g_admin_access</a>, 
  <a href="global.htm#g_quota">g_quota</a>, <a href="global.htm#g_user_alias">g_user_alias</a>, 
  <a href="global.htm#g_user_sms_quota">g_user_sms_quota</a>, <a href="global.htm#g_user_send_max">g_user_send_max</a>, 
  <a href="global.htm#g_user_send_rule">g_user_send_rule</a>, <a href="global.htm#g_user_list_quota">g_user_list_quota</a>, 
  <a href="domain.htm#authent_info_grp">authent_info_grp</a>, <a href="domain.htm#web_access_grp">web_access_grp</a></font></p>
<p><font face="Arial, Helvetica, sans-serif" >Membership of this group is checked 
  against the &quot;Access Type&quot; setting (NWAuth field: mailaccess) in the 
  authentication database.</font></p>
<p><font face="Arial, Helvetica, sans-serif" >eg. You could charge WebMail users 
  for pop access privileges:</font></p>
<blockquote> 
  <p class="pre">g_access_group group=&quot;paid_user&quot; access_pop=&quot;*&quot; 
    access_imap=&quot;*&quot; access_smtp=&quot;*&quot; </p>
  <p class="pre">g_access_group group=&quot;free_user&quot; access_pop=&quot;webmail.svr.ip&quot; 
    access_imap=&quot;webmail.svr.ip&quot; access_smtp=&quot;webmail.svr.ip&quot;</p>
  <p>with &quot;Access type&quot; set to &quot;free_user&quot; / &quot;paid_user&quot; 
    on accounts page or equivalently in NWAuth authentication database:</p>
  <p class="pre"> marijn@mydomain.com:{ssha}tVANQo...:created=&quot;1060034937&quot; 
    mailaccess=&quot;free_user&quot; ...</p>
</blockquote>
<p><font face="Arial, Helvetica, sans-serif" >Or the following would use three 
  arbitrary fields (SuspendedEmail, AllowedPOP, AllowedIMAP) in the authentication 
  database to define the whether POP / IMAP / Webmail / SMTP services can be used 
  on an individual per user basis. </font></p>
<blockquote> 
  <div class="pre"> 
    <p> g_access_group group=&quot;webmailonly&quot; access_pop=&quot;&quot; access_imap=&quot;1.2.3.4&quot; 
      access_smtp=&quot;*&quot; <br>
      g_access_group group=&quot;imap&quot; access_pop=&quot;&quot; access_imap=&quot;*&quot; 
      access_smtp=&quot;&quot; <br>
      g_access_group group=&quot;allowpop&quot; access_pop=&quot;*&quot; access_imap=&quot;&quot; 
      access_smtp=&quot;&quot; <br>
      g_access_group group=&quot;suspendemail&quot; access_pop=&quot;!*&quot; 
      access_imap=&quot;!*&quot; access_smtp=&quot;!*&quot; <br>
    </p>
    <p> g_group_field field=&quot;SuspendedEmail&quot; value=&quot;0&quot; group=&quot;webmailonly&quot; 
      <br>
      g_group_field field=&quot;SuspendedEmail&quot; value=&quot;1&quot; group=&quot;suspendemail&quot; 
      <br>
      g_group_field field=&quot;AllowedPOP&quot; value=&quot;1&quot; group=&quot;allowpop&quot; 
      <br>
      g_group_field field=&quot;AllowedIMAP&quot; value=&quot;1&quot; group=&quot;allowimap&quot; 
      <br>
    </p>
    <p> g_authent_info name=&quot;Suspended Email&quot; field=&quot;SuspendedEmail&quot; 
      access=&quot;domadmin&quot; default=&quot;0&quot;<br>
      g_authent_info name=&quot;Allowed POP&quot; field=&quot;AllowedPOP&quot; 
      access=&quot;domadmin&quot; <br>
      g_authent_info name=&quot;Allowed IMAP&quot; field=&quot;AllowedIMAP&quot; 
      access=&quot;domadmin&quot; <br>
    </p>
    <p><font face="Arial, Helvetica, sans-serif">marijn@mydomain.com:{ssha}tVANQo...:created=&quot;1060034937&quot;</font> 
      SuspendedEmail=&quot;0&quot; AllowedPOP=&quot;&quot; AllowedIMAP=&quot;1&quot; 
      <br>
    </p>
  </div>
  <p><font face="Arial, Helvetica, sans-serif">In this case four groups are defined 
    (webmailonly, SuspendedEmail, AllowedPOP, AllowedIMAP) with membership based 
    on the (SuspendedEmail, AllowedPOP and AllowedIMAP) databse fields. The use 
    of g_group_field has the same effect as manually setting &quot;Access Type&quot; 
    to the combined group membership of &quot;webmailonly,allowimap&quot; for 
    user marijn@mydomain.com.</font></p>
  <p><font face="Arial, Helvetica, sans-serif">Actual access that is granted is 
    worked out by processing the g_access_group rules in the order they are defined 
    in surgemail.ini building up from no access. So if you want &quot;suspendedemail&quot; 
    to override &quot;allowpop&quot; you need to make sure the &quot;suspendedemail&quot; 
    g_access_group entry is after the &quot;allowpop&quot; g_access_group in the 
    surgemail.ini file.</font></p>
</blockquote>
<h2><a name="user_access"></a>User access settings</h2>
<p><font face="Arial, Helvetica, sans-serif">There are many features provided 
  in the user self management and domain administrator interfaces and it is common 
  to want to enable or disable some or all of these features. SurgeMail uses user_access 
  settings to do this, see <a href="global.htm#g_user_access">g_user_access</a> 
  and <a href="global.htm#g_admin_access">g_admin_access</a> for details on the 
  various options.</font></p>
<h2><a name="mailstatus"></a>Account Status</h2>
<p><font face="Arial, Helvetica, sans-serif"><font >The account status field in 
  the authentication database allows the domain controller to easily enable / 
  disable individual mail accounts. This is the &quot;Account Status&quot; setting 
  in the Web Admin interface (NWAuth field: mailstatus). This setting can have 
  one of the following values:</font></font></p>
<table class="plain_table" width="95%">
  <tr> 
    <th width="13%">&nbsp;</th>
    <th width="13%"> 
      <p>Incoming SMTP</p>
    </th>
    <th width="7%">POP</th>
    <th width="7%">WEB</th>
    <th width="8%">IMAP</th>
    <th width="12%">Sending SMTP</th>
    <th width="40%">Response codes</th>
  </tr>
  <tr> 
    <td width="13%">ok,good</td>
    <td width="13%">Y</td>
    <td width="7%">Y</td>
    <td width="7%">Y</td>
    <td width="8%">Y</td>
    <td width="12%">Y</td>
    <td width="40%">&nbsp;</td>
  </tr>
  <tr> 
    <td width="13%">suspended</td>
    <td width="13%">Y</td>
    <td width="7%">N</td>
    <td width="7%">N</td>
    <td width="8%">N</td>
    <td width="12%">N</td>
    <td width="40%"> Account suspended.</td>
  </tr>
  <tr> 
    <td width="13%">cancelled</td>
    <td width="13%">N</td>
    <td width="7%">N</td>
    <td width="7%">N</td>
    <td width="8%">N</td>
    <td width="12%">N</td>
    <td width="40%"> Account cancelled</td>
  </tr>
  <tr> 
    <td width="13%">banned,bad</td>
    <td width="13%">N</td>
    <td width="7%">N</td>
    <td width="7%">N</td>
    <td width="8%">N</td>
    <td width="12%">N</td>
    <td width="40%">This account has been banned for inappropriate use.</td>
  </tr>
  <tr> 
    <td width="13%">closed</td>
    <td width="13%">N</td>
    <td width="7%">N</td>
    <td width="7%">N</td>
    <td width="8%">N</td>
    <td width="12%">N</td>
    <td width="40%">Account closed.</td>
  </tr>
  <tr> 
    <td width="13%">paydue,due</td>
    <td width="13%">Y</td>
    <td width="7%">Y</td>
    <td width="7%">Y</td>
    <td width="8%">Y</td>
    <td width="12%">Y</td>
    <td width="40%">&nbsp;</td>
  </tr>
  <tr> 
    <td width="13%">payup</td>
    <td width="13%">Y</td>
    <td width="7%">N</td>
    <td width="7%">N</td>
    <td width="8%">N</td>
    <td width="12%">N</td>
    <td width="40%">Please pay to continue service.</td>
  </tr>
  <tr> 
    <td width="13%">readonly</td>
    <td width="13%">N</td>
    <td width="7%">Y</td>
    <td width="7%">Y</td>
    <td width="8%">Y</td>
    <td width="12%">N</td>
    <td width="40%">Account is only allowed to read email.</td>
  </tr>
</table>
<p> These messages responses can be modified using the g_mailstatus_message:</p>
<blockquote> 
  <pre>g_mailstatus_message state=&quot;cancelled&quot; message=&quot;Account cancelled,
    please email postmaster@mydomain.com for further information&quot;</pre>
</blockquote>
<p>or adding an &quot;id&quot; field to the authentication database and using 
  this to supply a customised URL for updating account information:</p>
<blockquote> 
  <pre>g_mailstatus_message state=&quot;payup&quot; message=&quot;Payment is overdue
    for $full_name$, click http://myurl.com/cgi/mycgi.cgi?user=$id$ to update
    account&quot;</pre>
</blockquote>
<h2>Individual user bounce message setting: bounce_msg</h2>
<p>In versions 3.8g-12 and later you can use bounce_msg, e.g. </p>
<blockquote> 
  <pre>C:\surgemail&gt;nwauth -path .
       lookup test2@star
       +OK test2@star config 0 bounce_msg=&quot;please send to me@here.com&quot;</pre>
</blockquote>
<p>Then when you send a message to that account you will get an smtp rejection:<br>
</p>
<blockquote> 
  <pre>550 Bounce_msg: please send to me@here.com</pre>
</blockquote>
<p><br>
</p>
<h2><a name="localonly"></a>Restricting accounts to &quot;local only&quot;</h2>
<p>You may want to setup a goup of users (eg students, untrusted staff etc) who 
  should be able to email within themselves and email trusted staff accounts but 
  not email other internet accounts. There are several possibilities for implementing 
  this in surgemail. The easiest way is to implement this using g_user_send_rule 
  / g_user_receive_rule rules:<br>
</p>
<p>1) Setup appropriate rules to allow inbound / outbound mail based on group 
  membership and create an access group which you can use to apply these</p>
<blockquote> 
  <pre>
g_user_receive_rule group=&quot;local&quot; from=&quot;*@mydomain.com&quot;
g_user_send_rule group=&quot;local&quot; to=&quot;*@mydomain.com&quot;
g_access_group group=&quot;local&quot; access_pop=&quot;*&quot; access_imap=&quot;*&quot; access_smtp=&quot;*&quot; access_incoming=&quot;*&quot;
</pre>
</blockquote>
<p>2) Assign membership of this group to the relevant accounts on the accounts 
  page.</p>
<p>The rules above will allow accounts on mydomain.com that have &quot;local&quot; 
  group membership to only send and receive mail to / from local accounts. Other 
  possible relevant configuration options:</p>
<p>1) You could set this up as a separate &quot;localonly&quot; domain for easier 
  management and configuration. In this case the rules are likely to be something 
  like:</p>
<p>to allow sending between users and to main domain:<br>
<blockquote> 
  <pre>
g_user_receive_rule group=&quot;local&quot; from=&quot;*@localonly,*@mydomain.com&quot;
g_user_send_rule group=&quot;local&quot; to=&quot;*@localonly,*@mydomain.com&quot;
</pre>
</blockquote>
<p>to allow sending to main domain, but not between users:</p>
<blockquote> 
  <pre>
g_user_receive_rule group=&quot;local&quot; from=&quot;*@mydomain.com&quot;
g_user_send_rule group=&quot;local&quot; to=&quot;*@mydomain.com&quot;
</pre>
</blockquote>
<p>2) You may want to setup a restricted administrator account to allow user creation 
  and addition and quota management but not change access group membership. In 
  this case, make sure it setup as a separate localonly domain and then setup 
  a rule something like: <br>
<blockquote> 
  <pre>
g_authent_info_grp group=&quot;internal_manager&quot; fields=&quot;none,quota&quot; tag=&quot;dummy_tag&quot;</pre>
</blockquote>
<p>and make sure the account to adminster these restricted accounts is a domain 
  manager, and also has assigned internal_manager group priviliges.</p>
<p>3) A similar effect can be achieved with mfilter rules, but in this case full 
  configuration is done in mfilter.rul and it has to be the main server administrator 
  that makes any configuration changes. <br>
  eg:<br>
<blockquote> 
  <pre>
recipients
  if (isin(&quot;from&quot;,&quot;fred@mydomain.com&quot;)) then
    if (!isin(&quot;recipient&quot;, &quot;mydomain.com&quot;)) bounce &quot;Sorry you can only send to mydomain.com&quot;
  end if
end recipients
</pre>
  <p>&nbsp; </p>
</blockquote>
<!-- #EndEditable -->
<!-- CONTENT END -->
</div>

<!-- Back to accounts.htm -->
</div>

<!-- Back to accounts.htm -->

<div class="prefooter">&nbsp;</div>
<div id="footer" class="footer">
 <table align="center" CELLPADDING="0" CELLSPACING="0" WIDTH="900" HEIGHT="100" BORDER="0" >
  <tr>
    <td HEIGHT="100%" >
      <p align="center" style="margin-top: 8pt; margin-bottom: 2pt; margin-left: 8pt">
  	  <a href="http://netwinsite.com/sitemap.htm" class="footer_link">Site Map</a><span class="style2"> | </span>
  	      <a href="http://netwinsite.com/index.htm" class="footer_link">Home</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/products.htm" class="footer_link">Products</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/surgemail/post.htm" class="footer_link">Contact Netwin</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/company.htm" class="footer_link">Company</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/license_all.htm" class="footer_link">Licensing</a><span class="style2"> | </span>
	      <a href="http://netwinsite.com/links.htm" class="footer_link">Links</a><span class="style2">  </span>
        <table align=center width="370" border="0" style="margin-bottom: 2pt">
        <tr>
          <td width="32"><img src="template/img2/logo_small_ongray.png" height="25" hspace="1" vspace="1" align="bottom"></td>
          <td width="350"><p class="smaller" style="margin-top: 14pt;">Copyright &copy; 2009 Netwin Ltd. All rights reserved.
		  </td>
        </tr>
      </table>
	</td>
  </tr>
</table>
</div>
</div>

<br><br>
</body>

<!-- Back to accounts.htm -->

</body>
</html>

<!-- End of accounts.htm -->
