Skip to content

Commit 6cc113a

Browse files
committed
Moved binary, commands, HTTP proxy client to https://github.com/noglitchyo/dealdoh-client repository
1 parent af616c6 commit 6cc113a

17 files changed

+30
-792
lines changed

.gitignore

-1
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,3 @@ vendor
66
coverage
77
clover.xml
88
.phpunit*
9-
upstreampool.json

bin/dealdoh

-57
This file was deleted.

composer.json

+1-6
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,7 @@
2424
"php": "^7.3",
2525
"psr/http-client": "*",
2626
"psr/log": "^1.1",
27-
"php-http/guzzle6-adapter": "^2.0",
28-
"react/dns": "^0.4.17",
29-
"symfony/console": "^4.3"
27+
"react/dns": "^0.4.17"
3028
},
3129
"require-dev": {
3230
"phpunit/phpunit": "^8.1",
@@ -45,9 +43,6 @@
4543
"NoGlitchYo\\Dealdoh\\Tests\\": "tests/"
4644
}
4745
},
48-
"bin": [
49-
"bin/dealdoh"
50-
],
5146
"scripts": {
5247
"phpstan": "phpstan analyse -l max src",
5348
"phpcs": "phpcs --standard=PSR2 ./src/",

config/.gitkeep

Whitespace-only changes.

config/upstreampool.json

-3
This file was deleted.

config/upstreampool.json.dist

-5
This file was deleted.

dealdoh

-58
This file was deleted.

src/Client/DohClient.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,16 @@
22

33
namespace NoGlitchYo\Dealdoh\Client;
44

5-
use GuzzleHttp\Psr7\Request;
65
use NoGlitchYo\Dealdoh\Entity\Dns\MessageInterface;
76
use NoGlitchYo\Dealdoh\Entity\DnsUpstream;
87
use NoGlitchYo\Dealdoh\Exception\DnsClientException;
98
use NoGlitchYo\Dealdoh\Factory\Dns\MessageFactoryInterface;
9+
use Nyholm\Psr7\Request;
1010
use Psr\Http\Client\ClientInterface;
1111
use Throwable;
1212

1313
/**
14-
* DoH client following RFC-8484
14+
* DoH client making DNS query as described in RFC-8484
1515
*/
1616
class DohClient implements DnsClientInterface
1717
{

src/Command/AddUpstreamCommand.php

-78
This file was deleted.

src/Command/ResolveCommand.php

-113
This file was deleted.

src/Entity/DnsUpstreamPool.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@
77
/**
88
* @codeCoverageIgnore
99
*/
10-
class DnsUpstreamPool implements JsonSerializable
10+
class DnsUpstreamPool implements DnsUpstreamPoolInterface, JsonSerializable
1111
{
1212
/**
13-
* @var array
13+
* @var DnsUpstream[]
1414
*/
1515
private $dnsUpstreams = [];
1616

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?php declare(strict_types=1);
2+
3+
namespace NoGlitchYo\Dealdoh\Entity;
4+
5+
/**
6+
* @codeCoverageIgnore
7+
*/
8+
interface DnsUpstreamPoolInterface
9+
{
10+
public function addUpstream(DnsUpstream $dnsUpstream): self;
11+
12+
/**
13+
* @return DnsUpstream[]
14+
*/
15+
public function getUpstreams(): array;
16+
}

0 commit comments

Comments
 (0)