def testServerInsecurePath(self):
    raddress = '127.0.0.2'
    rport = 10000
    timeout = 5
    root = os.path.dirname(os.path.abspath(__file__))
    serverstate = tftpy.TftpContextServer(raddress, rport, timeout, root)
    rrq = tftpy.TftpPacketRRQ()
    rrq.filename = '../setup.py'
    rrq.mode = 'octet'
    rrq.options = {}
    self.assertRaises(tftpy.TftpException, serverstate.start, rrq.encode().buffer)
def testServerInsecurePath(self):
    raddress = '127.0.0.2'
    rport = 10000
    timeout = 5
    root = os.path.dirname(os.path.abspath(__file__))
    serverstate = tftpy.TftpContextServer(raddress, rport, timeout, root)
    rrq = tftpy.TftpPacketRRQ()
    rrq.filename = '../setup.py'
    rrq.mode = 'octet'
    rrq.options = {}
    self.assertRaises(tftpy.TftpException, serverstate.start, rrq.encode().buffer)