{"id":572,"date":"2016-05-01T23:08:42","date_gmt":"2016-05-01T23:08:42","guid":{"rendered":"https:\/\/www.homehost.com.br\/blog\/?p=572"},"modified":"2026-11-12T20:40:21","modified_gmt":"2026-11-12T23:40:21","slug":"como-configurar-spf-e-dkim-no-cpanel","status":"publish","type":"post","link":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/","title":{"rendered":"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">O <a href=\"https:\/\/www.homehost.com.br\/blog\/cpanel\/o-que-e-cpanel\/\">cPanel<\/a> possui, por padr\u00e3o, a configura\u00e7\u00e3o de SPF e DKIM para todas as zonas de DNS. Estes s\u00e3o mecanismos de verifica\u00e7\u00e3o que ajuda a combater spam. Tento o SPF configurado corretamente em seu servidor, ir\u00e1 aumentar consideravelmente a entrega de <a href=\"https:\/\/www.homehost.com.br\/hospedagem-de-e-mails\/\">emails<\/a>, e evitar que eles caiam em caixa de <a href=\"https:\/\/www.homehost.com.br\/blog\/contas-de-email\/spam\/\">spam<\/a> (lixo eletr\u00f4nico).<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>SPF<\/strong> significa Sender Policy Framework, ou seja, Sistema de controle de remetentes. <strong>DKIM<\/strong> significa <a href=\"https:\/\/www.homehost.com.br\/blog\/tutoriais\/como-instalar-domain-keys-no-cpanel\/\">Domain Keys<\/a>, ou seja, Chaves do dom\u00ednio. Antes de configurar, se quiser entender o que cada protocolo faz e por que importam, veja nosso artigo sobre <a href=\"https:\/\/www.homehost.com.br\/blog\/contas-de-email\/spf-dkim-dmarc\/\">o que s\u00e3o SPF, DKIM e DMARC<\/a>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Verificador de SPF, DKIM e DMARC<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Como o cPanel costuma criar o SPF e o DKIM por padr\u00e3o, comece conferindo se os registros j\u00e1 est\u00e3o publicados no seu dom\u00ednio. Se o verificador mostrar que falta algum, siga o passo a passo abaixo e depois volte aqui para confirmar.<\/p>\n\n\n\n<div class=\"hh-spf\" id=\"hh-spf\" style=\"max-width:780px;margin:28px auto;border:1px solid #c9d2dd;border-radius:14px;padding:22px 24px;background:#f4f6f9;font-family:Arial,Helvetica,sans-serif;color:#0F172A;font-size:15px;box-sizing:border-box;\"><\/div>\n<script>(function () { var Q = String.fromCharCode(34); var BS = String.fromCharCode(92); var AMP = String.fromCharCode(38); var TAB = String.fromCharCode(9); var ELL = String.fromCharCode(8230); var DOT = String.fromCharCode(183); var S2 = \"\/\" + \"\/\"; var PFX = \"hh-spf-\"; var root0 = document.getElementById(\"hh-spf\"); if (!root0) { return; } function U(n) { return String.fromCharCode(n); } var GURL = \"https:\" + S2 + \"dns.google\/resolve?name=\"; var CURL = \"https:\" + S2 + \"cloudflare-dns.com\/dns-query?name=\"; var DMARCGEN = \"https:\" + S2 + \"www.homehost.com.br\/blog\/contas-de-email\/spf-dkim-dmarc\/\"; var SEL = [\"default\", \"google\", \"selector1\", \"selector2\", \"x\", \"k1\", \"k2\", \"k3\", \"s1\", \"s2\", \"mandrill\", \"dkim\", \"mail\", \"smtp\", \"mx\", \"fm1\", \"fm2\", \"fm3\", \"protonmail\", \"protonmail2\", \"protonmail3\", \"sig1\", \"zoho\", \"zmail\"]; var B64 = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+\/=\"; var HOST = \"abcdefghijklmnopqrstuvwxyz0123456789-_\"; var COL = {ok: [\"#15803d\", \"#e8f5ec\", String.fromCharCode(10004)], warn: [\"#b45309\", \"#fff4e5\", String.fromCharCode(9888)], err: [\"#b42318\", \"#fdecec\", String.fromCharCode(10006)], info: [\"#1d4ed8\", \"#eef3ff\", String.fromCharCode(8505)]}; var MONO = \"font-family:Consolas,Menlo,monospace;font-size:13px;overflow-wrap:anywhere;background:#ffffff;border:1px solid #d5dce5;border-radius:6px;padding:8px 10px;margin:6px 0;color:#0F172A;\"; var useCF = false; var cache = {}; var ctx = null; var busy = false; var QMAX = 150; function el(id) { return document.getElementById(PFX + id); } function add(p, tag, text, style) { var n = document.createElement(tag); if (text) { n.textContent = text; } if (style) { n.setAttribute(\"style\", style); } p.appendChild(n); return n; } function gt(a, b) { return a === b ? false : Math.max(a, b) === a; } function lt(a, b) { return a === b ? false : Math.min(a, b) === a; } function ge(a, b) { return Math.max(a, b) === a; } function or(a, b) { return a ? a : b; } function has(s, x) { return String(s).indexOf(x) !== -1; } function digits(s) { if (s.length === 0) { return false; } for (var i = 0; i !== s.length; i++) { if (!has(\"0123456789\", s.charAt(i))) { return false; } } return true; } function say(arr, l, t, href, lt2) { arr.push({l: l, t: t, h: or(href, \"\"), lt: or(lt2, \"\")}); } function noDot(s) { s = String(s); while (s.charAt(s.length - 1) === \".\") { s = s.slice(0, -1); } return s; } function plural(n, one, many) { return n === 1 ? one : many; } function fetchJson(url, cf) { var ctl = window.AbortController ? new AbortController() : null; var opt = {credentials: \"omit\"}; if (cf) { opt.headers = {\"accept\": \"application\/dns-json\"}; } if (ctl) { opt.signal = ctl.signal; } var timer = setTimeout(function () { if (ctl) { ctl.abort(); } }, 8000); return fetch(url, opt).then(function (r) { clearTimeout(timer); return r.json(); }, function (e) { clearTimeout(timer); throw e; }); } async function dns(name, type) { var key = name + \"|\" + type; if (cache[key]) { return cache[key]; } if (ctx) { ctx.q++; } var res = null; try { var j = await fetchJson((useCF ? CURL : GURL) + encodeURIComponent(name) + AMP + \"type=\" + type, useCF); res = {st: j.Status, ans: or(j.Answer, []), cf: useCF}; } catch (e) { if (!useCF) { try { useCF = true; var j2 = await fetchJson(CURL + encodeURIComponent(name) + AMP + \"type=\" + type, true); res = {st: j2.Status, ans: or(j2.Answer, []), cf: true}; } catch (e2) { useCF = false; res = {st: -1, ans: []}; } } else { res = {st: -1, ans: []}; } } cache[key] = res; return res; } function txtData(d, cf) { d = String(d); if (!cf) { return d; } if (d.charAt(0) !== Q) { return d; } var out = \"\"; var inq = false; var i = 0; while (lt(i, d.length)) { var c = d.charAt(i); if (c === BS) { var n3 = d.substr(i + 1, 3); if (n3.length === 3 ? digits(n3) : false) { out += String.fromCharCode(parseInt(n3, 10)); i += 4; continue; } out += d.charAt(i + 1); i += 2; continue; } if (c === Q) { inq = !inq; i++; continue; } if (inq) { out += c; } i++; } return out; } function countType(r, t) { var n = 0; for (var i = 0; i !== r.ans.length; i++) { if (r.ans[i].type === t) { n++; } } return n; } async function txts(name) { var r = await dns(name, \"TXT\"); var recs = []; var cn = []; for (var i = 0; i !== r.ans.length; i++) { var a = r.ans[i]; if (a.type === 16) { recs.push({t: txtData(a.data, r.cf), ttl: a.TTL}); } if (a.type === 5) { cn.push(noDot(a.data)); } } return {st: r.st, recs: recs, cn: cn}; } var BADNAME = \"Isso n\"+U(227)+\"o parece um dom\"+U(237)+\"nio. Digite algo como seudominio.com.br.\"; function clean(raw) { var s = String(or(raw, \"\")).trim().toLowerCase(); var sel = \"\"; var www = false; var at = s.lastIndexOf(\"@\"); if (at !== -1) { s = s.slice(at + 1); } var p = s.indexOf(\":\" + S2); if (p !== -1) { s = s.slice(p + 3); } s = s.split(\"\/\")[0].split(\"?\")[0].split(\"#\")[0].split(\":\")[0].trim(); s = noDot(s); if (s.indexOf(\"_dmarc.\") === 0) { s = s.slice(7); } var dk = s.indexOf(\"._domainkey.\"); if (dk !== -1) { sel = s.slice(0, dk); s = s.slice(dk + 12); } if (s.indexOf(\"www.\") === 0) { s = s.slice(4); www = true; } if (s === \"\") { return {err: \"Digite um dom\"+U(237)+\"nio, como seudominio.com.br.\"}; } try { s = new URL(\"http:\" + S2 + s).hostname; } catch (e) { return {err: BADNAME}; } var labels = s.split(\".\"); if (labels.length === 1) { return {err: \"Digite o dom\"+U(237)+\"nio completo, com a extens\"+U(227)+\"o, como seudominio.com.br.\"}; } var allNum = true; for (var i = 0; i !== labels.length; i++) { var l = labels[i]; if (l.length === 0 ? true : gt(l.length, 63)) { return {err: BADNAME}; } for (var j = 0; j !== l.length; j++) { if (!has(HOST, l.charAt(j))) { return {err: BADNAME}; } } if (!digits(l)) { allNum = false; } } if (allNum) { return {err: \"Isso \"+U(233)+\" um endere\"+U(231)+\"o IP. Os registros de e-mail ficam no dom\"+U(237)+\"nio: digite algo como seudominio.com.br.\"}; } if (gt(s.length, 253)) { return {err: \"Esse nome passa dos 253 caracteres que o DNS permite.\"}; } return {d: s, sel: sel, www: www}; } function isSpf(t) { var l = t.toLowerCase(); return l === \"v=spf1\" ? true : l.indexOf(\"v=spf1 \") === 0; } function okIp4(v) { var parts = v.split(\"\/\"); if (gt(parts.length, 2)) { return false; } var a = parts[0].split(\".\"); if (a.length !== 4) { return false; } for (var i = 0; i !== 4; i++) { if (!digits(a[i])) { return false; } if (gt(Number(a[i]), 255)) { return false; } } if (parts.length === 2) { if (!digits(parts[1])) { return false; } if (gt(Number(parts[1]), 32)) { return false; } } return true; } function okIp6(v) { var parts = v.split(\"\/\"); if (gt(parts.length, 2)) { return false; } if (!has(parts[0], \":\")) { return false; } for (var i = 0; i !== parts[0].length; i++) { if (!has(\"0123456789abcdef:.\", parts[0].charAt(i).toLowerCase())) { return false; } } if (parts.length === 2) { if (!digits(parts[1])) { return false; } if (gt(Number(parts[1]), 128)) { return false; } } return true; } var PERM = \" Os servidores que recebem o e-mail retornam PermError, e o SPF falha.\"; async function spfNode(domain, depth, chain, pre, via) { var node = {d: domain, via: via, rec: \"\", ttl: null, own: 0, kids: [], err: \"\", macro: false}; if (gt(depth, 10)) { node.err = \"N\"+U(227)+\"o seguido: aninhado demais.\"; say(ctx.spf, \"err\", \"Os includes do SPF passam de 10 n\"+U(237)+\"veis em \" + domain + \".\"); return node; } if (gt(ctx.q, QMAX)) { node.err = \"N\"+U(227)+\"o seguido: consultas demais.\"; say(ctx.spf, \"warn\", \"A \"+U(225)+\"rvore do SPF \"+U(233)+\" grande demais para ser seguida at\"+U(233)+\" o fim, ent\"+U(227)+\"o a contagem abaixo est\"+U(225)+\" incompleta.\"); return node; } var r = pre ? pre : await txts(domain); if (r.st === -1) { node.err = \"N\"+U(227)+\"o deu para consultar.\"; say(ctx.spf, \"warn\", \"N\"+U(227)+\"o deu para consultar \" + domain + \", ent\"+U(227)+\"o a contagem abaixo pode estar incompleta.\"); return node; } if (r.st === 3) { node.err = \"Esse dom\"+U(237)+\"nio n\"+U(227)+\"o existe (NXDOMAIN).\"; ctx.voids++; if (depth !== 0) { say(ctx.spf, \"err\", via + \":\" + domain + \" aponta para um dom\"+U(237)+\"nio que n\"+U(227)+\"o existe.\" + PERM); } return node; } if (r.st !== 0) { node.err = \"Erro de DNS (c\"+U(243)+\"digo \" + r.st + \").\"; say(ctx.spf, \"err\", \"Erro de DNS ao consultar \" + domain + \" (c\"+U(243)+\"digo \" + r.st + \"). Os servidores podem retornar TempError at\"+U(233)+\" isso ser corrigido.\"); return node; } var list = []; for (var i = 0; i !== r.recs.length; i++) { if (isSpf(r.recs[i].t)) { list.push(r.recs[i]); } } if (list.length === 0) { if (r.recs.length === 0) { ctx.voids++; } node.err = \"Sem registro SPF aqui.\"; if (depth !== 0) { say(ctx.spf, \"err\", via + \":\" + domain + \" n\"+U(227)+\"o tem registro SPF. Os servidores retornam PermError, e o SPF falha em toda mensagem.\"); } return node; } if (list.length !== 1) { say(ctx.spf, \"err\", domain + \" tem \" + list.length + \" registros SPF, e s\"+U(243)+\" um \"+U(233)+\" permitido.\" + PERM + \" Junte tudo em um registro s\"+U(243)+\".\"); } node.rec = list[0].t; node.ttl = list[0].ttl; var terms = node.rec.split(\" \"); var hasAll = false; var afterAll = false; var redirect = \"\"; var count = 0; for (var k = 1; k !== terms.length; k++) { var raw = terms[k].split(TAB).join(\"\"); if (raw === \"\") { continue; } var q = \"+\"; var t = raw; if (has(\"+-~?\", t.charAt(0))) { q = t.charAt(0); t = t.slice(1); } var low = t.toLowerCase(); var ci = low.indexOf(\":\"); var ei = low.indexOf(\"=\"); var si = low.indexOf(\"\/\"); var isMod = ei === -1 ? false : (ci === -1 ? true : lt(ei, ci)); var name = low; var arg = \"\"; if (isMod) { name = low.slice(0, ei); arg = t.slice(ei + 1); if (name === \"redirect\") { redirect = arg; } else if (name !== \"exp\") { say(ctx.spf, \"warn\", \"Os servidores ignoram o modificador desconhecido \" + raw + \" em \" + domain + \". Confira se n\"+U(227)+\"o \"+U(233)+\" erro de digita\"+U(231)+U(227)+\"o.\"); } if (arg === \"\") { say(ctx.spf, \"err\", \"O termo \" + raw + \" em \" + domain + \" est\"+U(225)+\" sem valor.\" + PERM); } continue; } if (ci !== -1) { name = low.slice(0, ci); arg = t.slice(ci + 1); } else if (si !== -1) { name = low.slice(0, si); } if (hasAll) { afterAll = true; } if (name === \"all\") { hasAll = true; if (depth === 0) { if (q === \"+\") { say(ctx.spf, \"err\", \"+all deixa qualquer servidor do mundo enviar e-mail em nome do seu dom\"+U(237)+\"nio. Termine o registro com ~all ou -all.\"); } if (q === \"?\") { say(ctx.spf, \"warn\", \"?all (neutro) n\"+U(227)+\"o protege nada: o e-mail de servidores fora da lista n\"+U(227)+\"o \"+U(233)+\" marcado. Use ~all ou -all.\"); } if (q === \"~\") { say(ctx.spf, \"info\", \"~all (soft fail): o e-mail de servidores fora da lista \"+U(233)+\" marcado como suspeito. A pol\"+U(237)+\"tica DMARC decide o que acontece com ele.\"); } if (q === \"-\") { say(ctx.spf, \"info\", \"-all (hard fail): o e-mail de servidores fora da lista deve ser recusado. A pol\"+U(237)+\"tica DMARC decide a a\"+U(231)+U(227)+\"o final.\"); } } continue; } if (name === \"include\") { count++; if (arg === \"\") { say(ctx.spf, \"err\", \"Um include em \" + domain + \" est\"+U(225)+\" sem dom\"+U(237)+\"nio depois dele.\" + PERM); continue; } var tg = arg.toLowerCase(); if (has(tg, \"%\")) { node.kids.push({d: tg, via: \"include\", macro: true, kids: [], own: 0, rec: \"\", err: \"\"}); continue; } if (chain.indexOf(tg) !== -1) { say(ctx.spf, \"err\", \"include:\" + tg + \" cria um loop: ele acaba incluindo a si mesmo.\" + PERM); continue; } node.kids.push(await spfNode(tg, depth + 1, chain.concat([tg]), null, \"include\")); continue; } if (name === \"a\" ? true : name === \"mx\") { count++; var hostName = arg === \"\" ? domain : arg.split(\"\/\")[0].toLowerCase(); if (!has(hostName, \"%\")) { if (name === \"a\") { var ra = await dns(hostName, \"A\"); var found = countType(ra, 1) !== 0; if (!found) { var r6 = await dns(hostName, \"AAAA\"); found = countType(r6, 28) !== 0; } if (!found) { ctx.voids++; say(ctx.spf, \"warn\", \"O mecanismo a em \" + domain + \" n\"+U(227)+\"o encontra IP para \" + hostName + \" (consulta vazia). Tire-o se esse endere\"+U(231)+\"o n\"+U(227)+\"o envia e-mail.\"); } } else { var rm = await dns(hostName, \"MX\"); var nmx = countType(rm, 15); if (nmx === 0) { ctx.voids++; say(ctx.spf, \"warn\", \"O mecanismo mx em \" + domain + \" n\"+U(227)+\"o encontra registros MX para \" + hostName + \" (consulta vazia). Tire-o se esse dom\"+U(237)+\"nio n\"+U(227)+\"o recebe e-mail.\"); } if (gt(nmx, 10)) { say(ctx.spf, \"err\", hostName + \" tem \" + nmx + \" registros MX, mas o SPF confere no m\"+U(225)+\"ximo 10 por mecanismo mx.\" + PERM); } } } continue; } if (name === \"ptr\") { count++; say(ctx.spf, \"warn\", \"ptr em \" + domain + \" est\"+U(225)+\" obsoleto (RFC 7208): \"+U(233)+\" lento, pouco confi\"+U(225)+\"vel e alguns servidores o ignoram. Troque por ip4, ip6 ou include.\"); continue; } if (name === \"exists\") { count++; if (arg === \"\") { say(ctx.spf, \"err\", \"exists em \" + domain + \" est\"+U(225)+\" sem dom\"+U(237)+\"nio depois dele.\" + PERM); } continue; } if (name === \"ip4\") { if (!okIp4(arg)) { say(ctx.spf, \"err\", \"Endere\"+U(231)+\"o IPv4 inv\"+U(225)+\"lido em \" + domain + \": \" + raw + \".\" + PERM); } continue; } if (name === \"ip6\") { if (!okIp6(arg.toLowerCase())) { say(ctx.spf, \"err\", \"Endere\"+U(231)+\"o IPv6 inv\"+U(225)+\"lido em \" + domain + \": \" + raw + \".\" + PERM); } continue; } say(ctx.spf, \"err\", \"Termo desconhecido \" + raw + \" em \" + domain + \".\" + PERM + \" Confira se n\"+U(227)+\"o falta um espa\"+U(231)+\"o ou se n\"+U(227)+\"o h\"+U(225)+\" erro de digita\"+U(231)+U(227)+\"o.\"); } if (redirect !== \"\") { if (hasAll) { say(ctx.spf, \"info\", \"redirect=\" + redirect + \" em \" + domain + \" \"+U(233)+\" ignorado, porque o registro tamb\"+U(233)+\"m termina com all.\"); } else { count++; var rt = redirect.toLowerCase(); if (has(rt, \"%\")) { node.kids.push({d: rt, via: \"redirect\", macro: true, kids: [], own: 0, rec: \"\", err: \"\"}); } else if (chain.indexOf(rt) !== -1) { say(ctx.spf, \"err\", \"redirect=\" + rt + \" cria um loop.\" + PERM); } else { node.kids.push(await spfNode(rt, depth + 1, chain.concat([rt]), null, \"redirect\")); } } } if (depth === 0) { if (!hasAll) { if (redirect === \"\") { say(ctx.spf, \"warn\", \"O registro n\"+U(227)+\"o termina com all, ent\"+U(227)+\"o o e-mail de servidores fora da lista recebe resultado neutro. Termine com ~all ou -all.\"); } } if (afterAll) { say(ctx.spf, \"warn\", \"H\"+U(225)+\" termos depois do all. Os servidores nunca leem esses termos, ent\"+U(227)+\"o mova-os para antes do all.\"); } } node.own = count; ctx.total += count; return node; } function tags(t) { var o = {}; var parts = t.split(\";\"); for (var i = 0; i !== parts.length; i++) { var p = parts[i].trim(); if (p === \"\") { continue; } var e = p.indexOf(\"=\"); if (e === -1) { continue; } o[p.slice(0, e).trim().toLowerCase()] = p.slice(e + 1).trim(); } return o; } async function dmarc(domain) { var d = domain; var r = null; var recs = []; var other = []; var first = true; while (true) { r = await txts(\"_dmarc.\" + d); recs = []; for (var i = 0; i !== r.recs.length; i++) { var t = r.recs[i].t; if (t.trim().toLowerCase().indexOf(\"v=dmarc1\") === 0) { recs.push(r.recs[i]); } else if (first) { other.push(r.recs[i]); } } first = false; if (recs.length !== 0 ? true : r.st === -1) { break; } var labels = d.split(\".\"); if (gt(labels.length, 2)) { d = labels.slice(1).join(\".\"); } else { break; } } return {d: recs.length ? d : domain, inh: recs.length ? d !== domain : false, st: r.st, recs: recs, other: other}; } function keyInfo(t) { var o = tags(t); var res = {l: \"ok\", t: \"\", bits: \"\", test: false}; if (has(String(or(o.t, \"\")).toLowerCase(), \"y\")) { res.test = true; } if (!(\"p\" in o)) { res.l = \"err\"; res.t = \"Sem a tag p=, ent\"+U(227)+\"o n\"+U(227)+\"o h\"+U(225)+\" chave aqui.\"; return res; } var p = o.p.split(\" \").join(\"\").split(TAB).join(\"\"); if (p === \"\") { res.l = \"warn\"; res.t = \"Tag p= vazia: essa chave foi revogada e n\"+U(227)+\"o verifica assinaturas.\"; res.bits = \"revogada\"; return res; } for (var i = 0; i !== p.length; i++) { if (!has(B64, p.charAt(i))) { res.l = \"err\"; res.t = \"A chave tem um caractere que n\"+U(227)+\"o \"+U(233)+\" v\"+U(225)+\"lido numa chave (\" + p.charAt(i) + \"), ent\"+U(227)+\"o as assinaturas falham. Isso costuma acontecer quando aspas ou texto extra s\"+U(227)+\"o colados no painel de DNS.\"; res.bits = \"corrompida\"; return res; } } if (String(or(o.k, \"rsa\")).toLowerCase() === \"ed25519\") { res.t = \"Chave Ed25519.\"; res.bits = \"Ed25519\"; return res; } var pad = 0; while (p.charAt(p.length - 1 - pad) === \"=\") { pad++; } var bytes = Math.floor(p.length * 3 \/ 4) - pad; var bits = ge(bytes, 500) ? 4096 : ge(bytes, 400) ? 3072 : ge(bytes, 260) ? 2048 : ge(bytes, 190) ? 1536 : ge(bytes, 130) ? 1024 : 0; if (bits === 0) { res.l = \"err\"; res.t = \"Chave RSA com menos de 1024 bits: fraca demais, e muitos servidores a ignoram. Gere uma chave de 2048 bits.\"; res.bits = \"menos de 1024 bits\"; return res; } res.bits = bits + \" bits\"; if (bits === 1024) { res.l = \"warn\"; res.t = \"Chave RSA de 1024 bits: ainda aceita, mas a recomenda\"+U(231)+U(227)+\"o atual \"+U(233)+\" 2048 bits.\"; return res; } res.t = \"Chave RSA de \" + bits + \" bits.\"; return res; } function looksDkim(t) { var o = tags(t); if (\"p\" in o) { return true; } if (\"k\" in o) { return true; } return t.trim().toLowerCase().indexOf(\"v=dkim1\") === 0; } async function dkim(domain, user) { var list = []; if (user !== \"\") { list.push(user); } for (var i = 0; i !== SEL.length; i++) { if (SEL[i] !== user) { list.push(SEL[i]); } } var probe = \"hh\" + Math.random().toString(36).slice(2, 10); var all = list.concat([probe]); var res = await Promise.all(all.map(function (s) { return txts(s + \"._domainkey.\" + domain).then(function (r) { return {s: s, r: r}; }); })); var w = res[res.length - 1].r; var wTxt = w.recs.length ? w.recs[0].t : \"\"; var wCn = w.cn.length ? w.cn[w.cn.length - 1] : \"\"; var out = {found: [], dead: [], userMissing: false, notKey: false, wild: wTxt !== \"\" ? true : wCn !== \"\", failed: 0, total: list.length}; for (var k = 0; k !== res.length - 1; k++) { var x = res[k]; if (x.r.st === -1) { out.failed++; continue; } var cnl = x.r.cn.length ? x.r.cn[x.r.cn.length - 1] : \"\"; if (x.r.recs.length !== 0) { var tx = x.r.recs[0].t; if (wTxt !== \"\" ? tx === wTxt : false) { if (x.s === user) { out.userMissing = true; } continue; } if (!looksDkim(tx)) { if (x.s === user) { out.notKey = true; } continue; } out.found.push({s: x.s, rec: tx, n: x.r.recs.length, cn: x.r.cn, ki: keyInfo(tx)}); continue; } if (cnl !== \"\") { if (wCn !== \"\" ? cnl === wCn : false) { if (x.s === user) { out.userMissing = true; } continue; } out.dead.push({s: x.s, cn: cnl}); continue; } if (x.s === user) { out.userMissing = true; } } return out; } function kind(t) { var l = t.trim().toLowerCase(); if (isSpf(t)) { return \"SPF\"; } if (l.indexOf(\"v=dmarc1\") === 0) { return \"DMARC (lugar errado)\"; } if (l.indexOf(\"v=dkim1\") === 0) { return \"Chave DKIM\"; } if (l.indexOf(\"v=stsv1\") === 0) { return \"MTA-STS\"; } var e = l.indexOf(\"=\"); var key = e === -1 ? \"\" : l.slice(0, e); if (has(key, \"verif\") ? true : (key === \"ms\" ? true : (key === \"docusign\" ? true : has(key, \"site-verification\")))) { return \"Verifica\"+U(231)+U(227)+\"o\"; } return \"Outro\"; } function card(row, label, l, line, sub) { var c = COL[l]; var b = add(row, \"div\", \"\", \"flex:1 1 190px;min-width:0;background:#ffffff;border:1px solid #d5dce5;border-top:4px solid \" + c[0] + \";border-radius:10px;padding:10px 12px;box-sizing:border-box;\"); add(b, \"div\", label, \"font-size:12px;font-weight:700;letter-spacing:.05em;text-transform:uppercase;color:#475569;\"); add(b, \"div\", c[2] + \" \" + line, \"font-weight:800;color:\" + c[0] + \";margin-top:2px;\"); if (sub) { add(b, \"div\", sub, \"font-size:13px;color:#334155;margin-top:2px;\"); } } function section(out, title) { var s = add(out, \"div\", \"\", \"background:#ffffff;border:1px solid #d5dce5;border-radius:10px;padding:12px 14px;margin-top:12px;\"); add(s, \"div\", title, \"font-weight:800;color:#0b3d91;font-size:16px;margin-bottom:6px;\"); return s; } var RANK = {err: 0, warn: 1, ok: 2, info: 3}; function notes(parent, arr) { arr = arr.slice().sort(function (a, b) { return RANK[a.l] - RANK[b.l]; }); var seen = {}; for (var i = 0; i !== arr.length; i++) { var n = arr[i]; if (seen[n.t]) { continue; } seen[n.t] = true; var c = COL[n.l]; var d = add(parent, \"div\", \"\", \"background:\" + c[1] + \";border-left:4px solid \" + c[0] + \";border-radius:6px;padding:7px 10px;margin:6px 0;font-size:14px;line-height:1.5;color:#0F172A;overflow-wrap:anywhere;\"); add(d, \"span\", c[2] + \" \", \"color:\" + c[0] + \";font-weight:800;\"); d.appendChild(document.createTextNode(n.t + \" \")); if (n.h) { var a = add(d, \"a\", n.lt, \"color:#1d4ed8;font-weight:700;\"); a.setAttribute(\"href\", n.h); } } } function countNodes(n) { var c = 1; for (var i = 0; i !== n.kids.length; i++) { c += countNodes(n.kids[i]); } return c; } function drawNode(parent, node, depth) { var w = add(parent, \"div\", \"\", \"margin-left:\" + (depth === 0 ? 0 : 14) + \"px;padding-left:\" + (depth === 0 ? 0 : 10) + \"px;border-left:\" + (depth === 0 ? \"0\" : \"2px solid #d5dce5\") + \";margin-top:6px;\"); var head = add(w, \"div\", \"\", \"font-size:13.5px;overflow-wrap:anywhere;\"); add(head, \"span\", (node.via ? node.via + (node.via === \"redirect\" ? \"=\" : \":\") : \"\") + node.d, \"font-weight:700;color:#0b3d91;font-family:Consolas,Menlo,monospace;\"); var tail = node.macro ? \"  usa macros, avaliadas a cada mensagem\" : (node.err ? \"  \" + node.err : \"  \" + node.own + \" \" + plural(node.own, \"consulta\", \"consultas\") + \" aqui\"); add(head, \"span\", tail, \"color:\" + (node.err ? \"#b42318\" : \"#475569\") + \";\"); if (node.rec) { add(w, \"div\", depth === 0 ? node.rec : (gt(node.rec.length, 200) ? node.rec.slice(0, 200) + \" \" + ELL : node.rec), MONO); } for (var i = 0; i !== node.kids.length; i++) { drawNode(w, node.kids[i], depth + 1); } } function render(c, root, tree, dm, dk, sel) { var out = el(\"out\"); out.textContent = \"\"; if (c.www) { notes(out, [{l: \"info\", t: \"Verifiquei \" + c.d + \" sem o www: os registros de e-mail ficam no dom\"+U(237)+\"nio que vem depois do @ dos seus endere\"+U(231)+\"os.\", h: \"\", lt: \"\"}]); } var spfL = \"ok\"; var spfLine = \"\"; var spfSub = \"\"; if (tree.err) { spfL = \"err\"; spfLine = \"Sem registro SPF\"; spfSub = \"N\"+U(227)+\"o d\"+U(225)+\" para saber quem pode enviar\"; say(ctx.spf, \"err\", \"N\"+U(227)+\"o h\"+U(225)+\" registro SPF em \" + c.d + \". Os servidores n\"+U(227)+\"o conseguem conferir quem pode enviar e-mail pelo dom\"+U(237)+\"nio, e o Gmail e o Yahoo exigem SPF ou DKIM de todo remetente. No cPanel da Homehost, abra E-mails, depois Autentica\"+U(231)+U(227)+\"o, e clique em Habilitar no SPF, como mostra este tutorial. Se o dom\"+U(237)+\"nio nunca envia e-mail, publique v=spf1 -all.\"); } else { spfLine = ctx.total + \" de 10 consultas\"; var bad = false; for (var i = 0; i !== ctx.spf.length; i++) { if (ctx.spf[i].l === \"err\") { bad = true; } } if (gt(ctx.total, 10)) { spfL = \"err\"; spfSub = \"Passou do limite: PermError\"; say(ctx.spf, \"err\", ctx.total + \" consultas DNS: passou do limite de 10. Os servidores retornam PermError, e o SPF falha em toda mensagem. Tire includes de servi\"+U(231)+\"os que voc\"+U(234)+\" n\"+U(227)+\"o usa mais ou troque-os por ip4 e ip6.\"); } else if (ge(ctx.total, 9)) { spfL = \"warn\"; spfSub = \"No limite\"; say(ctx.spf, \"warn\", ctx.total + \" de 10 consultas DNS: no limite. O pr\"+U(243)+\"ximo servi\"+U(231)+\"o que voc\"+U(234)+\" incluir no SPF vai quebr\"+U(225)+\"-lo.\"); } else { spfSub = \"Dentro do limite\"; } if (gt(ctx.voids, 2)) { spfL = \"err\"; spfSub = \"Consultas vazias demais\"; say(ctx.spf, \"err\", ctx.voids + \" consultas n\"+U(227)+\"o retornaram nada (consultas vazias). O limite \"+U(233)+\" 2, ent\"+U(227)+\"o os servidores retornam PermError.\"); } if (bad) { spfL = \"err\"; if (!gt(ctx.total, 10)) { spfSub = \"Com erros\"; } } else if (spfL === \"ok\") { for (var w = 0; w !== ctx.spf.length; w++) { if (ctx.spf[w].l === \"warn\") { spfL = \"warn\"; spfSub = \"V\"+U(225)+\"lido, com avisos\"; } } } } var dmL = \"ok\"; var dmLine = \"\"; var dmSub = \"\"; var tg = dm.recs.length ? tags(dm.recs[0].t) : {}; for (var x = 0; x !== root.recs.length; x++) { if (kind(root.recs[x].t) === \"DMARC (lugar errado)\") { say(ctx.dm, \"err\", \"H\"+U(225)+\" um registro DMARC na raiz de \" + c.d + \". Os servidores o ignoram ali: ele precisa estar em _dmarc.\" + c.d + \".\"); } } if (dm.st === -1) { dmL = \"warn\"; dmLine = \"N\"+U(227)+\"o deu para verificar\"; } else if (dm.recs.length === 0) { dmL = \"err\"; dmLine = \"Sem registro DMARC\"; dmSub = \"Sem pol\"+U(237)+\"tica para e-mail que falha\"; for (var o = 0; o !== dm.other.length; o++) { say(ctx.dm, \"err\", \"H\"+U(225)+\" um registro em _dmarc.\" + c.d + \", mas ele n\"+U(227)+\"o come\"+U(231)+\"a com v=DMARC1, ent\"+U(227)+\"o os servidores o ignoram: \" + dm.other[o].t); } say(ctx.dm, \"err\", \"N\"+U(227)+\"o h\"+U(225)+\" registro DMARC. Cada servidor decide sozinho o que fazer com o e-mail que falha no SPF e no DKIM, e o Gmail e o Yahoo exigem DMARC (p=none basta) de quem envia em volume.\", DMARCGEN, \"Crie o seu no gerador de DMARC\"); } else { var p = String(or(dm.inh ? or(tg.sp, tg.p) : tg.p, \"\")).toLowerCase(); var pt = (dm.inh ? (tg.sp ? \"Herdada: sp=\" : \"Herdada: p=\") : \"p=\"); if (dm.recs.length !== 1) { say(ctx.dm, \"err\", dm.recs.length + \" registros DMARC em _dmarc.\" + dm.d + \". Os servidores ignoram o DMARC por completo quando h\"+U(225)+\" mais de um. Deixe um s\"+U(243)+\".\"); } if (dm.inh ? dm.other.length !== 0 : false) { say(ctx.dm, \"warn\", \"O registro TXT em _dmarc.\" + c.d + \" n\"+U(227)+\"o \"+U(233)+\" um registro DMARC, ent\"+U(227)+\"o os servidores o ignoram e usam a pol\"+U(237)+\"tica de \" + dm.d + \".\"); } else if (dm.inh) { say(ctx.dm, \"info\", \"N\"+U(227)+\"o h\"+U(225)+\" registro em _dmarc.\" + c.d + \", ent\"+U(227)+\"o vale o registro de \" + dm.d + (tg.sp ? \", que define sp=\" + tg.sp + \" para os subdom\"+U(237)+\"nios.\" : \", cuja pol\"+U(237)+\"tica tamb\"+U(233)+\"m cobre os subdom\"+U(237)+\"nios.\")); } if (p === \"\") { dmL = \"err\"; dmLine = \"Inv\"+U(225)+\"lido: sem a tag p=\"; say(ctx.dm, \"err\", \"O registro n\"+U(227)+\"o tem a tag p=, que \"+U(233)+\" obrigat\"+U(243)+\"ria. Acrescente p=none, p=quarantine ou p=reject.\"); } else if (p === \"none\") { dmL = \"warn\"; dmLine = pt + \"none\"; dmSub = \"S\"+U(243)+\" monitoramento\"; say(ctx.dm, \"warn\", \"A pol\"+U(237)+\"tica \"+U(233)+\" none, que s\"+U(243)+\" monitora: o e-mail que falha \"+U(233)+\" entregue normalmente. Quando os relat\"+U(243)+\"rios mostrarem todos os seus remetentes passando, mude para p=quarantine e depois para p=reject.\"); } else if (p === \"quarantine\") { dmLine = pt + \"quarantine\"; dmSub = \"O e-mail que falha vai para o spam\"; say(ctx.dm, \"ok\", \"A pol\"+U(237)+\"tica \"+U(233)+\" quarantine: o e-mail que falha no alinhamento de SPF e DKIM vai para o spam.\"); } else if (p === \"reject\") { dmLine = pt + \"reject\"; dmSub = \"O e-mail que falha \"+U(233)+\" recusado\"; say(ctx.dm, \"ok\", \"A pol\"+U(237)+\"tica \"+U(233)+\" reject: o e-mail que falha \"+U(233)+\" recusado. \"+U(201)+\" a prote\"+U(231)+U(227)+\"o mais forte.\"); } else { dmL = \"err\"; dmLine = \"Pol\"+U(237)+\"tica inv\"+U(225)+\"lida\"; say(ctx.dm, \"err\", \"p=\" + tg.p + \" n\"+U(227)+\"o \"+U(233)+\" uma pol\"+U(237)+\"tica v\"+U(225)+\"lida. Use none, quarantine ou reject.\"); } if (dm.recs.length !== 1) { dmL = \"err\"; dmSub = \"Registros duplicados\"; } if (tg.sp ? !dm.inh : false) { say(ctx.dm, \"info\", \"Os subdom\"+U(237)+\"nios usam sp=\" + tg.sp + \".\"); } if (tg.np) { say(ctx.dm, \"info\", \"Subdom\"+U(237)+\"nios que n\"+U(227)+\"o existem usam np=\" + tg.np + \".\"); } if (String(or(tg.t, \"\")).toLowerCase() === \"y\") { say(ctx.dm, \"info\", \"t=y: a pol\"+U(237)+\"tica est\"+U(225)+\" em modo de teste.\"); } if (\"pct\" in tg) { say(ctx.dm, \"warn\", \"A tag pct=\" + tg.pct + \" saiu do padr\"+U(227)+\"o na nova vers\"+U(227)+\"o do DMARC (RFC 9989, maio de 2026), e os servidores atualizados a ignoram. Para testar a pol\"+U(237)+\"tica, use t=y no lugar dela.\"); if (dmL === \"ok\") { dmL = \"warn\"; } } if ((\"rf\" in tg) ? true : (\"ri\" in tg)) { say(ctx.dm, \"info\", \"As tags rf e ri tamb\"+U(233)+\"m sa\"+U(237)+\"ram do padr\"+U(227)+\"o na RFC 9989 e podem ser removidas.\"); } if (tg.rua) { say(ctx.dm, \"info\", \"Os relat\"+U(243)+\"rios agregados v\"+U(227)+\"o para \" + tg.rua.split(\",\").join(\", \") + \".\"); } else { say(ctx.dm, \"warn\", \"Sem endere\"+U(231)+\"o rua=: voc\"+U(234)+\" n\"+U(227)+\"o recebe os relat\"+U(243)+\"rios agregados, ent\"+U(227)+\"o n\"+U(227)+\"o v\"+U(234)+\" quais servidores enviam e-mail em nome do seu dom\"+U(237)+\"nio.\"); if (dmL === \"ok\") { dmL = \"warn\"; } } if (String(or(tg.adkim, \"\")).toLowerCase() === \"s\") { say(ctx.dm, \"info\", \"adkim=s: o DKIM precisa bater com o dom\"+U(237)+\"nio exato (alinhamento estrito).\"); } if (String(or(tg.aspf, \"\")).toLowerCase() === \"s\") { say(ctx.dm, \"info\", \"aspf=s: o SPF precisa bater com o dom\"+U(237)+\"nio exato (alinhamento estrito).\"); } } var dkL = \"info\"; var dkLine = \"\"; var dkSub = \"\"; if (dk.found.length !== 0) { dkL = \"ok\"; var names = []; for (var f = 0; f !== dk.found.length; f++) { names.push(dk.found[f].s); if (dk.found[f].ki.l === \"err\") { dkL = \"err\"; } else if (dk.found[f].ki.l === \"warn\") { if (dkL === \"ok\") { dkL = \"warn\"; } } } dkLine = dk.found.length + \" \" + plural(dk.found.length, \"chave encontrada\", \"chaves encontradas\"); dkSub = \"Seletor: \" + names.join(\", \"); } else if (dk.failed !== 0 ? dk.failed === dk.total : false) { dkL = \"warn\"; dkLine = \"N\"+U(227)+\"o deu para verificar\"; } else { dkLine = \"N\"+U(227)+\"o encontrado\"; dkSub = sel ? \"O seletor \" + sel + \" n\"+U(227)+\"o tem chave\" : \"Nos seletores mais comuns\"; if (sel) { dkL = \"err\"; } } var row = add(out, \"div\", \"\", \"display:flex;gap:10px;flex-wrap:wrap;\"); card(row, \"SPF\", spfL, spfLine, spfSub); card(row, \"DMARC\", dmL, dmLine, dmSub); card(row, \"DKIM\", dkL, dkLine, dkSub); var s1 = section(out, \"SPF\"); if (!tree.err) { var meter = add(s1, \"div\", \"\", \"height:10px;background:#eef1f5;border-radius:99px;overflow:hidden;margin:4px 0 2px;\"); add(meter, \"div\", \"\", \"height:10px;width:\" + Math.min(100, ctx.total * 10) + \"%;background:\" + COL[gt(ctx.total, 10) ? \"err\" : (ge(ctx.total, 9) ? \"warn\" : \"ok\")][0] + \";\"); add(s1, \"div\", ctx.total + \" de 10 consultas DNS\" + (ctx.voids ? \" \" + DOT + \" \" + ctx.voids + \" \" + plural(ctx.voids, \"vazia\", \"vazias\") : \"\"), \"font-size:13px;color:#475569;margin-bottom:4px;\"); } notes(s1, ctx.spf); if (!tree.err) { var det = add(s1, \"details\", \"\", \"margin-top:10px;\"); if (lt(countNodes(tree), 5)) { det.open = true; } add(det, \"summary\", \"Como as consultas se somam (\" + countNodes(tree) + \" \" + plural(countNodes(tree), \"registro)\", \"registros)\"), \"font-weight:700;font-size:13.5px;color:#0b3d91;cursor:pointer;\"); drawNode(det, tree, 0); } var s2 = section(out, \"DMARC\"); if (dm.recs.length) { add(s2, \"div\", \"_dmarc.\" + dm.d, \"font-size:13px;color:#475569;font-family:Consolas,Menlo,monospace;\"); for (var m = 0; m !== dm.recs.length; m++) { add(s2, \"div\", dm.recs[m].t, MONO); } } notes(s2, ctx.dm); var s3 = section(out, \"DKIM\"); for (var g = 0; g !== dk.found.length; g++) { var k = dk.found[g]; add(s3, \"div\", k.s + \"._domainkey.\" + c.d + (k.cn.length ? \"  (CNAME para \" + k.cn[k.cn.length - 1] + \")\" : \"\"), \"font-size:13px;color:#475569;font-family:Consolas,Menlo,monospace;margin-top:8px;overflow-wrap:anywhere;\"); var kn = [{l: k.ki.l, t: \"Seletor \" + k.s + \": \" + k.ki.t, h: \"\", lt: \"\"}]; if (k.ki.test) { kn.push({l: \"warn\", t: \"t=y: essa chave est\"+U(225)+\" em modo de teste, ent\"+U(227)+\"o os servidores tratam seus e-mails assinados como se n\"+U(227)+\"o tivessem assinatura.\", h: \"\", lt: \"\"}); } if (gt(k.n, 1)) { kn.push({l: \"err\", t: k.n + \" registros nesse seletor. Os servidores podem pegar o errado: deixe uma chave s\"+U(243)+\" por seletor.\", h: \"\", lt: \"\"}); } notes(s3, kn); var kdet = add(s3, \"details\", \"\", \"margin:2px 0 6px;\"); add(kdet, \"summary\", \"Mostrar o registro\", \"font-size:13px;color:#1d4ed8;cursor:pointer;\"); add(kdet, \"div\", k.rec, MONO); } for (var dd = 0; dd !== dk.dead.length; dd++) { notes(s3, [{l: \"info\", t: \"O seletor \" + dk.dead[dd].s + \" aponta para \" + dk.dead[dd].cn + \", mas n\"+U(227)+\"o h\"+U(225)+\" chave l\"+U(225)+\". Costuma ser um seletor inativo, como o reserva do Microsoft 365.\", h: \"\", lt: \"\"}]); } if (dk.wild) { notes(s3, [{l: \"info\", t: \"Esse dom\"+U(237)+\"nio responde a qualquer nome em _domainkey com o mesmo registro (curinga), ent\"+U(227)+\"o s\"+U(243)+\" aparecem os seletores que t\"+U(234)+\"m chave pr\"+U(243)+\"pria.\", h: \"\", lt: \"\"}]); } if (dk.notKey) { notes(s3, [{l: \"err\", t: \"H\"+U(225)+\" um registro TXT em \" + sel + \"._domainkey.\" + c.d + \", mas ele n\"+U(227)+\"o \"+U(233)+\" uma chave DKIM: falta a tag p=. Confira o que foi publicado ali.\", h: \"\", lt: \"\"}]); } var selHelp = \"Confira o seletor na tag s= da linha DKIM-Signature, no cabe\"+U(231)+\"alho de um e-mail que voc\"+U(234)+\" enviou.\"; if (dk.userMissing ? dk.found.length !== 0 : false) { notes(s3, [{l: \"err\", t: \"N\"+U(227)+\"o h\"+U(225)+\" chave DKIM em \" + sel + \"._domainkey.\" + c.d + \". \" + selHelp, h: \"\", lt: \"\"}]); } if (dk.found.length === 0) { if (sel ? !dk.notKey : false) { notes(s3, [{l: \"err\", t: \"N\"+U(227)+\"o h\"+U(225)+\" chave DKIM em \" + sel + \"._domainkey.\" + c.d + \". \" + selHelp, h: \"\", lt: \"\"}]); } else if (!sel) { notes(s3, [{l: \"info\", t: \"Nenhuma chave nos \" + SEL.length + \" seletores mais comuns, incluindo o default, que o cPanel usa. No cPanel da Homehost, o DKIM vem ativado por padr\"+U(227)+\"o: confira na mesma tela do SPF (E-mails, depois Autentica\"+U(231)+U(227)+\"o) e veja se o dom\"+U(237)+\"nio usa o DNS da Homehost. Se voc\"+U(234)+\" envia por outro servi\"+U(231)+\"o, o seletor pode ser outro: \" + selHelp + \" Depois, digite-o no campo de seletor.\", h: \"\", lt: \"\"}]); } } var s4 = add(out, \"details\", \"\", \"background:#ffffff;border:1px solid #d5dce5;border-radius:10px;padding:12px 14px;margin-top:12px;\"); if (lt(root.recs.length, 6)) { s4.open = true; } add(s4, \"summary\", \"Todos os registros TXT de \" + c.d + \" (\" + root.recs.length + \")\", \"font-weight:800;color:#0b3d91;font-size:16px;cursor:pointer;\"); if (root.recs.length === 0) { add(s4, \"div\", \"Esse dom\"+U(237)+\"nio n\"+U(227)+\"o tem registros TXT.\", \"font-size:14px;color:#475569;\"); } for (var r = 0; r !== root.recs.length; r++) { var t = root.recs[r].t; var kd = kind(t); var line = add(s4, \"div\", \"\", \"margin-top:6px;\"); add(line, \"span\", kd, \"display:inline-block;font-size:11.5px;font-weight:700;background:\" + (kd === \"SPF\" ? \"#e8f5ec\" : (kd === \"Verifica\"+U(231)+U(227)+\"o\" ? \"#eef3ff\" : \"#eef1f5\")) + \";color:#0b3d91;border-radius:99px;padding:1px 8px;margin-right:6px;\"); add(line, \"span\", \"TTL \" + root.recs[r].ttl + \" s\", \"font-size:12px;color:#64748b;\"); add(line, \"div\", t, MONO); } el(\"st\").textContent = \"Pronto: \" + ctx.q + \" \" + plural(ctx.q, \"consulta DNS\", \"consultas DNS\") + (useCF ? \" (pelo DNS da Cloudflare).\" : \".\"); } function fail(msg) { var out = el(\"out\"); out.textContent = \"\"; notes(out, [{l: \"err\", t: msg, h: \"\", lt: \"\"}]); el(\"st\").textContent = \"\"; } async function run() { if (busy) { return; } var c = clean(el(\"d\").value); if (c.err) { fail(c.err); return; } var sel = String(or(el(\"s\").value, or(c.sel, \"\"))).trim().toLowerCase(); if (sel) { for (var i = 0; i !== sel.length; i++) { if (!has(HOST + \".\", sel.charAt(i))) { fail(\"Um seletor DKIM tem s\"+U(243)+\" letras, n\"+U(250)+\"meros, h\"+U(237)+\"fens e pontos, como default ou google.\"); return; } } } busy = true; var go = el(\"go\"); go.disabled = true; go.textContent = \"Verificando\" + ELL; go.style.opacity = \"0.7\"; el(\"out\").textContent = \"\"; cache = {}; useCF = false; ctx = {q: 0, total: 0, voids: 0, spf: [], dm: [], dk: []}; try { el(\"st\").textContent = \"Consultando \" + c.d + ELL; var root = await txts(c.d); if (root.st === -1) { fail(\"N\"+U(227)+\"o deu para acessar o servi\"+U(231)+\"o de DNS. Um firewall, uma rede corporativa ou uma extens\"+U(227)+\"o do navegador pode estar bloqueando. Tente outra rede ou uma janela an\"+U(244)+\"nima com as extens\"+U(245)+\"es desligadas.\"); } else if (root.st === 3) { fail(c.d + \" n\"+U(227)+\"o existe (NXDOMAIN). Confira a grafia ou se o dom\"+U(237)+\"nio expirou.\"); } else if (root.st !== 0) { fail(\"Os servidores DNS de \" + c.d + \" retornaram um erro (c\"+U(243)+\"digo \" + root.st + \"). Isso costuma indicar um problema nos servidores de nome ou no DNSSEC do dom\"+U(237)+\"nio.\"); } else { el(\"st\").textContent = \"Conferindo o SPF\" + ELL; var tree = await spfNode(c.d, 0, [c.d], root, \"\"); el(\"st\").textContent = \"Conferindo o DMARC\" + ELL; var dm = await dmarc(c.d); el(\"st\").textContent = \"Conferindo os seletores DKIM\" + ELL; var dk = await dkim(c.d, sel); render(c, root, tree, dm, dk, sel); } } catch (e) { fail(\"Algo deu errado durante a consulta. Tente de novo.\"); } busy = false; go.disabled = false; go.textContent = \"Verificar\"; go.style.opacity = \"1\"; } add(root0, \"div\", \"Verificador de SPF, DKIM e DMARC\", \"font-weight:800;font-size:19px;color:#0b3d91;margin-bottom:4px;\"); add(root0, \"p\", \"Digite o dom\"+U(237)+\"nio do seu e-mail para ver o SPF (com a contagem do limite de 10 consultas), a pol\"+U(237)+\"tica DMARC e as chaves DKIM, do jeito que o resto da internet enxerga agora.\", \"margin:0 0 14px;line-height:1.5;font-size:14.5px;\"); var line0 = add(root0, \"div\", \"\", \"display:flex;gap:8px;flex-wrap:wrap;\"); function field(id, ph, flex) { var i = document.createElement(\"input\"); i.type = \"text\"; i.id = PFX + id; i.placeholder = ph; i.setAttribute(\"autocomplete\", \"off\"); i.setAttribute(\"autocapitalize\", \"off\"); i.setAttribute(\"spellcheck\", \"false\"); i.setAttribute(\"aria-label\", ph); i.setAttribute(\"style\", \"flex:\" + flex + \";min-width:0;width:auto;box-sizing:border-box;padding:10px 12px;border:1px solid #9aa7b8;border-radius:8px;font-size:16px;background:#ffffff;color:#0F172A;margin:0;\"); line0.appendChild(i); return i; } var inD = field(\"d\", \"seudominio.com.br\", \"2 1 220px\"); var inS = field(\"s\", \"Seletor (opcional)\", \"1 1 160px\"); var btn = add(line0, \"button\", \"Verificar\", \"flex:0 0 auto;padding:10px 20px;border:0;background:#0b3d91;color:#ffffff;border-radius:8px;cursor:pointer;font-weight:700;font-size:15px;\"); btn.type = \"button\"; btn.id = PFX + \"go\"; var exl = add(root0, \"div\", \"\", \"margin-top:8px;font-size:13px;color:#334155;\"); exl.appendChild(document.createTextNode(\"Exemplos: \")); var EXS = [\"google.com\", \"github.com\", \"microsoft.com\"]; for (var x0 = 0; x0 !== EXS.length; x0++) { var eb = add(exl, \"button\", EXS[x0], \"margin:2px;padding:3px 8px;border:1px solid #0b3d91;background:#ffffff;color:#0b3d91;border-radius:6px;cursor:pointer;font-size:12.5px;\"); eb.type = \"button\"; eb.setAttribute(\"data-d\", EXS[x0]); eb.addEventListener(\"click\", function () { inD.value = this.getAttribute(\"data-d\"); inS.value = \"\"; run(); }); } var st0 = add(root0, \"div\", \"\", \"margin-top:12px;font-size:14px;color:#334155;\"); st0.id = PFX + \"st\"; st0.setAttribute(\"aria-live\", \"polite\"); var out0 = add(root0, \"div\", \"\", \"margin-top:12px;\"); out0.id = PFX + \"out\"; out0.setAttribute(\"aria-live\", \"polite\"); add(root0, \"p\", \"As consultas v\"+U(227)+\"o do seu navegador ao DNS p\"+U(250)+\"blico do Google (ou da Cloudflare, se o Google n\"+U(227)+\"o responder), ent\"+U(227)+\"o voc\"+U(234)+\" v\"+U(234)+\" o que o resto da internet v\"+U(234)+\" agora. Depois de mudar um registro, o resultado novo pode levar at\"+U(233)+\" o tempo do TTL para aparecer.\", \"margin:14px 0 0;font-size:12.5px;color:#475569;line-height:1.5;\"); btn.addEventListener(\"click\", run); inD.addEventListener(\"keydown\", function (e) { if (e.key === \"Enter\") { run(); } }); inS.addEventListener(\"keydown\", function (e) { if (e.key === \"Enter\") { run(); } }); })();<\/script>\n\n\n\n<h2 class=\"wp-block-heading\">Como configurar o SPF e o DKIM no cPanel<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Primeiramente, acesse seu <a href=\"https:\/\/www.homehost.com.br\/blog\/dominio\/como-adicionar-um-dominio-hospedagem\/\">painel de controle cPanel<\/a>, e clique na op\u00e7\u00e3o <strong>Authentication<\/strong> ou <strong>Autentica\u00e7\u00e3o<\/strong>, dentro da aba Emails.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img fetchpriority=\"high\" decoding=\"async\" src=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg\" alt=\"Como configurar SPF e DKIM no cPanel\" class=\"wp-image-574\" width=\"1365\" height=\"655\" srcset=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg 1365w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-300x144.jpg 300w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-768x369.jpg 768w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-1024x491.jpg 1024w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-1x1.jpg 1w\" sizes=\"(max-width: 1365px) 100vw, 1365px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Este m\u00f3dulo do <a href=\"https:\/\/www.homehost.com.br\/blog\/tutoriais\/como-configurar-o-cpanel-whm\/\">cPanel ir\u00e1 lhe dar diversas op\u00e7\u00f5es de configura\u00e7\u00e3o<\/a>. Primeiramente, caso o status do SPF esteja Disabled (Desabilitado), clique em <strong>Enable (Habilitar)<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-2.jpg\" alt=\"Como configurar SPF e DKIM no cPanel 2\" class=\"wp-image-573\" width=\"1365\" height=\"657\" srcset=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-2.jpg 1365w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-2-300x144.jpg 300w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-2-768x370.jpg 768w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-2-1024x493.jpg 1024w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-2-1x1.jpg 1w\" sizes=\"(max-width: 1365px) 100vw, 1365px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">O <a href=\"https:\/\/www.homehost.com.br\/blog\/e-mail\/email-pro-configurando-mx-dkim-e-spf-no-cpanel\/\">cPanel possui configura\u00e7\u00f5es padr\u00e3o seguras para o SPF<\/a>. Uma vez tendo ele habilitado, seus emails j\u00e1 ter\u00e3o um grande aumento na entregabilidade.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Ap\u00f3s habilitar a op\u00e7\u00e3o, voc\u00ea ver\u00e1 esta mensagem de sucesso:<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-3.jpg\" alt=\"Como configurar SPF e DKIM no cPanel 3\" class=\"wp-image-575\" width=\"833\" height=\"339\" srcset=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-3.jpg 833w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-3-300x122.jpg 300w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-3-768x313.jpg 768w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-3-1x1.jpg 1w\" sizes=\"(max-width: 833px) 100vw, 833px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Depois de habilitar, volte ao <a href=\"#hh-spf\">verificador no in\u00edcio do artigo<\/a> para confirmar que os registros j\u00e1 est\u00e3o publicados. A mudan\u00e7a pode levar alguns minutos para aparecer. Para confirmar na pr\u00e1tica, envie um e-mail para uma conta sua no Gmail e cole o cabe\u00e7alho no <a href=\"https:\/\/www.homehost.com.br\/blog\/contas-de-email\/cabecalho-de-email\/#hh-hdr\">analisador de cabe\u00e7alho de e-mail<\/a>: ele mostra se o SPF e o DKIM passaram.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Explicando em detalhes o&nbsp;registro SPF<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">A linha de <a href=\"https:\/\/www.homehost.com.br\/blog\/tutoriais\/como-transferir-seu-site\/como-alterar-o-dns-de-um-dominio-com-net-ou-org\/\">configura\u00e7\u00e3o no DNS<\/a>, neste exemplo, ficou:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">v=spf1 +a +mx +ip4:177.85.98.220 ~all<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">O que quer dizer cada \u00edtem ?<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td>v=spf1<\/td><td>Especifica a vers\u00e3o 1 do sistema<\/td><\/tr><tr><td>+a<\/td><td>Autoriza o envio atrav\u00e9s do registro A do DNS. O registo A \u00e9, normalmente, o IP principal do servidor<\/td><\/tr><tr><td>+mx<\/td><td>Similar ao item anterior, autorizando o envio atrav\u00e9s do MX (Mail Exchanger).<\/td><\/tr><tr><td>+ip4:177.85.98.220<\/td><td>Autoriza o envio atrav\u00e9s do IP do site<\/td><\/tr><tr><td>~all<\/td><td>O sinal ~ &nbsp;Informa que todos os demais IPs est\u00e3o proibidos de <a href=\"https:\/\/www.homehost.com.br\/blog\/produtos-e-servicos\/quantos-emails-posso-enviar-por-hora-na-hospedagem-compartilhada\/\">enviar emails<\/a>.<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">A sintaxe pode ser validada atrav\u00e9s&nbsp;do pr\u00f3prio cPanel.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Configura\u00e7\u00f5es avan\u00e7adas de SPF no cPanel<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">O <a href=\"https:\/\/www.homehost.com.br\/blog\/e-mail\/email-pro-configurando-mx-dkim-e-spf-no-cpanel\/\">cPanel tamb\u00e9m oferece possibilidades de configura\u00e7\u00f5es<\/a> avan\u00e7adas.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">A op\u00e7\u00e3o a seguir \u00e9 \u00fatil, para caso voc\u00ea tenha servidores <a href=\"https:\/\/www.homehost.com.br\/blog\/dominio\/como-adicionar-um-dominio-hospedagem\/\">adicionais que tamb\u00e9m enviam emails atrav\u00e9s do seu dom\u00ednio<\/a>. Por exemplo, um servidor externo, com um IP diferente, que fa\u00e7a o envio de <a href=\"https:\/\/www.homehost.com.br\/blog\/contas-de-email\/como-usar-o-gmail-para-acessar-emails-meu-site-cpanel\/\">emails atrav\u00e9s do seu servidor cPanel<\/a>. J\u00e1 quando todo o e-mail do dom\u00ednio fica no Google Workspace ou no Microsoft 365, o SPF \u00e9 o desses servi\u00e7os: veja o <a href=\"https:\/\/www.homehost.com.br\/blog\/contas-de-email\/servidor-mx-externo-google-apps\/#hh-gws\">SPF e o DKIM do Google Workspace e do Microsoft 365<\/a>.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-4.jpg\" alt=\"Como configurar SPF e DKIM no cPanel 4\" class=\"wp-image-576\" width=\"1290\" height=\"157\" srcset=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-4.jpg 1290w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-4-300x37.jpg 300w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-4-768x93.jpg 768w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-4-1024x125.jpg 1024w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-4-1x1.jpg 1w\" sizes=\"(max-width: 1290px) 100vw, 1290px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Servidores MX adicionais tamb\u00e9m podem ser configurados:<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-5.jpg\" alt=\"Como configurar SPF e DKIM no cPanel 5\" class=\"wp-image-577\" width=\"1290\" height=\"131\" srcset=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-5.jpg 1290w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-5-300x30.jpg 300w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-5-768x78.jpg 768w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-5-1024x104.jpg 1024w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-5-1x1.jpg 1w\" sizes=\"(max-width: 1290px) 100vw, 1290px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Pode-se adicionar a permiss\u00e3o de envio para blocos inteiros de IPs:<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-6.jpg\" alt=\"Como configurar SPF e DKIM no cPanel 6\" class=\"wp-image-578\" width=\"1290\" height=\"101\" srcset=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-6.jpg 1290w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-6-300x23.jpg 300w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-6-768x60.jpg 768w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-6-1024x80.jpg 1024w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-6-1x1.jpg 1w\" sizes=\"(max-width: 1290px) 100vw, 1290px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Use listas de include, para caso voc\u00ea envie emails atrav\u00e9s de outros dom\u00ednios:<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-7.jpg\" alt=\"Como configurar SPF e DKIM no cPanel 7\" class=\"wp-image-579\" width=\"1290\" height=\"108\" srcset=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-7.jpg 1290w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-7-300x25.jpg 300w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-7-768x64.jpg 768w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-7-1024x86.jpg 1024w, https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel-7-1x1.jpg 1w\" sizes=\"(max-width: 1290px) 100vw, 1290px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Com o SPF e o DKIM funcionando, o pr\u00f3ximo passo \u00e9 o DMARC \u2014 monte o seu no nosso <a href=\"https:\/\/www.homehost.com.br\/blog\/contas-de-email\/spf-dkim-dmarc\/\">gerador de registro DMARC<\/a>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n","protected":false},"excerpt":{"rendered":"<p>O cPanel possui, por padr\u00e3o, a configura\u00e7\u00e3o de SPF e DKIM para todas as zonas de DNS. Estes s\u00e3o mecanismos de verifica\u00e7\u00e3o que ajuda a combater spam. Tento o SPF configurado corretamente em seu servidor, ir\u00e1 aumentar consideravelmente a entrega de emails, e evitar que eles caiam em caixa de spam (lixo eletr\u00f4nico). SPF significa [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_helpful_status":1,"_lmt_disableupdate":"","_lmt_disable":"","_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[16,90,6],"tags":[125,18,123,92,124,96,122],"class_list":["post-572","post","type-post","status-publish","format-standard","hentry","category-contas-de-email","category-email-marketing","category-tutoriais","tag-caixa-de-spam","tag-cpanel","tag-dkim","tag-email-marketing","tag-lixo-eletronico","tag-newsletters","tag-spf"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.2 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis | Homehost<\/title>\n<meta name=\"description\" content=\"Veja se o seu dom\u00ednio j\u00e1 tem SPF, DKIM e DMARC no verificador gr\u00e1tis e aprenda a configurar o SPF e o DKIM no cPanel, passo a passo.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/\" \/>\n<meta property=\"og:locale\" content=\"pt_BR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis | Homehost\" \/>\n<meta property=\"og:description\" content=\"Veja se o seu dom\u00ednio j\u00e1 tem SPF, DKIM e DMARC no verificador gr\u00e1tis e aprenda a configurar o SPF e o DKIM no cPanel, passo a passo.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/\" \/>\n<meta property=\"og:site_name\" content=\"Homehost\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/Homehost\/\" \/>\n<meta property=\"article:published_time\" content=\"2016-05-01T23:08:42+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-11-12T23:40:21+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1365\" \/>\n\t<meta property=\"og:image:height\" content=\"655\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Gustavo Gallas\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@Homehost\" \/>\n<meta name=\"twitter:site\" content=\"@Homehost\" \/>\n<meta name=\"twitter:label1\" content=\"Escrito por\" \/>\n\t<meta name=\"twitter:data1\" content=\"Gustavo Gallas\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. tempo de leitura\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutos\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/\"},\"author\":{\"name\":\"Gustavo Gallas\",\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/#\\\/schema\\\/person\\\/df8002f43fc55e7f4e132abb2a6ddbc4\"},\"headline\":\"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis\",\"datePublished\":\"2016-05-01T23:08:42+00:00\",\"dateModified\":\"2026-11-12T23:40:21+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/\"},\"wordCount\":584,\"publisher\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2016\\\/05\\\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg\",\"keywords\":[\"caixa de spam\",\"cpanel\",\"dkim\",\"email marketing\",\"lixo eletr\u00f4nico\",\"newsletters\",\"spf\"],\"articleSection\":[\"Contas de email\",\"Email marketing\",\"Tutoriais\"],\"inLanguage\":\"pt-BR\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/\",\"url\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/\",\"name\":\"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis | Homehost\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2016\\\/05\\\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg\",\"datePublished\":\"2016-05-01T23:08:42+00:00\",\"dateModified\":\"2026-11-12T23:40:21+00:00\",\"description\":\"Veja se o seu dom\u00ednio j\u00e1 tem SPF, DKIM e DMARC no verificador gr\u00e1tis e aprenda a configurar o SPF e o DKIM no cPanel, passo a passo.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/#breadcrumb\"},\"inLanguage\":\"pt-BR\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2016\\\/05\\\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg\",\"contentUrl\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2016\\\/05\\\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg\",\"width\":1365,\"height\":655},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/tutoriais\\\/email-marketing\\\/como-configurar-spf-e-dkim-no-cpanel\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"In\u00edcio\",\"item\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/\",\"name\":\"Homehost\",\"description\":\"Hospedagem De Sites\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"pt-BR\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/#organization\",\"name\":\"Homehost\",\"url\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/10\\\/logo-detalhes.png\",\"contentUrl\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/10\\\/logo-detalhes.png\",\"width\":150,\"height\":48,\"caption\":\"Homehost\"},\"image\":{\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/Homehost\\\/\",\"https:\\\/\\\/x.com\\\/Homehost\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.homehost.com.br\\\/blog\\\/#\\\/schema\\\/person\\\/df8002f43fc55e7f4e132abb2a6ddbc4\",\"name\":\"Gustavo Gallas\",\"description\":\"Analista de sistemas, formado pela PUC-Rio. Programador, gestor de redes e diretor da empresa Homehost. Pai do B\u00f3ris, seu pet de estima\u00e7\u00e3o. Gosta de rock'n'roll, cerveja artesanal e de escrever sobre assuntos t\u00e9cnicos. Contato: gustavo.blog@homehost.com.br\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis | Homehost","description":"Veja se o seu dom\u00ednio j\u00e1 tem SPF, DKIM e DMARC no verificador gr\u00e1tis e aprenda a configurar o SPF e o DKIM no cPanel, passo a passo.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/","og_locale":"pt_BR","og_type":"article","og_title":"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis | Homehost","og_description":"Veja se o seu dom\u00ednio j\u00e1 tem SPF, DKIM e DMARC no verificador gr\u00e1tis e aprenda a configurar o SPF e o DKIM no cPanel, passo a passo.","og_url":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/","og_site_name":"Homehost","article_publisher":"https:\/\/www.facebook.com\/Homehost\/","article_published_time":"2016-05-01T23:08:42+00:00","article_modified_time":"2026-11-12T23:40:21+00:00","og_image":[{"width":1365,"height":655,"url":"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg","type":"image\/jpeg"}],"author":"Gustavo Gallas","twitter_card":"summary_large_image","twitter_creator":"@Homehost","twitter_site":"@Homehost","twitter_misc":{"Escrito por":"Gustavo Gallas","Est. tempo de leitura":"5 minutos"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/#article","isPartOf":{"@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/"},"author":{"name":"Gustavo Gallas","@id":"https:\/\/www.homehost.com.br\/blog\/#\/schema\/person\/df8002f43fc55e7f4e132abb2a6ddbc4"},"headline":"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis","datePublished":"2016-05-01T23:08:42+00:00","dateModified":"2026-11-12T23:40:21+00:00","mainEntityOfPage":{"@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/"},"wordCount":584,"publisher":{"@id":"https:\/\/www.homehost.com.br\/blog\/#organization"},"image":{"@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/#primaryimage"},"thumbnailUrl":"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg","keywords":["caixa de spam","cpanel","dkim","email marketing","lixo eletr\u00f4nico","newsletters","spf"],"articleSection":["Contas de email","Email marketing","Tutoriais"],"inLanguage":"pt-BR"},{"@type":"WebPage","@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/","url":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/","name":"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis | Homehost","isPartOf":{"@id":"https:\/\/www.homehost.com.br\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/#primaryimage"},"image":{"@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/#primaryimage"},"thumbnailUrl":"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg","datePublished":"2016-05-01T23:08:42+00:00","dateModified":"2026-11-12T23:40:21+00:00","description":"Veja se o seu dom\u00ednio j\u00e1 tem SPF, DKIM e DMARC no verificador gr\u00e1tis e aprenda a configurar o SPF e o DKIM no cPanel, passo a passo.","breadcrumb":{"@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/#breadcrumb"},"inLanguage":"pt-BR","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/"]}]},{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/#primaryimage","url":"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg","contentUrl":"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2016\/05\/Como-configurar-SPF-e-DKIM-no-cPanel.jpg","width":1365,"height":655},{"@type":"BreadcrumbList","@id":"https:\/\/www.homehost.com.br\/blog\/tutoriais\/email-marketing\/como-configurar-spf-e-dkim-no-cpanel\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"In\u00edcio","item":"https:\/\/www.homehost.com.br\/blog\/"},{"@type":"ListItem","position":2,"name":"SPF e DKIM: como configurar no cPanel e verificador gr\u00e1tis"}]},{"@type":"WebSite","@id":"https:\/\/www.homehost.com.br\/blog\/#website","url":"https:\/\/www.homehost.com.br\/blog\/","name":"Homehost","description":"Hospedagem De Sites","publisher":{"@id":"https:\/\/www.homehost.com.br\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.homehost.com.br\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"pt-BR"},{"@type":"Organization","@id":"https:\/\/www.homehost.com.br\/blog\/#organization","name":"Homehost","url":"https:\/\/www.homehost.com.br\/blog\/","logo":{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/www.homehost.com.br\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2022\/10\/logo-detalhes.png","contentUrl":"https:\/\/www.homehost.com.br\/blog\/wp-content\/uploads\/2022\/10\/logo-detalhes.png","width":150,"height":48,"caption":"Homehost"},"image":{"@id":"https:\/\/www.homehost.com.br\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/Homehost\/","https:\/\/x.com\/Homehost"]},{"@type":"Person","@id":"https:\/\/www.homehost.com.br\/blog\/#\/schema\/person\/df8002f43fc55e7f4e132abb2a6ddbc4","name":"Gustavo Gallas","description":"Analista de sistemas, formado pela PUC-Rio. Programador, gestor de redes e diretor da empresa Homehost. Pai do B\u00f3ris, seu pet de estima\u00e7\u00e3o. Gosta de rock'n'roll, cerveja artesanal e de escrever sobre assuntos t\u00e9cnicos. Contato: gustavo.blog@homehost.com.br"}]}},"modified_by":"ad_hmhst","jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/posts\/572","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/comments?post=572"}],"version-history":[{"count":17,"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/posts\/572\/revisions"}],"predecessor-version":[{"id":18683,"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/posts\/572\/revisions\/18683"}],"wp:attachment":[{"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/media?parent=572"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/categories?post=572"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.homehost.com.br\/blog\/wp-json\/wp\/v2\/tags?post=572"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}