Movim doesn't resolve hosts by SRV record

Bug #1462999 reported by fr34kyn01535
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Movim
Confirmed
High
Unassigned

Bug Description

Movim does only resolve the domain A record to an IP using Googles DNS 8.8.8.8.

Movim should:
    Check the SRV records from the specifications to find the servers IP and Port (See http://wiki.xmpp.org/web/SRV_Records)
    Use the local host file to determin if the IP is overidden there (https://github.com/reactphp/dns/issues/10)
    Not use the Google DNS, atleast not hardcoded

Revision history for this message
fr34kyn01535 (fr34kyn01535) wrote :

Technical aspect:

The following code resolves the ip & creates the connection:

$dnsResolverFactory = new React\Dns\Resolver\Factory();
$dns = $dnsResolverFactory->createCached('8.8.8.8', $loop);
$connector = new React\SocketClient\Connector($loop, $dns);

...

  $connector->create($domain, 5222)->then($xmpp_behaviour);

While React DNS is able to lookup SRV records (https://github.com/reactphp/dns/blob/master/src/Resolver/Resolver.php),
socket-client uses only the A record (https://github.com/reactphp/socket-client/blob/master/src/Connector.php)

Revision history for this message
fr34kyn01535 (fr34kyn01535) wrote :

Quick and dirty solution, overriding the resolvers result before line 55 in linker.php with
if($domain == "bam.yt") $domain = "127.0.0.1";

It looks like React DNS does NOT support resolving SRV records, since i don't want to craft another class to do it, and i don't feel like extending React to this specification (:P) - this feature can probably not be implemented in the near future..

Revision history for this message
edhelas (edhelas) wrote :

This issue is serious but related to the reactphp/dns issue https://github.com/reactphp/dns/issues/10

Changed in movim:
status: New → Confirmed
importance: Undecided → High
milestone: none → 0.9
summary: - Movim doesn't resolve hosts to SRV record
+ Movim doesn't resolve hosts by SRV record
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.