> My biggest concern is that nodes can access other nodes resources stored in
> PuppetDB, which effectively means that parameters like passwords and other
> sensitive information is exposed.
If the data is not exported this shouldn't be the case ordinarily.
Obviously though if your content is uncontrolled it is possible for
someone to use a function from the puppet master to query data (FYI -
functions run on the puppetmaster, not the agents), which is why
content changes should be revision controlled and verified for sanity
before merging in most cases.
From an REST API stand-point, switching on SSL provides certificate
verification, and won't allow clients who use certificates that are
not signed by the CA to connect. However, all clients have such CA's -
so if you want to restrict this you need to set a whitelist in the
jetty.ini of your PuppetDB:
http://docs.puppetlabs.com/puppetdb/1.1/configure.html#certificate-whitelist
In normal circumstances only the puppetmasters should be in such a
list, plus any API consumer you may be running internally. Basic local
box firewalling or network firewalling of the PuppetDB host is also a
good idea. As mentioned though, neither the whitelist or any
firewalling constrains the API access to read only access only - a
proxy would be better at doing this today however as the API
end-points for read and write are quite different (due to our CQRS
separation) and should be easy enough to segment.
> I also wonder if PuppetDB has any sense of environments? What I mean, does
> it separate data in environments, so for example, NODE1 being in development
> environment can access NODE2's resources which is in production environment?
No it does not. At the moment you need to provide multiple PuppetDB's
- one for each environment. There is a ticket to provide more
environment awareness within queries here:
http://projects.puppetlabs.com/issues/17785
But no mention of security constraints around environments.
This is an interesting topic though, how would you like to see it work
from your perspective?
ken.