Will the pc be acting as a hub or do I need to setup the pc so that it can forward the requests.
Yes and yes.
So I guess I need to set IP forwarding for this.
But you will not have a DHCP server, so have to set IP addresses for both.
How do I do this. Do i have to setup a dhcp server on the pc? that probably wont be ok. How else can i achieve this.
Why would you want to do this ?
If both the PC and the Arduino are connected with DHCP to a hub, they can connect to each other without problem.
It is much easier with a hub as the 'glue' between the two. If the hub is connected to internet or not, that doesn't matter.
I know, but I have to support both options.