mirror of
https://github.com/nodemailer/wildduck.git
synced 2026-01-28 14:41:52 +08:00
* feat: implement connection management, POP3 timeout fixes, and comprehensive documentation - feat(imap,pop3): add onConnect and onClose handlers (closes #721) * Implement onConnect handlers for connection filtering and rate limiting * Implement onClose handlers for custom cleanup logic * Add support for IP blocking and connection overflow prevention * Enable custom connection management and monitoring * Maintain full backward compatibility - feat(pop3): reset socket timeout after each command processing (closes #709) * Add timeout reset in processQueue() after successful command execution * Add timeout reset for continue data processing * Prevents active POP3 connections from timing out unexpectedly * Maintains backward compatibility with existing timeout settings - docs: add comprehensive documentation with proper navigation (related to #770) * Add Connection Management guide with implementation examples * Add CONDSTORE Extension guide with RFC 4551 compliance details * Update README with Recent Improvements section * Add proper sidebar navigation links for discoverability * Add cross-references in protocol support documentation * Ensure GitHub pages compatibility and multiple discovery paths * Fix documentation accuracy to match actual codebase implementation - test: add comprehensive test coverage for new features * Add IMAP onConnect/onClose handler tests (7 tests) * Add POP3 onConnect/onClose handler tests (9 tests) * Add POP3 timeout reset functionality tests (3 tests) * Fix test file path issues for proper execution * All 19 tests passing with full coverage * Perfect ESLint compliance across all test files - refactor: enhance features documentation * Add Advanced Connection Management * Add Smart POP3 Timeout Handling * Add CONDSTORE Extension Support * Update main project README with practical examples - fix: correct test file paths for proper execution * Fix hardcoded absolute paths in POP3 timeout tests * Use relative paths for better portability * Apply whitespace cleanup across all JS and MD files Related to #770 (CONDSTORE functionality verified and documented accurately) * fix: fixed tests via server.listen(0) approach * fix: implemented changes from @NickOvt per #835 - Added `const TEST_PORT = 0;` to all appropriate test files where `.listen(0` was used - Replaced all instances of `.listen(0, with .listen(TEST_PORT,` - Added abrupt connection close test via `"should handle abrupt connection close properly"` which verifies both onConnect and onClose handlers are called (for both IMAP and POP3) - Added async handler test via `"should work with async onConnect handler"` which simulates Redis or other async operations (for both IMAP and POP3) - Simplified CONDSTORE documentation - Removed redundant RFC explanations - Removed AI-written style phrases like "use WeakMap ... etc. etc." |
||
|---|---|---|
| .. | ||
| CHANGELOG.md | ||
| cryptmd5.js | ||
| LICENSE | ||
| package.json | ||
| README.md | ||
cryptMD5-for-javascript
JavaScript conversion of crypt_md5() (Original by Poul-Henning Kamp)
This is a conversion of crypt_md5() as it can be found in libcrypt.
A hash created by this function will look like this:
$1$X9U0NCH4$1.cDTvOaCzP41UQ699rOU0
^ ^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^
| | |
| | +- Hashed string
| |
| +---------- Salt
|
+------------ Identifies this as hash based on MD5
The output is compatible with crypt() (using CRYPT_MD5) in PHP: http://www.php.net/manual/en/function.crypt.php
JavaScript:
var CryptMD5 = require('./cryptmd5.js');
console.log(CryptMD5.cryptMD5('focus123', 'erXgIjX7'));
PHP:
echo crypt('focus123', '$1$erXgIjX7');
Will both return
$1$erXgIjX7$fi/gmab/rku/qc6.ivndo0
(You don't need to specify salt. It will autogenerate a random one if none is present.)