Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@azure/core-auth

Package Overview
Dependencies
Maintainers
1
Versions
307
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@azure/core-auth - npm Package Compare versions

Comparing version 1.1.4-dev.20200807.1 to 1.1.4

dist-esm/src/tracing.js

4

CHANGELOG.md
# Release History
## 1.1.4 (Unreleased)
## 1.1.4 (2021-01-07)
- Updated to use OpenTelemetry 0.10.2 via `@azure/core-tracing`
- Removed direct dependency on `@opentelemetry/api` and `@azure/core-tracing`.

@@ -7,0 +7,0 @@ ## 1.1.3 (2020-06-30)

@@ -12,3 +12,3 @@ // Copyright (c) Microsoft Corporation.

*
* @param key the initial value of the key to use in authentication
* @param key - The initial value of the key to use in authentication
*/

@@ -37,3 +37,3 @@ function AzureKeyCredential(key) {

*
* @param newKey the new key value to be used
* @param newKey - The new key value to be used
*/

@@ -40,0 +40,0 @@ AzureKeyCredential.prototype.update = function (newKey) {

@@ -6,3 +6,3 @@ // Copyright (c) Microsoft Corporation.

*
* @param credential The assumed TokenCredential to be tested.
* @param credential - The assumed TokenCredential to be tested.
*/

@@ -15,6 +15,7 @@ export function isTokenCredential(credential) {

// it doesn't actually implement TokenCredential also.
return (credential &&
typeof credential.getToken === "function" &&
(credential.signRequest === undefined || credential.getToken.length > 0));
var castCredential = credential;
return (castCredential &&
typeof castCredential.getToken === "function" &&
(castCredential.signRequest === undefined || castCredential.getToken.length > 0));
}
//# sourceMappingURL=tokenCredential.js.map

@@ -16,3 +16,3 @@ 'use strict';

*
* @param key the initial value of the key to use in authentication
* @param key - The initial value of the key to use in authentication
*/

@@ -41,3 +41,3 @@ function AzureKeyCredential(key) {

*
* @param newKey the new key value to be used
* @param newKey - The new key value to be used
*/

@@ -55,3 +55,3 @@ AzureKeyCredential.prototype.update = function (newKey) {

*
* @param credential The assumed TokenCredential to be tested.
* @param credential - The assumed TokenCredential to be tested.
*/

@@ -64,5 +64,6 @@ function isTokenCredential(credential) {

// it doesn't actually implement TokenCredential also.
return (credential &&
typeof credential.getToken === "function" &&
(credential.signRequest === undefined || credential.getToken.length > 0));
var castCredential = credential;
return (castCredential &&
typeof castCredential.getToken === "function" &&
(castCredential.signRequest === undefined || castCredential.getToken.length > 0));
}

@@ -69,0 +70,0 @@

{
"name": "@azure/core-auth",
"version": "1.1.4-dev.20200807.1",
"version": "1.1.4",
"description": "Provides low-level interfaces and helper methods for authentication in Azure SDK",

@@ -20,3 +20,3 @@ "sdk-type": "client",

"build:node": "tsc -p . && cross-env ONLY_NODE=true rollup -c 2>&1",
"build:samples": "cd samples && tsc -p .",
"build:samples": "echo Skipped.",
"build:test": "tsc -p . && rollup -c rollup.test.config.js 2>&1",

@@ -34,3 +34,3 @@ "build:types": "downlevel-dts types/latest types/3.1",

"lint:fix": "eslint package.json api-extractor.json src test --ext .ts --fix --fix-type [problem,suggestion]",
"lint": "eslint package.json api-extractor.json src test --ext .ts -f html -o core-auth-lintReport.html",
"lint": "eslint package.json api-extractor.json src test --ext .ts",
"pack": "npm pack 2>&1",

@@ -43,3 +43,4 @@ "prebuild": "npm run clean",

"unit-test:node": "mocha test-dist/**/*.js --reporter ../../../common/tools/mocha-multi-reporter.js",
"unit-test": "npm run unit-test:node && npm run unit-test:browser"
"unit-test": "npm run unit-test:node && npm run unit-test:browser",
"docs": "typedoc --excludePrivate --excludeNotExported --excludeExternals --mode file --out ./dist/docs ./src"
},

@@ -72,8 +73,6 @@ "files": [

"@azure/abort-controller": "^1.0.0",
"@azure/core-tracing": "^1.0.0-dev",
"@opentelemetry/api": "^0.10.2",
"tslib": "^2.0.0"
},
"devDependencies": {
"@azure/eslint-plugin-azure-sdk": "^3.0.0-dev",
"@azure/eslint-plugin-azure-sdk": "^3.0.0",
"@microsoft/api-extractor": "7.7.11",

@@ -87,12 +86,6 @@ "@rollup/plugin-commonjs": "11.0.2",

"@types/node": "^8.0.0",
"@typescript-eslint/eslint-plugin": "^2.0.0",
"@typescript-eslint/parser": "^2.0.0",
"assert": "^1.4.1",
"cross-env": "^7.0.2",
"downlevel-dts": "~0.4.0",
"eslint": "^6.1.0",
"eslint-config-prettier": "^6.0.0",
"eslint-plugin-no-null": "^1.0.2",
"eslint-plugin-no-only-tests": "^2.3.0",
"eslint-plugin-promise": "^4.1.1",
"eslint": "^7.15.0",
"inherits": "^2.0.3",

@@ -107,5 +100,6 @@ "mocha": "^7.1.1",

"rollup-plugin-visualizer": "^4.0.4",
"typescript": "~3.9.3",
"util": "^0.12.1"
"typescript": "4.1.2",
"util": "^0.12.1",
"typedoc": "0.15.0"
}
}
import { AbortSignalLike } from '@azure/abort-controller';
import { SpanOptions } from '@azure/core-tracing';
/**

@@ -27,3 +26,3 @@ * Represents an access token with an expiration time.

*
* @param key the initial value of the key to use in authentication
* @param key - The initial value of the key to use in authentication
*/

@@ -37,3 +36,3 @@ constructor(key: string);

*
* @param newKey the new key value to be used
* @param newKey - The new key value to be used
*/

@@ -72,5 +71,5 @@ update(newKey: string): void;

*
* @param credential The assumed TokenCredential to be tested.
* @param credential - The assumed TokenCredential to be tested.
*/
export declare function isTokenCredential(credential: any): credential is TokenCredential;
export declare function isTokenCredential(credential: unknown): credential is TokenCredential;
/**

@@ -86,2 +85,36 @@ * Represents a credential defined by a static API key.

/**
* A light interface that tries to be structurally compatible with OpenTelemetry.
*/
export declare interface SpanContext {
/**
* UUID of a trace.
*/
traceId: string;
/**
* UUID of a Span.
*/
spanId: string;
/**
* https://www.w3.org/TR/trace-context/#trace-flags
*/
traceFlags: number;
}
/**
* An interface that enables manual propagation of Spans.
*/
export declare interface SpanOptions {
/**
* The SpanContext that refers to a parent span, if any.
* A null value indicates that this should be a new root span,
* rather than potentially detecting a span via a context manager.
*/
parent?: SpanContext | null;
/**
* Attributes to set on the Span
*/
attributes?: {
[key: string]: unknown;
};
}
/**
* Represents a credential capable of providing an authentication token.

@@ -93,4 +126,7 @@ */

*
* @param scopes The list of scopes for which the token will have access.
* @param options The options used to configure any requests this
* This method is called automatically by Azure SDK client libraries. You may call this method
* directly, but you must also handle token caching and token refreshing.
*
* @param scopes - The list of scopes for which the token will have access.
* @param options - The options used to configure any requests this
* TokenCredential implementation might make.

@@ -97,0 +133,0 @@ */

import { AbortSignalLike } from '@azure/abort-controller';
import { SpanOptions } from '@azure/core-tracing';

@@ -32,3 +31,3 @@ /**

*
* @param key the initial value of the key to use in authentication
* @param key - The initial value of the key to use in authentication
*/

@@ -42,3 +41,3 @@ constructor(key: string);

*
* @param newKey the new key value to be used
* @param newKey - The new key value to be used
*/

@@ -79,5 +78,5 @@ update(newKey: string): void;

*
* @param credential The assumed TokenCredential to be tested.
* @param credential - The assumed TokenCredential to be tested.
*/
export declare function isTokenCredential(credential: any): credential is TokenCredential;
export declare function isTokenCredential(credential: unknown): credential is TokenCredential;

@@ -95,2 +94,38 @@ /**

/**
* A light interface that tries to be structurally compatible with OpenTelemetry.
*/
export declare interface SpanContext {
/**
* UUID of a trace.
*/
traceId: string;
/**
* UUID of a Span.
*/
spanId: string;
/**
* https://www.w3.org/TR/trace-context/#trace-flags
*/
traceFlags: number;
}
/**
* An interface that enables manual propagation of Spans.
*/
export declare interface SpanOptions {
/**
* The SpanContext that refers to a parent span, if any.
* A null value indicates that this should be a new root span,
* rather than potentially detecting a span via a context manager.
*/
parent?: SpanContext | null;
/**
* Attributes to set on the Span
*/
attributes?: {
[key: string]: unknown;
};
}
/**
* Represents a credential capable of providing an authentication token.

@@ -102,4 +137,7 @@ */

*
* @param scopes The list of scopes for which the token will have access.
* @param options The options used to configure any requests this
* This method is called automatically by Azure SDK client libraries. You may call this method
* directly, but you must also handle token caching and token refreshing.
*
* @param scopes - The list of scopes for which the token will have access.
* @param options - The options used to configure any requests this
* TokenCredential implementation might make.

@@ -106,0 +144,0 @@ */

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc