summaryrefslogtreecommitdiff
path: root/include/junk
diff options
context:
space:
mode:
authorAaditya Dhruv <[email protected]>2025-07-31 22:18:27 -0500
committerAaditya Dhruv <[email protected]>2025-07-31 22:18:27 -0500
commitb385a2eda3a12b1b578aef4d0ef9037da3d947e4 (patch)
tree9d537c19c8b24c2a56f38a9be0120537605c8c57 /include/junk
parent4c595bf45e87269d541b30b8012512cba15521f7 (diff)
Parse arp_packet struct and return to caller in eth_recv
Diffstat (limited to 'include/junk')
-rw-r--r--include/junk/network.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/junk/network.h b/include/junk/network.h
index 12a3af0..c88e7f7 100644
--- a/include/junk/network.h
+++ b/include/junk/network.h
@@ -9,10 +9,6 @@ int ipv4_bind(char* ip, char* port, char* data);
//Layer 2, Ethernet
-int eth_bind(char address[]);
-int eth_send(int sockfd, char* data);
-int eth_recv(int sockfd);
-
typedef struct ethhdr ethhdr;
typedef struct arp_packet {
@@ -26,3 +22,7 @@ typedef struct arp_packet {
unsigned char target_hardware_address[6];
unsigned char target_protocol_address[4];
} arp_packet;
+
+int eth_bind(char address[]);
+int eth_send(int sockfd, char* data);
+int eth_recv(int sockfd, arp_packet* packet);