Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove IAS SPID and IAS API KEY #3615

Merged
merged 1 commit into from
Oct 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 0 additions & 25 deletions .github/workflows/mobilecoin-workflow-dev-setup-environment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,6 @@ on:
DEV_FOG_REPORT_SIGNING_CERT_KEY:
description: "Fog Report signing cert key"
required: true
DEV_IAS_KEY:
description: "IAS"
required: true
DEV_IAS_SPID:
description: "IAS"
required: true
DEV_KEYS_SEED_FOG:
description: "static wallet seed"
required: true
Expand Down Expand Up @@ -103,24 +97,12 @@ on:
IP_INFO_TOKEN:
description: "ipinfo.io token for authenticated access"
required: true
MAIN_IAS_KEY:
description: "MainNet IAS"
required: true
MAIN_IAS_SPID:
description: "MainNet IAS"
required: true
MAIN_TOKENS_CONFIG_V1_JSON:
description: "MainNet signed tokens config json"
required: true
MAIN_TOKENS_CONFIG_V2_JSON:
description: "MainNet signed tokens config json"
required: true
TEST_IAS_KEY:
description: "TestNet IAS"
required: true
TEST_IAS_SPID:
description: "TestNet IAS"
required: true
TEST_TOKENS_CONFIG_V1_JSON:
description: "TestNet signed tokens config json"
required: true
Expand Down Expand Up @@ -224,15 +206,8 @@ jobs:

# We're only deploying to the dev cluster here.
# We want to still point at dev values for buckets and certs.
# We need "production" IAS creds to start up test/main enclaves.
- name: Generate environment values file
env:
DEV_IAS_KEY: ${{ secrets.DEV_IAS_KEY }}
DEV_IAS_SPID: ${{ secrets.DEV_IAS_SPID }}
MAIN_IAS_KEY: ${{ secrets.MAIN_IAS_KEY }}
MAIN_IAS_SPID: ${{ secrets.MAIN_IAS_SPID }}
TEST_IAS_KEY: ${{ secrets.TEST_IAS_KEY }}
TEST_IAS_SPID: ${{ secrets.TEST_IAS_SPID }}
LEDGER_AWS_ACCESS_KEY_ID: ${{ secrets.DEV_LEDGER_AWS_ACCESS_KEY_ID }}
LEDGER_AWS_SECRET_ACCESS_KEY: ${{ secrets.DEV_LEDGER_AWS_SECRET_ACCESS_KEY }}
FOG_REPORT_SIGNING_CERT: ${{ secrets.DEV_FOG_REPORT_SIGNING_CERT }}
Expand Down
4 changes: 0 additions & 4 deletions .internal-ci/docker/entrypoints/node_hw.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@
# MC_CLIENT_RESPONDER_ID - fully qualified name:port that fronts the client port
# example client1.test.mobilecoin.com:443
# MC_MSG_SIGNER_KEY - private key for signing messages
# MC_IAS_API_KEY - Intel IAS API key
# MC_IAS_SPID - Intel IAS spid

# Optional Vars consensus-service
# MC_TX_SOURCE_URL - http url to retrieve archive (s3) blocks for node
Expand Down Expand Up @@ -105,8 +103,6 @@ then
is_set MC_PEER_RESPONDER_ID
is_set MC_CLIENT_RESPONDER_ID
is_set MC_MSG_SIGNER_KEY
is_set MC_IAS_API_KEY
is_set MC_IAS_SPID
is_set MC_DEST
is_set AWS_ACCESS_KEY_ID
is_set AWS_SECRET_ACCESS_KEY
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ is_set MC_BRANCH
is_set MC_PEER_RESPONDER_ID
is_set MC_CLIENT_RESPONDER_ID
is_set MC_MSG_SIGNER_KEY
is_set MC_IAS_API_KEY
is_set MC_IAS_SPID

