I have a pc that shares internet connection to another device, which is configurated to access it's manufacturers website and get any updates available. Note that this internet sharing is made through my ethernet port and that the device isn't configurable to access any other website.

Are there any methods to get all the data that is passing through my ethernet port and then connect my pc to the device and reproduce exactly what the website sent to the device when I recorded it like making my pc the website?

An Example:

Device x Website

device : get the website ID

site : 0000000XX0Xx00xx0

device : get date and time

site : 12:30.31-12-2011GMT-4

device : download updates if available

site : pkg1.zip pkg2.iso pkg3.tar

Device x PC

device : get the website ID

pc : 0000000XX0Xx00xx0

device : get date and time

pc : 12:30.31-12-2011GMT-4

device : download updates if available

pc : pkg1.zip pkg2.iso pkg3.tar

So just reproduce the same thing the website sent to the device, but it'll be my pc that will be sending the data.

4) Ask your friend to access the site from your IP address through a browser. To get the IP address, use the connection information option in your network manager ( top right of your screen ) or use the command ifconfig

You cannot reproduce a non static website, one that contain some sort of server-side scripting or programming, like ASP, JSP, cgi or similar.
–
enzotibOct 22 '11 at 5:44

Regarding what @enzotib said, yes we need to know what sort of website it is. Or we can simply make a cache instead? We can also have a local DNS server pointing to the server on the network instead of fourth point.
–
OxwiviOct 22 '11 at 6:31

You seem to have updated your question, Rodrigo. The solution that you want is possibly different from the one I suggested. Some man-in-the-middle stuff might help, but am not sure. You would probably need to run dns, and use Apache's proxypass module to mirror the manufacturer site. Oh, or you could probably just use some tool that listens on your Ethernet port in promiscuous mode. Don't know of any such tools, though. Some expert could probably help
–
AnirudhOct 24 '11 at 8:57

Thank you all for the help, but I gave up on doing this, I found a program called Wireshark, to listen to my Ethernet port, how ever it's not easy to mirror the data collected. I think that it's perfectly possible with some efforts, but I won't keep trying to do this because I have other priorities at the moment. Thank you for the attention!
–
Rodrigo MartinsNov 2 '11 at 23:49

If the website you are trying to 'copy' is doing any dynamic processing on the server before rendering the HTML, you will not be able to accurately copy it. Without access to the back-end code, the best you would be able to do is to make a static snapshot of that site that would always return the same html response.

Perfect, I think I didn't expressed my case very well, but I don't need to have all the behavior of the website, re-read my question now and tell me if it's possible to be done.
–
Rodrigo MartinsOct 22 '11 at 17:40

1

a static snapshot may do what you want then - Anirudh's answer would get you most of the way there.
–
ImaginaryRobotsOct 22 '11 at 17:50