6 ms·
How come there is none? Set up DNS in whatever way you prefer. Give each service a name. Create a self-signed root cert, push it to all machines via whatever
by nine_k 5y ago
How come there is none?
Set up DNS in whatever way you prefer. Give each service a name.
Create a self-signed root cert, push it to all machines via whatever administrative update tool you use, or just walk around a small office with a flash drive.
Create an intermediate cert. From it, create certs for all services that need one, and push them.
Voilá, you can use https without warnings.
Am I missing something?
- beebmam 5y agoThis is exactly right. PKI is for everyone. It's really quite simple once you learn how it works! Here's a great explanation that covers a ton: https://smallstep.com/blog/everything-pki/ https://smallstep.com/blog/everything-pki/
- schoen 5y agoOne SmallStep for a LAN, one giant leap for LANkind?
- paulddraper 5y ago> flash drive Make sure to get the mobile devices too. But yeah, that is the solution. Works great on all platforms. --- The only time you run into problems with tech is if you try MITM/corporate proxy shenanigans.
- nine_k 5y agoIf you have a really small office with 10 desktops / laptops, you may consider that deploying puppet / chef / saltstack / whatever is overkill. Walking around with a flash drive is just faster.
- chousuke 5y agoBut it's not more consistent if you need to change something. Having declarative desired state configuration is useful for any environment, even when n = 1. I would definitely deploy a configuration management solution for 10 hosts; it takes a couple hours of work to do properly and you can do it without a server initially (though a central server provides other benefits)
- flowerlad 5y agoThis requires a level of expertise that is not available at most small businesses. Going around to each machine with a flash drive is not practical either, especially since this is not a one time thing (because machines die and are replaced).
- nine_k 5y agoThis is a good call. I thought Windows Server (or maybe just Pro?) makes this easy enough: AD must provide DNS and a CA, and any DC should be able to provide startup scripts to every workstation to install the certificates, set hostnames, etc. For a more diverse office, with a mix of Macs and Windows machines, maybe there is a niche of an app server box / vm, or even router software that also handles that.
- Jonnax 5y agoIf the expertise isn't there then they should use SaaS solutions. There's plenty that aren't expensive. And they don't need to roll their own software.
- flowerlad 5y ago> If the expertise isn't there then they should use SaaS solutions. Or browser makers can invent a solution for this scenario. That's what software companies do — identify problems that need solving, then solve them. Strive constantly to make things easier.
- gregmac 5y ago> Create a self-signed root cert, The OP was specifically talking about a small business with no IT. I'd say it applies equally to a home. I'm sure there's some ways to manage all the non-domain-connected computers, phones, tablets, chromebooks and other stuff in my house (which is going to vary by ecosystem) and "push" a root cert out, but I sure don't want to spend the time to learn all that just to secure a web app I have running. The magic of Lets Encrypt is you run something on the server you're securing, and a few minutes later you're done -- it works with everything.
- 5Qn8mNbc2FNCiVV 5y agoAt home you either don't need to secure it or if you do, you'll have to learn it. And when you are in a small business with no IT and want to share salary data, well, you can print it and give it to the employer in an envelope. No need to go digital when doing it analog is not a big problem
- Helmut10001 5y agoIf self-signed certificates are too much, then perhaps this is, too - You can use Let's Encrypt SSL certs locally for the Intranet/LAN as well. Get a wildcard SSL cert for a lan-reserved subdomain of a TLD (e.g. local.mytld.com) through a DNS API (e.g. cloudflare - any other DNS API works, too). Override DNS entries in your router to redirect to local services, e.g.: cloud.mytld.com -> 192.168.0.10 gitlab.mytld.com -> 192.168.0.11 You can have your services individually query Let's encrypt (ACME), or have your router get the wildcard cert and deploy this locally (e.g. ssh, ftp). No one external can reach your services, no one external knows how your services are called (in case of wildcard certs). You do not need to open any port for this.
- magicalhippo 5y agoInspired by this thread I just did this, except not with the wildcard. I have a droplet at Digital Ocean, so I used their DNS service. I configured some CNAME records for the local services, pointing to the internal names[1]. I then configured my PiHole with a local DNS CNAME record, pointing service.local.example.com to service.localdomain. Since my PiHole is not the DHCP server, I had to add a local DNS record for service.localdomain which matched the static IP that my router gives out. It seems the conditional forwarding done by PiHole happens earlier in the resolution process. I could then configure my services to use the DNS challenge for service.local.example.com, using the DO plugin for certbot[2] or just acme.sh[3], depending on what was available. I didn't get it to work immediately on Android devices, until I discovered that Android only uses IPv6 DNS servers if it has an IPv6 address, and I hadn't configured that in my router. So added the static ULA address of the PiHole lease to the DHCPv6 DNS server announcement[4]. Was a bit of fiddling since I'm a networking nub, but went smoother than I had feared. Not sure how to best distribute certificates though, if I had found a way I could let the router do all the renewals. [1]: Not sure if this is needed but didn't bother experimenting with removing it yet. [2]: https://certbot-dns-digitalocean.readthedocs.io/en/stable/ https://certbot-dns-digitalocean.readthedocs.io/en/stable/ [3]: https://github.com/acmesh-official/acme.sh/wiki/dnsapi#20-use-digitalocean-api-native https://github.com/acmesh-official/acme.sh/wiki/dnsapi#20-us... [4]: https://openwrt.org/docs/techref/odhcpd#dhcp_section https://openwrt.org/docs/techref/odhcpd#dhcp_section
- maxdamantus 5y agoI don't like this solution, mainly because installing custom CA certificates increases the chance of a MITM attack involving other services. Any trusted "intermediate" certificate in X.509 is allowed to be a CA, so it can be used to sign certificates for any domain. If an attacker gets the private key for that certificate which has been manually installed on everyone's PC, they can impersonate any website, including external web mail, etc, until someone manually removes the certificate again from all the PCs. In the past when we've used custom CAs for test environments, I've preferred to just deal with the TLS warnings instead of trusting a non-standard CA on the computers I use.
- pabs3 5y agoPerhaps the CA could be constrained to only sign certs for *.foo.local?
- maxdamantus 5y agoAs far as I know, X.509 doesn't currently have such a concept, and web browsers don't have it either. If you install a certificate as a CA, it is a CA for any domain. If a CA signs another certificate with the "Certificate Sign" flag (intermediate certificate), that other certificate is also a CA for any domain. The subject name fields are not used when validating authority as a CA.
- pabs3 5y agoWell, there is the name constraints mechanism, but I'm not sure how well supported that is in TLS libraries and web browsers. https://datatracker.ietf.org/doc/html/rfc5280#section-4.2.1.10 https://datatracker.ietf.org/doc/html/rfc5280#section-4.2.1.... https://timothy-quinn.com/name-constraints-in-x509-certificates/ https://timothy-quinn.com/name-constraints-in-x509-certifica... https://www.sysadmins.lv/blog-en/x509-name-constraints-certificate-extension-all-you-should-know.aspx https://www.sysadmins.lv/blog-en/x509-name-constraints-certi... https://blog.codekills.net/2012/04/08/adventures-in-x509-the-utterly-ignored-nameconstraints/ https://blog.codekills.net/2012/04/08/adventures-in-x509-the...
- KronisLV 5y ago> We need a simple solution for this... I think that "simple" is the key word here. Running your own DNS server isn't necessarily as easy as just using something like NameCheap or another domain name provider with a DNS manager. There probably are somewhat easy DNS servers out there, but in the case of BIND, the configuration format feels obtuse, things break in interesting ways and you'll probably need at least 2 of those servers for more resiliency. Furthermore, you are assuming that there even is an administrative tool that can push certificates there in the first place, which isn't necessarily true in many environments. And then you also run into the fact that now you need to manage a PKI with all of the certificates, CSRs and now you'll also spend some of your time renewing all of the certificates. Contrast all of those processes with just having the following in your Caddy web server's configuration (for public sites): my-public-site.com { reverse_proxy 10.0.4.5:8080 } We'd need something equally simple: https://caddyserver.com/docs/automatic-https https://caddyserver.com/docs/automatic-https
- nine_k 5y agoBIND is just a wrong scale. Think tinydns or dnsmasq.
- iso1631 5y ago> Create a self-signed root cert, push it to all machines via whatever administrative update tool you use, or just walk around a small office with a flash drive. Congratulations, you've just installed a massive security risk in an organisation that barely understands the word certificate
- WhyNotHugo 5y agoDNS server might be an overkill, mDNS should work fine for a small org.