Files
duplicati/Duplicati/WebserverCore/Abstractions/IHostnameValidator.cs
T
Kenneth Skovhede 2b55b3449d Add custom hostname validation
This adds a manually implemented hostname check that is applied as an endpoint filter.
With the implemented filter, the validation rules are similar to those before Kestrel was introduced.
This fixes #5469
2024-08-19 14:07:48 +02:00

15 lines
403 B
C#

namespace Duplicati.WebserverCore.Abstractions;
/// <summary>
/// Interface for hostname validation
/// </summary>
public interface IHostnameValidator
{
/// <summary>
/// Validates a hostname
/// </summary>
/// <param name="hostname">The hostname to validate</param>
/// <returns>True if the hostname is valid, false otherwise</returns>
bool IsValidHostname(string hostname);
}