Skip to content
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
17 changes: 13 additions & 4 deletions cs/src/Contracts/TunnelServiceProperties.cs
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,18 @@ public class TunnelServiceProperties
/// </summary>
/// <remarks>
/// Used for authenticating AAD/MSA users, and service principals outside the AME tenant,
/// in the PPE and DEV service environments.
/// in the PPE service environments.
/// </remarks>
internal const string NonProdFirstPartyAppId = "54c45752-bacd-424a-b928-652f3eca2b18";
internal const string PpeFirstPartyAppId = "54c45752-bacd-424a-b928-652f3eca2b18";

/// <summary>
/// First-party app ID: `DEV-VSTunnels`
/// </summary>
/// <remarks>
/// Used for authenticating AAD/MSA users, and service principals outside the AME tenant,
/// in the DEV service environment
/// </remarks>
internal const string DevFirstPartyAppId = "9c63851a-ba2b-40a5-94bd-890be43b9284";

/// <summary>
/// Third-party app ID: `tunnels-prod-app-sp`
Expand Down Expand Up @@ -116,7 +125,7 @@ private TunnelServiceProperties(
/// </summary>
public static TunnelServiceProperties Staging { get; } = new TunnelServiceProperties(
$"https://{PpeDnsName}/",
NonProdFirstPartyAppId,
PpeFirstPartyAppId,
PpeThirdPartyAppId,
NonProdGitHubAppClientId);

Expand All @@ -125,7 +134,7 @@ private TunnelServiceProperties(
/// </summary>
public static TunnelServiceProperties Development { get; } = new TunnelServiceProperties(
$"https://{DevDnsName}/",
NonProdFirstPartyAppId,
DevFirstPartyAppId,
DevThirdPartyAppId,
NonProdGitHubAppClientId);

Expand Down
4 changes: 2 additions & 2 deletions go/tunnels/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ var ServiceProperties = TunnelServiceProperties{

var PpeServiceProperties = TunnelServiceProperties{
ServiceURI: fmt.Sprintf("https://%s/", ppeDnsName),
ServiceAppID: nonProdFirstPartyAppID,
ServiceAppID: ppeFirstPartyAppID,
ServiceInternalAppID: ppeThirdPartyAppID,
GitHubAppClientID: nonProdGitHubAppClientID,
}

var DevServiceProperties = TunnelServiceProperties{
ServiceURI: fmt.Sprintf("https://%s/", devDnsName),
ServiceAppID: nonProdFirstPartyAppID,
ServiceAppID: devFirstPartyAppID,
ServiceInternalAppID: devThirdPartyAppID,
GitHubAppClientID: nonProdGitHubAppClientID,
}
Expand Down
10 changes: 8 additions & 2 deletions go/tunnels/tunnel_service_properties.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,14 @@ var prodFirstPartyAppID = "46da2f7e-b5ef-422a-88d4-2a7f9de6a0b2"
// First-party app ID: `Visual Studio Tunnel Service - Test`
//
// Used for authenticating AAD/MSA users, and service principals outside the AME tenant,
// in the PPE and DEV service environments.
var nonProdFirstPartyAppID = "54c45752-bacd-424a-b928-652f3eca2b18"
// in the PPE service environments.
var ppeFirstPartyAppID = "54c45752-bacd-424a-b928-652f3eca2b18"

// First-party app ID: `DEV-VSTunnels`
//
// Used for authenticating AAD/MSA users, and service principals outside the AME tenant,
// in the DEV service environment
var devFirstPartyAppID = "9c63851a-ba2b-40a5-94bd-890be43b9284"

// Third-party app ID: `tunnels-prod-app-sp`
//
Expand Down
2 changes: 1 addition & 1 deletion go/tunnels/tunnels.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"github.com/rodaine/table"
)

const PackageVersion = "0.1.8"
const PackageVersion = "0.1.9"

func (tunnel *Tunnel) requestObject() (*Tunnel, error) {
convertedTunnel := &Tunnel{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,17 @@ public class TunnelServiceProperties {
* First-party app ID: `Visual Studio Tunnel Service - Test`
*
* Used for authenticating AAD/MSA users, and service principals outside the AME
* tenant, in the PPE and DEV service environments.
* tenant, in the PPE service environments.
*/
static final String nonProdFirstPartyAppId = "54c45752-bacd-424a-b928-652f3eca2b18";
static final String ppeFirstPartyAppId = "54c45752-bacd-424a-b928-652f3eca2b18";

/**
* First-party app ID: `DEV-VSTunnels`
*
* Used for authenticating AAD/MSA users, and service principals outside the AME
* tenant, in the DEV service environment
*/
static final String devFirstPartyAppId = "9c63851a-ba2b-40a5-94bd-890be43b9284";

/**
* Third-party app ID: `tunnels-prod-app-sp`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class TunnelServicePropertiesStatics {
*/
static final TunnelServiceProperties staging = new TunnelServiceProperties(
"https://" + TunnelServiceProperties.ppeDnsName + "/",
TunnelServiceProperties.nonProdFirstPartyAppId,
TunnelServiceProperties.ppeFirstPartyAppId,
TunnelServiceProperties.ppeThirdPartyAppId,
TunnelServiceProperties.nonProdGitHubAppClientId);

Expand All @@ -31,7 +31,7 @@ class TunnelServicePropertiesStatics {
*/
static final TunnelServiceProperties development = new TunnelServiceProperties(
"https://" + TunnelServiceProperties.devDnsName + "/",
TunnelServiceProperties.nonProdFirstPartyAppId,
TunnelServiceProperties.devFirstPartyAppId,
TunnelServiceProperties.devThirdPartyAppId,
TunnelServiceProperties.nonProdGitHubAppClientId);

Expand Down
2 changes: 1 addition & 1 deletion rs/src/contracts/tunnel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
// Licensed under the MIT license.
// Generated from ../../../cs/src/Contracts/Tunnel.cs

use chrono::{DateTime, Utc};
use crate::contracts::TunnelAccessControl;
use crate::contracts::TunnelEndpoint;
use crate::contracts::TunnelOptions;
use crate::contracts::TunnelPort;
use crate::contracts::TunnelStatus;
use chrono::{DateTime, Utc};
use serde::{Deserialize, Serialize};
use std::collections::HashMap;

Expand Down
2 changes: 1 addition & 1 deletion rs/src/contracts/tunnel_access_control_entry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
// Licensed under the MIT license.
// Generated from ../../../cs/src/Contracts/TunnelAccessControlEntry.cs

use crate::contracts::TunnelAccessControlEntryType;
use chrono::{DateTime, Utc};
use crate::contracts::TunnelAccessControlEntryType;
use serde::{Deserialize, Serialize};

// Data contract for an access control entry on a `Tunnel` or `TunnelPort`.
Expand Down
2 changes: 1 addition & 1 deletion rs/src/contracts/tunnel_constraints.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ pub const TUNNEL_ALIAS_PATTERN: &str = r#"[0123456789bcdfghjklmnpqrstvwxz]{3,60}
pub const TUNNEL_NAME_PATTERN: &str = r#"([a-z0-9][a-z0-9-]{1,58}[a-z0-9])|(^$)"#;

// Regular expression that can match or validate tunnel or port labels.
pub const LABEL_PATTERN: &str = r"[\w-=]{1,50}";
pub const LABEL_PATTERN: &str = r#"[\w-=]{1,50}"#;

// Regular expression that can match or validate tunnel domains.
//
Expand Down
2 changes: 1 addition & 1 deletion rs/src/contracts/tunnel_environments.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ pub fn env_staging() -> TunnelServiceProperties {
pub fn env_development() -> TunnelServiceProperties {
TunnelServiceProperties {
service_uri: format!("https://{}", DEV_DNS_NAME),
service_app_id: NON_PROD_FIRST_PARTY_APP_ID.to_owned(),
service_app_id: DEV_FIRST_PARTY_APP_ID.to_owned(),
service_internal_app_id: DEV_THIRD_PARTY_APP_ID.to_owned(),
github_app_client_id: NON_PROD_GITHUB_APP_CLIENT_ID.to_owned(),
}
Expand Down
2 changes: 1 addition & 1 deletion rs/src/contracts/tunnel_port.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ pub struct TunnelPort {
// A client that connects to a tunnel (by ID or name) without specifying a port number
// will connect to the default port for the tunnel, if a default is configured. Or if
// the tunnel has only one port then the single port is the implicit default.
//
//
// Selection of a default port for a connection also depends on matching the
// connection to the port `TunnelPort.Protocol`, so it is possible to configure
// separate defaults for distinct protocols like `TunnelProtocol.Http` and
Expand Down
10 changes: 8 additions & 2 deletions rs/src/contracts/tunnel_service_properties.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,14 @@ pub const PROD_FIRST_PARTY_APP_ID: &str = "46da2f7e-b5ef-422a-88d4-2a7f9de6a0b2"
// First-party app ID: `Visual Studio Tunnel Service - Test`
//
// Used for authenticating AAD/MSA users, and service principals outside the AME tenant,
// in the PPE and DEV service environments.
pub const NON_PROD_FIRST_PARTY_APP_ID: &str = "54c45752-bacd-424a-b928-652f3eca2b18";
// in the PPE service environments.
pub const PPE_FIRST_PARTY_APP_ID: &str = "54c45752-bacd-424a-b928-652f3eca2b18";

// First-party app ID: `DEV-VSTunnels`
//
// Used for authenticating AAD/MSA users, and service principals outside the AME tenant,
// in the DEV service environment
pub const DEV_FIRST_PARTY_APP_ID: &str = "9c63851a-ba2b-40a5-94bd-890be43b9284";

// Third-party app ID: `tunnels-prod-app-sp`
//
Expand Down
4 changes: 2 additions & 2 deletions ts/src/connections/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@
"buffer": "^5.2.1",
"debug": "^4.1.1",
"vscode-jsonrpc": "^4.0.0",
"@microsoft/dev-tunnels-contracts": ">1.1.24",
"@microsoft/dev-tunnels-management": ">1.1.24",
"@microsoft/dev-tunnels-contracts": ">1.1.26",
"@microsoft/dev-tunnels-management": ">1.1.26",
"@microsoft/dev-tunnels-ssh": "^3.11.36",
"@microsoft/dev-tunnels-ssh-tcp": "^3.11.36",
"uuid": "^3.3.3",
Expand Down
12 changes: 10 additions & 2 deletions ts/src/contracts/tunnelServiceProperties.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,17 @@ export const prodFirstPartyAppId = '46da2f7e-b5ef-422a-88d4-2a7f9de6a0b2';
* First-party app ID: `Visual Studio Tunnel Service - Test`
*
* Used for authenticating AAD/MSA users, and service principals outside the AME tenant,
* in the PPE and DEV service environments.
* in the PPE service environments.
*/
export const nonProdFirstPartyAppId = '54c45752-bacd-424a-b928-652f3eca2b18';
export const ppeFirstPartyAppId = '54c45752-bacd-424a-b928-652f3eca2b18';

/**
* First-party app ID: `DEV-VSTunnels`
*
* Used for authenticating AAD/MSA users, and service principals outside the AME tenant,
* in the DEV service environment
*/
export const devFirstPartyAppId = '9c63851a-ba2b-40a5-94bd-890be43b9284';

/**
* Third-party app ID: `tunnels-prod-app-sp`
Expand Down
7 changes: 4 additions & 3 deletions ts/src/contracts/tunnelServicePropertiesStatics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
import {
TunnelServiceProperties as ITunnelServiceProperties,
prodFirstPartyAppId,
nonProdFirstPartyAppId,
ppeFirstPartyAppId,
devFirstPartyAppId,
prodThirdPartyAppId,
ppeThirdPartyAppId,
devThirdPartyAppId,
Expand All @@ -30,7 +31,7 @@ export const production = <ITunnelServiceProperties>{
*/
export const staging = <ITunnelServiceProperties>{
serviceUri: `https://${ppeDnsName}/`,
serviceAppId: nonProdFirstPartyAppId,
serviceAppId: ppeFirstPartyAppId,
serviceInternalAppId: ppeThirdPartyAppId,
gitHubAppClientId: nonProdGitHubAppClientId,
};
Expand All @@ -40,7 +41,7 @@ export const staging = <ITunnelServiceProperties>{
*/
export const development = <ITunnelServiceProperties>{
serviceUri: `https://${devDnsName}/`,
serviceAppId: nonProdFirstPartyAppId,
serviceAppId: devFirstPartyAppId,
serviceInternalAppId: devThirdPartyAppId,
gitHubAppClientId: nonProdGitHubAppClientId,
};
Expand Down
2 changes: 1 addition & 1 deletion ts/src/management/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"buffer": "^5.2.1",
"debug": "^4.1.1",
"vscode-jsonrpc": "^4.0.0",
"@microsoft/dev-tunnels-contracts": ">1.1.24",
"@microsoft/dev-tunnels-contracts": ">1.1.26",
"axios": "^1.6.6"
}
}