summaryrefslogtreecommitdiff
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Merge passwords into restBarry Warsaw2011-04-0817-40/+138
|\
| * encrypt_password(): New convenience function for ensuring that a password isBarry Warsaw2011-04-0811-31/+99
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | both encrypted according to a scheme, and a bytes object. add_member(): Use encrypt_password(). cli_members: Give the user a default, user-friendly password. Of course, this will be encrypted so it can't be retrieved, but it can be reset. Passwords are stored as bytes objects, not unicode now. ConfigLayer: Set the default test password scheme to cleartext. General test repair.
| * add_member()Barry Warsaw2011-04-087-14/+44
| | | | | | | | | | | | | | | | | | | | | | | | - As the most common interface for adding new members (and users), adapt the password storing bit to storing only encrypted passwords in the database. schema.cfg: - Remove the creator_pw_file and site_pw_file as they are obsolete. - Add password_schema key for defining the default password encryption scheme. mailman.sql, user.py: - Store the password as a binary blob instead of as unicode text.
* | Merge passwords into restBarry Warsaw2011-04-083-1/+15
|\|
| * Merge users into passwordsBarry Warsaw2011-04-083-1/+15
| |\
| | * Add an attribute for getting the IUser record from an IMember record. This isBarry Warsaw2011-04-083-1/+15
| | | | | | | | | | | | pure convenience by way of an IUserManager lookup.
* | | Merge passwords into restBarry Warsaw2011-04-074-4/+77
|\| |
| * | make_user_friendly_password(): Ported from Mailman 2.1.Barry Warsaw2011-04-074-4/+77
| |/
* | Move missing users test, and add a test for bogus email address.Barry Warsaw2011-04-061-7/+21
| |
* | Get users via email address through the REST API.Barry Warsaw2011-04-052-2/+24
| |
* | Removing debugging printBarry Warsaw2011-04-041-1/+0
| |
* | More fleshing out of the users REST API.Barry Warsaw2011-04-049-18/+180
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add a 'uid factory' which allows us to return predictable unique ids for various testing purposes, e.g. user ids. This should work even in the case of cross-subprocess uid generation. * REST access to individual users, or the set of all users. * User objects now have a created_on attribute. * Users can be created through the web, but must have an email address. * Add a [devmode] 'testing' variable for communicating to qrunner subprocesses that we're running in testing mode. This allows us to coordinate factories and such in the qrunner processes. * layers.is_testing() for more consistent API. * Give AddressError a .address attribute for better diagnostics.
* | Merge users into restBarry Warsaw2011-04-0110-32/+159
|\|
| * * Re-organize the interface between buildout.cfg and the zope.testing layerBarry Warsaw2011-04-0110-32/+159
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | initialization. buildout.cfg is now really simple; it calls one method. That method does all the relevant layer initializations. This better localizes what has to be set up before testing can even begin. * IUsers now have a created_on property which contains the datetime at which the user record was created. * Rework the date and uid factories so that they consult the MockAndMonkeyLayer for the current testing flag. Also, those factories register themselves with the layer so that they'll get automatically reset between tests, without the layer actually having to know about them. * Move the User model object initialization into User.__init__() from the user manager. The User now also adds itself to the store. * Add a 'uid factory' for unique id creation, which is test suite aware.
* | Basic REST users URL.Barry Warsaw2011-03-181-0/+41
| |
* | Merge users into restBarry Warsaw2011-03-1811-21/+79
|\|
| * * Give users a unique, random, immutable user id.Barry Warsaw2011-03-1811-21/+79
| | | | | | | | | | * Find users by user_id via the user manager. * Extend the repr of users to include the user id.
* | * Start fleshing out the REST API for users.Barry Warsaw2011-03-184-113/+62
|/ | | | * Remove mmsitepass.py - there is no more site password.
* Reimplement wrap() using modern techniques, and finally get rid of Utils.py!Barry Warsaw2011-03-1719-173/+263
|
* Update comment.Barry Warsaw2011-03-161-1/+5
|
* Utils.maketext() and Utils.findtext() are gone.Barry Warsaw2011-03-1613-222/+100
|
* make() and some tests.Barry Warsaw2011-03-162-4/+113
|
* Checkpointing migration of findtext() and maketext() out of Utils.py. TestsBarry Warsaw2011-03-162-15/+254
| | | | added. TODO: flesh out make().
* Basic tests for Utils.py findtext(). This will go away, but for now it'sBarry Warsaw2011-03-155-3/+157
| | | | useful for ensuring current functionality.
* More eradication of Utils.py.Barry Warsaw2011-02-263-42/+43
|
* Cue Freddy Mercury. Another one bites the dust.Barry Warsaw2011-02-254-10/+11
|
* nntpsplit() is replaced by lazr.config.as_host_port().Barry Warsaw2011-02-253-16/+6
|
* Two more unused functions removed. Utils.py, your days are numbered.Barry Warsaw2011-02-251-20/+0
|
* Move oneline() out of Utils.py.Barry Warsaw2011-02-258-24/+46
|
* Remove an unused function from Utils.py.Barry Warsaw2011-02-251-55/+0
|
* Eliminate Utils.get_pattern() and in the process, completely revampBarry Warsaw2011-02-2511-38/+461
| | | | | | | | | subscription bans so as not to have to rely on BLOBS or pickles in the database. Also, be sure to include .rst files in both doctests and in the packaged tarballs. With the now awesome reST mode for Emacs, I plan to rename all .txt doctest files to .rst.
* Move passwords module to the utilities subpackage.Barry Warsaw2011-02-254-6/+2
|
* Fixed a typo in add_member() which prevented subscribing an email address thatBarry Warsaw2011-01-316-16/+110
| | | | | | | | was already linked to a user. Found by Florian Fuchs who also provided the fix, though I implemented the test differently. LP: #710182 Also, refactor the "reset the world" functionality ConfigLayer.testTearDown() so that it could be used by other test code.
* Implement the email address validator as a utility for easier pluggability.Barry Warsaw2011-01-066-41/+71
|
* Remove some unused/untested stuff regarding password creation from Utils.py.Barry Warsaw2011-01-043-355/+1
| | | | Also, remove a obsolete test.
* Better wording given by Patrick Ben Koetter.Barry Warsaw2011-01-031-2/+14
|
* Catch up on news for 3.0.0a7.Barry Warsaw2011-01-031-4/+42
|
* LP: #490044 - Support SMTP AUTH.Barry Warsaw2011-01-027-3/+160
| | | | | Added smtp_user and smtp_pass options to the [mta] section to support logging into the SMTP server. All the underlying support is in Python's smtplib.
* Make sure all documentation is included in the toctree.Barry Warsaw2011-01-021-0/+1
|
* Split member and nonmember moderation.Barry Warsaw2011-01-0215-230/+363
| | | | | | | | | | | | | | | | * member-moderation happens at the same place in the built-in chain that the previously named moderation rule happens. nonmember-moderation happens after all the other normal moderation rules. * Handle unsubscribed nonmember posts. Other changes: * Message.senders now filters out Nones and empty strings. * Various test cleanups and simplifications. * More `address` -> `email` fixes. * Give Link class a useful repr. * Fix a potential UnboundLocalError. * Various other small changes.
* Happy New Year.Barry Warsaw2011-01-01256-257/+257
|
* Because it was just to damn confusing, rename IAddress.address toBarry Warsaw2011-01-0133-352/+429
| | | | | | IAddress.email and IAddress.original_address to IAddress.original_email. From now on we'll use "address" to talk about the IAddress object and "email" to talk about the textual email address.
* * Simplify the membership.txt doctest.Barry Warsaw2010-12-316-156/+176
| | | | | | | * Add test to show that the incoming runner adds all sender addresses to the global user manager. * New doctest helper: dump_list() * Other random cleanups.
* Fairly significant change to the way member and nonmember moderation occurs.Barry Warsaw2010-12-2921-437/+397
| | | | | | | | | | | | | | | | | | | | | | | | | Now, nonmembers are represented by a separate roster of IMembers, the latter which has grown a `moderation_action` enum. When that action is `defer`, then the normal processing rules apply. Anything else and the `moderation` chain is jumped to for a shortcut to moderation (which may include immediate acceptance). TODO: handle unregistered nonmembers. Details: * The member-moderation rule is renamed to just moderation, and handles both members and nonmembers (though the latter must currently be registered). * The moderation rule is moved up in the builtin chain. It is now checked after `approved`, `emergency`, and `loop`, but before the normal moderation checks. This means that nonmember postings will be (by default) held much earlier. * IMember.is_moderated is removed. * IMember.moderation_action is added. * IMailingList.default_member_moderation is removed. * IMailingList.default_member_action and IMailingList.default_nonmember_action are added. * MemberRole.nonmember is added.
* Clean up from the previous commit.Barry Warsaw2010-12-283-3/+14
| | | | | | * member_moderation_action exposed in IMailingList * REST configuration test for member_moderation_action, send_welcome_msg, and welcome_msg.
* This is part 1 of the merge of Jimmy Bergman's branchBarry Warsaw2010-12-2819-106/+416
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | lp:~jimmy-sigint/mailman/restapi_additional_attributes Ostensibly, this adds support for a few additional attributes through the REST API: * default_member_moderation * generic_nonmember_action * member_moderation_action * reply_goes_to_list * send_welcome_msg * welcome_msg However, I had never previously fleshed out the conversion of default_member_moderation and member_moderation_action into the MM3 way of things. That is now done. Non-member moderation still needs to be done. Specific changes: * mailman.chains.base.Chain no longer self registers * The built-in chain gets a new link for checking 'member-moderation'. If this rule matches, it jumps to the 'member-moderation' chain, which checks member_moderation_action and returns a link that jumps to the appropriate terminal chain. * Chain initialization is done by the same auto-detection as rules, handlers, etc. The one tricky thing is that abstract base classes such as Chain and TerminalChainBase can't be instantiated. For now, there's an ugly special case to skip these. * default_member_moderation is now exposed in the IMailingList interface. * Member.is_moderated gets set in the constructor from the mailing list's default_member_moderation. * The 'moderation' rule is renamed 'member-moderation'. TODO: * Work out non-member moderation * Add member_moderation_action to IMailingList * Double check tests for reply_goes_to_list, send_welcome_msg, and welcome_msg
| * Add reply_goes_to_list, send_welcome_msg, welcome_msg, ↵root2010-10-132-0/+29
| | | | | | | | member_moderation_action, default_member_moderation and generic_nonmember_action to the writable attributes in the REST service
* | In the REST API, include the fqdn_listname and email address in the member'sBarry Warsaw2010-12-262-0/+44
| | | | | | | | JSON representation.
* | Insulate the test environment from the running environment. Sadly, the testBarry Warsaw2010-12-2211-93/+105
| | | | | | | | | | | | ports are still hard coded. Also, 'bin/mailman info' dumps the REST root url and credentials.
* | * Start to get rid of pylint; it's more trouble than it's worth and pyflakesBarry Warsaw2010-12-226-44/+245
| | | | | | | | | | | | | | | | | | | | | | | | | | does a pretty good job anyway. * Remove master.get_lock_data() now that flufl.lock 2.1 provides the same detailed information. * Add WatcherState.none to indicate that the master is not running. * Instrument master_state() and acquire_lock_1() for testing, and add unittests. * LBYL for 'bin/mailman start' so that the error message when the master is already running happens in the foreground process and is more user friendly. * Add 'bin/mailman status' to provide master queue runner status on the command line.