HS TFTP C Source Library

Overview

HS TFTP is a software library in C (supplied with full source code) which implements Trivial File Transfer Protocol (TFTP) over UDP socket layer according to RFC 1350. Support for client and server side for both file get and put are provided. Up to 100 concurrent sessions are supported. TFTP blocksize option is also supported (RFC 1782, RFC 1783). A version of HS TFTP for Windows Mobile / WinCE is also available, contact us for more information

HS TFTP is supplied in a form of full ANSI C source code and binaries and would require no or minimal integration effort by the customer, assisted by Hillstone Software after sales support.

The use of HS TFTP C Source Library is Royalty Free.



Features

  • TFTP server and client
  • Defaults to 100 concurrent sessions
  • Configurable block size (default 512), TFTP blocksize option (RFC 1782 and RFC 1783)
  • TFTP File upload
  • TFTP File download


Model of operation

When user application initlialises Hs TFTP library, it provides interface callbacks for the services used by HS TFTP protocol module: timer management, memory management and event callbacks. This architecture makes it easy to port HS TFTP protocol module to any environment. HS TFTP internally at a lower layer interfaces to HS Sock library which provides UDP transport services. User application need not worry about Winsock - HS TFTP does all transmission, reception and event handling over socket layer

TFTP module handles all protocol information flow, error recovery, acknowledgements, timeouts and so on. When it is appropriate to send next block of data HS TFTP will get next memory block from user application. Similarly, when data has been received HS TFTP module will get the next block of memory from user application to store data into

Along with XMODEM or as an alternative, TFTP is often used in embedded devices and appliances for the purpose of software or configuration upgrade or retrieval.

Release History

23 August 2012, Version 1.3.3
- Send TFTP ERR packet and close session if ACK received from remote peer with block nuber greater than expected. This sitiation was previously handled by retransmissions and timeouts only

12 April 2012, Version 1.3.3
- Fixed a bug in the HSTFTP library, on reception of ERR packet the TFTP session was not closed (instead it was allowed to timeout). The correct behaviour is to close the session immediately - this was the nature of the fix.
- Create build environemnt for MS Visual Studio 2010 based on existing Visual Studio 6 projects

15 June 2011, Version 1.3.2
- Potential fixes / improvements in HsSock - socket interface library
- Registry / config changes in tftp demo to support Windows 7

14 October 2010, Version 1.3.1
- Better support for concurrent sessions in serer and client mode
- Improvements in HsSock - socket interface library
- UI changes to support Windows 7
- Improve timer support
- Improve internal session management

14 July 2009, Version 1.3.0
- Support for TFTP blocksize option (RFC 1782 and RFC 1783)

05 July 2008, Version 1.2.6
- fixed handle leak in socket layer when closing and de-initialising the library

03 Dec 2008, Version 1.2.5
- Fix memory corruption, prevent socket from closing twice

22 Oct 2007, Version 1.2.4
- Fix memory leak in list library - Added console demo application

02 Oct 2007, Version 1.2.3
- support for transfer of files between directories on same PC - fix for Last ack not sent if size multiple of 512

01 Nov 2007, Version 1.2.1
- memory leak fix for packet buffers

04 Dec 2007, Version 1.2
- base tested full release


HS TFTP Library Architecture

The library is a stand-alone module which links directly to customer application:



Customization

Hillstone Software provides additional services for customization, porting and integration of the library code to better suit the needs of your products