# Default vars
export MC_PEER_LISTEN_URI=${MC_PEER_LISTEN_URI:-"insecure-mcp://0.0.0.0:8443/"}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,6 @@ spec:
name: {{ include "consensusNode.ledgerDistribution.secret.name" . }}
- secretRef:
name: {{ include "consensusNode.msgSignerKey.secret.name" . }}
- secretRef:
name: ias
- configMapRef:
name: {{ include "consensusNode.nodeConfig.configMap.name" . }}
- secretRef:
Expand Down
3 changes: 0 additions & 3 deletions .internal-ci/helm/consensus-node/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,6 @@ mcCoreCommonConfig:
enabled: false
# clientAuth:
# token: ''
# ias:
# key: ''
# spid: ''
# mobileCoinNetwork:
# network: ''
# partner: ''
Expand Down
15 changes: 0 additions & 15 deletions .internal-ci/helm/fog-ingest/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,21 +24,6 @@ The peer list generation happens when the chart is generated. In order to scale

Configure a `values.yaml` file or pre-populate your namespace with the following ConfigMaps and Secrets.

- `ias`

Intel spid and primary or secondary key.

```yaml
apiVersion: v1
kind: Secret
metadata:
name: ias
type: Opaque
stringData:
key: <primary or secondary key>
spid: <spid>
```

- `sentry`

