Edit: posted too early; earlier analysis is wrong. There's agreement in packet type, but obexftpd is still complaining that the data packet(s) don't have any body to them.
I'm having some trouble getting openObex and obexFTP to work (the boss is asking for an automatable way of moving files over bluetooth). From the look of the debug output of obexFTP, it seems like there's some confusion between obexftp and obexftpd about what kind of packet is being sent when sending a file. This kind of cock-up wouldn't surprise me with vapor ware, but openobex and obexftp are still available as debian packages, so I'd assume someone in charge thinks it works ok.
obexftp is running on a raspian system, and obexftpd on debian 9.5. They're both running obexftp v0.24 and openObex v1.7.1. For this test, I've built/installed both packages from source on both machines. Not entirely sure where I got the source packages ATM (not from apt-get), but they seemed fine when I DLed them.
I'm running ./obexftp-F -b -B 10 -p ~/404_chars.txt on the raspbian system
Output from obexftpd on the debian system follows:
Waiting for connection...
obex_event() OBEX_EV_REQCHECK: mode=01, obex_cmd=00, obex_rsp=00
Incoming request 00
\obex_event() OBEX_EV_REQDONE: obex_rsp=00
obex_event() OBEX_EV_REQCHECK: mode=01, obex_cmd=02, obex_rsp=00
|obex_ev_progress: obex_cmd_put
put_done>>>
Iconv to locale "UTF-8"
put file name: 404_chars.txt #the file '404_chars.txt' is 404 bytes long
HEADER_LENGTH = 404 #interpreting file data as a large header?!
Got a PUT without a body
Incoming request 02
Received PUT command
put_done>>>
Got a PUT without a body
Deleting file 404_chars.txt #probably deleting because it never got
<<<put_done #anything it recognized as data
/obex_ev_progress: obex_cmd_put
put_done>>>
Got a PUT without a body
Got a PUT without a name. Setting name to OBEX_PUT_Unknown_object
obex_event() OBEX_EV_REQDONE: obex_rsp=00
obex_event() OBEX_EV_REQCHECK: mode=01, obex_cmd=01, obex_rsp=00
Incoming request 01
-obex_event() OBEX_EV_REQDONE: obex_rsp=00
failed: 0
obexftpd reset
Waiting for connection...
it would be an... erm... unusual design if the file data was expected to come in a big header like this output suggests is happening, and after looking over obexftpd.c, I see no reason to suspect that is what was intended. So I'm spelunking down in the openobex tree looking for a why, but in the meantime, can anyone shed any light on this? I absolutely would not expect this from two programs presumably designed to work with each other and from the same distribution version.
Comments
Post a Comment