Sponsored Content
Special Forums IP Networking Obtaining IP address from both my network interface Post 302199439 by citiz3n on Tuesday 27th of May 2008 12:07:14 AM
Old 05-27-2008
Obtaining IP address from both my network interface

HI folks,

I am developing a software which one of the module is to interchange the ip address of another active network interface's when making a socket connection.

I would like to know whether there is any function call that would enable me to retrieve the ip address that is obtained by a particular network interface.

Please.

tq.

Citiz3n
 

10 More Discussions You Might Find Interesting

1. IP Networking

Obtaining IP address

How can UNIX systems obtain IP addresses? Can it obtain from Win 2000 Server, DHCP service, dynamically? (1 Reply)
Discussion started by: Raael
1 Replies

2. UNIX for Dummies Questions & Answers

network address and broadcast address?

say I have a IP address which is 10.0.0.12, and subnet mask is 255.255.255.240, what is the network address and what is the broadcast address which host lives on? And could you explain how to get the answer? thanx in advance! (7 Replies)
Discussion started by: pnxi
7 Replies

3. IP Networking

Obtaining your external IP address using a Unix Utility

Hello, this is my first post on the Unix forums. This is something that's been bothering me for a while, is there any particular UNIX/Linux application that will allow you to see you external IP address? :confused: ( The address beyond your router ) Thank you in advance, I could not find a... (4 Replies)
Discussion started by: inquen
4 Replies

4. Solaris

How to assign MAC address to N/W interface in solaris

I m having interface ce0 ce1 and its sub interfaces for that. I want to give MAC addresses for the same. How will I assign it. Please give solution for the same (4 Replies)
Discussion started by: sunray
4 Replies

5. Solaris

configure zones to have different network interface and network

i need to configure a zone to use different interface (bge2) than global and have connected to completely different network switch & to use its own defaultrouter and hosts file .. is it possible ..if so ..how ? Thanks (9 Replies)
Discussion started by: skamal4u
9 Replies

6. UNIX and Linux Applications

Access to network interface (Mac-network)

Hi, I'm a italian student. For my thesis I develop a gateway with protocol 6lowpan. For that I must access to network interface to develope my personal stack based on standard 802.15.4. Can you help me? I need an explanation for that. (0 Replies)
Discussion started by: berny88
0 Replies

7. Solaris

No network cable But Network interface is UP and Running

I've one Netra 240 After changing main board and system configuration card reader, Network is not accessible any more, Network interfaces are always UP and Running even when there is no cable connected to Network interfaces. I tried to restart and plumb/unplumb with no luck. ifconfig -a... (7 Replies)
Discussion started by: samer.odeh
7 Replies

8. UNIX for Dummies Questions & Answers

Adding a network interface to a bonded interface

I have a RHEL 5 system with a bonded interface configure using only one network port (eth0). So I have config file for ifcfg-bond0 and ifcfg-eth. I'd like to configure eth5 to be the second SLAVE in the bond. My question is, after I modify ifcfg-eth5, can I add eth5 to the bond0 interface without... (1 Reply)
Discussion started by: westmoreland
1 Replies

9. Solaris

How to set gateway address to a particular interface?

How to set gateway address to a particular interface? waht are the files need to update to make it permanent? (2 Replies)
Discussion started by: Naveen.6025
2 Replies

10. UNIX for Advanced & Expert Users

C program to detect duplicate ip address if any after assigning ip address to ethernet interface

Hi , Could someone let me know how to detect duplicate ip address after assigning ip address to ethernet interface using c program (3 Replies)
Discussion started by: Gopi Krishna P
3 Replies
cmpt_get_ifcid(3)					     Library Functions Manual						 cmpt_get_ifcid(3)

NAME
cmpt_get_ifcid(), cmpt_get_addrcid() - get the compartment IDs associated with a network interfaces SYNOPSIS
Parameters ifname Pointer to network interface name string. family Address family of the ipaddress specified. Currently, the AF_INET and AF_INET6 address families are supported. addr Points to a buffer holding an IPv4 address if the family argument is AF_INET or an IPv6 address if the family is AF_INET6. The address should be in numeric format in the network byte order. Numeric format is the binary value that goes into a socket address structure. The binary value is the hex representation of the IPv4/IPv6 address. This binary value resides in the structure for IPv4 address and in the structure for IPv6 address. (See inet(3N) for more details.) mask Network mask in the CIDR representation. DESCRIPTION
The function returns the compartment ID associated with a network interface. The function returns the compartment ID of the tuple as set by a previous invocation of the command. RETURN VALUE
The functions and return the following values: Successful completion. n is the compartment of the interface or the tuple. Function failed. may be set to indicate the error. ERRORS
If any of the following conditions occur, and fails and sets Compartmentalization feature is not supported. The process does not have the appropriate privilege. See privileges(5). Specified interface or the address tuple has no compartment mapping. Specified mask or family is invalid. DEPENDENCIES
These functions are a part of the library. SEE ALSO
compartments(4), compartments(5), privileges(5). cmpt_get_ifcid(3)
All times are GMT -4. The time now is 04:43 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy