phorge/src
epriestley adf209e655 When registering a device, write a device ID
Summary:
Ref T5833. In some cases, we need to know if an Almanac device is the localhost or not, so we can either handle or forward the request.

To accomplish this, write a device ID when running `bin/almanac register`.

Using `--allow-key-reuse` and `--identify-as`, multiple devices are permitted to //authenticate// as one device but //identify// as different devices. In the Phacility cluster, this allows all the `repoXXX` machines to have one keypair (making key management much easier) but still work as separate devices. This is an advanced feature; normal installs with 1-3 hosts would just generate a key + device per host and identify/authenticate as the same device.

Test Plan: Ran commands with lots of flags like `PHACILITY_INSTANCE=local sudo -E ./bin/almanac register --device daemon.phacility.net --private-key ~/dev/core/conf/keys/daemon.key --force --allow-key-reuse --identify-as local001.phacility.net`. Got a good result from `AlmanacKeys::getDeviceID()` afterward.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T5833

Differential Revision: https://secure.phabricator.com/D11452
2015-01-22 16:06:04 -08:00
..
__tests__ Use PhutilLibraryTestCase 2015-01-07 07:38:08 +11:00
aphront Fix an issue with clearing cookies when a cookie prefix is set 2015-01-08 16:24:34 -08:00
applications When registering a device, write a device ID 2015-01-22 16:06:04 -08:00
docs OAuthServer - harden things up a bit 2015-01-09 11:04:18 -08:00
extensions
infrastructure When storage is not initialized, write the error message to stderr instead of stdout 2015-01-20 14:14:44 -08:00
view Fix mobile action menus in Phriction 2015-01-19 12:42:05 -08:00
__phutil_library_init__.php
__phutil_library_map__.php Rename DifferentialHunk subclasses for consistency 2015-01-23 07:17:04 +11:00