Fork me on GitHub

Rat (Release Audit Tool) results

The following document contains the results of Rat (Release Audit Tool).

*****************************************************
Summary
-------
Generated at: 2017-03-11T23:43:52-05:00

Notes: 0
Binaries: 0
Archives: 0
Standards: 2

Apache Licensed: 0
Generated Documents: 0

JavaDocs are generated, thus a license header is optional.
Generated files do not require license headers.

2 Unknown Licenses

*****************************************************

Files with unapproved licenses:

  C:/projects/fgsms/fgsms-agents/fgsms-discovery-dns/pom.xml
  C:/projects/fgsms/fgsms-agents/fgsms-discovery-dns/src/main/java/org/miloss/fgsms/discovery/dns/DNSDiscovery.java

*****************************************************

*****************************************************
  Files with Apache License headers will be marked AL
  Binary files (which do not require any license headers) will be marked B
  Compressed archives will be marked A
  Notices, licenses etc. will be marked N
 !????? C:/projects/fgsms/fgsms-agents/fgsms-discovery-dns/pom.xml
 !????? C:/projects/fgsms/fgsms-agents/fgsms-discovery-dns/src/main/java/org/miloss/fgsms/discovery/dns/DNSDiscovery.java
 
*****************************************************

 Printing headers for text files without a valid license header...
 
=====================================================
== File: C:/projects/fgsms/fgsms-agents/fgsms-discovery-dns/pom.xml
=====================================================
<?xml version="1.0" encoding="UTF-8"?>
<!--
 This Source Code Form is subject to the terms of the Mozilla Public
 License, v. 2.0. If a copy of the MPL was not distributed with this
 file, You can obtain one at http://mozilla.org/MPL/2.0/.

 If it is not possible or desirable to put the notice in a particular
 file, then You may include the notice in a location (such as a LICENSE
 file in a relevant directory) where a recipient would be likely to look
 for such a notice.

 

 
 U.S. Government, Department of the Army
 Army Materiel Command
 Research Development Engineering Command
 Communications Electronics Research Development and Engineering Center

-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<parent>
		<groupId>org.mil-oss</groupId>
		<artifactId>fgsms-agents</artifactId>
		<version>7.0.0</version>
	</parent>
	<artifactId>fgsms-discovery-dns</artifactId>
	<packaging>bundle</packaging>
	<name>fgsms DNS Discovery</name>
	<description>Agetns can use a DNS TXT record to locate the fgsms server</description>
	<dependencies>

		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.mil-oss</groupId>
			<artifactId>fgsms-common</artifactId>
			<version>${project.parent.version}</version>
		</dependency>
		<dependency>
			<groupId>org.mil-oss</groupId>
			<artifactId>fgsms-common-interfaces</artifactId>
			<version>${project.parent.version}</version>
		</dependency>


=====================================================
== File: C:/projects/fgsms/fgsms-agents/fgsms-discovery-dns/src/main/java/org/miloss/fgsms/discovery/dns/DNSDiscovery.java
=====================================================
/**
 * This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
 *
 * If it is not possible or desirable to put the notice in a particular
 * file, then You may include the notice in a location (such as a LICENSE
 * file in a relevant directory) where a recipient would be likely to look
 * for such a notice.

 * 
 */
 
/*  ---------------------------------------------------------------------------
 *  U.S. Government, Department of the Army
 *  Army Materiel Command
 *  Research Development Engineering Command
 *  Communications Electronics Research Development and Engineering Center
 *  ---------------------------------------------------------------------------
 */
package org.miloss.fgsms.discovery.dns;

import java.util.ArrayList;
import java.util.List;
import java.util.Properties;
import org.miloss.fgsms.plugins.agents.IEndpointDiscovery;
import org.apache.log4j.Level;
import org.miloss.fgsms.common.Logger;;
import org.xbill.DNS.*;

/**
 *
 * @author AO
 */
public class DNSDiscovery implements IEndpointDiscovery {

    static final Logger log = Logger.getLogger("fgsms.DNSDiscovery");

    private static List<String> DnsProbeTXT(String value) {
        log.log(Level.INFO, "Discovering endpoints for " + value + " via DNS TXT record search");
        List<String> ret = new ArrayList<String>();
        try {
            Lookup up = null;
            Record[] run = null;
            up = new Lookup(value, Type.TXT);
            run = up.run();
            if (run != null) {
                for (int i = 0; i < run.length; i++) {

                    TXTRecord tr = (TXTRecord) run[i];