There are days when you're poking around in /proc/net, and you see "2A00000A" and immediately recognize that as "10.0.0.42"... but you can't seem to figure out how to determine your own machine's ip address in any clever way... this is one of those days.
Because ifconfig (and busybox, actually... oh my goodness, busybox is huge, and I've now looked at more of it than I would have liked to...) know how to do it, but they do it in disgustingly convoluted ways that would be unpleasant to pull out...
So this is a question for you, O my hackerly readers -- how do you figure out what all of your IP addresses are? It seems like the information would be hidden in /proc/net somewheres, but is there a syscall or something? ... Because, elrond is not just called 127.0.0.1, and if I was cool for this proxying thing, I'd recognize when he's referred to as 10.0.0.1 as well... *bangs fist on table* *opts to say "hot dammit!" for emphasis*... hot dammit!
My apologies to the readers for whom that made no sense a'tall.
Because ifconfig (and busybox, actually... oh my goodness, busybox is huge, and I've now looked at more of it than I would have liked to...) know how to do it, but they do it in disgustingly convoluted ways that would be unpleasant to pull out...
So this is a question for you, O my hackerly readers -- how do you figure out what all of your IP addresses are? It seems like the information would be hidden in /proc/net somewheres, but is there a syscall or something? ... Because, elrond is not just called 127.0.0.1, and if I was cool for this proxying thing, I'd recognize when he's referred to as 10.0.0.1 as well... *bangs fist on table* *opts to say "hot dammit!" for emphasis*... hot dammit!
My apologies to the readers for whom that made no sense a'tall.