Skip to content

[Dod:S only?] sb_debug_connection.php - not returning host name in UDP check #1502

Description

@DNA-styx

What are the steps to reproduce this issue?

  1. Use current 2.0.0 rc7 sb_debug_connection.php to check a Day of Defeat Source dedicated server

What happens?

host name not returned in UDP check

Image

What were you expecting to happen?

With blow code change, host name is returned

Image

Any logs, error output, etc.?

Any other comments?

only seems needed with DoD:S server,, TF2 servers return their hostname without the second step.

           if (strlen($packet) >= 9 && $packet[4] === "\x41") {
                $challenge = substr($packet, 5, 4);
                echo '<div class="log-line info">[+] Challenge received. Sending follow-up request...</div>';

                $query2 = "\xFF\xFF\xFF\xFF\x54Source Engine Query\0" . $challenge;
                $written2 = @fwrite($sock, $query2);

                if ($written2 === false) {
                    $errors[] = "udp_write_failed";
                    $error = error_get_last();
                    echo '<div class="log-line error">[-] Write error on challenge response: ' . $error['message'] . '</div>';
                } else {
                    $packet = fread($sock, 1480);
                }
            }

What versions of software are you using?

Operating System:
SourceBans++ Version:
PHP Version:
MySQL Version:
Link to your project:
Link to a phpinfo() output:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions