Results 1 to 3 of 3

Thread: Connect to gateway

  1. #1
    Join Date
    2023-Feb
    Posts
    1

    Unhappy Connect to gateway

    Hi guys, I'm new to Linux, so it would be nice if you could explain your answers.
    I want to use my virtual Linux machine for pentesting in my OWN network, but I don't get it to connect to it. It connects to the Wi-Fi, but if I run bettercap for example and scan my network it doesn't find anything.
    My input:
    Code:
    net.probe on
    Code:
    [16:10:22] [sys.log] [inf] net.probe starting net.recon as a requirement for net.probe
    10.0.2.0/24 > 10.0.2.15  ? [16:10:22] [sys.log] [inf] net.probe probing 256 addresses on 10.0.2.0/24
    10.0.2.0/24 > 10.0.2.15  ? [16:10:23] [endpoint.new] endpoint 10.0.2.4 detected as 52:54:00:12:35:04 (Realtek (UpTech? also reported)).
    10.0.2.0/24 > 10.0.2.15  ? [16:10:23] [endpoint.new] endpoint 10.0.2.3 detected as 52:54:00:12:35:03 (Realtek (UpTech? also reported)).
    My router-ip is 192.168.2.1, but the routing table is following:
    Code:
    Kernel IP routing table
    Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
    default         10.0.2.2        0.0.0.0         UG    100    0        0 eth0
    10.0.2.0        0.0.0.0         255.255.255.0   U     100    0        0 eth0
    I don't know how to do it right. I have tried it for many hours now, but I get error messages or the Internet is completely gone after my tries.

    Help would be nice.

  2. #2
    Join Date
    2021-May
    Location
    UK
    Posts
    784
    Your in a VM so your VM kali is using a virtual ethernet connection with an ip of 10.0.2.2

    your home network router is on a 192.168.2.* so all your other network devices, including your host the VM is running on, will be on this other subnet!

    Bettercap is an ARP scanner, so it uses MAC addresses and only works on a wired LAN

    lets say we want to run a scan on your home network with nmap;

    nmap 192.168.2.0/24

    that means 'scan all IP's from 192.168.2.0 - 192.168.2.255

    you need to understand networking, that /24 at the end is a CIDR mask, your IPv4 address is 32 bits long, 8 bits per 'octect' so that mask says 'only check the IP's after the first 24 bits have been ignored' so only last 8 bits are used.

    https://www.packetcoders.io/a-beginn...to-subnetting/

    nmap has lots of scripts to help you find open ports and services on your home network, the nmap website is the best place to look, you can even get a free book!

  3. #3
    Join Date
    2021-May
    Location
    UK
    Posts
    784

Similar Threads

  1. How to setup a VM Gateway like Whonix but for a generic VPN
    By AlphaNeptunium in forum General Archive
    Replies: 1
    Last Post: 2023-08-21, 07:06
  2. Reverse VPN Gateway With Raspberry Pi 2B
    By reubadoob in forum ARM Archive
    Replies: 0
    Last Post: 2017-09-13, 03:55

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •