1. You are viewing our forum as a guest. For full access please Register. WindowsBBS.com is completely free, paid for by advertisers and donations.

Help with Xp dns redirection problem

Discussion in 'Networking (Hardware & Software)' started by pberrett, 2008/12/20.

  1. 2008/12/20
    pberrett

    pberrett Inactive Thread Starter

    Joined:
    2008/12/20
    Messages:
    3
    Likes Received:
    0
    Hi all

    I have a dns redirection problem and would be grateful if someone could provide some help. I wish to stress at the outside that what I am trying to do is not for any kind of personal gain nor is it for any kind of spoofing or illegal activity. I recently sought help at another bulletin board and got a number of negative responses which were entirely undeserved.

    Anyway here is my problem. I cohost an iptv show about Amateur Radio and electronics and am looking to put together a segment about building what I call a 'warmspot' (like a hotspot but cooler). You probably have connected to a hotspot at some point in order to get internet access (eg at McDonalds) and been taken to a captive portal page and thence gone on to surf the internet.

    What I want to do is similar but without the internet access. I figure that there can be occasions when someone might like to deliver information by wifi on a localised and short-term basis eg you might be selling your home so you setup a web page on an old wirelessly connected windows laptop and deliver that by wireless to a local area. People see a sign at the front of your house saying connect to 'Petes Home' using your wirelessly connected laptop and open your browser. They are then taken to a home page with pictures of the inside of the house. Alternatively you might be running a local festival and you use the same system to deliver a web page to people locally telling then about what hours the festival is open and what attractions there are.

    In each case there is no internet connectivity and no internet access is provided. There is no spoofing or any illegal activity, this is just a simple delivery of a web site using a captive portal.

    Why Windows and why an old laptop? I want to make this project as simple as possible and use recycled stuff that people already have. Many people may have an old slow windows enabled laptop and they can use this with an old router or perhaps a wireless card to build a Warmspot. I tried to do this using Linux but installing Linux on my laptop proved to be a nightmare (I tried several different types of Linux but ultimately failed). It just isn't easy particularly with the drivers.

    I have suggested this idea to a few people and they have agreed that it would be a great project if I could get it working.

    I have had some limited success so far. I have managed to install and configure Abyss Web Server running on an old Windows Xp laptop which is connected to a router. I can use a 2nd laptop to connect wirelessly to the router and the router's DHCP gives me an ip address. I then open up internet explorer and if I type in 192.168.0.100 (the ip address of the first laptop) I get taken to the web page that I have setup on the web server. So you can see I am almost there. I could easily put on my sign ' type in 192.168.0.100 into the address field in internet explorer' but I would prefer to have a captive portal solution like you see at Hotspots ie when you initially open the browser your initial page request is redirected to 192.169.0.100

    I should have mentioned earlier that I wish to implement all this above using freeware to reduce costs for people trying to build this project. Abyss is freeware and I tried to use a freeware program called dnsredirector but have been unable to get it working. Perhaps there is an easier way?

    I have spent several days trying to get my captive portal working without success. As I said before I don't want to spoof anything - I also want the address field to change to reflect the redirected page ie to 192.168.0.100

    Can anyone help me? I think this is a worthy project that could be of use to a lot of people.

    One other thing. Once I get my Warmspot running I'd like to interface Christmas light around my house to it so that people in my immediate area can do interesting stuff using their laptops eg turning the lights on or off, activating a predetermined light show etc etc. It could be a fun thing to try out for next Christmas and the kids would love it.

    Regards Peter
     
  2. 2008/12/20
    ReggieB

    ReggieB Inactive Alumni

    Joined:
    2004/05/12
    Messages:
    2,786
    Likes Received:
    2
    I think the redirect will be difficult to implement robustly - a key problem being how do you release it so people can get back to normal when they disconnect from your network.

    I'd suggest a simpler approach would be to install a DNS server on the XP system. You can set up the router so that it's DHCP gives out the XP PC as the DNS server. Then you will be able to create a local domain (e.g. petes-home.local) with an www A host record pointing at your XP box. Then people can access your site via www.petes-home.local while they are connected to your network.

    As for the control of the lights: Lindy's IPower Controllers work a treat though may well be out of your budget. You can get a perl script from Lindy to control it remotely, and I was easily able to create a Ruby class to control these units. So they are relatively easy to encorporate into a web application.
     

  3. to hide this advert.

  4. 2008/12/20
    pberrett

    pberrett Inactive Thread Starter

    Joined:
    2008/12/20
    Messages:
    3
    Likes Received:
    0
    Thanks Reggie

    Your post raises some interesting issues and this is an area I need to get a better understanding of.

    First my router has an area where one can manually set the ip address and also specify where the dns server is. When I use my second laptop to connect to the router via wireless I get allocated a new ip address say 192.168.0.101 if I click on the wireless connection icon at the bottom of my screen and then go into support I can see what the connection details are ie my new ip etc. it shows that my dns server is 192.168.0.1 which is the ip of my router. Even if I manually set my router's dns to be 192.168.0.100 (ip of 1st laptop) it still end up showing as being 192.168.0.1 which is strange.

    You mention releasing the ip when people disconnect. When people connect to a new access point or hotspot wouldn't they just get a new ip address, dns server etc allocated at that point?

    You are correct that I might be able to set up a dns server and have people log into a preprepared domain say petes-home.com however I could just as easily ask people to type in 192.168.0.100 on my sign. My router also has a field for my domain name so I probably could implement what you are suggesting that way although I have as yet not tried.

    Hotspots however generally don't implement their access in the manner you are suggesting. I presume they do so to ensure control over what the user has access to. In my case I just assume that some people are really dumb and I want to make my system a no-brainer for people to use ie they don't have to think too hard. I will take on board the idea of using a local domain name though as it does have a certain appeal.

    I cna see that there would be 2 ways of implementing the redirection. One could run the dns server and map all domains name (*) to the one ip address or actually have software do the direction. Alternatively one could have no domain names mapped and then have the 404 error web page as the page you want to serve.

    I have tried all the above using dnsdirector with no success. I am puzzled as to why it will not redirect the requests from laptop 2?

    Regards Peter
     
  5. 2008/12/21
    Scott Smith

    Scott Smith Inactive Alumni

    Joined:
    2002/01/12
    Messages:
    1,950
    Likes Received:
    4
  6. 2008/12/21
    TonyT

    TonyT SuperGeek Staff

    Joined:
    2002/01/18
    Messages:
    9,072
    Likes Received:
    400
  7. 2008/12/22
    pberrett

    pberrett Inactive Thread Starter

    Joined:
    2008/12/20
    Messages:
    3
    Likes Received:
    0
    Thanks but software like 2hotspot requires you to be connected to the internet.

    I really don't want to have to rely on an internet service (and their costs) and also I want my setup to be portable.

    I winder if anyone out there has ever gotten dnsredirector to work?

    Regards Peter
     
  8. 2008/12/22
    ReggieB

    ReggieB Inactive Alumni

    Joined:
    2004/05/12
    Messages:
    2,786
    Likes Received:
    2
    It is. Most routers designed for SME behave as DNS redirectors. So if you tell the router your DNS is at 192.168.0.11, it will redirect all DNS queries sent to the router, to that address. DHCP is then set so that the DNS address is the router's address.

    PC gets IP address from router including DNS at router IP.
    PC sends DNS request to router
    Router forwards DNS request to IP you set as DNS server.

    Your laptop server should be assigned with a static IP address if you want an easy life.
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.