in my module i am adding a event hook for user_send_packet. I trying to log all the packets sent by a user. I also want to log any presence packet sent by the user. but for some reason, i am not receiving the presence packets on the event hook. I do get IQ and chat message packets. Is this a normal behaviour or is there some configuration i need to do to make this work. any help appreciated. thanks guys.
JJ
Looking at the ejabberd
Looking at the ejabberd source code, it seems presence packets sent by the user use a different set of hooks:
thanks for the help. but the
thanks for the help. but the problem is none of the hooks are fired for muc events. more specifically i want to get hold of any presence message sent by a user to muc room. the module i am writing POSTs these packets to our weblogic server. One of the requirements is the server should not receive duplicate packets. so i have to filter all the messages in the ejabberd module before POSTing. which is very difficult if listening on user_receive_packet, which is only hook i know of which will give me presence packets of muc.
ofcourse, it would be great if user_send_packet worked.
JJ