removed methods that exists in IDnsApplication.

This commit is contained in:
Shreyas Zare
2021-09-26 17:01:27 +05:30
parent 02238de5e7
commit 32cabfdbb1
4 changed files with 4 additions and 55 deletions

View File

@@ -17,7 +17,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
using System;
using System.Net;
using System.Threading.Tasks;
using TechnitiumLibrary.Net.Dns;
@@ -27,15 +26,8 @@ namespace DnsServerCore.ApplicationCommon
/// <summary>
/// Allows a DNS App to handle incoming DNS requests for configured APP records in the DNS server zones.
/// </summary>
public interface IDnsAppRecordRequestHandler : IDisposable
public interface IDnsAppRecordRequestHandler
{
/// <summary>
/// Allows initializing the DNS application with a config. This function is also called when the config is updated to allow reloading.
/// </summary>
/// <param name="dnsServer">The DNS server interface object that allows access to DNS server properties.</param>
/// <param name="config">The DNS application config stored in the <c>dnsApp.config</c> file.</param>
Task InitializeAsync(IDnsServer dnsServer, string config);
/// <summary>
/// Allows a DNS App to respond to the incoming DNS requests for an APP record in a primary or secondary zone.
/// </summary>
@@ -49,11 +41,6 @@ namespace DnsServerCore.ApplicationCommon
/// <returns>The DNS response for the DNS request or <c>null</c> to send no answer response with an SOA authority.</returns>
Task<DnsDatagram> ProcessRequestAsync(DnsDatagram request, IPEndPoint remoteEP, DnsTransportProtocol protocol, bool isRecursionAllowed, string zoneName, uint appRecordTtl, string appRecordData);
/// <summary>
/// The description about this app to be shown in the Apps section of the DNS web console.
/// </summary>
string Description { get; }
/// <summary>
/// A template of the record data format that is required by this app. This template is populated in the UI to allow the user to edit in the expected values. The format could be JSON or any other custom text based format which the app is programmed to parse. This property is optional and can return <c>null</c> if no APP record data is required by the app.
/// </summary>

View File

@@ -17,7 +17,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
using System;
using System.Net;
using System.Threading.Tasks;
using TechnitiumLibrary.Net.Dns;
@@ -27,15 +26,8 @@ namespace DnsServerCore.ApplicationCommon
/// <summary>
/// Lets a DNS App to handle incoming requests for the DNS server's authoritative zone allowing it to act as an authoritative zone by itself and respond to any requests.
/// </summary>
public interface IDnsAuthoritativeRequestHandler : IDisposable
public interface IDnsAuthoritativeRequestHandler
{
/// <summary>
/// Allows initializing the DNS application with a config. This function is also called when the config is updated to allow reloading.
/// </summary>
/// <param name="dnsServer">The DNS server interface object that allows access to DNS server properties.</param>
/// <param name="config">The DNS application config stored in the <c>dnsApp.config</c> file.</param>
Task InitializeAsync(IDnsServer dnsServer, string config);
/// <summary>
/// Allows a DNS App to respond to an incoming DNS request for the DNS server's authoritative zone. This method is called by the DNS Server's authoritative zone before querying its built in zone database. Response returned may be further processed to resolve CNAME or ANAME records, or referral response.
/// </summary>
@@ -45,10 +37,5 @@ namespace DnsServerCore.ApplicationCommon
/// <param name="isRecursionAllowed">Tells if the DNS server is configured to allow recursion for the client making this request.</param>
/// <returns>The DNS response for the DNS request or <c>null</c> to let the DNS server core process the request as usual.</returns>
Task<DnsDatagram> ProcessRequestAsync(DnsDatagram request, IPEndPoint remoteEP, DnsTransportProtocol protocol, bool isRecursionAllowed);
/// <summary>
/// The description about this app to be shown in the Apps section of the DNS web console.
/// </summary>
string Description { get; }
}
}

View File

@@ -36,15 +36,8 @@ namespace DnsServerCore.ApplicationCommon
/// <summary>
/// Allows a DNS App to log incoming DNS requests and their corresponding responses.
/// </summary>
public interface IDnsLogger : IDisposable
public interface IDnsQueryLogger
{
/// <summary>
/// Allows initializing the DNS application with a config. This function is also called when the config is updated to allow reloading.
/// </summary>
/// <param name="dnsServer">The DNS server interface object that allows access to DNS server properties.</param>
/// <param name="config">The DNS application config stored in the <c>dnsApp.config</c> file.</param>
Task InitializeAsync(IDnsServer dnsServer, string config);
/// <summary>
/// Allows a DNS App to log incoming DNS requests and responses. This method is called by the DNS Server after an incoming request is processed and a response is sent.
/// </summary>
@@ -71,11 +64,6 @@ namespace DnsServerCore.ApplicationCommon
/// <param name="qclass">Optional parameter to filter records by the request QCLASS.</param>
/// <returns>The <code>DnsLogPage</code> object that contains all the entries in the requested page number.</returns>
Task<DnsLogPage> QueryLogsAsync(long pageNumber, int entriesPerPage, bool descendingOrder, DateTime? start, DateTime? end, IPAddress clientIpAddress, DnsTransportProtocol? protocol, DnsServerResponseType? responseType, DnsResponseCode? rcode, string qname, DnsResourceRecordType? qtype, DnsClass? qclass);
/// <summary>
/// The description about this app to be shown in the Apps section of the DNS web console.
/// </summary>
string Description { get; }
}
public class DnsLogPage

View File

@@ -17,7 +17,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
using System;
using System.Net;
using System.Threading.Tasks;
using TechnitiumLibrary.Net.Dns;
@@ -45,15 +44,8 @@ namespace DnsServerCore.ApplicationCommon
/// <summary>
/// Allows a DNS App to inspect and optionally block incoming DNS requests before they are processed by the DNS Server core.
/// </summary>
public interface IDnsRequestController : IDisposable
public interface IDnsRequestController
{
/// <summary>
/// Allows initializing the DNS application with a config. This function is also called when the config is updated to allow reloading.
/// </summary>
/// <param name="dnsServer">The DNS server interface object that allows access to DNS server properties.</param>
/// <param name="config">The DNS application config stored in the <c>dnsApp.config</c> file.</param>
Task InitializeAsync(IDnsServer dnsServer, string config);
/// <summary>
/// Allows a DNS App to inspect an incoming DNS request and decide whether to allow or block it. This method is called by the DNS Server before an incoming request is processed.
/// </summary>
@@ -62,10 +54,5 @@ namespace DnsServerCore.ApplicationCommon
/// <param name="protocol">The protocol using which the request was received.</param>
/// <returns>The action that must be taken by the DNS server i.e. if the request must be allowed or dropped.</returns>
Task<DnsRequestControllerAction> GetRequestActionAsync(DnsDatagram request, IPEndPoint remoteEP, DnsTransportProtocol protocol);
/// <summary>
/// The description about this app to be shown in the Apps section of the DNS web console.
/// </summary>
string Description { get; }
}
}