
cbus Documentation, Release 0.1-dev
4.4 CFTP
CFTP is a service which acts as a back-door into the device. It runs on port 8336, and is managed by the service
cftp_daemon.
It has a hard-coded password to access the service. Despite the name, it doesn’t actually implement FTP. It is used by
Clipsal’s programming software in order to manage the device. It appears to have the following functionality:
• Manage port forwards inside of the network when the device is acting as the router for the network. Unknown
how this is controlled.
• Reflash the contents of partition 6 of FLASH (label: clipsal). Appears to be a gzip-compressed tarball,
which gets extracted to /www/clipsal/resources.
Communication with the server is done with a simple text-based protocol, with the UNIX newline character indicating
the end of command. Do not send DOS or other style linefeeds as this will not work.
If the daemon does not understand your command, it will simply send no response.
4.4.1 Startup process
On startup, the process will:
1. Delete /tmp/
*
.tar.gz.
2. Copy the contents of /dev/mtblock/6 to /tmp/test.cta.
3. Mount a new ramfs to /www/clipsal/resources/
4. Extract settings.conf from the gzip-compressed tarball /tmp/test.cta to
/www/clipsal/resources/.
5. Read daemon configuration from settings.conf.
6. Extract all files from the tarball to /www/clipsal/resources/.
4.4.2 Unauthenticated state
Connecting to the service yields a welcome message:
200 Welcome
PASS
Client command:
PASS bloop
The server will respond that you are logged in successfully, and transition your connection to the authenticated state:
201 Logged in
Note: There is no way to change this password. It is hard coded in Wiser’s firmware.
Sending other passwords yield no response.
16 Chapter 4. Wiser
Comentários a estes Manuais