Pagina 1 di 2 1 2 ultimoultimo
Visualizzazione dei risultati da 1 a 10 su 20
  1. #1
    Utente di HTML.it L'avatar di james
    Registrato dal
    Jun 2002
    Messaggi
    1,481

    conoscere il proprio indirizzo ip pubblico (dietro al router) da shell

    Mi chiedevo se ci fosse un modo per poter conoscere da una linux box, da shell, l'ip che compare dalla parte wan del router a cui è connesso il pc stesso...tipo tutti quei siti che ti dicono che ip pubblico hai, solo che da shell come faccio a saperlo??

  2. #2
    ho trovato questo: http://bbs.archlinux.org/viewtopic.php?id=53709

    non ho provato perche' su mac non ho wget, ma penso funzionera'.

    edit: provato e funziona.
    max

    Silence is better than bullshit.
    @mmarcon
    jHERE, Maps made easy

  3. #3

  4. #4
    Originariamente inviato da mxa
    ho trovato questo: http://bbs.archlinux.org/viewtopic.php?id=53709

    non ho provato perche' su mac non ho wget, ma penso funzionera'.

    edit: provato e funziona.
    Mac nativamente ha wget
    There are two kinds of researchers:
    those that have implemented something and those that have not.
    The latter will tell you that there are 142 ways of doing things
    and that there isn't consensus on which is best.
    The former will simply tell you that 141 of them don't work.

  5. #5
    Utente di HTML.it L'avatar di james
    Registrato dal
    Jun 2002
    Messaggi
    1,481
    Grazie, siete stati molto precisi!

  6. #6
    Utente di HTML.it L'avatar di alexmaz
    Registrato dal
    May 2001
    Messaggi
    972
    Tutti i metodi segnalati non fanno altro che prendere l'ip da una pagina web. Ok lo fai da riga di comando ma se quei siti fossero inaccessibili non avresti l'informazione.
    The individual has always had to struggle to keep from being overwhelmed by the tribe. If you try it, you will be lonely often, and sometimes frightened. But no price is too high to pay for the privilege of owning yourself.

  7. #7
    Utente di HTML.it
    Registrato dal
    Jun 2007
    Messaggi
    225
    Direi che non c'e' altra possibilità. Quanti hop si possono fare prima di arrivare all'esterno in una rete?

  8. #8
    Utente di HTML.it L'avatar di james
    Registrato dal
    Jun 2002
    Messaggi
    1,481
    Originariamente inviato da alexmaz
    Tutti i metodi segnalati non fanno altro che prendere l'ip da una pagina web. Ok lo fai da riga di comando ma se quei siti fossero inaccessibili non avresti l'informazione.
    sì hai ragione, ma non c'è altro modo...meglio di niente no!?

  9. #9
    Sempre con il WGET ma è un lavoro orrendo...

    "rm -rf .temp ; mkdir .temp ; cd .temp ; wget http://checkip.dyndns.org/index.html && cat index.html | cut -d ' ' -f 6 | cut -d '<' -f 1 ; cd .. ; rm -rf .temp"

    cancella una aventuale cartella .temp (nascosta) la ricrea scarica l' index.html nella cartella nascosta e ne estrae il tuo IP e poi ricancella la cartella nascosta.

    Lo usano molti temi di superkaramba per trovare l' indirizzo wan.
    There are two kinds of researchers:
    those that have implemented something and those that have not.
    The latter will tell you that there are 142 ways of doing things
    and that there isn't consensus on which is best.
    The former will simply tell you that 141 of them don't work.

  10. #10
    Originariamente inviato da claudiocrack
    Mac nativamente ha wget
    codice:
    mmarcon@dhcp192-1-118-113:~$ wget
    -bash: wget: command not found
    max

    Silence is better than bullshit.
    @mmarcon
    jHERE, Maps made easy

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.