{"action":"created","issue":{"url":"https://api.github.com/repos/ntop/nDPI/issues/272","repository_url":"https://api.github.com/repos/ntop/nDPI","labels_url":"https://api.github.com/repos/ntop/nDPI/issues/272/labels{/name}","comments_url":"https://api.github.com/repos/ntop/nDPI/issues/272/comments","events_url":"https://api.github.com/repos/ntop/nDPI/issues/272/events","html_url":"https://github.com/ntop/nDPI/issues/272","id":178565637,"number":272,"title":"ndpi binary crashing in ftp_control file.","user":{"login":"JeevanNailwal","id":15610624,"avatar_url":"https://avatars.githubusercontent.com/u/15610624?v=3","gravatar_id":"","url":"https://api.github.com/users/JeevanNailwal","html_url":"https://github.com/JeevanNailwal","followers_url":"https://api.github.com/users/JeevanNailwal/followers","following_url":"https://api.github.com/users/JeevanNailwal/following{/other_user}","gists_url":"https://api.github.com/users/JeevanNailwal/gists{/gist_id}","starred_url":"https://api.github.com/users/JeevanNailwal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JeevanNailwal/subscriptions","organizations_url":"https://api.github.com/users/JeevanNailwal/orgs","repos_url":"https://api.github.com/users/JeevanNailwal/repos","events_url":"https://api.github.com/users/JeevanNailwal/events{/privacy}","received_events_url":"https://api.github.com/users/JeevanNailwal/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-09-22T09:48:29Z","updated_at":"2016-09-23T08:25:59Z","closed_at":"2016-09-22T17:00:49Z","body":"Hi All,\r\nI am using the ndpi binary for my assignment project. I am trying to use ndpi to get the application and http url info across a router. In between, I came across a crash(Segfault crash). Please find the gdb details of the crash below:\r\n\r\n(gdb) bt\r\n#0  ndpi_check_ftp_control (flow=0x7f419cac5e40, ndpi_struct=0x7f419daa81c0)\r\n    at protocols/ftp_control.c:942\r\n#1  ndpi_search_ftp_control (ndpi_struct=0x7f419daa81c0, flow=0x7f419cac5e40)\r\n    at protocols/ftp_control.c:994\r\n#2  0x00007f41141c6d2a in check_ndpi_tcp_flow_func (\r\n    ndpi_struct=0x7f419daa81c0, flow=0x7f419cac5e40, \r\n    ndpi_selection_packet=0x7f4115becd28) at ndpi_main.c:3092\r\n#3  0x00007f41141c7402 in ndpi_detection_process_packet (\r\n    ndpi_struct=ndpi_struct@entry=0x7f419daa81c0, \r\n    flow=flow@entry=0x7f419cac5e40, packet=<optimized out>, \r\n    packetlen=<optimized out>, current_tick_l=current_tick_l@entry=0, \r\n    src=src@entry=0x7f4115becd70, dst=0x7f4115bece60) at ndpi_main.c:3358\r\n\r\nI checked the code and figured that it missed a precautionary check in the line 942 in ftp_control.c. Once I added that, my code is running fine.\r\n\r\nCan you please confirm the same? Please let me know if you have any questions about my setup?"},"comment":{"url":"https://api.github.com/repos/ntop/nDPI/issues/comments/249132798","html_url":"https://github.com/ntop/nDPI/issues/272#issuecomment-249132798","issue_url":"https://api.github.com/repos/ntop/nDPI/issues/272","id":249132798,"user":{"login":"kYroL01","id":7222956,"avatar_url":"https://avatars.githubusercontent.com/u/7222956?v=3","gravatar_id":"","url":"https://api.github.com/users/kYroL01","html_url":"https://github.com/kYroL01","followers_url":"https://api.github.com/users/kYroL01/followers","following_url":"https://api.github.com/users/kYroL01/following{/other_user}","gists_url":"https://api.github.com/users/kYroL01/gists{/gist_id}","starred_url":"https://api.github.com/users/kYroL01/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kYroL01/subscriptions","organizations_url":"https://api.github.com/users/kYroL01/orgs","repos_url":"https://api.github.com/users/kYroL01/repos","events_url":"https://api.github.com/users/kYroL01/events{/privacy}","received_events_url":"https://api.github.com/users/kYroL01/received_events","type":"User","site_admin":false},"created_at":"2016-09-23T08:25:59Z","updated_at":"2016-09-23T08:25:59Z","body":"This is because FTP uses TCP, not UDP.\r\nSo, if a packet is carry on UDP, for sure is not FTP. In this way we just quit from dissector and saves time from useless control.\r\nhttps://en.wikipedia.org/wiki/File_Transfer_Protocol#Protocol_overview"}}
{"actor":{"display_login":"kYroL01"}}