Sentry service alert and error monitoring
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,6 @@ spec:
envFrom:
- configMapRef:
name: fog-ingest
- secretRef:
name: ias
- secretRef:
name: ipinfo
optional: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ data:
--pubkey-expiry-window %(ENV_FOG_PUBKEY_EXPIRY_WINDOW)s
--peers {{ include "fogIngest.peerURLs" . }}
--local-node-id %(ENV_LOCAL_NODE_ID)s
--ias-spid %(ENV_IAS_SPID)s
--ias-api-key %(ENV_IAS_API_KEY)s
--ledger-db /fog-data/ledger
--watcher-db /fog-data/watcher
--client-listen-uri insecure-fog-ingest://0.0.0.0:3226/
Expand Down
15 changes: 0 additions & 15 deletions .internal-ci/helm/fog-services/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,6 @@ Configure a `values.yaml` file or pre-populate your namespace with the following
network: testnet
```

- `ias`

Intel spid and primary or secondary key.

```yaml
apiVersion: v1
kind: Secret
metadata:
name: ias
type: Opaque
stringData:
key: <primary or secondary key>
spid: <spid>
```

- `sentry`

Sentry service alert and error monitoring
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,6 @@ spec:
- name: mgmt-http
containerPort: 8000
envFrom:
- secretRef:
name: ias
- configMapRef:
# This is installed from the fog-services-config chart or Terraform
name: fog-ledger
Expand Down Expand Up @@ -349,8 +347,6 @@ spec:
- name: mgmt-http
containerPort: 8000
envFrom:
- secretRef:
name: ias
- configMapRef:
# Configmap is created by fog-services chart, or Terraform
name: fog-ledger
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,6 @@ spec:
- configMapRef:
# This is pre-installed from the fog-services-config chart or Terraform
name: fog-view
- secretRef:
name: ias
startupProbe:
grpc:
port: 3225
Expand Down Expand Up @@ -304,8 +302,6 @@ spec:
envFrom:
- configMapRef:
name: fog-view
- secretRef:
name: ias
env:
- name: RUST_BACKTRACE
value: {{ $.Values.fogView.rust.backtrace | quote }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ data:
--client-auth-token-secret "%(ENV_CLIENT_AUTH_TOKEN_SECRET)s"
--client-auth-token-max-lifetime 31536000
{{- end }}
--ias-spid %(ENV_IAS_SPID)s
--ias-api-key %(ENV_IAS_API_KEY)s
--admin-listen-uri insecure-mca://127.0.0.1:8001/

stdout_logfile=/dev/fd/1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ data:
--watcher-db /fog-data/watcher
--client-responder-id "%(ENV_HOSTNAME)s.{{ include "fogServices.fullname" . }}-fog-ledger-store.{{ .Release.Namespace }}.svc.cluster.local:3228"
--client-listen-uri insecure-key-image-store://0.0.0.0:3228/?responder-id="%(ENV_HOSTNAME)s.{{ include "fogServices.fullname" . }}-fog-ledger-store.{{ .Release.Namespace }}.svc.cluster.local:3228"
--ias-spid %(ENV_IAS_SPID)s
--ias-api-key %(ENV_IAS_API_KEY)s
--admin-listen-uri insecure-mca://127.0.0.1:8001/

stdout_logfile=/dev/fd/1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ data:
command=/usr/bin/fog_view_server
--client-listen-uri insecure-fog-view-store://0.0.0.0:3225/?responder-id=%(ENV_HOSTNAME)s.{{ include "fogServices.fullname" . }}-fog-view-store.{{ .Release.Namespace }}:3225
--client-responder-id "%(ENV_HOSTNAME)s.{{ include "fogServices.fullname" . }}-fog-view-store.{{ .Release.Namespace }}:3225"
--ias-spid %(ENV_IAS_SPID)s
--ias-api-key %(ENV_IAS_API_KEY)s
--admin-listen-uri insecure-mca://127.0.0.1:8001/

stdout_logfile=/dev/fd/1
Expand Down
13 changes: 0 additions & 13 deletions .internal-ci/helm/mc-core-common-config/templates/ias-secret.yaml

This file was deleted.

4 changes: 0 additions & 4 deletions .internal-ci/helm/mc-core-common-config/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@
clientAuth:
token: ''

ias:
key: ''
spid: ''

mobileCoinNetwork:
network: ''
partner: ''
Expand Down
11 changes: 0 additions & 11 deletions .internal-ci/helm/watcher/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -63,17 +63,6 @@ Create the name of the service account to use
{{- end }}
{{- end }}

{{/*
IAS Secret Name
*/}}
{{- define "chart.iasSecretName" -}}
{{- if .Values.ias.secret.external }}
{{- .Values.ias.secret.name }}
{{- else }}
{{- include "chart.fullname" . }}-{{ .Values.ias.secret.name }}
{{- end }}
{{- end }}

{{/*
Sentry ConfigMap Name
*/}}
Expand Down
25 changes: 0 additions & 25 deletions .internal-ci/util/generate_dev_values.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,28 +31,6 @@ then
tokens_signed_json=$(cat "${TOKENS_PATH}")
fi

echo "Get config for network based semver tag" >&2
network=$(get_network_tier "${1}")
case "${network}" in
test)
IAS_KEY=${TEST_IAS_KEY}
IAS_SPID=${TEST_IAS_SPID}
;;
main)
IAS_KEY=${MAIN_IAS_KEY}
IAS_SPID=${MAIN_IAS_SPID}
;;
dev)
IAS_KEY=${DEV_IAS_KEY}
IAS_SPID=${DEV_IAS_SPID}
;;
*)
echo "ERROR: Unknown network ${network}"
exit 1;
;;
esac


cat << EOF
global:
node:
Expand All @@ -76,9 +54,6 @@ $(echo -n "${tokens_signed_json}" | sed 's/^/ /')
mcCoreCommonConfig:
ipinfo:
token: '${IP_INFO_TOKEN}'
ias:
key: '${IAS_KEY}'
spid: '${IAS_SPID}'
clientAuth:
token: '${CLIENT_AUTH_TOKEN}'
sentry:
Expand Down
11 changes: 0 additions & 11 deletions consensus/service/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,6 @@ Follow the steps below:
'{"threshold":3,"members":[{"type":"Node","args":"node1.test.mobilecoin.com:8443"},{"type":"Node","args":"node2.test.mobilecoin.com:8443"},{"type":"Node","args":"node3.test.mobilecoin.com:8443"},{"type":"Node","args":"node5.test.mobilecoin.com:8443"}]}'
```

1. Obtain SPID key.

Attestation with Intel's Attestation Service (IAS) requires the nodes making the request to be linked to a developer account on their platform. When running the consensus service, you will provide both the `IAS_API_KEY` and `IAS_SPID`, which you can obtain by registering with the [Intel SGX Portal](https://api.portal.trustedservices.intel.com/EPID-attestation).

* Choose Dev for a developer network, or Prod for the TestNet.
* Choose Linkable (name base mode). This allows other nodes in the network to blocklist nodes who are misbehaving by submitting too many attestation requests. If you choose Unlinkable, your node will be denied peer connections.

