Changeset 4111 for trunk/lisp/erc/erc-identd.el
- Timestamp:
- 2006年07月16日 08時36分52秒 (2 years ago)
- Files:
-
- trunk/lisp/erc/erc-identd.el (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/lisp/erc/erc-identd.el
r4058 r4111 25 25 ;;; Commentary: 26 26 27 ;; You can have a local identd server (running on port 8113; I use DNAT28 ;; to bind 113->8113) if you add this to .emacs.el:27 ;; This module allows you to run a local identd server on port 8113. 28 ;; You will need to set up DNAT to bind 113->8113, or use a proxy. 29 29 30 ;; (add-hook 'erc-connect-pre-hook 'erc-identd-start) 31 ;; (add-hook 'erc-disconnected-hook 'erc-identd-stop) 30 ;; To use this module, add identd to `erc-modules' and run 31 ;; `erc-update-modules'. 32 33 ;; Here is an example /etc/inetd.conf rule that forwards identd 34 ;; traffic to port 8113. You will need simpleproxy installed for it 35 ;; to work. 36 37 ;; 113 stream tcp nowait nobody /usr/sbin/tcpd /usr/bin/simpleproxy simpleproxy -i -R 127.0.0.1:8113 32 38 33 39 ;;; Code: 34 40 41 (require 'erc) 42 35 43 (defvar erc-identd-process nil) 44 45 ;;;###autoload (autoload 'erc-identd-mode "erc-identd") 46 (define-erc-module identd nil 47 "This mode launches an identd server on port 8113." 48 ((add-hook 'erc-connect-pre-hook 'erc-identd-start) 49 (add-hook 'erc-disconnected-hook 'erc-identd-stop)) 50 ((remove-hook 'erc-connect-pre-hook 'erc-identd-start) 51 (remove-hook 'erc-disconnected-hook 'erc-identd-stop))) 36 52 37 53 (defun erc-identd-filter (proc string) … … 64 80 (setq erc-identd-process 65 81 (make-network-process :name "identd" 66 :buffer (generate-new-buffer "identd")82 :buffer nil 67 83 :host 'local :service port 68 :server t :noquery t 69 :filter 'erc-identd-filter))) 84 :server t :noquery t :nowait t 85 :filter 'erc-identd-filter)) 86 (set-process-query-on-exit-flag erc-identd-process nil)) 70 87 71 88 ;;;###autoload
