How can I capture traffic to localhost using Wireshark?












6















I am using Wireshark on Windows Vista and I would like to capture http traffic to localhost (127.0.0.1), for debugging purposes, but I have some questions.




  • How can I do this?

  • What capture interface should I use?


    • If I use my NIC as capture interface, only packets to and from the internet are captured.



  • Are there any settings in Wireshark to capture packets going to and from localhost?










share|improve this question





























    6















    I am using Wireshark on Windows Vista and I would like to capture http traffic to localhost (127.0.0.1), for debugging purposes, but I have some questions.




    • How can I do this?

    • What capture interface should I use?


      • If I use my NIC as capture interface, only packets to and from the internet are captured.



    • Are there any settings in Wireshark to capture packets going to and from localhost?










    share|improve this question



























      6












      6








      6


      1






      I am using Wireshark on Windows Vista and I would like to capture http traffic to localhost (127.0.0.1), for debugging purposes, but I have some questions.




      • How can I do this?

      • What capture interface should I use?


        • If I use my NIC as capture interface, only packets to and from the internet are captured.



      • Are there any settings in Wireshark to capture packets going to and from localhost?










      share|improve this question
















      I am using Wireshark on Windows Vista and I would like to capture http traffic to localhost (127.0.0.1), for debugging purposes, but I have some questions.




      • How can I do this?

      • What capture interface should I use?


        • If I use my NIC as capture interface, only packets to and from the internet are captured.



      • Are there any settings in Wireshark to capture packets going to and from localhost?







      windows-vista localhost wireshark capture






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Apr 25 '14 at 3:56









      HopelessN00b

      1,82931829




      1,82931829










      asked Jun 29 '10 at 22:20









      JonasJonas

      9,6673994120




      9,6673994120






















          3 Answers
          3






          active

          oldest

          votes


















          7














          The short answer is, on Windows you can't. The Wireshark Wiki describes a couple of workarounds, such as installing a virtual network card using the Microsoft Loopback Adapter, however the results are less than optimal. Their suggestion of setting up a new route will give you all of your data twice, and could put unnecessary load on your network if left enabled, but you should get the data.






          share|improve this answer































            2














            If you capture on the local loopback interface (called lo0 on my machine), that will show you the traffic between localhost and itself. The loopback is where localhost traffic goes when it doesn't have to go through the NIC interface.






            share|improve this answer
























            • Thanks, but I forgot to write that I'm using it on Windows. I have updated my question now.

              – Jonas
              Jun 29 '10 at 22:27











            • Oh okay. I've never actually tried Wireshark on Windows, only Linux and Mac OS X.

              – Steve Nay
              Jun 29 '10 at 22:36



















            0














            For anyone reading this in 2019 or later, Wireshark 3.0 ships with Npcap, which allows loopback capture.






            share|improve this answer























              Your Answer








              StackExchange.ready(function() {
              var channelOptions = {
              tags: "".split(" "),
              id: "3"
              };
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function() {
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled) {
              StackExchange.using("snippets", function() {
              createEditor();
              });
              }
              else {
              createEditor();
              }
              });

              function createEditor() {
              StackExchange.prepareEditor({
              heartbeatType: 'answer',
              autoActivateHeartbeat: false,
              convertImagesToLinks: true,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: 10,
              bindNavPrevention: true,
              postfix: "",
              imageUploader: {
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              },
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              });


              }
              });














              draft saved

              draft discarded


















              StackExchange.ready(
              function () {
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f158352%2fhow-can-i-capture-traffic-to-localhost-using-wireshark%23new-answer', 'question_page');
              }
              );

              Post as a guest















              Required, but never shown

























              3 Answers
              3






              active

              oldest

              votes








              3 Answers
              3






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              7














              The short answer is, on Windows you can't. The Wireshark Wiki describes a couple of workarounds, such as installing a virtual network card using the Microsoft Loopback Adapter, however the results are less than optimal. Their suggestion of setting up a new route will give you all of your data twice, and could put unnecessary load on your network if left enabled, but you should get the data.






              share|improve this answer




























                7














                The short answer is, on Windows you can't. The Wireshark Wiki describes a couple of workarounds, such as installing a virtual network card using the Microsoft Loopback Adapter, however the results are less than optimal. Their suggestion of setting up a new route will give you all of your data twice, and could put unnecessary load on your network if left enabled, but you should get the data.






                share|improve this answer


























                  7












                  7








                  7







                  The short answer is, on Windows you can't. The Wireshark Wiki describes a couple of workarounds, such as installing a virtual network card using the Microsoft Loopback Adapter, however the results are less than optimal. Their suggestion of setting up a new route will give you all of your data twice, and could put unnecessary load on your network if left enabled, but you should get the data.






                  share|improve this answer













                  The short answer is, on Windows you can't. The Wireshark Wiki describes a couple of workarounds, such as installing a virtual network card using the Microsoft Loopback Adapter, however the results are less than optimal. Their suggestion of setting up a new route will give you all of your data twice, and could put unnecessary load on your network if left enabled, but you should get the data.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Jun 29 '10 at 22:31









                  heavydheavyd

                  50.5k12123156




                  50.5k12123156

























                      2














                      If you capture on the local loopback interface (called lo0 on my machine), that will show you the traffic between localhost and itself. The loopback is where localhost traffic goes when it doesn't have to go through the NIC interface.






                      share|improve this answer
























                      • Thanks, but I forgot to write that I'm using it on Windows. I have updated my question now.

                        – Jonas
                        Jun 29 '10 at 22:27











                      • Oh okay. I've never actually tried Wireshark on Windows, only Linux and Mac OS X.

                        – Steve Nay
                        Jun 29 '10 at 22:36
















                      2














                      If you capture on the local loopback interface (called lo0 on my machine), that will show you the traffic between localhost and itself. The loopback is where localhost traffic goes when it doesn't have to go through the NIC interface.






                      share|improve this answer
























                      • Thanks, but I forgot to write that I'm using it on Windows. I have updated my question now.

                        – Jonas
                        Jun 29 '10 at 22:27











                      • Oh okay. I've never actually tried Wireshark on Windows, only Linux and Mac OS X.

                        – Steve Nay
                        Jun 29 '10 at 22:36














                      2












                      2








                      2







                      If you capture on the local loopback interface (called lo0 on my machine), that will show you the traffic between localhost and itself. The loopback is where localhost traffic goes when it doesn't have to go through the NIC interface.






                      share|improve this answer













                      If you capture on the local loopback interface (called lo0 on my machine), that will show you the traffic between localhost and itself. The loopback is where localhost traffic goes when it doesn't have to go through the NIC interface.







                      share|improve this answer












                      share|improve this answer



                      share|improve this answer










                      answered Jun 29 '10 at 22:24









                      Steve NaySteve Nay

                      21028




                      21028













                      • Thanks, but I forgot to write that I'm using it on Windows. I have updated my question now.

                        – Jonas
                        Jun 29 '10 at 22:27











                      • Oh okay. I've never actually tried Wireshark on Windows, only Linux and Mac OS X.

                        – Steve Nay
                        Jun 29 '10 at 22:36



















                      • Thanks, but I forgot to write that I'm using it on Windows. I have updated my question now.

                        – Jonas
                        Jun 29 '10 at 22:27











                      • Oh okay. I've never actually tried Wireshark on Windows, only Linux and Mac OS X.

                        – Steve Nay
                        Jun 29 '10 at 22:36

















                      Thanks, but I forgot to write that I'm using it on Windows. I have updated my question now.

                      – Jonas
                      Jun 29 '10 at 22:27





                      Thanks, but I forgot to write that I'm using it on Windows. I have updated my question now.

                      – Jonas
                      Jun 29 '10 at 22:27













                      Oh okay. I've never actually tried Wireshark on Windows, only Linux and Mac OS X.

                      – Steve Nay
                      Jun 29 '10 at 22:36





                      Oh okay. I've never actually tried Wireshark on Windows, only Linux and Mac OS X.

                      – Steve Nay
                      Jun 29 '10 at 22:36











                      0














                      For anyone reading this in 2019 or later, Wireshark 3.0 ships with Npcap, which allows loopback capture.






                      share|improve this answer




























                        0














                        For anyone reading this in 2019 or later, Wireshark 3.0 ships with Npcap, which allows loopback capture.






                        share|improve this answer


























                          0












                          0








                          0







                          For anyone reading this in 2019 or later, Wireshark 3.0 ships with Npcap, which allows loopback capture.






                          share|improve this answer













                          For anyone reading this in 2019 or later, Wireshark 3.0 ships with Npcap, which allows loopback capture.







                          share|improve this answer












                          share|improve this answer



                          share|improve this answer










                          answered Jan 16 at 0:27









                          Gerald CombsGerald Combs

                          26114




                          26114






























                              draft saved

                              draft discarded




















































                              Thanks for contributing an answer to Super User!


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid



                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.


                              To learn more, see our tips on writing great answers.




                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function () {
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f158352%2fhow-can-i-capture-traffic-to-localhost-using-wireshark%23new-answer', 'question_page');
                              }
                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              Popular posts from this blog

                              flock() on closed filehandle LOCK_FILE at /usr/bin/apt-mirror

                              Mangá

                              Eduardo VII do Reino Unido