>Note: You will provide the access qualifier when you run consensus, to indicate which Attestation endpoint to hit, via `IAS_MODE=DEV` or `IAS_MODE=PROD`

1. Generate your ed25519 message-signing key.

```
Expand Down Expand Up @@ -161,8 +152,6 @@ SGX_MODE=HW IAS_MODE=DEV \
--client-responder-id my_node.my_domain.com:443 \
--peer-responder-id node1.my_domain.com:8443 \
--network /etc/mc-network.toml \
--ias-api-key="${IAS_API_KEY}" \
--ias-spid="${IAS_SPID}" \
--ledger-path /tmp/ledger-db-1 \
--peer-listen-uri='mcp://0.0.0.0:8443/' \
--msg-signer-key MC4CAQAwBQYDK2VwBCIEIGz4xR7wuPKjwM1EK0MKrc9ukTjiDqvKKREITPXPkNku \
Expand Down
13 changes: 0 additions & 13 deletions consensus/service/config/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ pub use crate::{

use base64::{engine::general_purpose::STANDARD as BASE64_ENGINE, Engine};
use clap::Parser;
use mc_attest_core::ProviderId;
use mc_common::{NodeID, ResponderId};
use mc_crypto_keys::{DistinguishedEncoding, Ed25519Pair, Ed25519Private};
use mc_transaction_core::BlockVersion;
Expand Down Expand Up @@ -61,14 +60,6 @@ pub struct Config {
#[clap(long = "network", env = "MC_NETWORK")]
pub network_path: PathBuf,

/// Your Intel IAS API key.
#[clap(long, env = "MC_IAS_API_KEY")]
pub ias_api_key: String,

/// The Service Provider ID (SPID) associated with your Intel IAS API Key.
#[clap(long, env = "MC_IAS_SPID")]
pub ias_spid: ProviderId,

/// The location on which to listen for peer traffic.
///
/// The local node id is derived from the peer_listen_uri.
Expand Down Expand Up @@ -210,8 +201,6 @@ mod tests {
)
.unwrap(),
network_path: PathBuf::from("network.toml"),
ias_api_key: "".to_string(),
ias_spid: ProviderId::from_str("22222222222222222222222222222222").unwrap(),
peer_listen_uri: PeerUri::from_str("insecure-mcp://0.0.0.0:8081/").unwrap(),
client_listen_uri: ClientUri::from_str("insecure-mc://0.0.0.0:3223/").unwrap(),
admin_listen_uri: Some(AdminUri::from_str("insecure-mca://0.0.0.0:9090/").unwrap()),
Expand Down Expand Up @@ -279,8 +268,6 @@ mod tests {
"MC4CAQAwBQYDK2VwBCIEIC50QXQll2Y9qxztvmsUgcBBIxkmk7EQjxzQTa926bKo",
) .unwrap(),
network_path: PathBuf::from("network.toml"),
ias_api_key: "".to_string(),
ias_spid: ProviderId::from_str("22222222222222222222222222222222").unwrap(),
peer_listen_uri: PeerUri::from_str("mcp://0.0.0.0:8443/?tls-chain=./public/attest/test_certs/selfsigned_mobilecoin.crt&tls-key=./public/attest/test_certs/selfsigned_mobilecoin.key").unwrap(),
client_listen_uri: ClientUri::from_str("insecure-mc://0.0.0.0:3223/").unwrap(),
admin_listen_uri: Some(AdminUri::from_str("insecure-mca://0.0.0.0:9090/").unwrap()),
Expand Down
2 changes: 0 additions & 2 deletions consensus/service/src/api/client_api_service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -491,8 +491,6 @@ mod client_api_tests {
"--admin-listen-uri=insecure-mca://0.0.0.0:9090/",
"--sealed-block-signing-key=/tmp/key",
"--ledger-path=/tmp/ledger",
"--ias-spid=22222222222222222222222222222222",
"--ias-api-key=asdf",
])
.unwrap()
}
Expand Down
Loading
Loading