Trivial File Transfer Protocol (TFTP)
Assignment 2
The Trivial File Transfer Protocol (TFTP) is an Internet software utility for
transferring files that is simpler to use than the File Transfer Protocol (FTP) but
less capable. It is used where user authentication and directory visibility are not
required. For example, it is used by Cisco routers and switches to transfer
images of the operating system from/to the devices.
NOTE: TFTP's port is 69 (a system/OS port). This is below 1024 and therefore
you cannot bind a Socket to it unless you have administrative access rights on
the machine you are working. To avoid any complications you can use any port >
1024 to bind server sockets.
Task 1: Implementation of the Trivial File
Transfer Protocol (TFTP)
For this task you need to implement (in Java) the Trivial File Transfer Protocol
(TFTP) as specified in RFC 1350 (Links to an external site.)Links to an external
site.. You will submit source code for a client and server application that 'speak'
the TFTP protocol. You will built your protocol on top of UDP. Compared to the
specifications in the RFC, you will implement a slightly simplified version:
Support for octet mode only. The files should be transferred as a raw
sequence of bytes. Do not read, write or transfer files as characters.
Support only for error handling when the server is unable to satisfy the
request because the file cannot be found.
No support for error handling when data duplication occurs.
The client and server applications should be simple Java console applications.
The server should operate (i.e. read and write files) in the directory where it is
started from. The server should support simultaneous file transfers to and from
multiple clients. The client should just read command line arguments (or have a
very simple console-based menu - e.g. "press 1 to store file, press 2 to retrieve
file") and execute user commands (i.e. reading or writing a file).
Hint: the simplest way to implement timeouts is by calling
代写TFTP留学生作业、Java课程设计作业代做、Java程序语言作业调试
the setSoTimeout() method on the DatagramSocket objects (assuming that you
are using blocking I/O). If the timeout expires,
a java.net.SocketTimeoutException is raised, though the DatagramSocket is still
valid.
Task 2: Implementation of an even simpler
version of TFTP on top of TCP
For this task you will use TCP sockets to implement a protocol that operates like
TFTP (i.e. supports only read and write operations). Given that TCP supports
in-order, reliable data transport, you should not implement the relevant
mechanisms described in RFC 1350 (ACKs, retransmissions). The client and
server applications should be equally simple, as in Task 1. The server must be
able to handle multiple file transfers.
Marking Criteria
You should make sure that your code compiles. Code which does not compile
will receive at most 20%.
I will assess your assignment using the following criteria:
TFTP-UDP-Server (35%)
Is the server-side of the protocol fully and correctly implemented
(based on the specifications in the RFC)? i.e. read/write requests,
acknowledgments, timeouts, error handling, support for simultaneous
file transfers.
TFTP-UDP-Client (30%):
Is the client-side of the protocol fully and correctly implemented (based
on the specifications in the RFC)? i.e. read/write requests,
acknowledgments, timeouts, error handling.
TFTP-TCP-Server (10%)
Is the server-side of the protocol fully and correctly implemented? i.e.
read/write requests, error handling, support for simultaneous file
transfers.
TFTP-TCP-Client (10%):
Is the client-side of the protocol fully and correctly implemented? i.e.
read/write requests, error handling.
Description of Protocols (10%):
Is there description for both protocols and how/where the specifications
are implemented?
Is the description well-written with clear references to the source code?
Other Characteristics (5%):
Is the code commented appropriately?
Is it indented correctly?
? Is naming of variables and methods sensible?
Submission Guidelines
You should submit the coursework by the deadline posted on Sussex
Direct (and the submission link on Canvas). Standard penalties for late
submissions will apply. You will need to submit a .zip file containing the
following:
Well-formatted and well-documented source code (written in Java) in 4
separate Netbeans projects that can be compiled and run. The
Netbeans projects, named TFTP-UDP-Server, TFTP-UDP-Client,
TFTP-TCP-Server and TFTP-TCP-Client, respectively, will include all
required source code to execute the 2 different file transfer protocols.
A short report (up to 2000 words) describing your protocols, the source
code and the design decisions that you made.
Please do not put your names on your submissions, but do include your
candidate number. Failure to submit source code, as described in the first
bullet, will result to a zero mark as I will not be able to assess your
programming effort.
Plagiarism and Collusion
The coursework you submit is supposed to have been produced by
you and you alone. This means that you should not: work together with
anyone else on this assignment
give code for the assignment to other students
request help from external sources
do anything that means that the work you submit for assessment is not
wholly your own work, but consists in part or whole of other people’s
work, presented as your own, for which you should in fairness get no
credit
If you need help ask your tutor The University considers it misconduct to
give or receive help other than from your tutors, or to copy work from
uncredited sources, and if any suspicion arises that this has happened,
formal action will be taken. Remember that in cases of collusion (students
helping each other on assignments) the student giving help is regarded by
the University as just as guilty as the person receiving help, and is liable
to potentially receive the same penalty. Also bear in mind that suspicious
similarities in student code are surprisingly easy to spot and sadly the
procedures for dealing with it are stressful and unpleasant. Academic
misconduct also upsets other students, who do complain to us about
unfairness. So please don’t collude or plagiarise.
因为专业,所以值得信赖。如有需要,请加QQ:99515681 或邮箱:99515681@qq.com
微信:codinghelp
Trivial File Transfer Protocol (TFTP)的更多相关文章
- TFTP(Trivial File Transfer Protocol,简单文件传输协议)
TFTP(Trivial File Transfer Protocol,简单文件传输协议),是 TCP/IP 协议族中用来在客户机和服务器之间进行简单文件传输的协议,开销很小.这时候有人可能会纳闷,既 ...
- TFTP(Trivial File Transfer Protocol,简单文件传输协议)
网络特性 通常使用UDP 69端口(据说可改成TCP) 与FTP区别 轻量级,适用于传输小文件,当然功能也少些,比如没有列出目录功能,不进行认证
- FTP(File Transfer Protocol)是什么?
文件传输协议 FTP(File Transfer Protocol),是文件传输协议的简称.用于Internet上的控制文件的双向传输.同时,它也是一个应用程序(Application).用户可以通过 ...
- FTP - File Transfer Protocol
FTP - File Transfer Protocol FTP 实际上使用了两个 TCP 链接. 一个作为控制信道用, 主要传输一些指令和响应, 比如 ACK 或 错误码. 另一个链接是数据信道, ...
- ftp - Internet 文件传输程序 (file transfer program)
概述 (SYNOPSIS) ftp [-pinegvd ] [host ] pftp [-inegvd ] [host ] 说明 (DESCRIPTION) 用户通过 Ftp 这个程序来使用 Inte ...
- SSH File Transfer遇到错误"too many authentication failures for root".A protocol error was detected......
在SSH Secure Shell 连接Linux centos的时候,遇到F-Secure SSH File Transfer错误"too many authentication fai ...
- PAT 5-8 File Transfer (25分)
We have a network of computers and a list of bi-directional connections. Each of these connections a ...
- 让 File Transfer Manager 在新版本WIndows上能用
最近研究.NET NATIVE,听说发布了第二个预览版,增加了X86支持,所以下,发现连接到的页面是:https://connect.microsoft.com/VisualStudio/Downlo ...
- PAT 05-树7 File Transfer
这次的题让我对选择不同数据结构所产生的结果惊呆了,一开始用的是结构来存储集合,课件上有现成的,而且我也是实在不太会,150ms的时间限制过不去,不得已,看到这题刚好可以用数组,结果7ms最多,有意思! ...
随机推荐
- 【原创】Linux基础之上传下载
1 rz sz 安装 yum install -y lrzsz 上传 rz ,对话框操作 下载 sz $filename 注意:rz不能上传大于4g的文件,此时可以改为scp或sftp上传,其中sft ...
- JS 判断传入的变量类型是否是Array
function f(arr){ 1.通过_proto_ 进行判断 (arr._proto_ 指向Array.prototype); 2.通过constructor进行判断 (arr.construc ...
- VICA 架构设计
本文记录最近完成的一个通用实时通信客户端的架构. 背景 我们公司是做税务相关的软件,有针对大客户 MIS 系统,也有针对中小客户的 SaaS 平台.这些系统虽然都是 B/S 的,但是也需要使用 Act ...
- 学习笔记: 异常状态管理,托管堆垃圾回收,CLR寄宿
1. 2. string 在内存中是连续分配的,是一个数组, 数组的特点就是 查询块,增删慢,改动Array导致所有数组成员地址变动,成本高 而string又是在程序中经常变动的 ,所有 clr中对 ...
- CAP分布式事务 学习及简单demo
完全参考 github的指导 demo地址, Pub使用 efcore , Sub 使用 dapper, mysql数据库 https://files.cnblogs.com/files/xtxtx/ ...
- neo4j 学习笔记
1.参考 https://blog.csdn.net/appleyk/article/category/7408344 系列文章 (不支持 spring boo 2.0 以下的,入门可做参考) 2.底 ...
- fft,ntt
在被两题卡了常数之后,花了很久优化了自己的模板 现在的一般来说任意模数求逆1s跑3e5,exp跑1e5是没啥问题的(自己电脑,可能比luogu慢一倍) 当模数是$998244353,100453580 ...
- vitualbox中的centos7与主机共享文件
我在vitualbox中安装了一个centos7,最小安装.主机是win10操作系统.那么如何在虚拟机和主机之间进行文件共享呢,下面是本人实现过程,以及过程中遇到的一些问题. 1.在主机中选择一个文件 ...
- python 单行写法
if not any([_ in fingers for _ in finger_ids])
- Selenium2+python自动化45-18种定位方法(find_elements)
前言 江湖传言,武林中流传八种定位,其中xpath是宝刀屠龙,css是倚天剑. 除了这八种,其实还有十种定位方法,眼看就快失传了,今天小编让失传已久的定位方法重出江湖! 一.十八种定位方法 前八种是大 ...