Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 834ca651 authored by Ken Chen's avatar Ken Chen Committed by android-build-merger
Browse files

Merge "Disable sensitive log in DnsProxyListener"

am: 6b6d44c64c

Change-Id: I5bb908a97f2dbb8fac345c925de36a518c25aae5
parents 11e517dc 594fc94a
Loading
Loading
Loading
Loading
+8 −8
Original line number Diff line number Diff line
@@ -426,14 +426,14 @@ bool synthesizeNat64PrefixWithARecord(const netdutils::IPPrefix& prefix, struct
        *ia6 = v6prefix->sin6_addr;
        ia6->s6_addr32[3] = iaOriginal.s_addr;

        if (WOULD_LOG(DEBUG)) {
        if (WOULD_LOG(VERBOSE)) {
            char buf[INET6_ADDRSTRLEN];  // big enough for either IPv4 or IPv6
            inet_ntop(AF_INET, &iaOriginal.s_addr, buf, sizeof(buf));
            LOG(DEBUG) << __func__ << ": DNS A record: " << buf;
            LOG(VERBOSE) << __func__ << ": DNS A record: " << buf;
            inet_ntop(AF_INET6, &v6prefix->sin6_addr, buf, sizeof(buf));
            LOG(DEBUG) << __func__ << ": NAT64 prefix: " << buf;
            LOG(VERBOSE) << __func__ << ": NAT64 prefix: " << buf;
            inet_ntop(AF_INET6, ia6, buf, sizeof(buf));
            LOG(DEBUG) << __func__ << ": DNS64 Synthesized AAAA record: " << buf;
            LOG(VERBOSE) << __func__ << ": DNS64 Synthesized AAAA record: " << buf;
        }
    }
    hp->h_addrtype = AF_INET6;
@@ -464,14 +464,14 @@ bool synthesizeNat64PrefixWithARecord(const netdutils::IPPrefix& prefix, addrinf
        ai->ai_addrlen = sizeof(struct sockaddr_in6);
        ai->ai_family = AF_INET6;

        if (WOULD_LOG(DEBUG)) {
        if (WOULD_LOG(VERBOSE)) {
            char buf[INET6_ADDRSTRLEN];  // big enough for either IPv4 or IPv6
            inet_ntop(AF_INET, &sinOriginal.sin_addr.s_addr, buf, sizeof(buf));
            LOG(DEBUG) << __func__ << ": DNS A record: " << buf;
            LOG(VERBOSE) << __func__ << ": DNS A record: " << buf;
            inet_ntop(AF_INET6, &v6prefix->sin6_addr, buf, sizeof(buf));
            LOG(DEBUG) << __func__ << ": NAT64 prefix: " << buf;
            LOG(VERBOSE) << __func__ << ": NAT64 prefix: " << buf;
            inet_ntop(AF_INET6, &sin6->sin6_addr, buf, sizeof(buf));
            LOG(DEBUG) << __func__ << ": DNS64 Synthesized AAAA record: " << buf;
            LOG(VERBOSE) << __func__ << ": DNS64 Synthesized AAAA record: " << buf;
        }
    }
    logDnsQueryResult(result);