InterviewSolution
| 1. |
Why Shouldn't I Use Autosign For All My Clients? |
|
Answer» It is very tempting to enable autosign for all nodes, as it cuts down on the manual steps required to bootstrap a new node (or indeed to move it to a new puppet master). Typically this would be done with a *.example.com or even * in the autosign.conf FILE. This however can be very dangerous as it can enable a node to masquerade as another node, and GET the configuration INTENDED for that node. The reason for this is that the node chooses the certificate COMMON name (‘CN’ – usually its fqdn, but this is fully configurable), and the puppet master then uses this CN to look up the node definition to serve. The certificate itself is stored, so two nodes could not connect with the same CN (eg alice.example.com), but this is not the problem. The problem lies in the fact that the puppet master does not make a 1-1 mapping between a node and the first certificate it SAW for it, and hence multiple certificates can map to the same node. for example:
Without autosigning, it would be apparent that bob was trying to get alice’s configuration – as the puppet cert process lists the full fqdn/CN presented. With autosign turned on, bob silently retrieves alice’s configuration. It is very tempting to enable autosign for all nodes, as it cuts down on the manual steps required to bootstrap a new node (or indeed to move it to a new puppet master). Typically this would be done with a *.example.com or even * in the autosign.conf file. This however can be very dangerous as it can enable a node to masquerade as another node, and get the configuration intended for that node. The reason for this is that the node chooses the certificate common name (‘CN’ – usually its fqdn, but this is fully configurable), and the puppet master then uses this CN to look up the node definition to serve. The certificate itself is stored, so two nodes could not connect with the same CN (eg alice.example.com), but this is not the problem. The problem lies in the fact that the puppet master does not make a 1-1 mapping between a node and the first certificate it saw for it, and hence multiple certificates can map to the same node. for example: Without autosigning, it would be apparent that bob was trying to get alice’s configuration – as the puppet cert process lists the full fqdn/CN presented. With autosign turned on, bob silently retrieves alice’s configuration. |
|