Skip to content

Davenchy/domain_to_ipv4_c

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

Domain to IPv4 Converter in C

This project provides a simple command-line tool written in C to convert domain names to their corresponding IPv4 addresses. It uses the getaddrinfo function from the netdb.h library to perform DNS resolution and retrieve IP addresses associated with a given domain name.

Usage

Simply compile the provided source code and run the executable with the domain name as an argument.

$ gcc domain_to_ipv4.c -o domain_to_ipv4
$ ./domain_to_ipv4
Usage: ./domain_to_ipv4 <domain>
$ ./domain_to_ipv4 example.com
93.184.216.34

Resources

Releases

No releases published

Packages

No packages published

Languages