[Mailman-Users] Help in setting up Regular Expressions

Jim Tittsler jwt at onjapan.net
Sat Aug 6 06:25:15 CEST 2005


On Aug 6, 2005, at 12:24, ajit k jena wrote:

> I administer a few mailing lists. I have been struggling to
> setup regular expressions to allow people to subscribe (and
> may be post) from specfic address patterns.

My first impression is that it would be better to do this in your MTA  
than mailman.  If nobody outside your domain can subscribe or post,  
you could just make Mailman invisible to them.

>     SUBSCRIPTION :
>
>     I wish that people with address pattern abc at iitb.ac.in and
>     def@<dept>.iitb.ac.in (where dept is a department such as
>     phy, cc, che, chem, ee .... etc) to be able to send
>     subscription requests to this list. All others must be
>     automatically discarded.

I don't believe you can do this without changing the code.  While you  
might use a negative lookahead assertion in a regular expression in  
Subscription rules ban_list, the unwanted subscriptions are rejected  
with a notice rather than being quietly discarded.

>     POSTING :
>
>     Similarly, while posting, only members post without moderator's
>     intervention. For postings that come from non-members the
>     following should happen:
>
>       a) Non-member address pattern confirming to the scheme
>          abc at iitb.ac.in and def@<dept>.iitb.ac.in should be
>          held up for moderator's approval.
>
>       b) Non-member address pattern not confirming to the
>          above patterns get discarded.

The Sender filters hold_these_nonmemembers and  
discard_these_nonmembers settings are checked in order, so I believe  
you could use ^[^@]+@(.+\.)?iitb\.ac\.in and ^.* respectively for those.


-- 
Jim Tittsler     http://www.OnJapan.net/      GPG: 0x01159DB6
Python Starship  http://Starship.Python.net/crew/jwt/
Mailman IRC      irc://irc.freenode.net/#mailman






More information about the Mailman-Users mailing list