44 questions
3
votes
1
answer
248
views
Implementing a local VpnService that allows whitelisted traffic won't load any websites
Let me preface this by saying that I'm definitely out of my depth here in terms of knowledge. I'm trying to implement a VpnService that users of my app can enable in order for any traffic not going ...
0
votes
2
answers
162
views
Using a custom DNS resolver not resolving for Type.ANY
When I try to use a custom DNS server (either a single server using SimpleResolver or multiple servers using ExtendedResolver) and want to do a lookup for ANY records relating to a domain, I am ...
0
votes
1
answer
138
views
dnsjava - How are DNS query retries controlled using Simple Resolver in DNSJava?
How are DNS query retries controlled using Simple Resolver in DNSJava? Using the same resolver, we see retries of 2 and in some cases 3. It is not clear as to how it is retried. Any help in this ...
0
votes
2
answers
77
views
Why does dnsjava requires slf4j and logback?
So I'm (trying) developing a kotlin console application, where the user can sign up with an email, and in order to validate this email I use dnsjava library, but that requires me to use the slf4j and ...
0
votes
1
answer
399
views
DNSJava 2.1.8 as dependency invalidates JPMS (Java 9 Platform Module System) compatibility
There is a maven artifact called xxx:
Having this vanilla pom:
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
...
0
votes
0
answers
853
views
How to retrieve the host name by IP with dnsjava library?
I'm trying to retrieve the host name (or domain) of an IP address with dnsjava library by using a SimpleResolver and the ReverseMap and I wrote the following code:
import java.net.InetAddress;
import ...
0
votes
0
answers
98
views
How do I convert the IP to domain name (not hostname) in java?
How do I convert the IP to domain name (not hostname) in java?
C:\WINDOWS\system32>ping google.com
Pinging google.com [142.251.42.78] with 32 bytes of data:
public static void main(String[] args) {
...
0
votes
1
answer
2k
views
How to read TXT Records longer than 255 characters in correct order
I am using DNSJava lib to fetch DKIM TXT records for a given selector + domain name. I want to ensure I read the record in the correct order when the record size is greater than 255 characters and ...
1
vote
1
answer
324
views
com.android.builder.dexing.DexArchiveBuilderException: Failed to process D:....\app\build\intermediates\transforms\desugar\debug\13.jar
I am working with an app in Android Studio. I need to use Java version 8 so I can use one library(dnsjava: https://github.com/dnsjava/dnsjava ).
When I try to use java version 8 writing this in my ...
0
votes
1
answer
325
views
Resolve mx records for a domain using dnsjava in kubernetes/ docker
I'm trying to resolve mx records in a kubernetes pod.
The dnsjava library works when tested on mac and ubuntu outside of a container but returns an empty array once deployed.
What needs to be ...
2
votes
2
answers
2k
views
Android dnsjava NoClassDefFoundError: Failed resolution of: Ljava/time/Duration;
I'm getting a NoClassDefFoundError with my app. I'm using dnsjava, okhttp3 and retrofit. My min API is 19.
I read that the java.time package was added in API 26. Does this mean that I can't use ...
0
votes
3
answers
748
views
DNSJava in Kubernetes
Dnsjava is an implementation of DNS in Java.
We have built some of our application logic around it..
Just wanted to check if Kubernetes would support DNS interfaces at application level
0
votes
1
answer
4k
views
Using dnsjava to query using java?
I am trying to query using the google public dns server (8.8.8.8) to get the IP address of some known URL. However, it seems like I am not able to get that using the following code? I am using the ...
0
votes
1
answer
933
views
dnsjava library return "no records found"
I'm using dnsjava in my android project "android studio" I have imported the library. But when I run the code I'm getting "no records found" does anyone face this? I found a post here that talks about ...
0
votes
1
answer
174
views
DNS Java no text format defined for TSIG
I am using the Master class in the DNS Java library to parse bind zone files. However, when I try to parse the .BIZ zone file from Neustar, I get this error:
org.xbill.DNS.Tokenizer$...
1
vote
1
answer
511
views
dnsjava returns network error on lookup.run()
I'm using dnsjava in my android app to retrieve a txt file on the first time the app starts up.
val lookup = Lookup(domain, Type.TXT)
lookup.setResolver(SimpleResolver())
val records = lookup.run()...
0
votes
1
answer
553
views
Parsing Verisign COM Zone File with DNSJava
I'm attempting to read the Verisign COM master zone file using the Master parser in DNSJava.
Here is an example input:
; The use of the Data contained in Verisign Inc.'s aggregated
; .com, and .net ...
2
votes
0
answers
1k
views
How to query authoritative dns server in java to get txt records instantly
I am trying to validate txt records in the dns in order to verify if a domain is owned by an entity. To do this I will ask the domain owner to add a txt record I provide. After they make the change I ...
0
votes
1
answer
953
views
How to disable recursive query of DNS java?
I'm doing query using dnsjava, and program did query 2 times, the first query is necessary and return desired result (this result only see if I capture UDP package, not in result of my program), and ...
0
votes
1
answer
1k
views
Use dnsjava to get hostname from ip address from 192.168.1.1 to 192.168.1.254
I am trying to use dnsjava in an android app to find hostnames of devices in my local wifi network.
Below is the code used:
try
{
String ipAddress = "33.1.168.192";
String dnsblDomain = "in-addr.arpa"...
0
votes
1
answer
707
views
Zone file format issue, dnsjava parser crashing - BIND 9
I am making an application that uses a parser to parse all the master zones from the DNS, the parser I am using is from dnsjava library (org.xbill.DNS.Master). All the zones I am parsing are already ...
0
votes
1
answer
393
views
Storing key-value pairs in DNS request
What is the recommended place for storing key-value pairs in a DNS request?
I'm designing a system where the DNS requests traverse multiple hops. Some hops may need to append key-value pairs to the ...
1
vote
0
answers
88
views
MapReduce Job is hung at map=12%,how could I go through it?
I wrote a HiveQL script like:
create temporary function getdomainips as 'com.is.mail.domainspf.IpFromDomainExtract';
select Domain,getdomainips(Domain) as ips from tmp_domain;
And IpFromDomainExtract ...
0
votes
2
answers
2k
views
Choose root DNS server to use
I want to choose what DNS server to use. I will make potentially multiple choices in the same JVM. I want to resolve IP addresses from hostnames.
Things I have considered:
Using System.setProperty to ...
3
votes
0
answers
439
views
dnsjava - Create new Record
I am assigned a task to update the zone files. And I found dnsjava.
However, when using it to add a new Record, I am successfully creating new records using the classes NSRecord, ARecord. But since ...
1
vote
1
answer
1k
views
Using dnsjava to resolve a given IP to its Hostnames
I want to get a list of all registered Domains for a given IP Address .
Could I use PTR records. I tried the following
ip = "217.13.68.220";
l = new Lookup(ip, Type.PTR );
l.setResolver(new ...
0
votes
1
answer
1k
views
Retrieving DNS SRV records on Android using service name
On android I want to find list of records just by using service name. I have tried api's like dnsjava and jmdns but all returned empty results. I have come across this similar Question but no one has ...
1
vote
1
answer
3k
views
How to put in an entry into dnsjava cache to override DNS lookup
In trying to avoid having a hostname looked up from the public DNS for testing purposes, I need to essentially set /etc/hosts file, but I don't always know what hostnames I'll need to override the IP ...
2
votes
3
answers
3k
views
dnsjava - How to do a Lookup with DNSSEC validation?
dnsjava has DNSSEC support. I'd like to do a simple Lookup, just like the Lookup examples ( http://www.xbill.org/dnsjava/dnsjava-current/examples.html ), but have dnsjava tell me if it validates ...
-1
votes
1
answer
586
views
Querying DNS spam service doesn't work properly with DNSJava
I'm developing a function that queries a list of DNS servers using DNSJava library to check if a specific domain is blacklisted. Here you have the portion of code that make the check. At the end you ...
2
votes
1
answer
1k
views
Why does dnsjava not retrieve all records?
I'm using the following code (dnsjava) to retrieve records from dns.
Record[] records1 = null;
Lookup look;
try {
look = new Lookup(domainName,Type.A);
try {
look.setResolver(new ...
0
votes
1
answer
919
views
How do I update a PTR record on a DDNS server, with dnsjava?
I am able to update A, AAAA, and TXT records without an issue. Unfortunately, I haven't yet been able to find any examples of how to update a PTR record.
Here's the code I'm using to send the ...
0
votes
2
answers
2k
views
dnsjava and Android
I have an Android app to which I am trying to add DNS SRV record detection. I know it is possible, based on the existence of apps such as DNS Lookup, which I have installed, and it works just fine.
...
1
vote
1
answer
4k
views
Not getting DNS record using org.xbill.DNS lib
I have written following code to get MX record for any Domain, here google.com
public class DNSRec {
public static void main(String... args)
{
try{
Record [] records = new Lookup("http://...
2
votes
1
answer
2k
views
DNS automation in a private cloud using DNSJava
I am trying to create a DNS service (automation of various DNS operations) to serve our existing private cloud. I am looking for options and ideas to do this. Is there any existing Java API to do this?...
2
votes
1
answer
2k
views
Find nameservers of a domain
How can I find the nameservers of a domain name like google.com using Java?
I m using "dnsjava" library to find out the host details, MX records, bind version and zone transfer. But I m unable to ...
0
votes
1
answer
3k
views
dnsjava can't resolve "localhost" on Linux machine
After I registered dnsjava as default Java DNS provider I get a problem. It can't resolve local addresses which described in /etc/hosts file on my Linux machine. This file look something like this:
...
0
votes
2
answers
2k
views
How to get multiple domains for the single IP?
Here's the method-
public static String getHostByAddr(byte[] addr) throws UnknownHostException {
Name name = ReverseMap.fromAddress(InetAddress.getByAddress(addr));
final String[] servers = ...
6
votes
1
answer
2k
views
Proguard to obfuscate Android code with DNSJava library
I have an android app which has dnsjava.jar in the /libs/ directory of the project. Everything built fine and can be packaged into APK (without proguard).
However, when i introduced proguard into the ...
1
vote
1
answer
3k
views
Possible to programmatically resolve specific ip address to load balanced domain name?
Our environment is setup with multiple apache httpd's that serve as reverse proxies to a various backend java servers (mostly tomcat servers).
We'd like to write a script to hit each individual ip ...
0
votes
1
answer
3k
views
Asking DNS server for record and checking authoritative
How can I ask DNS server e.g 8.8.8.8 for google.com domain? On this http://www.xbill.org/dnsjava/dnsjava-current/examples.html page is example how can you send request for specified domain, but how ...
2
votes
0
answers
3k
views
add/delete dns entries in a bind dns server zones using dnsjava
I searched a lot but I didn't find a clear answer. My goal is to make java methods that can add and delete dns entries from a dns server. I installed and configured bind9 dns server on a debian VM. I'...
1
vote
3
answers
2k
views
java.lang.NoClassDefFoundError thrown for static method but not for static member
Working with the dnsjava library, I've encountered a frustrating and confusing problem where I can call Type.A properly but calling Type.value(str) throws a java.lang.NoClassDefFoundError.
System....
7
votes
1
answer
14k
views
How to change the java DNS service provider
I'm building a fast web crawler and I need to have multithreaded DNS resolution, so I picked up a multithreaded DNS service provider called dnsjava. Unfortunately, I can't figure out how to replace ...