Sponsored Content
Full Discussion: Tweaking the DNS response
Special Forums IP Networking Tweaking the DNS response Post 302847063 by rstnsrr on Monday 26th of August 2013 07:56:28 AM
Old 08-26-2013
Tweaking the DNS response

Hi All,

The following is the scenario.

I open the browser and request a web page. The DNS query is sent to the DNS server of my company and replies my GNU/Linux machine with a DNS response. I have "insmod"ed a kernel module that picks up the DNS response and over rides the "Addr" field of the "Answers" Section of the DNS response packet with a different IP address. However, after overriding the "Addr" field, my machine sends a ICMP(Host unreachable, administratively probihited) msg to the DNS server.
Can some one throw light on what is happening.


I am using netfilter frame work in my module and tweaking the DNS response in the NF_INET_PRE_ROUTING hook.

I m attaching the wireshark pcap.
192.168.180.29 - IP of my machine.
192.168.164.12 - DNS server IP.


Thank You.
roy
 

9 More Discussions You Might Find Interesting

1. IP Networking

Apache mod_proxy +DNS slow response problem

My company has a private network, including a Apache web server (Linux) and some WinXP machines. The web server had been configured to use mod_proxy to connect to window update site via another company proxy server. It works for few years. Recently, some parties had setup a DNS server on the... (2 Replies)
Discussion started by: donaldfung
2 Replies

2. Shell Programming and Scripting

New help tweaking awk...

Guys, My awk is not very good and I'm kind of stuck. I have a file like so: 1,a,a,ab1234,ab1234,e,f 2,a,b,cd1234,ef5678,e,f 3,a,a,cd3456,gh5678,g,h 4,a,b,ef5678,ef1234,g,h 5,a,a,cd7890,ab5678,e,f 6.a,b,cd7890,jk1234,il I don't care about any other columns other than col4 and col5. ... (6 Replies)
Discussion started by: giannicello
6 Replies

3. Shell Programming and Scripting

Question on tweaking the PATH variable to allow the world to run my executable script

All, I am pretty new to Unix and still in the learning curve :) I have a simple requirement for which I did not get an answer yet (Atleast I do not know how to keyword the search for my requirement!!!). I have an executable script my.script1 in a folder /data/misc/scripts/dev, which when... (5 Replies)
Discussion started by: bharath.gct
5 Replies

4. UNIX for Dummies Questions & Answers

Changing email header information by tweaking sendmail

How can i tweak sendmail configuration files so that the "Received:" field is removed from email header information? Or else can i change Received: (from enswitch@localhost) in email header to something likeReceived: (from xyz@localhost)? ---------- Post updated at 09:57 PM ---------- Previous... (2 Replies)
Discussion started by: proactiveaditya
2 Replies

5. IP Networking

Network Tweaking - Database Query Across Internet

Hi We run a script that queries a database via the internet and we need the fast possible connections to the database server. I have centos server which sends the requests to the database across the internet . it sends upto 800 queries per milliseconds however this using the default... (4 Replies)
Discussion started by: um08
4 Replies

6. Red Hat

DHCP & DNS - Clients get IP but don't register in DNS

I am trying to setup a CentOS 6.2 server that will be doing 3 things DHCP, DNS & Samba for a very small office (2 users). The idea being this will replace a very old Win2k server. The users are all windows based clients so only the server will be Linux based. I've installed CentOS 6.2 with... (4 Replies)
Discussion started by: FireBIade
4 Replies

7. Shell Programming and Scripting

Tweaking the output of diff

hello everyone, I am trying to compare two files and have the result in a new files. When I used diff I am getting the header, '<' and '>' in my result which I don't want to have it in my output file. :wall: opt/sam/input: diff file1.txt file2.txt 1,20d0 < 16,ZA, < ZJ,08, < Z7,03, Any... (1 Reply)
Discussion started by: siteregsam
1 Replies

8. Shell Programming and Scripting

Perl: Regular expression tweaking?

Hello! I'm trying to tweak my regular expression to take care of this tedious little "blank space" problem. I don't know what's causing the " : 2 times, lines 1, 5," to be printed. Here is what the input looks like: http://i48.tinypic.com/34g0tv8.png Here's what the output is... (6 Replies)
Discussion started by: D2K
6 Replies

9. Linux

DNS Response Issue

Hi, I have a Windows based Domain (abc.com)servers like: 172.30.1.246 172.30.1.247 172.30.3.246 172.30.3.247 On all my Linux servers (/etc/resolv.conf) have a following DNS servers entries: nameserver 172.30.3.246 nameserver 172.30.3.247 But when i ping my Domain (abc.com), it... (5 Replies)
Discussion started by: refra
5 Replies
Net::DNS::Mailbox(3)					User Contributed Perl Documentation				      Net::DNS::Mailbox(3)

NAME
Net::DNS::Mailbox - DNS mailbox representation SYNOPSIS
use Net::DNS::Mailbox; $mailbox = new Net::DNS::Mailbox('user@example.com'); $address = $mailbox->address; DESCRIPTION
The Net::DNS::Mailbox module implements a subclass of DNS domain name objects representing the DNS coded form of RFC822 mailbox address. METHODS
new $mailbox = new Net::DNS::Mailbox('John.Doe@example.com'); $mailbox = new Net::DNS::Mailbox('John Doe <j.doe@example.com>'); Creates a mailbox object which represents the DNS domain encoded form of the mail address specified by the character string argument. The argument string consists of printable characters from the 7-bit ASCII repertoire. address $address = $mailbox->address; Returns a character string containing the RFC822 mailbox address corresponding to the encoded domain name representation described in RFC1035 section 8. DOMAIN NAME COMPRESSION AND CANONICALISATION
The Net::DNS::Mailbox1035 and Net::DNS::Mailbox2535 subclass packages implement RFC1035 domain name compression and RFC2535 canonicalisation. COPYRIGHT
Copyright (c)2009,2012 Dick Franks. All rights reserved. This program is free software; you may redistribute it and/or modify it under the same terms as Perl itself. SEE ALSO
perl, Net::DNS, Net::DNS::DomainName, RFC822, RFC1035, RFC5322 perl v5.16.3 2012-12-28 Net::DNS::Mailbox(3)
All times are GMT -4. The time now is 02:55 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy