Results 1 to 5 of 5
  1. #1
    islamfunny is offline Member
    Join Date
    Aug 2008
    Posts
    27
    Rep Power
    0

    Default Reading or changing sequenc number in TCP packets

    I don't know wether this is feasible,But you're my last chance to figure out something else.Can i read the sequence number that comes inside the TCP header in the incomming packets?This sound illogical but since there is a method for getting the IP of the sender(And that IP exits in the IP header Network layer i),then the sequence number (TCP header inside the Transport layer)must exits in the packet.Can i read it?

    -And an even more illogical question? can i change that sequence number or the acknowlege number to form a new packet ? Its like converting a packet to and from a packet object to a string of bits ?

    I know excatly where the sequence and acknowledge numbers are located (after how many bits) inside the TCP header?

  2. #2
    fishtoprecords's Avatar
    fishtoprecords is offline Senior Member
    Join Date
    Jun 2008
    Posts
    571
    Rep Power
    7

    Default

    You can write your own protocol if you don't like TCP/IP. That is what you would be doing if you changed the use of the sequence field that are internal to TCP/IP packets.

    I can't imagine why you would want to do this. Its much easier to just use TCP/IP, it works and has been debugged over decades.

  3. #3
    islamfunny is offline Member
    Join Date
    Aug 2008
    Posts
    27
    Rep Power
    0

    Default

    first off I'm wanna appply this to javame application and jpcap have some native code i dunno how to use it on a cell phone.

    I was thinking if i can change the acknowledge number i can order the server i'm connected to to send the data from a specific byte no sequentially.

    This way say if I'm downloading a file and i quit for some reasone io can later on calculate the size of what I;ve downloded and do the following :

    -Establish the connection with the server
    -Receive the first packet.
    -Drop this packet and then form another packet with the same info as if it were formed automatically except replaciong the acknolwedge number with the size of my buffered data + 1 .

    I know there will be more to it than this row dicription (in case iit is feasible) but i wannna know wether this is feasible.

    I also know that some protocols support requesting files from a specific byte(like HTTP) but i wanna do it inside the network layer not the application layer

  4. #4
    Norm's Avatar
    Norm is online now Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,902
    Rep Power
    25

    Default

    Does the network layer have access to anything other than what the application layer gives it?
    Would look like a way to access anything.

  5. #5
    satu is offline Member
    Join Date
    Aug 2008
    Posts
    12
    Rep Power
    0

    Default

    if you are wanting to do this just use your own Protocol Implementation. use java's UDP style and make it like TCP, after this you have full control over packets and all.

Similar Threads

  1. changing current directory
    By flaca in forum New To Java
    Replies: 7
    Last Post: 03-06-2011, 03:50 AM
  2. Regarding UDP Datagram packets
    By Raghavendra in forum Networking
    Replies: 1
    Last Post: 06-11-2008, 12:12 AM
  3. Encrypting packets
    By bugger in forum Networking
    Replies: 2
    Last Post: 02-04-2008, 11:24 AM
  4. Reading Binary File and Changing data
    By janakiram.attuluri in forum Advanced Java
    Replies: 1
    Last Post: 12-21-2007, 11:10 AM
  5. How to capture IP packets
    By Hasan in forum Networking
    Replies: 1
    Last Post: 05-31-2007, 06:44 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •