ejabberd - Comments for "--mod_shit--Drop messages based on &amp;quot;from&amp;quot; or &amp;quot;to&amp;quot; headers" https://www.ejabberd.im/node/1524 en How i can run mod_filter with https://www.ejabberd.im/node/1524#comment-61922 <p>How i can run mod_filter with ejabberd-2.1.13 to drop bad words</p> Thu, 21 Nov 2013 13:19:17 +0000 Drag7n comment 61922 at https://www.ejabberd.im How i can run mod_filter with https://www.ejabberd.im/node/1524#comment-61921 <p>How i can run mod_filter with ejabberd-2.1.13 to drop bad words</p> Thu, 21 Nov 2013 13:18:15 +0000 Drag7n comment 61921 at https://www.ejabberd.im Hi.. i use ejabberd 2.1.13 i https://www.ejabberd.im/node/1524#comment-61692 <p>Hi..<br /> i use ejabberd 2.1.13<br /> i was try mod_shit to filter bad msg but not work!<br /> i want config ejabberd with mod_filter to work with isida bot and filter conferences...<br /> "filter messages from unaffliated users through Jabber ID"<br /> like jabber.ru<br /> what should I do?</p> <p>Thank you.</p> Sun, 20 Oct 2013 06:20:58 +0000 autorun comment 61692 at https://www.ejabberd.im :D https://www.ejabberd.im/node/1524#comment-3692 <p>Thankx a lot ppl!</p> <p>It's working :D</p> <p>if i was christian would say god bless u all!! :)</p> Tue, 08 May 2007 15:32:02 +0000 non_j comment 3692 at https://www.ejabberd.im Oh, I forgot… you need to https://www.ejabberd.im/node/1524#comment-3691 <p>Oh, I forgot… you need to have the MSN transport itself among the good MSN users:</p> <pre> {acl, good_msn_users, {user, "", "msn.example.com"}}. </pre> Tue, 08 May 2007 15:03:51 +0000 legoscia comment 3691 at https://www.ejabberd.im can't login to msn anymore https://www.ejabberd.im/node/1524#comment-3690 <p>well, i put that piece of configuration, but it just doesnt let any user use the MSN transport to login on MSN</p> <p>i think i did nothing wrong but....here goes the code:</p> <p>% Default Debian ejabberd.cfg</p> <p>override_acls.<br /> override_global.<br /> override_local.</p> <p>%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%<br /> %% ucf section</p> <p>%% Admin user<br /> {acl, admin, {user, "administrator", "nonj.domain.com"}}.</p> <p>%% Hostname<br /> {hosts, ["nonj.domain.com", "domain.com"]}.</p> <p>%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%</p> <p>% Users that have admin access. Add line like one of the following after you<br /> % will be successfully registered on server to get admin access:<br /> %{acl, admin, {user, "aleksey"}}.</p> <p>% Blocked users:<br /> %{acl, blocked, {user, "test"}}.</p> <p>% Local users:<br /> {acl, local, {user_regexp, ""}}.</p> <p>% Another examples of ACLs:<br /> %{acl, jabberorg, {server, "jabber.org"}}.<br /> %{acl, aleksey, {user, "aleksey", "jabber.ru"}}.<br /> %{acl, test, {user_regexp, "^test"}}.<br /> %{acl, test, {user_glob, "test*"}}.</p> <p>% Everybody can create pubsub nodes<br /> {access, pubsub_createnode, [{allow, all}]}.</p> <p>% Only admins can use configuration interface:<br /> {access, configure, [{allow, admin}]}.</p> <p>% Every username can be registered via in-band registration:<br /> %{access, register, [{allow, all}]}.</p> <p>% None username can be registered via in-band registration:<br /> {access, register, [{deny, all}]}.</p> <p>% After successful registration user will get message with following subject<br /> % and body:<br /> {welcome_message,<br /> {"Welcome!",<br /> "Welcome to Debian Jabber Service. "<br /> "For information about Jabber visit http://jabber.org"}}.<br /> % Replace them with 'none' if you don't want to send such message:<br /> %{welcome_message, none}.</p> <p>% List of people who will get notifications about registered users<br /> %{registration_watchers, ["admin1@localhost",<br /> % "admin2@localhost"]}.<br /> % Only admins can send announcement messages:<br /> {access, announce, [{allow, admin}]}.</p> <p>% Only non-blocked users can use c2s connections:<br /> {access, c2s, [{deny, blocked},<br /> {allow, all}]}.</p> <p>{acl, good_msn_users, {user, "nonj%yahoo.com", "msn.domain.com"}}.<br /> {acl, good_msn_users, {user, "juliet%hotmail.com", "msn.domain.com"}}.<br /> {acl, msn_users, {server_glob, "msn.domain.com"}}.</p> <p>{access, mod_filter,<br /> %% filter incoming messages; allow only good messages<br /> [{allow, good_msn_users},<br /> {deny, msn_users},<br /> %% filter the rest, including outgoing messages<br /> {filter_msn, all}]}.</p> <p> {access, filter_msn,<br /> %% Users can send messages to good MSN users<br /> [{allow, good_msn_users},<br /> %% but not to other MSN users<br /> {deny, msn_users},<br /> %% All non-MSN traffic is allowed<br /> {allow, all}]}.</p> <p>% Set shaper with name "normal" to limit traffic speed to 1000B/s<br /> {shaper, normal, {maxrate, 1000}}.</p> <p>% Set shaper with name "fast" to limit traffic speed to 50000B/s<br /> {shaper, fast, {maxrate, 50000}}.</p> <p>% For all users except admins used "normal" shaper<br /> {access, c2s_shaper, [{none, admin},<br /> {normal, all}]}.</p> <p>% For all S2S connections used "fast" shaper<br /> {access, s2s_shaper, [{fast, all}]}.<br /> Admins of this server are also admins of MUC service:<br /> {access, muc_admin, [{allow, admin}]}.</p> <p>% All users are allowed to use MUC service:<br /> {access, muc, [{allow, all}]}.</p> <p>% This rule allows access only for local users:<br /> {access, local, [{allow, local}]}.</p> <p>% Authentication method. If you want to use internal user base, then use<br /> % this line:<br /> {auth_method, internal}.</p> <p>% For LDAP authentication use these lines instead of above one:<br /> {auth_method, ldap}.<br /> {ldap_servers, ["localhost"]}. % List of LDAP servers<br /> {ldap_uidattr, "uid"}. % LDAP attribute that holds user ID<br /> {ldap_base, "dc=domain,dc=com"}. % Search base of LDAP directory</p> <p>% For authentication via external script use the following:<br /> %{auth_method, external}.<br /> %{extauth_program, "/path/to/authentication/script"}.</p> <p>% For authentication via ODBC use the following:<br /> %{auth_method, odbc}.<br /> %{odbc_server, "DSN=ejabberd;UID=ejabberd;PWD=ejabberd"}.</p> <p>%% Anonymous login support:<br /> %% auth_method: anonymous<br /> %% anonymous_protocol: sasl_anon|login_anon|both<br /> %% allow_multiple_connections: true|false<br /> %%{host_config, "public.example.org", [{auth_method, anonymous},<br /> %% {allow_multiple_connections, false},<br /> %% {anonymous_protocol, sasl_anon}]}.<br /> %% To use both anonymous and internal authentication:<br /> %%{host_config, "public.example.org", [{auth_method, [anonymous, internal]}]}.</p> <p>% Host(s) name: (replace for your hostname(s))<br /> % Old {host, "localhost"}. option is equivalent to {hosts, ["localhost"]}.<br /> %{hosts, ["localhost"]}.</p> <p>%% Define the maximum number of time a single user is allowed to connect:<br /> {max_user_sessions, 10}.</p> <p>% Default language for server messages<br /> {language, "en"}.<br /> % Listened ports:<br /> {listen,<br /> % Ordinary client-2-server service<br /> [{5222, ejabberd_c2s, [{access, c2s},<br /> {max_stanza_size, 65536},<br /> starttls, {certfile, "/etc/ejabberd/ejabberd.pem"},<br /> {shaper, c2s_shaper}]},</p> <p>% SSL-enabled client-2-server service<br /> {5223, ejabberd_c2s, [{access, c2s},<br /> {max_stanza_size, 65536},<br /> tls, {certfile, "/etc/ejabberd/ejabberd.pem"},<br /> {shaper, c2s_shaper}]},</p> <p>% Server-2-server service<br /> {5269, ejabberd_s2s_in, [{shaper, s2s_shaper},<br /> {max_stanza_size, 131072}]},</p> <p>% External MUC jabber-muc (but internal mod_muc is better :))<br /> % {5554, ejabberd_service, [{ip, {127, 0, 0, 1}},<br /> % {access, all},<br /> % {host, "muc.localhost", [{password, "secret"}]}]},</p> <p>% Jabber ICQ Transport<br /> % {5555, ejabberd_service, [{ip, {127, 0, 0, 1}},<br /> % {access, all},<br /> % {hosts, ["icq.localhost", "sms.localhost"], [{password, "secret"}]}]},</p> <p>% AIM Transport<br /> % {5556, ejabberd_service, [{ip, {127, 0, 0, 1}},<br /> % {access, all},<br /> % {host, "aim.localhost", [{password, "secret"}]}]},</p> <p>% MSN Transport<br /> {5347, ejabberd_service, [{access, all},<br /> {host, "msn.domain.com", [{password, "secret"}]}]},</p> <p>% Yahoo! Transport<br /> % {5558, ejabberd_service, [{ip, {127, 0, 0, 1}},<br /> % {access, all},<br /> % {host, "yahoo.localhost", [{password, "secret"}]}]},</p> <p>% External JUD (internal is more powerful,<br /> % but doesn't allow to register users from other servers)<br /> % {5559, ejabberd_service, [{ip, {127, 0, 0, 1}},<br /> % {access, all},<br /> % {host, "jud.localhost", [{password, "secret"}]}]},</p> <p>% HTTP service (You may choose options HTTP-polling and Web-administering)<br /> % When commenting out, be careful with commas<br /> {5280, ejabberd_http, [http_poll, web_admin]}<br /> ]}.</p> <p>% Use STARTTLS+Dialback for S2S connections<br /> {s2s_use_starttls, true}.<br /> {s2s_certfile, "/etc/ejabberd/ejabberd.pem"}.<br /> %{domain_certfile, "example.org", "/etc/ejabberd/example_org.pem"}.<br /> %{domain_certfile, "example.com", "/etc/ejabberd/example_com.pem"}.</p> <p>% If SRV lookup fails, then port 5269 is used to communicate with remote server<br /> {outgoing_s2s_port, 5269}.</p> <p>% Used modules:<br /> {modules,<br /> [<br /> {mod_adhoc, []},<br /> {mod_announce, [{access, announce}]}, % Depends on mod_adhoc<br /> {mod_register, [{access, register}]},<br /> {mod_roster, []},<br /> {mod_privacy, []},<br /> {mod_configure, []}, % Depends on mod_adhoc<br /> {mod_configure2, []},<br /> {mod_disco, [{extra_domains, ["msn.domain.com"]}]},<br /> {mod_stats, []},<br /> {mod_vcard, []},<br /> {mod_offline, []},<br /> {mod_echo, []},<br /> {mod_private, []},<br /> {mod_irc, []},<br /> {mod_filter, []},<br /> % Default options for mod_muc:<br /> % host: "conference." ++ ?MYNAME<br /> % access: all<br /> % access_create: all<br /> % access_admin: none (only room creator has owner privileges)<br /> {mod_muc, [{access, muc},<br /> {access_create, muc},<br /> {access_admin, muc_admin}]},<br /> % {mod_muc_log, []},<br /> % {mod_shared_roster, []},<br /> {mod_pubsub, [{access_createnode, pubsub_createnode}]},<br /> {mod_time, []},<br /> {mod_last, []},<br /> {mod_version, []}<br /> ]}.</p> <p>Once again, thank u in advance.</p> Tue, 08 May 2007 14:53:21 +0000 non_j comment 3690 at https://www.ejabberd.im Oh, you can. Try something https://www.ejabberd.im/node/1524#comment-3685 <p>Oh, you can. Try something like:</p> <pre> {acl, good_msn_users, {user, "romeo%hotmail.com", "msn.example.com"}}. {acl, good_msn_users, {user, "juliet%hotmail.com", "msn.example.com"}}. {acl, msn_users, {server_glob, "msn*"}}. {access, mod_filter, %% filter incoming messages; allow only good messages [{allow, good_msn_users}, {deny, msn_users}, %% filter the rest, including outgoing messages {filter_msn, all}]}. {access, filter_msn, %% Users can send messages to good MSN users [{allow, good_msn_users}, %% but not to other MSN users {deny, msn_users}, %% All non-MSN traffic is allowed {allow, all}]}. </pre> Tue, 08 May 2007 13:36:10 +0000 legoscia comment 3685 at https://www.ejabberd.im hi again well, i tried with https://www.ejabberd.im/node/1524#comment-3682 <p>hi again</p> <p>well, i tried with mod_filter, but i want, among other things, to allow just some msn users to comunicate with the users of my server, and i can't define acl's for external users...</p> Tue, 08 May 2007 12:05:27 +0000 non_j comment 3682 at https://www.ejabberd.im Try mod_filter https://www.ejabberd.im/node/1524#comment-3681 <p>You can try <noindex><a href="/mod_filter" rel="nofollow" >mod_filter</a></noindex>. Maybe you get what you want just setting some ACL and ACCESS.</p> Tue, 08 May 2007 11:20:13 +0000 mfoss comment 3681 at https://www.ejabberd.im