From f122713b48fe6f48bab440c4df88fbd4cc21c3cf Mon Sep 17 00:00:00 2001 From: Ashok Kumar M <35134347+marks0351@users.noreply.github.com> Date: Fri, 28 May 2021 08:28:02 +0530 Subject: [PATCH 01/17] Fix: Adding missing widget properties when a new tab is created. (#4733) * dip * dip * dip * Revert "dip" This reverts commit f0eeaa4a2dc9845509945c2af9376f1573baafdf. * dip * removing unwanted iteration. * Adding and fixing specs. (cherry picked from commit 575d7fe7f97596c5565010727634d7a67b68f5a2) --- .../Applications/DuplicateApplication_spec.js | 2 +- .../Applications/ForkApplication_spec.js | 2 +- app/client/src/constants/WidgetConstants.tsx | 2 +- .../mockResponses/WidgetConfigResponse.tsx | 2 +- .../src/utils/WidgetPropsUtils.test.tsx | 46 +++++++++++++++++++ app/client/src/utils/WidgetPropsUtils.tsx | 45 +++++++++++++++++- app/client/src/widgets/Tabs/TabsWidget.tsx | 7 +++ 7 files changed, 101 insertions(+), 5 deletions(-) diff --git a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/DuplicateApplication_spec.js b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/DuplicateApplication_spec.js index 31427f6462..74f6848425 100644 --- a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/DuplicateApplication_spec.js +++ b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/DuplicateApplication_spec.js @@ -6,7 +6,7 @@ let duplicateApplicationDsl; describe("Duplicate application", function() { before(() => { - dsl.dsl.version = 20; // latest migrated version + dsl.dsl.version = 21; // latest migrated version cy.addDsl(dsl); }); diff --git a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/ForkApplication_spec.js b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/ForkApplication_spec.js index 4defd83f1b..2dc3773ffc 100644 --- a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/ForkApplication_spec.js +++ b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/ForkApplication_spec.js @@ -5,7 +5,7 @@ let forkedApplicationDsl; describe("Fork application across orgs", function() { before(() => { - dsl.dsl.version = 20; // latest migrated version + dsl.dsl.version = 21; // latest migrated version cy.addDsl(dsl); }); diff --git a/app/client/src/constants/WidgetConstants.tsx b/app/client/src/constants/WidgetConstants.tsx index 12c34a9ff1..6226293292 100644 --- a/app/client/src/constants/WidgetConstants.tsx +++ b/app/client/src/constants/WidgetConstants.tsx @@ -96,7 +96,7 @@ export const layoutConfigurations: LayoutConfigurations = { FLUID: { minWidth: -1, maxWidth: -1 }, }; -export const LATEST_PAGE_VERSION = 20; +export const LATEST_PAGE_VERSION = 21; export const GridDefaults = { DEFAULT_CELL_SIZE: 1, diff --git a/app/client/src/mockResponses/WidgetConfigResponse.tsx b/app/client/src/mockResponses/WidgetConfigResponse.tsx index 521ce177cf..51545b5945 100644 --- a/app/client/src/mockResponses/WidgetConfigResponse.tsx +++ b/app/client/src/mockResponses/WidgetConfigResponse.tsx @@ -368,7 +368,7 @@ const WidgetConfigResponse: WidgetConfigReducerState = { }, ], }, - version: 2, + version: 3, }, MODAL_WIDGET: { rows: 6 * GRID_DENSITY_MIGRATION_V1, diff --git a/app/client/src/utils/WidgetPropsUtils.test.tsx b/app/client/src/utils/WidgetPropsUtils.test.tsx index 2b774e45fb..c4b9565c3d 100644 --- a/app/client/src/utils/WidgetPropsUtils.test.tsx +++ b/app/client/src/utils/WidgetPropsUtils.test.tsx @@ -4,9 +4,11 @@ import { migrateChartDataFromArrayToObject, migrateToNewLayout, migrateInitialValues, + extractCurrentDSL, } from "./WidgetPropsUtils"; import { buildChildren, + widgetCanvasFactory, buildDslWithChildren, } from "test/factories/WidgetFactoryUtils"; import { cloneDeep } from "lodash"; @@ -694,4 +696,48 @@ describe("Initial value migration test", () => { expect(migrateInitialValues(input)).toEqual(output); }); + it("", () => { + const tabsWidgetDSL: any = (version = 1) => { + const children: any = buildChildren([ + { + version, + type: "TABS_WIDGET", + children: [ + { + type: "CANVAS_WIDGET", + tabId: "tab1212332", + tabName: "Newly Added Tab", + widgetId: "o9ody00ep7", + parentId: "jd83uvbkmp", + detachFromLayout: true, + children: [], + parentRowSpace: 1, + parentColumnSpace: 1, + // leftColumn: 0, + // rightColumn: 592, // Commenting these coz they are not provided for a newly added tab in the Tabs widget version 2 + // bottomRow: 280, + topRow: 0, + isLoading: false, + widgetName: "Canvas1", + renderMode: "CANVAS", + }, + ], + }, + ]); + const dsl: any = widgetCanvasFactory.build({ + children, + }); + return { + data: { + layouts: [{ dsl }], + }, + }; + }; + const migratedDslV2: any = extractCurrentDSL(tabsWidgetDSL()); + expect(migratedDslV2.children[0].children[0].leftColumn).toBeNaN(); + const migratedDslV3: any = extractCurrentDSL(tabsWidgetDSL(2)); + expect(migratedDslV3.children[0].version).toBe(3); + expect(migratedDslV3.children[0].children[0].leftColumn).not.toBeNaN(); + expect(migratedDslV3.children[0].children[0].leftColumn).toBe(0); + }); }); diff --git a/app/client/src/utils/WidgetPropsUtils.tsx b/app/client/src/utils/WidgetPropsUtils.tsx index 54979e9b1b..672abde7b4 100644 --- a/app/client/src/utils/WidgetPropsUtils.tsx +++ b/app/client/src/utils/WidgetPropsUtils.tsx @@ -22,7 +22,7 @@ import defaultTemplate from "templates/default"; import { generateReactKey } from "./generators"; import { ChartDataPoint } from "widgets/ChartWidget"; import { FlattenedWidgetProps } from "reducers/entityReducers/canvasWidgetsReducer"; -import { isString, set } from "lodash"; +import { has, isString, set } from "lodash"; import log from "loglevel"; import { migrateTablePrimaryColumnsBindings, @@ -735,12 +735,55 @@ const transformDSL = (currentDSL: ContainerWidgetProps) => { currentDSL.detachFromLayout || false, ); currentDSL = migrateToNewLayout(currentDSL); + currentDSL.version = 20; + } + + if (currentDSL.version === 20) { + currentDSL = migrateNewlyAddedTabsWidgetsMissingData(currentDSL); currentDSL.version = LATEST_PAGE_VERSION; } return currentDSL; }; +const migrateNewlyAddedTabsWidgetsMissingData = ( + currentDSL: ContainerWidgetProps, +) => { + if (currentDSL.type === WidgetTypes.TABS_WIDGET && currentDSL.version === 2) { + try { + if (currentDSL.children && currentDSL.children.length) { + currentDSL.children = currentDSL.children.map((each) => { + if (has(currentDSL, ["leftColumn", "rightColumn", "bottomRow"])) { + return each; + } + return { + ...each, + leftColumn: 0, + rightColumn: + (currentDSL.rightColumn - currentDSL.leftColumn) * + currentDSL.parentColumnSpace, + bottomRow: + (currentDSL.bottomRow - currentDSL.topRow) * + currentDSL.parentRowSpace, + }; + }); + } + currentDSL.version = 3; + } catch (error) { + Sentry.captureException({ + message: "Tabs Migration to add missing fields Failed", + oldData: currentDSL.children, + }); + } + } + if (currentDSL.children && currentDSL.children.length) { + currentDSL.children = currentDSL.children.map( + migrateNewlyAddedTabsWidgetsMissingData, + ); + } + return currentDSL; +}; + export const migrateToNewLayout = (dsl: ContainerWidgetProps) => { const scaleWidget = (widgetProps: WidgetProps) => { widgetProps.bottomRow *= GRID_DENSITY_MIGRATION_V1; diff --git a/app/client/src/widgets/Tabs/TabsWidget.tsx b/app/client/src/widgets/Tabs/TabsWidget.tsx index f8cd1ec930..6e164ede2e 100644 --- a/app/client/src/widgets/Tabs/TabsWidget.tsx +++ b/app/client/src/widgets/Tabs/TabsWidget.tsx @@ -210,6 +210,13 @@ class TabsWidget extends BaseWidget< topRow: 1, newWidgetId, widgetId: this.props.widgetId, + leftColumn: 0, + rightColumn: + (this.props.rightColumn - this.props.leftColumn) * + this.props.parentColumnSpace, + bottomRow: + (this.props.bottomRow - this.props.topRow) * + this.props.parentRowSpace, props: { tabId: tab.id, tabName: tab.label, From 18275be7fd6906570e8883750c0d200e43a82f58 Mon Sep 17 00:00:00 2001 From: Sumit Kumar Date: Mon, 31 May 2021 11:55:47 +0530 Subject: [PATCH 02/17] Fix: Fix redis plugin socket error (#4791) * fix socket error * fix default port * remove invalid check for missing port, since default port would be supplied if user leaves the port field empty. (cherry picked from commit e2f4fd5e94a1ca34fc703b2a94e5c773ca454d63) --- .../java/com/external/plugins/RedisPlugin.java | 16 ++++++++++++---- .../com/external/plugins/RedisPluginTest.java | 7 ++++--- 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/app/server/appsmith-plugins/redisPlugin/src/main/java/com/external/plugins/RedisPlugin.java b/app/server/appsmith-plugins/redisPlugin/src/main/java/com/external/plugins/RedisPlugin.java index 4a5dfcd059..f5dca31ecb 100644 --- a/app/server/appsmith-plugins/redisPlugin/src/main/java/com/external/plugins/RedisPlugin.java +++ b/app/server/appsmith-plugins/redisPlugin/src/main/java/com/external/plugins/RedisPlugin.java @@ -36,7 +36,7 @@ import java.util.stream.Collectors; import static com.appsmith.external.constants.ActionConstants.ACTION_CONFIGURATION_BODY; public class RedisPlugin extends BasePlugin { - private static final Integer DEFAULT_PORT = 6379; + private static final Long DEFAULT_PORT = 6379L; public RedisPlugin(PluginWrapper wrapper) { super(wrapper); @@ -106,6 +106,17 @@ public class RedisPlugin extends BasePlugin { result.setRequest(request); return result; }) + .doFinally(signalType -> { + /* + * - For some reason, Jedis throws a socket error when kept idle for like 10 min when + * appsmith is setup via docker image. + * - APMU, jedis.close() should disconnect the connection, causing jedis to refresh connection + * during next execution. + * - This is a placeholder solution till better fix is available (would connection pool fix + * it ?) + */ + jedis.close(); + }) .subscribeOn(scheduler); } @@ -178,9 +189,6 @@ public class RedisPlugin extends BasePlugin { if (StringUtils.isNullOrEmpty(endpoint.getHost())) { invalids.add("Missing host for endpoint"); } - if (endpoint.getPort() == null) { - invalids.add("Missing port for endpoint"); - } } DBAuth auth = (DBAuth) datasourceConfiguration.getAuthentication(); diff --git a/app/server/appsmith-plugins/redisPlugin/src/test/java/com/external/plugins/RedisPluginTest.java b/app/server/appsmith-plugins/redisPlugin/src/test/java/com/external/plugins/RedisPluginTest.java index 72198786c1..58274a14d2 100644 --- a/app/server/appsmith-plugins/redisPlugin/src/test/java/com/external/plugins/RedisPluginTest.java +++ b/app/server/appsmith-plugins/redisPlugin/src/test/java/com/external/plugins/RedisPluginTest.java @@ -83,7 +83,7 @@ public class RedisPluginTest { Endpoint endpoint = new Endpoint(); invalidDatasourceConfiguration.setEndpoints(Collections.singletonList(endpoint)); - Assert.assertEquals(Set.of("Missing port for endpoint", "Missing host for endpoint"), + Assert.assertEquals(Set.of("Missing host for endpoint"), pluginExecutor.validateDatasource(invalidDatasourceConfiguration)); } @@ -95,7 +95,8 @@ public class RedisPluginTest { endpoint.setHost("test-host"); invalidDatasourceConfiguration.setEndpoints(Collections.singletonList(endpoint)); - Assert.assertEquals(pluginExecutor.validateDatasource(invalidDatasourceConfiguration), Set.of("Missing port for endpoint")); + // Since default port is picked, set of invalids should be empty. + Assert.assertEquals(pluginExecutor.validateDatasource(invalidDatasourceConfiguration), Set.of()); } @Test @@ -112,7 +113,7 @@ public class RedisPluginTest { invalidDatasourceConfiguration.setEndpoints(Collections.singletonList(endpoint)); Assert.assertEquals( - Set.of("Missing port for endpoint", "Missing username for authentication.", "Missing password for authentication."), + Set.of("Missing username for authentication.", "Missing password for authentication."), pluginExecutor.validateDatasource(invalidDatasourceConfiguration) ); } From f85b21199375c686770dc2867478bf8d2a7902a1 Mon Sep 17 00:00:00 2001 From: Ashok Kumar M <35134347+marks0351@users.noreply.github.com> Date: Fri, 28 May 2021 22:25:10 +0530 Subject: [PATCH 03/17] Fix: Positioning widgets without left right column towards the end of the page. (#4777) --- app/client/src/constants/WidgetConstants.tsx | 2 +- app/client/src/utils/WidgetPropsUtils.tsx | 98 +++++++++++++++++++- 2 files changed, 97 insertions(+), 3 deletions(-) diff --git a/app/client/src/constants/WidgetConstants.tsx b/app/client/src/constants/WidgetConstants.tsx index 6226293292..9f8cc38859 100644 --- a/app/client/src/constants/WidgetConstants.tsx +++ b/app/client/src/constants/WidgetConstants.tsx @@ -96,7 +96,7 @@ export const layoutConfigurations: LayoutConfigurations = { FLUID: { minWidth: -1, maxWidth: -1 }, }; -export const LATEST_PAGE_VERSION = 21; +export const LATEST_PAGE_VERSION = 22; export const GridDefaults = { DEFAULT_CELL_SIZE: 1, diff --git a/app/client/src/utils/WidgetPropsUtils.tsx b/app/client/src/utils/WidgetPropsUtils.tsx index 672abde7b4..338c9db8ca 100644 --- a/app/client/src/utils/WidgetPropsUtils.tsx +++ b/app/client/src/utils/WidgetPropsUtils.tsx @@ -22,7 +22,7 @@ import defaultTemplate from "templates/default"; import { generateReactKey } from "./generators"; import { ChartDataPoint } from "widgets/ChartWidget"; import { FlattenedWidgetProps } from "reducers/entityReducers/canvasWidgetsReducer"; -import { has, isString, set } from "lodash"; +import { has, isString, omit, set } from "lodash"; import log from "loglevel"; import { migrateTablePrimaryColumnsBindings, @@ -33,7 +33,10 @@ import * as Sentry from "@sentry/react"; import { migrateTextStyleFromTextWidget } from "./migrations/TextWidgetReplaceTextStyle"; import { nextAvailableRowInContainer } from "entities/Widget/utils"; import { DATA_BIND_REGEX_GLOBAL } from "constants/BindingsConstants"; -import { GRID_DENSITY_MIGRATION_V1 } from "mockResponses/WidgetConfigResponse"; +import WidgetConfigResponse, { + GRID_DENSITY_MIGRATION_V1, +} from "mockResponses/WidgetConfigResponse"; +import CanvasWidgetsNormalizer from "normalizers/CanvasWidgetsNormalizer"; export type WidgetOperationParams = { operation: WidgetOperation; @@ -740,12 +743,103 @@ const transformDSL = (currentDSL: ContainerWidgetProps) => { if (currentDSL.version === 20) { currentDSL = migrateNewlyAddedTabsWidgetsMissingData(currentDSL); + currentDSL.version = 21; + } + + if (currentDSL.version === 21) { + const { + entities: { canvasWidgets }, + } = CanvasWidgetsNormalizer.normalize(currentDSL); + currentDSL = migrateWidgetsWithoutLeftRightColumns( + currentDSL, + canvasWidgets, + ); + currentDSL = migrateOverFlowingTabsWidgets(currentDSL, canvasWidgets); currentDSL.version = LATEST_PAGE_VERSION; } return currentDSL; }; +const migrateOverFlowingTabsWidgets = ( + currentDSL: ContainerWidgetProps, + canvasWidgets: any, +) => { + if ( + currentDSL.type === "TABS_WIDGET" && + currentDSL.version === 3 && + currentDSL.children && + currentDSL.children.length + ) { + const tabsWidgetHeight = + (currentDSL.bottomRow - currentDSL.topRow) * currentDSL.parentRowSpace; + const widgetHasOverflowingChildren = currentDSL.children.some((eachTab) => { + if (eachTab.children && eachTab.children.length) { + return eachTab.children.some((child: WidgetProps) => { + if (canvasWidgets[child.widgetId].repositioned) { + const tabHeight = child.bottomRow * child.parentRowSpace; + return tabsWidgetHeight < tabHeight; + } + return false; + }); + } + return false; + }); + if (widgetHasOverflowingChildren) { + currentDSL.shouldScrollContents = true; + } + } + if (currentDSL.children && currentDSL.children.length) { + currentDSL.children = currentDSL.children.map((eachChild) => + migrateOverFlowingTabsWidgets(eachChild, canvasWidgets), + ); + } + return currentDSL; +}; + +const migrateWidgetsWithoutLeftRightColumns = ( + currentDSL: ContainerWidgetProps, + canvasWidgets: any, +) => { + if ( + currentDSL.widgetId !== MAIN_CONTAINER_WIDGET_ID && + !( + currentDSL.hasOwnProperty("leftColumn") && + currentDSL.hasOwnProperty("rightColumn") + ) + ) { + try { + const nextRow = nextAvailableRowInContainer( + currentDSL.parentId || MAIN_CONTAINER_WIDGET_ID, + omit(canvasWidgets, [currentDSL.widgetId]), + ); + canvasWidgets[currentDSL.widgetId].repositioned = true; + const leftColumn = 0; + const rightColumn = WidgetConfigResponse.config[currentDSL.type].rows; + const bottomRow = nextRow + (currentDSL.bottomRow - currentDSL.topRow); + const topRow = nextRow; + currentDSL = { + ...currentDSL, + topRow, + bottomRow, + rightColumn, + leftColumn, + }; + } catch (error) { + Sentry.captureException({ + message: "Migrating position of widget on data loss failed", + oldData: currentDSL, + }); + } + } + if (currentDSL.children && currentDSL.children.length) { + currentDSL.children = currentDSL.children.map((dsl) => + migrateWidgetsWithoutLeftRightColumns(dsl, canvasWidgets), + ); + } + return currentDSL; +}; + const migrateNewlyAddedTabsWidgetsMissingData = ( currentDSL: ContainerWidgetProps, ) => { From 8fc2b6251dedb363e7a5e372afb29a9a773e691f Mon Sep 17 00:00:00 2001 From: "vicky.bansal@primathon.in" Date: Mon, 31 May 2021 17:09:06 +0530 Subject: [PATCH 04/17] Added migration to update parentRowSpace property of table widget --- app/client/src/constants/WidgetConstants.tsx | 2 +- app/client/src/utils/WidgetPropsUtils.tsx | 6 + .../src/utils/migrations/TableWidget.test.ts | 282 +++++++++++++++++- .../src/utils/migrations/TableWidget.ts | 17 ++ 4 files changed, 305 insertions(+), 2 deletions(-) diff --git a/app/client/src/constants/WidgetConstants.tsx b/app/client/src/constants/WidgetConstants.tsx index 9f8cc38859..a1b2807a35 100644 --- a/app/client/src/constants/WidgetConstants.tsx +++ b/app/client/src/constants/WidgetConstants.tsx @@ -96,7 +96,7 @@ export const layoutConfigurations: LayoutConfigurations = { FLUID: { minWidth: -1, maxWidth: -1 }, }; -export const LATEST_PAGE_VERSION = 22; +export const LATEST_PAGE_VERSION = 23; export const GridDefaults = { DEFAULT_CELL_SIZE: 1, diff --git a/app/client/src/utils/WidgetPropsUtils.tsx b/app/client/src/utils/WidgetPropsUtils.tsx index 338c9db8ca..1f580a6abc 100644 --- a/app/client/src/utils/WidgetPropsUtils.tsx +++ b/app/client/src/utils/WidgetPropsUtils.tsx @@ -27,6 +27,7 @@ import log from "loglevel"; import { migrateTablePrimaryColumnsBindings, tableWidgetPropertyPaneMigrations, + migrateTableWidgetParentRowSpaceProperty, } from "utils/migrations/TableWidget"; import { migrateIncorrectDynamicBindingPathLists } from "utils/migrations/IncorrectDynamicBindingPathLists"; import * as Sentry from "@sentry/react"; @@ -755,6 +756,11 @@ const transformDSL = (currentDSL: ContainerWidgetProps) => { canvasWidgets, ); currentDSL = migrateOverFlowingTabsWidgets(currentDSL, canvasWidgets); + currentDSL.version = 22; + } + + if (currentDSL.version === 22) { + currentDSL = migrateTableWidgetParentRowSpaceProperty(currentDSL); currentDSL.version = LATEST_PAGE_VERSION; } diff --git a/app/client/src/utils/migrations/TableWidget.test.ts b/app/client/src/utils/migrations/TableWidget.test.ts index 5715074956..11b0000740 100644 --- a/app/client/src/utils/migrations/TableWidget.test.ts +++ b/app/client/src/utils/migrations/TableWidget.test.ts @@ -1,6 +1,9 @@ import { WidgetProps } from "widgets/BaseWidget"; import { ContainerWidgetProps } from "widgets/ContainerWidget"; -import { tableWidgetPropertyPaneMigrations } from "./TableWidget"; +import { + tableWidgetPropertyPaneMigrations, + migrateTableWidgetParentRowSpaceProperty, +} from "./TableWidget"; const input1: ContainerWidgetProps = { widgetName: "MainContainer", @@ -639,4 +642,281 @@ describe("Table Widget Property Pane Upgrade", () => { const newDsl = tableWidgetPropertyPaneMigrations(input3); expect(JSON.stringify(newDsl) === JSON.stringify(output3)); }); + + it("To test table parentRowSpace is updated", () => { + const inputDsl: ContainerWidgetProps = { + widgetName: "MainContainer", + backgroundColor: "none", + rightColumn: 1224, + snapColumns: 16, + detachFromLayout: true, + widgetId: "0", + topRow: 0, + bottomRow: 1840, + containerStyle: "none", + snapRows: 33, + parentRowSpace: 1, + type: "CANVAS_WIDGET", + canExtend: true, + version: 7, + minHeight: 1292, + parentColumnSpace: 1, + dynamicBindingPathList: [], + leftColumn: 0, + isLoading: false, + parentId: "", + renderMode: "CANVAS", + children: [ + { + isVisible: true, + label: "Data", + widgetName: "Table1", + searchKey: "", + tableData: + '[\n {\n "id": 2381224,\n "email": "michael.lawson@reqres.in",\n "userName": "Michael Lawson",\n "productName": "Chicken Sandwich",\n "orderAmount": 4.99\n },\n {\n "id": 2736212,\n "email": "lindsay.ferguson@reqres.in",\n "userName": "Lindsay Ferguson",\n "productName": "Tuna Salad",\n "orderAmount": 9.99\n },\n {\n "id": 6788734,\n "email": "tobias.funke@reqres.in",\n "userName": "Tobias Funke",\n "productName": "Beef steak",\n "orderAmount": 19.99\n }\n]', + type: "TABLE_WIDGET", + isLoading: false, + parentColumnSpace: 74, + parentRowSpace: 40, + leftColumn: 0, + rightColumn: 8, + topRow: 19, + bottomRow: 26, + parentId: "0", + widgetId: "fs785w9gcy", + dynamicBindingPathList: [], + primaryColumns: { + id: { + index: 0, + width: 150, + id: "id", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "id", + computedValue: "", + }, + email: { + index: 1, + width: 150, + id: "email", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "email", + computedValue: "", + }, + userName: { + index: 2, + width: 150, + id: "userName", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "userName", + computedValue: "", + }, + productName: { + index: 3, + width: 150, + id: "productName", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "productName", + computedValue: "", + }, + orderAmount: { + index: 4, + width: 150, + id: "orderAmount", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "orderAmount", + computedValue: "", + }, + }, + textSize: "PARAGRAPH", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + renderMode: "CANVAS", + version: 1, + }, + ], + }; + const outputDsl: ContainerWidgetProps = { + widgetName: "MainContainer", + backgroundColor: "none", + rightColumn: 1224, + snapColumns: 16, + detachFromLayout: true, + widgetId: "0", + topRow: 0, + bottomRow: 1840, + containerStyle: "none", + snapRows: 33, + parentRowSpace: 1, + type: "CANVAS_WIDGET", + canExtend: true, + version: 7, + minHeight: 1292, + parentColumnSpace: 1, + dynamicBindingPathList: [], + leftColumn: 0, + isLoading: false, + parentId: "", + renderMode: "CANVAS", + children: [ + { + isVisible: true, + label: "Data", + widgetName: "Table1", + searchKey: "", + tableData: + '[\n {\n "id": 2381224,\n "email": "michael.lawson@reqres.in",\n "userName": "Michael Lawson",\n "productName": "Chicken Sandwich",\n "orderAmount": 4.99\n },\n {\n "id": 2736212,\n "email": "lindsay.ferguson@reqres.in",\n "userName": "Lindsay Ferguson",\n "productName": "Tuna Salad",\n "orderAmount": 9.99\n },\n {\n "id": 6788734,\n "email": "tobias.funke@reqres.in",\n "userName": "Tobias Funke",\n "productName": "Beef steak",\n "orderAmount": 19.99\n }\n]', + type: "TABLE_WIDGET", + isLoading: false, + parentColumnSpace: 74, + parentRowSpace: 10, + leftColumn: 0, + rightColumn: 8, + topRow: 19, + bottomRow: 26, + parentId: "0", + widgetId: "fs785w9gcy", + dynamicBindingPathList: [], + primaryColumns: { + id: { + index: 0, + width: 150, + id: "id", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "id", + computedValue: "", + }, + email: { + index: 1, + width: 150, + id: "email", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "email", + computedValue: "", + }, + userName: { + index: 2, + width: 150, + id: "userName", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "userName", + computedValue: "", + }, + productName: { + index: 3, + width: 150, + id: "productName", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "productName", + computedValue: "", + }, + orderAmount: { + index: 4, + width: 150, + id: "orderAmount", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + columnType: "text", + textColor: "#231F20", + textSize: "PARAGRAPH", + fontStyle: "REGULAR", + enableFilter: true, + enableSort: true, + isVisible: true, + isDerived: false, + label: "orderAmount", + computedValue: "", + }, + }, + textSize: "PARAGRAPH", + horizontalAlignment: "LEFT", + verticalAlignment: "CENTER", + renderMode: "CANVAS", + version: 1, + }, + ], + }; + const newDsl = migrateTableWidgetParentRowSpaceProperty(inputDsl); + expect(JSON.stringify(newDsl) === JSON.stringify(output1)); + }); }); diff --git a/app/client/src/utils/migrations/TableWidget.ts b/app/client/src/utils/migrations/TableWidget.ts index 7daddef4de..edd976764b 100644 --- a/app/client/src/utils/migrations/TableWidget.ts +++ b/app/client/src/utils/migrations/TableWidget.ts @@ -4,6 +4,7 @@ import { WidgetTypes, FontStyleTypes, TextSizes, + GridDefaults, } from "constants/WidgetConstants"; import { getAllTableColumnKeys } from "components/designSystems/appsmith/TableComponent/TableHelpers"; import { @@ -214,3 +215,19 @@ export const migrateTablePrimaryColumnsBindings = ( }); return currentDSL; }; + +export const migrateTableWidgetParentRowSpaceProperty = ( + currentDSL: ContainerWidgetProps, +) => { + currentDSL.children = currentDSL.children?.map((child: WidgetProps) => { + if (child.type === WidgetTypes.TABLE_WIDGET) { + if (child.parentRowSpace === 40) { + child.parentRowSpace = GridDefaults.DEFAULT_GRID_ROW_HEIGHT; + } + } else if (child.children && child.children.length > 0) { + child = migrateTableWidgetParentRowSpaceProperty(child); + } + return child; + }); + return currentDSL; +}; From 2357f886fcad5bfc5457334d15129847c9ad59c3 Mon Sep 17 00:00:00 2001 From: NandanAnantharamu <67676905+NandanAnantharamu@users.noreply.github.com> Date: Wed, 2 Jun 2021 13:34:02 +0530 Subject: [PATCH 05/17] Added wait for route (#4817) * Added wait for route * updated test with datasource route * udpated version and cleanup * updated duplicate app --- .../Applications/DuplicateApplication_spec.js | 2 +- .../ClientSideTests/Applications/ForkApplication_spec.js | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/DuplicateApplication_spec.js b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/DuplicateApplication_spec.js index 74f6848425..7cc05bf94f 100644 --- a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/DuplicateApplication_spec.js +++ b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/DuplicateApplication_spec.js @@ -6,7 +6,7 @@ let duplicateApplicationDsl; describe("Duplicate application", function() { before(() => { - dsl.dsl.version = 21; // latest migrated version + dsl.dsl.version = 23; // latest migrated version cy.addDsl(dsl); }); diff --git a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/ForkApplication_spec.js b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/ForkApplication_spec.js index 2dc3773ffc..91f4ece082 100644 --- a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/ForkApplication_spec.js +++ b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Applications/ForkApplication_spec.js @@ -5,7 +5,7 @@ let forkedApplicationDsl; describe("Fork application across orgs", function() { before(() => { - dsl.dsl.version = 21; // latest migrated version + dsl.dsl.version = 23; // latest migrated version cy.addDsl(dsl); }); @@ -32,12 +32,15 @@ describe("Fork application across orgs", function() { cy.wait("@postForkAppOrg").then((httpResponse) => { expect(httpResponse.status).to.equal(200); }); + cy.get("@getPage").then((httpResponse) => { + expect(httpResponse.status).to.deep.equal(200); + }); // check that forked application has same dsl cy.get("@getPage").then((httpResponse) => { const data = httpResponse.response.body.data; forkedApplicationDsl = data.layouts[0].dsl; - expect(forkedApplicationDsl).to.deep.equal(dsl.dsl); }); + cy.NavigateToHome(); }); }); From 2eff8bd821abe780167c3e30af709920727599b2 Mon Sep 17 00:00:00 2001 From: "vicky.bansal@primathon.in" Date: Mon, 31 May 2021 17:27:00 +0530 Subject: [PATCH 06/17] Fix unused variable issue --- app/client/src/utils/migrations/TableWidget.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/client/src/utils/migrations/TableWidget.test.ts b/app/client/src/utils/migrations/TableWidget.test.ts index 11b0000740..a135af9384 100644 --- a/app/client/src/utils/migrations/TableWidget.test.ts +++ b/app/client/src/utils/migrations/TableWidget.test.ts @@ -917,6 +917,6 @@ describe("Table Widget Property Pane Upgrade", () => { ], }; const newDsl = migrateTableWidgetParentRowSpaceProperty(inputDsl); - expect(JSON.stringify(newDsl) === JSON.stringify(output1)); + expect(JSON.stringify(newDsl) === JSON.stringify(outputDsl)); }); }); From c5c0269954e9ebe22bc5dd8b4450680373060319 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Thu, 3 Jun 2021 09:20:47 +0530 Subject: [PATCH 07/17] Default state for mongo actions that were already configured (#4873) * Default state for mongo actions that were already configured * Clean up --- .../server/migrations/DatabaseChangelog.java | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/app/server/appsmith-server/src/main/java/com/appsmith/server/migrations/DatabaseChangelog.java b/app/server/appsmith-server/src/main/java/com/appsmith/server/migrations/DatabaseChangelog.java index 2a206bb0ce..6058061098 100644 --- a/app/server/appsmith-server/src/main/java/com/appsmith/server/migrations/DatabaseChangelog.java +++ b/app/server/appsmith-server/src/main/java/com/appsmith/server/migrations/DatabaseChangelog.java @@ -50,6 +50,7 @@ import com.appsmith.server.services.OrganizationService; import com.fasterxml.jackson.databind.ObjectMapper; import com.github.cloudyrock.mongock.ChangeLog; import com.github.cloudyrock.mongock.ChangeSet; +import com.github.cloudyrock.mongock.decorator.impl.MongockTemplate; import com.google.gson.Gson; import com.mongodb.MongoClient; import com.mongodb.MongoException; @@ -2277,4 +2278,34 @@ public class DatabaseChangelog { // Delete all the existing mongo datasource structures by setting the key to null. mongoOperations.updateMulti(query, update, Datasource.class); } + + @ChangeSet(order = "069", id = "set-mongo-actions-type-to-raw", author = "") + public void setMongoActionInputToRaw(MongockTemplate mongockTemplate) { + + // All the existing mongo actions at this point will only have ever been in the raw format + // For these actions to be readily available to users, we need to set their input type to raw manually + // This is required because since the mongo form, the default input type on the UI has been set to FORM + Plugin mongoPlugin = mongockTemplate.findOne(query(where("packageName").is("mongo-plugin")), Plugin.class); + + // Fetch all the actions built on top of a mongo database, not having any value set for input type + assert mongoPlugin != null; + List rawMongoActions = mongockTemplate.find( + query(new Criteria().andOperator( + where(fieldName(QNewAction.newAction.pluginId)).is(mongoPlugin.getId()))), + NewAction.class + ) + .stream() + .filter(mongoAction -> { + final List pluginSpecifiedTemplates = mongoAction.getUnpublishedAction().getActionConfiguration().getPluginSpecifiedTemplates(); + return pluginSpecifiedTemplates != null && pluginSpecifiedTemplates.size() == 1; + }) + .collect(Collectors.toList()); + + for (NewAction action : rawMongoActions) { + List pluginSpecifiedTemplates = action.getUnpublishedAction().getActionConfiguration().getPluginSpecifiedTemplates(); + pluginSpecifiedTemplates.add(new Property(null, "RAW")); + + mongockTemplate.save(action); + } + } } From ad9e7e05152696a7b1bd243dc0a2de3a6aafe273 Mon Sep 17 00:00:00 2001 From: Shrikant Sharat Kandula Date: Thu, 3 Jun 2021 10:58:26 +0530 Subject: [PATCH 08/17] Fix migration NPE --- .../java/com/appsmith/server/migrations/DatabaseChangelog.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/server/appsmith-server/src/main/java/com/appsmith/server/migrations/DatabaseChangelog.java b/app/server/appsmith-server/src/main/java/com/appsmith/server/migrations/DatabaseChangelog.java index 6058061098..9d1b3e4d18 100644 --- a/app/server/appsmith-server/src/main/java/com/appsmith/server/migrations/DatabaseChangelog.java +++ b/app/server/appsmith-server/src/main/java/com/appsmith/server/migrations/DatabaseChangelog.java @@ -2296,6 +2296,9 @@ public class DatabaseChangelog { ) .stream() .filter(mongoAction -> { + if (mongoAction.getUnpublishedAction() == null || mongoAction.getUnpublishedAction().getActionConfiguration() == null) { + return false; + } final List pluginSpecifiedTemplates = mongoAction.getUnpublishedAction().getActionConfiguration().getPluginSpecifiedTemplates(); return pluginSpecifiedTemplates != null && pluginSpecifiedTemplates.size() == 1; }) From 0b298d2a7afb2e79b69d2aeaf9db4563330cd77c Mon Sep 17 00:00:00 2001 From: Pranav Kanade Date: Fri, 4 Jun 2021 16:26:58 +0530 Subject: [PATCH 09/17] [Feature #4903] Show warning text for choosing choosing to leave organisation. (#4915) * added the isOpen and onClose pros to context menu component * added a warning shown before letting a user leave org * added confirmation modal for removing members from table * Added warning modal to be showing on member deletion * updated cypress tests * fixed typo * removed log --- .../LeaveOrganizationTest_spec.js | 2 +- app/client/src/components/ads/Menu.tsx | 4 + app/client/src/constants/messages.ts | 4 + app/client/src/pages/Applications/index.tsx | 30 ++++++- .../organization/DeleteConfirmationModal.tsx | 88 +++++++++++++++++++ app/client/src/pages/organization/Members.tsx | 65 +++++++++++++- .../src/reducers/uiReducers/orgReducer.ts | 16 ++-- 7 files changed, 193 insertions(+), 16 deletions(-) create mode 100644 app/client/src/pages/organization/DeleteConfirmationModal.tsx diff --git a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/OrganisationTests/LeaveOrganizationTest_spec.js b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/OrganisationTests/LeaveOrganizationTest_spec.js index 73758abae9..325789bc62 100644 --- a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/OrganisationTests/LeaveOrganizationTest_spec.js +++ b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/OrganisationTests/LeaveOrganizationTest_spec.js @@ -27,7 +27,7 @@ describe("Leave organization test spec", function() { cy.visit("/applications"); cy.openOrgOptionsPopup(newOrganizationName); cy.contains("Leave Organization").click(); - + cy.contains("Are you sure").click(); cy.wait("@leaveOrgApiCall").then((httpResponse) => { expect(httpResponse.status).to.equal(400); }); diff --git a/app/client/src/components/ads/Menu.tsx b/app/client/src/components/ads/Menu.tsx index dc3437cba9..b235273c38 100644 --- a/app/client/src/components/ads/Menu.tsx +++ b/app/client/src/components/ads/Menu.tsx @@ -12,6 +12,8 @@ type MenuProps = CommonComponentProps & { onOpening?: (node: HTMLElement) => void; onClosing?: (node: HTMLElement) => void; modifiers?: PopperModifiers; + isOpen?: boolean; + onClose?: () => void; }; const MenuWrapper = styled.div` @@ -30,8 +32,10 @@ function Menu(props: MenuProps) { className={props.className} data-cy={props.cypressSelector} disabled={props.disabled} + isOpen={props.isOpen} minimal modifiers={props.modifiers} + onClose={props.onClose} onClosing={props.onClosing} onOpening={props.onOpening} portalClassName={props.className} diff --git a/app/client/src/constants/messages.ts b/app/client/src/constants/messages.ts index b40f6f66db..ff7a684eba 100644 --- a/app/client/src/constants/messages.ts +++ b/app/client/src/constants/messages.ts @@ -332,3 +332,7 @@ export const TROUBLESHOOT_ISSUE = () => "Troubleshoot issue"; // Import/Export Application features export const IMPORT_APPLICATION_MODAL_TITLE = () => "Import Application"; + +export const DELETE_CONFIRMATION_MODAL_TITLE = () => `Are you sure?`; +export const DELETE_CONFIRMATION_MODAL_SUBTITLE = (name?: string | null) => + `You want to remove ${name} from this organization`; diff --git a/app/client/src/pages/Applications/index.tsx b/app/client/src/pages/Applications/index.tsx index 64642b3cdb..36a5425ec3 100644 --- a/app/client/src/pages/Applications/index.tsx +++ b/app/client/src/pages/Applications/index.tsx @@ -526,6 +526,8 @@ function ApplicationsSection(props: any) { }); } }; + const [warnLeavingOrganization, setWarnLeavingOrganization] = useState(false); + const [orgToOpenMenu, setOrgToOpenMenu] = useState(null); const updateApplicationDispatch = ( id: string, data: UpdateApplicationPayload, @@ -545,6 +547,8 @@ function ApplicationsSection(props: any) { const Form: any = OrgInviteUsersForm; const leaveOrg = (orgId: string) => { + setWarnLeavingOrganization(false); + setOrgToOpenMenu(null); dispatch(leaveOrganization(orgId)); }; @@ -565,7 +569,11 @@ function ApplicationsSection(props: any) { const { disabled, orgName, orgSlug } = props; return ( - + setOrgToOpenMenu(orgSlug)} + > { + setOrgToOpenMenu(null); + }} + onClosing={() => { + setWarnLeavingOrganization(false); + }} position={Position.BOTTOM_RIGHT} target={OrgMenuTarget({ orgName: organization.name, @@ -706,8 +721,17 @@ function ApplicationsSection(props: any) { )} leaveOrg(organization.id)} - text="Leave Organization" + onSelect={() => + !warnLeavingOrganization + ? setWarnLeavingOrganization(true) + : leaveOrg(organization.id) + } + text={ + !warnLeavingOrganization + ? "Leave Organization" + : "Are you sure?" + } + type={!warnLeavingOrganization ? undefined : "warning"} /> )} diff --git a/app/client/src/pages/organization/DeleteConfirmationModal.tsx b/app/client/src/pages/organization/DeleteConfirmationModal.tsx new file mode 100644 index 0000000000..333675b6d5 --- /dev/null +++ b/app/client/src/pages/organization/DeleteConfirmationModal.tsx @@ -0,0 +1,88 @@ +import React from "react"; +import styled from "styled-components"; +import Button, { Size, Category } from "components/ads/Button"; +import Text, { TextType } from "components/ads/Text"; +import { Variant } from "components/ads/common"; +import { + DELETE_CONFIRMATION_MODAL_TITLE, + DELETE_CONFIRMATION_MODAL_SUBTITLE, +} from "constants/messages"; +import Dialog from "components/ads/DialogComponent"; +import { Classes } from "@blueprintjs/core"; + +const StyledDialog = styled(Dialog)` + && .${Classes.DIALOG_BODY} { + padding-top: 0px; + } +`; + +const CenteredContainer = styled.div` + text-align: center; +`; + +const ImportButton = styled(Button)<{ disabled?: boolean }>` + height: 30px; + width: 81px; + pointer-events: ${(props) => (!!props.disabled ? "none" : "auto")}; +`; + +const ButtonWrapper = styled.div` + display: flex; + justify-content: center; + margin-top: 20px; + + & > a { + margin: 0 4px; + } +`; + +type DeleteConfirmationProps = { + username?: string | null; + name?: string | null; + isOpen: boolean; + onClose: () => void; + onConfirm: () => void; + isDeletingUser: boolean; +}; + +function DeleteConfirmationModal(props: DeleteConfirmationProps) { + const { isDeletingUser, isOpen, name, onClose, onConfirm, username } = props; + + return ( + + + + {DELETE_CONFIRMATION_MODAL_SUBTITLE(name || username)} + + + + + + + + ); +} + +export default DeleteConfirmationModal; diff --git a/app/client/src/pages/organization/Members.tsx b/app/client/src/pages/organization/Members.tsx index 796628eb36..698550910b 100644 --- a/app/client/src/pages/organization/Members.tsx +++ b/app/client/src/pages/organization/Members.tsx @@ -1,4 +1,4 @@ -import React, { useEffect } from "react"; +import React, { useEffect, useState } from "react"; import { useDispatch, useSelector } from "react-redux"; import { @@ -29,6 +29,7 @@ import { SettingsHeading } from "./General"; import styled from "styled-components"; import { Classes } from "@blueprintjs/core"; import { Variant } from "components/ads/common"; +import DeleteConfirmationModal from "./DeleteConfirmationModal"; export type PageProps = RouteComponentProps<{ orgId: string; @@ -54,6 +55,35 @@ export default function MemberSettings(props: PageProps) { dispatch(fetchOrg(orgId)); }, [orgId]); + const [ + showMemberDeletionConfirmation, + setShowMemberDeletionConfirmation, + ] = useState(false); + const [isDeletingUser, setIsDeletingUser] = useState(false); + const onOpenConfirmationModal = () => setShowMemberDeletionConfirmation(true); + const onCloseConfirmationModal = () => + setShowMemberDeletionConfirmation(false); + + const [userToBeDeleted, setUserToBeDeleted] = useState<{ + name: string; + username: string; + orgId: string; + } | null>(null); + + const onConfirmMemberDeletion = ( + name: string, + username: string, + orgId: string, + ) => { + setUserToBeDeleted({ name, username, orgId }); + onOpenConfirmationModal(); + }; + + const onDeleteMember = () => { + if (!userToBeDeleted) return null; + dispatch(deleteOrgUser(userToBeDeleted.orgId, userToBeDeleted.username)); + }; + const { deletingUserInfo, isFetchingAllRoles, @@ -66,6 +96,21 @@ export default function MemberSettings(props: PageProps) { (el) => el.id === orgId, )[0]; + useEffect(() => { + if (!!userToBeDeleted && showMemberDeletionConfirmation) { + const userBeingDeleted = allUsers.find( + (user) => user.username === userToBeDeleted.username, + ); + if (!userBeingDeleted) { + setUserToBeDeleted(null); + onCloseConfirmationModal(); + setIsDeletingUser(false); + } else { + setIsDeletingUser(userBeingDeleted.isDeleting); + } + } + }, [allUsers]); + const userTableData = allUsers.map((user) => ({ ...user, isCurrentUser: user.username === currentUser?.username, @@ -139,8 +184,10 @@ export default function MemberSettings(props: PageProps) { } name="delete" onClick={() => { - dispatch( - deleteOrgUser(orgId, cellProps.cell.row.values.username), + onConfirmMemberDeletion( + cellProps.cell.row.values.username, + cellProps.cell.row.values.username, + orgId, ); }} size={IconSize.LARGE} @@ -174,7 +221,17 @@ export default function MemberSettings(props: PageProps) { {isFetchingAllUsers && isFetchingAllRoles ? ( ) : ( - + <> +
+ + )} ); diff --git a/app/client/src/reducers/uiReducers/orgReducer.ts b/app/client/src/reducers/uiReducers/orgReducer.ts index 984506b53d..9207c16725 100644 --- a/app/client/src/reducers/uiReducers/orgReducer.ts +++ b/app/client/src/reducers/uiReducers/orgReducer.ts @@ -78,6 +78,14 @@ const orgReducer = createImmerReducer(initialState, { } }); }, + [ReduxActionErrorTypes.CHANGE_ORG_USER_ROLE_ERROR]: ( + draftState: OrgReduxState, + ) => { + draftState.orgUsers.forEach((user: OrgUser) => { + //TODO: This will change the status to false even if one role change api fails. + user.isChangingRole = false; + }); + }, [ReduxActionTypes.DELETE_ORG_USER_INIT]: ( draftState: OrgReduxState, action: ReduxAction<{ username: string }>, @@ -96,14 +104,6 @@ const orgReducer = createImmerReducer(initialState, { (user: OrgUser) => user.username !== action.payload.username, ); }, - [ReduxActionErrorTypes.CHANGE_ORG_USER_ROLE_ERROR]: ( - draftState: OrgReduxState, - ) => { - draftState.orgUsers.forEach((user: OrgUser) => { - //TODO: This will change the status to false even if one role change api fails. - user.isChangingRole = false; - }); - }, [ReduxActionErrorTypes.DELETE_ORG_USER_ERROR]: ( draftState: OrgReduxState, ) => { From 6989da0b3a7314bf7e32dd79c1902ce9be9490dc Mon Sep 17 00:00:00 2001 From: Pranav Kanade Date: Sat, 5 Jun 2021 11:01:18 +0530 Subject: [PATCH 10/17] Fix/update cypress command delete user from org (#4930) * added the isOpen and onClose pros to context menu component * added a warning shown before letting a user leave org * added confirmation modal for removing members from table * Added warning modal to be showing on member deletion * updated cypress tests * fixed typo * removed log * updated deleteUserFromOrg cypress command --- app/client/cypress/locators/HomePage.json | 2 ++ app/client/cypress/support/commands.js | 2 ++ app/client/src/pages/organization/DeleteConfirmationModal.tsx | 2 +- 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/app/client/cypress/locators/HomePage.json b/app/client/cypress/locators/HomePage.json index 39bfc865de..d6b0808e4b 100644 --- a/app/client/cypress/locators/HomePage.json +++ b/app/client/cypress/locators/HomePage.json @@ -63,6 +63,8 @@ "orgImportAppOption": "[data-cy=t--org-import-app]", "orgImportAppModal": ".t--import-application-modal", "orgImportAppButton": "[data-cy=t--org-import-app-button]", + "leaveOrgConfirmModal": ".t--member-delete-confirmation-modal", + "leaveOrgConfirmButton": "[data-cy=t--org-leave-button]", "orgNameInput": "[data-cy=t--org-name-input]", "renameOrgInput": "[data-cy=t--org-rename-input]", "orgEmailInput": "[data-cy=t--org-email-input]", diff --git a/app/client/cypress/support/commands.js b/app/client/cypress/support/commands.js index 1e49791eaa..aa74b07d33 100644 --- a/app/client/cypress/support/commands.js +++ b/app/client/cypress/support/commands.js @@ -170,6 +170,8 @@ Cypress.Commands.add("deleteUserFromOrg", (orgName, email) => { cy.get(homePage.DeleteBtn) .last() .click({ force: true }); + cy.get(homePage.leaveOrgConfirmModal).should("be.visible"); + cy.get(homePage.leaveOrgConfirmButton).click({ force: true }); cy.xpath(homePage.appHome) .first() .should("be.visible") diff --git a/app/client/src/pages/organization/DeleteConfirmationModal.tsx b/app/client/src/pages/organization/DeleteConfirmationModal.tsx index 333675b6d5..a8f3176b9b 100644 --- a/app/client/src/pages/organization/DeleteConfirmationModal.tsx +++ b/app/client/src/pages/organization/DeleteConfirmationModal.tsx @@ -72,7 +72,7 @@ function DeleteConfirmationModal(props: DeleteConfirmationProps) { /> Date: Mon, 7 Jun 2021 11:30:10 +0530 Subject: [PATCH 11/17] App viewer will not be able to export app (#4938) --- app/client/src/pages/Applications/ApplicationCard.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/client/src/pages/Applications/ApplicationCard.tsx b/app/client/src/pages/Applications/ApplicationCard.tsx index e65dc5f501..e7ed55a90e 100644 --- a/app/client/src/pages/Applications/ApplicationCard.tsx +++ b/app/client/src/pages/Applications/ApplicationCard.tsx @@ -300,7 +300,7 @@ export function ApplicationCard(props: ApplicationCardProps) { cypressSelector: "t--fork-app", }); } - if (!!props.enableImportExport) { + if (!!props.enableImportExport && hasEditPermission) { moreActionItems.push({ onSelect: exportApplicationAsJSONFile, text: "Export", From b23e3b1f0b75a0be4cdbec93b85ae96a0026383d Mon Sep 17 00:00:00 2001 From: Shrikant Sharat Kandula Date: Wed, 9 Jun 2021 16:57:43 +0530 Subject: [PATCH 12/17] Disable ui-test checking for master branch (cherry picked from commit cfdf9c722339c9a34caa93481bd0f5a9212694b9) --- .github/workflows/client-test.yml | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/client-test.yml b/.github/workflows/client-test.yml index caea0a51b3..d8c818f13c 100644 --- a/.github/workflows/client-test.yml +++ b/.github/workflows/client-test.yml @@ -29,10 +29,10 @@ jobs: # then we don't check for the PR approved state # Only PR approvals of internally created PRs should trigger this workflow if: | - github.event_name == 'workflow_dispatch' || - github.event_name == 'push' || - (github.event_name == 'pull_request_review' && - github.event.review.state == 'approved' && + github.event_name == 'workflow_dispatch' || + github.event_name == 'push' || + (github.event_name == 'pull_request_review' && + github.event.review.state == 'approved' && github.event.pull_request.head.repo.full_name == github.repository) runs-on: ubuntu-latest defaults: @@ -298,15 +298,15 @@ jobs: - name: Return status for ui-matrix run: | - if [[ "${{ needs.ui-test.result }}" == "success" ]]; then - echo "Integration tests completed successfully!"; - exit 0; - elif [[ "${{ needs.ui-test.result }}" == "skipped" ]]; then - echo "Integration tests were skipped"; - exit 1; - else - echo "Integration tests have failed"; - exit 1; + if [[ "${{ needs.ui-test.result }}" == "success" ]]; then + echo "Integration tests completed successfully!"; + exit 0; + elif [[ "${{ needs.ui-test.result }}" == "skipped" ]]; then + echo "Integration tests were skipped"; + exit 1; + else + echo "Integration tests have failed"; + exit 1; fi package: @@ -316,7 +316,7 @@ jobs: run: working-directory: app/client # Run this job only if all the previous steps are a success and the reference if the release or master branch - if: success() && (github.ref == 'refs/heads/release' || github.ref == 'refs/heads/master') + if: (success() && github.ref == 'refs/heads/release') || github.ref == 'refs/heads/master' steps: # Checkout the code From 023f1712fcda9272d5306184794cfcd27badf921 Mon Sep 17 00:00:00 2001 From: Rishabh Saxena Date: Wed, 16 Jun 2021 21:21:18 +0530 Subject: [PATCH 13/17] Feature/signup success url (#5124) (cherry picked from commit 10b3f7e790fe8b99b9ba7365774540ba549cda12) --- app/client/src/AppRouter.tsx | 9 +++- app/client/src/constants/routes.ts | 1 + app/client/src/pages/Applications/index.tsx | 25 ++++++++--- .../AuthenticationSuccessHandler.java | 43 ++++++++++++++----- .../server/helpers/RedirectHelper.java | 1 + 5 files changed, 61 insertions(+), 18 deletions(-) diff --git a/app/client/src/AppRouter.tsx b/app/client/src/AppRouter.tsx index 1ba02d5b77..430762a01b 100644 --- a/app/client/src/AppRouter.tsx +++ b/app/client/src/AppRouter.tsx @@ -13,6 +13,7 @@ import { getApplicationViewerPageURL, ORG_URL, SIGN_UP_URL, + SIGNUP_SUCCESS_URL, USER_AUTH_URL, USERS_URL, PROFILE, @@ -47,7 +48,8 @@ function changeAppBackground(currentTheme: any) { if ( trimTrailingSlash(window.location.pathname) === "/applications" || window.location.pathname.indexOf("/settings/") !== -1 || - trimTrailingSlash(window.location.pathname) === "/profile" + trimTrailingSlash(window.location.pathname) === "/profile" || + trimTrailingSlash(window.location.pathname) === "/signup-success" ) { document.body.style.backgroundColor = currentTheme.colors.homepageBackground; @@ -101,6 +103,11 @@ class AppRouter extends React.Component { exact path={APPLICATIONS_URL} /> + { - if (window.location.href) { - const url = new URL(window.location.href); - const searchParams = url.searchParams; - return !!searchParams.get("isFromSignup"); - } - return false; + return window.location?.pathname === SIGNUP_SUCCESS_URL; }; + const { onboardingFormEnabled } = getAppsmithConfigs(); class Applications extends Component< ApplicationProps, @@ -912,9 +909,23 @@ class Applications extends Component< PerformanceTracker.stopTracking(PerformanceTransactionName.LOGIN_CLICK); PerformanceTracker.stopTracking(PerformanceTransactionName.SIGN_UP); this.props.getAllApplication(); + const isFromSignUp = getIsFromSignup(); this.setState({ - showOnboardingForm: getIsFromSignup() && onboardingFormEnabled, + showOnboardingForm: isFromSignUp && onboardingFormEnabled, }); + + // Redirect directly in case we're not showing the onboarding form + if (isFromSignUp && !onboardingFormEnabled) { + const urlObject = new URL(window.location.href); + const redirectUrl = urlObject?.searchParams.get("redirectUrl"); + if (redirectUrl) { + try { + window.location.replace(redirectUrl); + } catch (e) { + console.error("Error handling the redirect url"); + } + } + } } public render() { diff --git a/app/server/appsmith-server/src/main/java/com/appsmith/server/authentication/handlers/AuthenticationSuccessHandler.java b/app/server/appsmith-server/src/main/java/com/appsmith/server/authentication/handlers/AuthenticationSuccessHandler.java index ae48813763..8c78cd7c20 100644 --- a/app/server/appsmith-server/src/main/java/com/appsmith/server/authentication/handlers/AuthenticationSuccessHandler.java +++ b/app/server/appsmith-server/src/main/java/com/appsmith/server/authentication/handlers/AuthenticationSuccessHandler.java @@ -2,6 +2,7 @@ package com.appsmith.server.authentication.handlers; import com.appsmith.server.constants.AnalyticsEvents; import com.appsmith.server.constants.Security; +import com.appsmith.server.domains.User; import com.appsmith.server.helpers.RedirectHelper; import com.appsmith.server.services.AnalyticsService; import com.appsmith.server.services.SessionUserService; @@ -21,8 +22,13 @@ import org.springframework.web.server.ServerWebExchange; import reactor.core.publisher.Mono; import java.net.URI; +import java.net.URLEncoder; +import java.nio.charset.StandardCharsets; +import java.time.Instant; import java.util.Map; +import static com.appsmith.server.helpers.RedirectHelper.SIGNUP_SUCCESS_URL; + @Slf4j @Component @RequiredArgsConstructor @@ -59,8 +65,16 @@ public class AuthenticationSuccessHandler implements ServerAuthenticationSuccess ) { log.debug("Login succeeded for user: {}", authentication.getPrincipal()); + if (authentication instanceof OAuth2AuthenticationToken) { + // In case of OAuth2 based authentication, there is no way to identify if this was a user signup (new user + // creation) or if this was a login (existing user). What we do here to identify this, is an approximation. + // If and when we find a better way to do identify this, let's please move away from this approximation. + // If the user object was created within the last 5 seconds, we treat it as a new user. + isFromSignup = ((User) authentication.getPrincipal()).getCreatedAt().isAfter(Instant.now().minusSeconds(5)); + } + Mono redirectionMono = authentication instanceof OAuth2AuthenticationToken - ? handleOAuth2Redirect(webFilterExchange) + ? handleOAuth2Redirect(webFilterExchange, isFromSignup) : handleRedirect(webFilterExchange, isFromSignup); return sessionUserService.getCurrentUser() @@ -92,23 +106,26 @@ public class AuthenticationSuccessHandler implements ServerAuthenticationSuccess // Disabling this because although the reference in the Javadoc is to a private method, it is still useful. "JavadocReference" ) - private Mono handleOAuth2Redirect(WebFilterExchange webFilterExchange) { + private Mono handleOAuth2Redirect(WebFilterExchange webFilterExchange, boolean isFromSignup) { ServerWebExchange exchange = webFilterExchange.getExchange(); String state = exchange.getRequest().getQueryParams().getFirst(Security.QUERY_PARAMETER_STATE); - String originHeader = RedirectHelper.DEFAULT_REDIRECT_URL; + String redirectUrl = RedirectHelper.DEFAULT_REDIRECT_URL; + String prefix = Security.STATE_PARAMETER_ORIGIN + "="; if (state != null && !state.isEmpty()) { String[] stateArray = state.split(","); - for (int i = 0; i < stateArray.length; i++) { - String stateVar = stateArray[i]; - if (stateVar != null && stateVar.startsWith(Security.STATE_PARAMETER_ORIGIN) && stateVar.contains("=")) { + for (String stateVar : stateArray) { + if (stateVar != null && stateVar.startsWith(prefix)) { // This is the origin of the request that we want to redirect to - originHeader = stateVar.split("=")[1]; + redirectUrl = stateVar.split("=", 2)[1]; } } } - URI defaultRedirectLocation = URI.create(originHeader); - return this.redirectStrategy.sendRedirect(exchange, defaultRedirectLocation); + if (isFromSignup) { + redirectUrl = buildSignupSuccessUrl(redirectUrl); + } + + return redirectStrategy.sendRedirect(exchange, URI.create(redirectUrl)); } private Mono handleRedirect(WebFilterExchange webFilterExchange, boolean isFromSignup) { @@ -120,11 +137,17 @@ public class AuthenticationSuccessHandler implements ServerAuthenticationSuccess .flatMap(redirectHelper::getRedirectUrl) .map(url -> { if (isFromSignup) { - url += (url.contains("?") ? "&" : "?") + "isFromSignup=true"; + // This redirectUrl will be used by the client to redirect after showing a welcome page. + url = buildSignupSuccessUrl(url); } return url; }) .map(URI::create) .flatMap(redirectUri -> redirectStrategy.sendRedirect(exchange, redirectUri)); } + + private String buildSignupSuccessUrl(String redirectUrl) { + return SIGNUP_SUCCESS_URL + "?redirectUrl=" + URLEncoder.encode(redirectUrl, StandardCharsets.UTF_8); + } + } diff --git a/app/server/appsmith-server/src/main/java/com/appsmith/server/helpers/RedirectHelper.java b/app/server/appsmith-server/src/main/java/com/appsmith/server/helpers/RedirectHelper.java index 443a991992..36d960405b 100644 --- a/app/server/appsmith-server/src/main/java/com/appsmith/server/helpers/RedirectHelper.java +++ b/app/server/appsmith-server/src/main/java/com/appsmith/server/helpers/RedirectHelper.java @@ -21,6 +21,7 @@ import static com.appsmith.server.acl.AclPermission.READ_APPLICATIONS; public class RedirectHelper { public static final String DEFAULT_REDIRECT_URL = "/applications"; + public static final String SIGNUP_SUCCESS_URL = "/signup-success"; public static final String DEFAULT_REDIRECT_ORIGIN = "https://app.appsmith.com"; private static final String REDIRECT_URL_HEADER = "X-Redirect-Url"; private static final String REDIRECT_URL_QUERY_PARAM = "redirectUrl"; From 9c3251be4efedad2ab9795d64953520546619625 Mon Sep 17 00:00:00 2001 From: Sumit Kumar Date: Mon, 21 Jun 2021 19:36:06 +0530 Subject: [PATCH 14/17] Bug Fix: Fix dynamic binding substitution failure with Firestore `where` condition input boxes. (#5280) Modify dynamic binding substitution method to handle list and map types containing generic type values. (cherry picked from commit 7787a0ddacc7f32047b3f0cf8cf0e846a4b7ea90) --- .../external/dtos/ExecuteActionDTO.java | 2 + .../external/helpers/MustacheHelper.java | 87 ++++++++++--------- .../com/appsmith/external/models/Param.java | 4 + .../external/plugins/FirestorePluginTest.java | 85 ++++++++++++++++-- 4 files changed, 131 insertions(+), 47 deletions(-) diff --git a/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/dtos/ExecuteActionDTO.java b/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/dtos/ExecuteActionDTO.java index 6565a8109c..60d3c0307a 100644 --- a/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/dtos/ExecuteActionDTO.java +++ b/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/dtos/ExecuteActionDTO.java @@ -4,11 +4,13 @@ import com.appsmith.external.models.PaginationField; import com.appsmith.external.models.Param; import lombok.Getter; import lombok.Setter; +import lombok.ToString; import java.util.List; @Getter @Setter +@ToString public class ExecuteActionDTO { String actionId; diff --git a/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/helpers/MustacheHelper.java b/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/helpers/MustacheHelper.java index afa5dbd5cc..3dc8147ee7 100644 --- a/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/helpers/MustacheHelper.java +++ b/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/helpers/MustacheHelper.java @@ -4,12 +4,14 @@ import com.appsmith.external.models.ActionConfiguration; import lombok.extern.slf4j.Slf4j; import org.apache.commons.text.StringEscapeUtils; import org.springframework.beans.BeanWrapper; +import org.springframework.beans.BeansException; import org.springframework.beans.PropertyAccessorFactory; import org.springframework.util.StringUtils; import java.beans.PropertyDescriptor; import java.util.ArrayList; import java.util.Collections; +import java.util.HashMap; import java.util.HashSet; import java.util.LinkedList; import java.util.List; @@ -255,56 +257,57 @@ public class MustacheHelper { } } + /** + * - If object is null, then return object. + * - If object is an Appsmith domain object then iterate over all fields of the object and render field values + * for each of them. + * - If object is list type then iterate over each item in the list and render field value for them. + * - If object is map type, then iterate over each value in the map and render field value for them. + * - If the object is string type (base case), then do the binding substitution if applicable. + * - If the object falls under none of the above conditions then return the object without doing anything. + */ public static T renderFieldValues(T object, Map context) { - final BeanWrapper sourceBeanWrapper = PropertyAccessorFactory.forBeanPropertyAccess(object); + if (object == null) { + return object; + } - try { - - for (PropertyDescriptor propertyDescriptor : sourceBeanWrapper.getPropertyDescriptors()) { - // For properties like `class` that don't have a set method, just ignore them. - if (propertyDescriptor.getWriteMethod() == null) { - continue; - } - - String name = propertyDescriptor.getName(); - Object value = sourceBeanWrapper.getPropertyValue(name); - - // If value is null, don't copy it over to target and just move on to the next property. - if (value == null) { - continue; - } - - if (isDomainModel(propertyDescriptor.getPropertyType())) { - // Go deeper *only* if the property belongs to Appsmith's models, and both the source and target - // values are not null. - renderFieldValues(value, context); - - } else if (value instanceof List) { - for (Object childValue : (List) value) { - if (childValue != null && isDomainModel(childValue.getClass())) { - renderFieldValues(childValue, context); - } + if (isDomainModel(object.getClass())) { + try { + final BeanWrapper sourceBeanWrapper = PropertyAccessorFactory.forBeanPropertyAccess(object); + for (PropertyDescriptor propertyDescriptor : sourceBeanWrapper.getPropertyDescriptors()) { + // For properties like `class` that don't have a set method, just ignore them. + if (propertyDescriptor.getWriteMethod() == null) { + continue; } - } else if (value instanceof Map) { - for (Object childValue : ((Map) value).values()) { - if (childValue != null && isDomainModel(childValue.getClass())) { - renderFieldValues(childValue, context); - } - } - - } else if (value instanceof String) { - sourceBeanWrapper.setPropertyValue( - name, - render((String) value, context) - ); - + String name = propertyDescriptor.getName(); + Object value = sourceBeanWrapper.getPropertyValue(name); + sourceBeanWrapper.setPropertyValue(name, renderFieldValues(value, context)); } + } catch (BeansException e) { + log.error("Exception caught while substituting values in mustache template.", e); + } + } else if (object instanceof List) { + List renderedList = new ArrayList(); + for (Object childValue : (List) object) { + renderedList.add(renderFieldValues(childValue, context)); } - } catch (Exception e) { - log.error("Exception caught while substituting values in mustache template.", e); + return (T) renderedList; + } else if (object instanceof Map) { + Map renderedMap = new HashMap(); + for (Object entry : ((Map)object).entrySet()) { + renderedMap.put( + ((Map.Entry) entry).getKey(), // key + renderFieldValues(((Map.Entry) entry).getValue(), context) // value + ); + } + + return (T) renderedMap; + + } else if (object instanceof String) { + return (T) render((String) object, context); } return object; diff --git a/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/models/Param.java b/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/models/Param.java index 2e4d8278eb..5c4bb9234e 100644 --- a/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/models/Param.java +++ b/app/server/appsmith-interfaces/src/main/java/com/appsmith/external/models/Param.java @@ -1,10 +1,14 @@ package com.appsmith.external.models; +import lombok.AllArgsConstructor; import lombok.Getter; +import lombok.NoArgsConstructor; import lombok.Setter; +import lombok.ToString; @Getter @Setter +@ToString public class Param { String key; diff --git a/app/server/appsmith-plugins/firestorePlugin/src/test/java/com/external/plugins/FirestorePluginTest.java b/app/server/appsmith-plugins/firestorePlugin/src/test/java/com/external/plugins/FirestorePluginTest.java index 2a0eba77fa..fd884b70c8 100644 --- a/app/server/appsmith-plugins/firestorePlugin/src/test/java/com/external/plugins/FirestorePluginTest.java +++ b/app/server/appsmith-plugins/firestorePlugin/src/test/java/com/external/plugins/FirestorePluginTest.java @@ -9,6 +9,7 @@ import com.appsmith.external.models.ActionExecutionResult; import com.appsmith.external.models.DBAuth; import com.appsmith.external.models.DatasourceConfiguration; import com.appsmith.external.models.PaginationField; +import com.appsmith.external.models.Param; import com.appsmith.external.models.Property; import com.appsmith.external.models.RequestParamDTO; import com.fasterxml.jackson.core.JsonProcessingException; @@ -710,9 +711,9 @@ public class FirestorePluginTest { * - this returns 2 documents. */ ((List)whereProperty.getValue()).add(new HashMap() {{ - put("path", "category"); + put("path", "{{Input1.text}}"); put("operator", "EQ"); - put("value", "test"); + put("value", "{{Input2.text}}"); }}); /* @@ -720,16 +721,36 @@ public class FirestorePluginTest { * - Of the two documents returned by above condition, this will narrow it down to one. */ ((List)whereProperty.getValue()).add(new HashMap() {{ - put("path", "name"); + put("path", "{{Input3.text}}"); put("operator", "EQ"); - put("value", "two"); + put("value", "{{Input4.text}}"); }}); pluginSpecifiedTemplates.add(whereProperty); actionConfiguration.setPluginSpecifiedTemplates(pluginSpecifiedTemplates); + List params = new ArrayList(); + Param param = new Param(); + param.setKey("Input1.text"); + param.setValue("category"); + params.add(param); + param = new Param(); + param.setKey("Input2.text"); + param.setValue("test"); + params.add(param); + param = new Param(); + param.setKey("Input3.text"); + param.setValue("name"); + params.add(param); + param = new Param(); + param.setKey("Input4.text"); + param.setValue("two"); + params.add(param); + + ExecuteActionDTO executeActionDTO = new ExecuteActionDTO(); + executeActionDTO.setParams(params); Mono resultMono = pluginExecutor - .executeParameterized(firestoreConnection, null, dsConfig, actionConfiguration); + .executeParameterized(firestoreConnection, executeActionDTO, dsConfig, actionConfiguration); StepVerifier.create(resultMono) .assertNext(result -> { @@ -755,6 +776,7 @@ public class FirestorePluginTest { .verifyComplete(); } + @Test public void testUpdateDocumentWithFieldValueTimestamp() { List properties = new ArrayList<>(); properties.add(new Property("method", "UPDATE_DOCUMENT")); // index 0 @@ -1011,4 +1033,57 @@ public class FirestorePluginTest { }) .verifyComplete(); } + + @Test + public void testDynamicBindingSubstitutionInActionConfiguration() { + ActionConfiguration actionConfiguration = new ActionConfiguration(); + actionConfiguration.setPath("{{Input1.text}}"); + List pluginSpecifiedTemplates = new ArrayList<>(); + pluginSpecifiedTemplates.add(new Property("method", "GET_COLLECTION")); + pluginSpecifiedTemplates.add(new Property("order", null)); + pluginSpecifiedTemplates.add(new Property("limit", null)); + Property whereProperty = new Property("where", null); + whereProperty.setValue(new ArrayList<>()); + /* + * - get all documents where category == test. + * - this returns 2 documents. + */ + ((List)whereProperty.getValue()).add(new HashMap() {{ + put("path", "{{Input2.text}}"); + put("operator", "EQ"); + put("value", "{{Input3.text}}"); + }}); + + pluginSpecifiedTemplates.add(whereProperty); + actionConfiguration.setPluginSpecifiedTemplates(pluginSpecifiedTemplates); + + List params = new ArrayList(); + Param param = new Param(); + param.setKey("Input1.text"); + param.setValue("initial"); + params.add(param); + param = new Param(); + param.setKey("Input2.text"); + param.setValue("category"); + params.add(param); + param = new Param(); + param.setKey("Input3.text"); + param.setValue("test"); + params.add(param); + ExecuteActionDTO executeActionDTO = new ExecuteActionDTO(); + executeActionDTO.setParams(params); + + // Substitute dynamic binding values + pluginExecutor + .prepareConfigurationsForExecution(executeActionDTO, actionConfiguration, null); + + // check if dynamic binding values have been substituted correctly + assertEquals("initial", actionConfiguration.getPath()); + assertEquals("category", + ((Map)((List)actionConfiguration.getPluginSpecifiedTemplates().get(3).getValue()).get(0)).get( + "path")); + assertEquals("test", + ((Map)((List)actionConfiguration.getPluginSpecifiedTemplates().get(3).getValue()).get(0)).get( + "value")); + } } From bce98c55e3f618508c677b6cc3573d76b0bb871f Mon Sep 17 00:00:00 2001 From: Rishabh Saxena Date: Mon, 28 Jun 2021 13:08:44 +0530 Subject: [PATCH 15/17] Onboarding typeform related fixes (#5416) --- .../src/pages/Applications/OnboardingForm.tsx | 7 ++- app/client/src/pages/Applications/index.tsx | 47 +++++++++++++++---- app/client/src/utils/storage.ts | 28 +++++++++++ 3 files changed, 71 insertions(+), 11 deletions(-) diff --git a/app/client/src/pages/Applications/OnboardingForm.tsx b/app/client/src/pages/Applications/OnboardingForm.tsx index 7e1ca92b99..f573d62b10 100644 --- a/app/client/src/pages/Applications/OnboardingForm.tsx +++ b/app/client/src/pages/Applications/OnboardingForm.tsx @@ -1,8 +1,9 @@ -import React from "react"; +import React, { useEffect } from "react"; import { useSelector } from "react-redux"; import { useScript, ScriptStatus } from "utils/hooks/useScript"; import { getCurrentUser } from "selectors/usersSelectors"; import styled from "styled-components"; +import { setOnboardingFormInProgress } from "utils/storage"; export const TypeformContainer = styled.div` & iframe { @@ -19,6 +20,10 @@ function OnboardingForm() { const status = useScript(`https://embed.typeform.com/embed.js`); const currentUser = useSelector(getCurrentUser); + useEffect(() => { + setOnboardingFormInProgress(true); + }, []); + if (status !== ScriptStatus.READY || !currentUser) return null; return ( diff --git a/app/client/src/pages/Applications/index.tsx b/app/client/src/pages/Applications/index.tsx index e23314c79b..64c44d95a9 100644 --- a/app/client/src/pages/Applications/index.tsx +++ b/app/client/src/pages/Applications/index.tsx @@ -83,6 +83,10 @@ import ImportApplicationModal from "./ImportApplicationModal"; import OnboardingForm from "./OnboardingForm"; import { getAppsmithConfigs } from "configs"; import { SIGNUP_SUCCESS_URL } from "constants/routes"; +import { + setOnboardingFormInProgress, + getOnboardingFormInProgress, +} from "utils/storage"; const OrgDropDown = styled.div` display: flex; @@ -911,24 +915,47 @@ class Applications extends Component< PerformanceTracker.stopTracking(PerformanceTransactionName.LOGIN_CLICK); PerformanceTracker.stopTracking(PerformanceTransactionName.SIGN_UP); this.props.getAllApplication(); + window.addEventListener("message", this.handleTypeFormMessage, false); + this.showOnboardingForm(); + } + + componentWillUnmount() { + window.removeEventListener("message", this.handleTypeFormMessage); + } + + showOnboardingForm = async () => { const isFromSignUp = getIsFromSignup(); + const isOnboardingFormInProgress = await getOnboardingFormInProgress(); + const showOnboardingForm = + onboardingFormEnabled && (isFromSignUp || isOnboardingFormInProgress); this.setState({ - showOnboardingForm: isFromSignUp && onboardingFormEnabled, + showOnboardingForm: !!showOnboardingForm, }); // Redirect directly in case we're not showing the onboarding form if (isFromSignUp && !onboardingFormEnabled) { - const urlObject = new URL(window.location.href); - const redirectUrl = urlObject?.searchParams.get("redirectUrl"); - if (redirectUrl) { - try { - window.location.replace(redirectUrl); - } catch (e) { - console.error("Error handling the redirect url"); - } + this.redirectUsingQueryParam(); + } + }; + + redirectUsingQueryParam = () => { + const urlObject = new URL(window.location.href); + const redirectUrl = urlObject?.searchParams.get("redirectUrl"); + if (redirectUrl) { + try { + window.location.replace(redirectUrl); + } catch (e) { + console.error("Error handling the redirect url"); } } - } + }; + + handleTypeFormMessage = (event: any) => { + if (event?.data?.type === "form-submit" && this.state.showOnboardingForm) { + setOnboardingFormInProgress(); + this.redirectUsingQueryParam(); + } + }; public render() { return ( diff --git a/app/client/src/utils/storage.ts b/app/client/src/utils/storage.ts index 2fb222bd15..abff1ab1c6 100644 --- a/app/client/src/utils/storage.ts +++ b/app/client/src/utils/storage.ts @@ -11,6 +11,7 @@ const STORAGE_KEYS: { [id: string]: string } = { ONBOARDING_WELCOME_STATE: "OnboardingWelcomeState", RECENT_ENTITIES: "RecentEntities", COMMENTS_INTRO_SEEN: "CommentsIntroSeen", + ONBOARDING_FORM_IN_PROGRESS: "ONBOARDING_FORM_IN_PROGRESS", }; const store = localforage.createInstance({ @@ -204,3 +205,30 @@ export const getCommentsIntroSeen = async () => { console.log("An error occurred while fetching COMMENTS_INTRO_SEEN", error); } }; + +export const setOnboardingFormInProgress = async (flag?: boolean) => { + try { + await store.setItem(STORAGE_KEYS.ONBOARDING_FORM_IN_PROGRESS, flag); + return true; + } catch (error) { + console.log( + "An error occurred when setting ONBOARDING_FORM_IN_PROGRESS", + error, + ); + return false; + } +}; + +export const getOnboardingFormInProgress = async () => { + try { + const onboardingFormInProgress = await store.getItem( + STORAGE_KEYS.ONBOARDING_FORM_IN_PROGRESS, + ); + return onboardingFormInProgress; + } catch (error) { + console.log( + "An error occurred while fetching ONBOARDING_FORM_IN_PROGRESS", + error, + ); + } +}; From 1d7a9033bd6c9c142e9af803b3b9ed8d9fc4857e Mon Sep 17 00:00:00 2001 From: Shrikant Sharat Kandula Date: Thu, 1 Jul 2021 11:54:54 +0530 Subject: [PATCH 16/17] Fix missing quotes in generated nginx conf (cherry picked from commit b051b010fc569a682116acb115c9459ae7ae14d3) --- deploy/template/nginx_app.conf.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/deploy/template/nginx_app.conf.sh b/deploy/template/nginx_app.conf.sh index 8954753b82..0e56aa3361 100644 --- a/deploy/template/nginx_app.conf.sh +++ b/deploy/template/nginx_app.conf.sh @@ -109,8 +109,8 @@ $NGINX_SSL_CMNT sub_filter __APPSMITH_VERSION_RELEASE_DATE__ '\${APPSMITH $NGINX_SSL_CMNT sub_filter __APPSMITH_INTERCOM_APP_ID__ '\${APPSMITH_INTERCOM_APP_ID}'; $NGINX_SSL_CMNT sub_filter __APPSMITH_MAIL_ENABLED__ '\${APPSMITH_MAIL_ENABLED}'; $NGINX_SSL_CMNT sub_filter __APPSMITH_DISABLE_TELEMETRY__ '\${APPSMITH_DISABLE_TELEMETRY}'; -$NGINX_SSL_CMNT sub_filter __APPSMITH_RECAPTCHA_SITE_KEY__ '\${APPSMITH_RECAPTCHA_SITE_KEY}; -$NGINX_SSL_CMNT sub_filter __APPSMITH_RECAPTCHA_SECRET_KEY__ '\${APPSMITH_RECAPTCHA_SECRET_KEY}; +$NGINX_SSL_CMNT sub_filter __APPSMITH_RECAPTCHA_SITE_KEY__ '\${APPSMITH_RECAPTCHA_SITE_KEY}'; +$NGINX_SSL_CMNT sub_filter __APPSMITH_RECAPTCHA_SECRET_KEY__ '\${APPSMITH_RECAPTCHA_SECRET_KEY}'; $NGINX_SSL_CMNT sub_filter __APPSMITH_RECAPTCHA_ENABLED__ '\${APPSMITH_RECAPTCHA_ENABLED}'; $NGINX_SSL_CMNT } $NGINX_SSL_CMNT From 14fc506613745f7c4aa298f2694f539753ab99a6 Mon Sep 17 00:00:00 2001 From: Hetu Nandu Date: Mon, 5 Jul 2021 17:15:21 +0530 Subject: [PATCH 17/17] Add node-forge crypto libraries (#5597) --- app/client/package.json | 2 + app/client/src/constants/defs/forge.json | 11263 ++++++++++++++++ app/client/src/utils/DynamicBindingUtils.ts | 10 + .../src/utils/autocomplete/TernServer.ts | 3 +- app/client/yarn.lock | 8 + 5 files changed, 11285 insertions(+), 1 deletion(-) create mode 100644 app/client/src/constants/defs/forge.json diff --git a/app/client/package.json b/app/client/package.json index 875dc7b839..68dfc235ee 100644 --- a/app/client/package.json +++ b/app/client/package.json @@ -91,6 +91,7 @@ "moment": "^2.24.0", "moment-timezone": "^0.5.27", "nanoid": "^2.0.4", + "node-forge": "^0.10.0", "node-sass": "^4.11.0", "normalizr": "^3.3.0", "path-to-regexp": "^6.2.0", @@ -204,6 +205,7 @@ "@types/jest": "^24.0.22", "@types/jshint": "^2.12.0", "@types/marked": "^1.2.2", + "@types/node-forge": "^0.10.0", "@types/react-beautiful-dnd": "^11.0.4", "@types/react-select": "^3.0.5", "@types/react-tabs": "^2.3.1", diff --git a/app/client/src/constants/defs/forge.json b/app/client/src/constants/defs/forge.json new file mode 100644 index 0000000000..876bb7a773 --- /dev/null +++ b/app/client/src/constants/defs/forge.json @@ -0,0 +1,11263 @@ +{ + "!name": "../../node-forge/lib/aes.js", + "!define": { + "forge.aes.Algorithm.prototype.initialize.!0": { + "key": { + "!type": "string", + "!span": "2009[76:4]-2012[76:7]" + }, + "decrypt": { + "!type": "bool", + "!span": "2023[77:4]-2030[77:11]" + } + }, + "forge.aes.Algorithm.!1": { + "prototype": { + "encrypt": {}, + "afterFinish": {}, + "generateHashTable": {}, + "generateSubHashTable": {}, + "start": "modes.gcm.prototype.start", + "decrypt": "modes.gcm.prototype.decrypt", + "multiply": "modes.gcm.prototype.multiply", + "pow": "modes.gcm.prototype.pow", + "tableMultiply": "modes.gcm.prototype.tableMultiply", + "ghash": "modes.gcm.prototype.ghash" + } + }, + "forge.aes.Algorithm.!1.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "19360[681:12]-19364[681:16]" + } + }, + "forge.aes.Algorithm.!1.prototype.afterFinish.!1": { + "decrypt": { + "!type": "bool", + "!span": "6102[201:10]-6109[201:17]" + }, + "overflow": { + "!type": "number", + "!span": "6182[204:10]-6190[204:18]", + "!doc": "get # of bytes that won't fill a block" + } + }, + "forge.aes.Algorithm.!1.!0": { + "blockSize": { + "!type": "number", + "!span": "4691[159:4]-4700[159:13]" + }, + "cipher": { + "encrypt": "modes.gcm.cipher.encrypt", + "decrypt": "modes.gcm.cipher.decrypt" + } + }, + "forge.asn1.create.!ret": { + "tagClass": { + "!type": "number", + "!span": "8212[212:4]-8220[212:12]" + }, + "type": { + "!type": "number", + "!span": "8236[213:4]-8240[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "8252[214:4]-8263[214:15]" + }, + "composed": { + "!type": "bool", + "!span": "8282[215:4]-8290[215:12]" + }, + "read": { + "!type": "number", + "!span": "19652[653:42]-19656[655:1]" + }, + "original": "_fromDer.!ret" + }, + "forge.asn1.validate.!1": { + "name": { + "!type": "string", + "!span": "12601[409:2]-12605[409:6]" + }, + "tagClass": { + "!type": "number", + "!span": "12637[410:2]-12645[410:10]" + }, + "type": { + "!type": "number", + "!span": "12671[411:2]-12675[411:6]" + }, + "constructed": { + "!type": "bool", + "!span": "12699[412:2]-12710[412:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "12720[413:2]-12731[413:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "12777[415:4]-12781[415:8]" + }, + "tagClass": { + "!type": "number", + "!span": "12823[416:4]-12831[416:12]" + }, + "type": { + "!type": "number", + "!span": "12859[417:4]-12863[417:8]" + }, + "constructed": { + "!type": "bool", + "!span": "12888[418:4]-12899[418:15]" + }, + "capture": { + "!type": "string", + "!span": "12912[419:4]-12919[419:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "13002[422:4]-13006[422:8]", + "!doc": "Name (subject) (RDNSequence)" + }, + "tagClass": { + "!type": "number", + "!span": "13048[423:4]-13056[423:12]" + }, + "type": { + "!type": "number", + "!span": "13084[424:4]-13088[424:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13114[425:4]-13125[425:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "13137[426:4]-13148[426:15]" + } + }, + "2": { + "name": { + "!type": "string", + "!span": "6195[231:2]-6199[231:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6227[232:2]-6235[232:10]" + }, + "type": { + "!type": "number", + "!span": "6261[233:2]-6265[233:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6289[234:2]-6300[234:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6310[235:2]-6321[235:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6363[237:4]-6367[237:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6417[238:4]-6425[238:12]" + }, + "type": { + "!type": "number", + "!span": "6453[239:4]-6457[239:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6483[240:4]-6494[240:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6522[242:6]-6526[242:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6567[243:6]-6575[243:14]" + }, + "type": { + "!type": "number", + "!span": "6605[244:6]-6609[244:10]" + }, + "constructed": { + "!type": "bool", + "!span": "6632[245:6]-6643[245:17]" + }, + "capture": { + "!type": "string", + "!span": "6658[246:6]-6665[246:13]" + } + } + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6724[250:4]-6728[250:8]", + "!doc": "subjectPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6775[251:4]-6783[251:12]" + }, + "type": { + "!type": "number", + "!span": "6811[252:4]-6815[252:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6842[253:4]-6853[253:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6904[256:6]-6908[256:10]", + "!doc": "RSAPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6970[257:6]-6978[257:14]" + }, + "type": { + "!type": "number", + "!span": "7008[258:6]-7012[258:10]" + }, + "constructed": { + "!type": "bool", + "!span": "7040[259:6]-7051[259:17]" + }, + "optional": { + "!type": "bool", + "!span": "7065[260:6]-7073[260:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "7087[261:6]-7098[261:17]" + } + } + } + } + } + }, + "3": { + "name": { + "!type": "string", + "!span": "13245[431:4]-13249[431:8]" + }, + "tagClass": { + "!type": "number", + "!span": "13294[432:4]-13302[432:12]" + }, + "type": { + "!type": "number", + "!span": "13337[433:4]-13341[433:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13350[434:4]-13361[434:15]" + }, + "optional": { + "!type": "bool", + "!span": "13373[435:4]-13381[435:12]" + }, + "capture": { + "!type": "string", + "!span": "13393[436:4]-13400[436:11]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "13460[438:6]-13464[438:10]" + }, + "tagClass": { + "!type": "number", + "!span": "13511[439:6]-13519[439:14]" + }, + "type": { + "!type": "number", + "!span": "13549[440:6]-13553[440:10]" + }, + "constructed": { + "!type": "bool", + "!span": "13581[441:6]-13592[441:17]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "13624[443:8]-13628[443:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13682[444:8]-13690[444:16]" + }, + "type": { + "!type": "number", + "!span": "13722[445:8]-13726[445:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13751[446:8]-13762[446:19]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "13789[448:8]-13793[448:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13848[449:8]-13856[449:16]" + }, + "type": { + "!type": "number", + "!span": "13888[450:8]-13892[450:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13917[451:8]-13928[451:19]" + } + } + } + } + } + } + } + }, + "forge.asn1.prettyPrint.!0": { + "tagClass": { + "!type": "number", + "!span": "9228[254:4]-9236[254:12]" + }, + "type": { + "!type": "number", + "!span": "9256[255:4]-9260[255:8]" + }, + "constructed": { + "!type": "bool", + "!span": "9276[256:4]-9287[256:15]" + }, + "composed": { + "!type": "bool", + "!span": "9310[257:4]-9318[257:12]" + } + }, + "forge.cipher.algorithms..!ret": "+forge.des.Algorithm", + "forge.cipher.BlockCipher.!0": { + "key": { + "!type": "string", + "!span": "2009[76:4]-2012[76:7]" + }, + "decrypt": { + "!type": "bool", + "!span": "2023[77:4]-2030[77:11]" + } + }, + "forge.cipher.modes.ecb.prototype.unpad.!1": { + "decrypt": { + "!type": "bool", + "!span": "6102[201:10]-6109[201:17]" + }, + "overflow": { + "!type": "number", + "!span": "6182[204:10]-6190[204:18]", + "!doc": "get # of bytes that won't fill a block" + } + }, + "forge.cipher.modes.ecb.!0": { + "blockSize": { + "!type": "number", + "!span": "4691[159:4]-4700[159:13]" + }, + "cipher": { + "encrypt": "modes.gcm.cipher.encrypt", + "decrypt": "modes.gcm.cipher.decrypt" + } + }, + "forge.cipher.modes.cfb.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "6987[257:10]-6991[257:14]" + } + }, + "forge.cipher.modes.cfb.prototype.decrypt.!0": { + "read": { + "!type": "number", + "!span": "8719[317:10]-8723[317:14]" + } + }, + "forge.cipher.modes.ofb.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "11014[400:10]-11018[400:14]" + } + }, + "forge.cipher.modes.ctr.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "13308[482:12]-13312[482:16]" + } + }, + "forge.cipher.modes.gcm.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "19360[681:12]-19364[681:16]" + } + }, + "forge.des.Algorithm.prototype.initialize.!0": { + "plugin": { + "md": { + "create": {} + }, + "formatKey": "forge.random.plugin.formatKey", + "formatSeed": "forge.random.plugin.formatSeed", + "cipher": "forge.random.plugin.cipher", + "increment": "forge.random.plugin.increment" + }, + "reseeds": { + "!type": "number", + "!span": "1481[48:4]-1488[48:11]", + "!doc": "update reseed count" + }, + "generated": { + "!type": "number", + "!span": "1536[50:4]-1545[50:13]", + "!doc": "amount of data generated so far" + }, + "keyBytes": { + "!type": "string", + "!span": "1582[52:4]-1590[52:12]", + "!doc": "get digest for key bytes" + }, + "pools": { + "": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + } + }, + "pool": { + "!type": "number", + "!span": "1866[64:6]-1870[64:10]", + "!doc": "entropy pools are written to cyclically, starting at index 0" + }, + "seed": "forge.random.seed", + "generate": "forge.random.generate", + "generateSync": "forge.random.generateSync", + "seedFile": "forge.random.seedFile", + "seedFileSync": "forge.random.seedFileSync", + "collect": "forge.random.collect", + "collectInt": "forge.random.collectInt", + "registerWorker": "forge.random.registerWorker", + "getBytes": "forge.random.getBytes", + "getBytesSync": "forge.random.getBytesSync", + "createInstance": "forge.random.createInstance" + }, + "forge.des.Algorithm.prototype.initialize.!0.plugin.md.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + }, + "forge.pki.ed25519.generateKeyPair.!0": { + "seed": { + "!type": "+Float32Array", + "!span": "5339[164:43]-5343[164:47]" + } + }, + "forge.pki.pbe.generatePkcs12Key.!5": { + "algorithm": { + "!type": "string", + "!span": "2315[98:4]-2324[98:13]", + "!doc": "SHA-512 => sha512" + }, + "blockLength": { + "!type": "number", + "!span": "2372[99:4]-2383[99:15]" + }, + "digestLength": { + "!type": "number", + "!span": "2394[100:4]-2406[100:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "2611[106:4]-2628[106:21]", + "!doc": "size of message length in bytes" + }, + "messageLength128": "_createKDF.!1.fullMessageLength", + "fullMessageLength": "_createKDF.!1.fullMessageLength", + "start": "_createKDF.!1.start", + "update": "_createKDF.!1.update", + "digest": "_createKDF.!1.digest" + }, + "forge.pki.pbe.opensslDeriveBytes.!3": { + "algorithm": { + "!type": "string", + "!span": "746[36:4]-755[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "768[37:4]-779[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "789[38:4]-801[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "996[44:4]-1013[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "hash.!0.fullMessageLength", + "fullMessageLength": "hash.!0.fullMessageLength", + "start": "hash.!0.start", + "update": "hash.!0.update", + "digest": "hash.!0.digest" + }, + "forge.pki.encryptPrivateKeyInfo.!2": { + "legacy": { + "!type": "bool", + "!span": "4915[152:5]-4921[152:11]" + }, + "algorithm": { + "!type": "string", + "!span": "4929[152:19]-4938[152:28]" + }, + "saltSize": { + "!type": "number", + "!span": "6295[196:28]-6303[196:36]" + }, + "count": { + "!type": "number", + "!span": "6339[198:30]-6344[198:35]" + }, + "prfAlgorithm": { + "!type": "string", + "!span": "6433[202:5]-6445[202:17]" + } + }, + "forge.pki.encryptedPrivateKeyFromPem.!0": { + "encode": {}, + "decode": {} + }, + "forge.pki.encryptedPrivateKeyFromPem.!0.encode.!0": { + "type": { + "!type": "string", + "!span": "27457[901:4]-27461[901:8]" + } + }, + "forge.pki.encryptedPrivateKeyFromPem.!0.decode.!ret": { + "": { + "type": { + "!type": "string", + "!span": "3012[109:6]-3016[109:10]" + }, + "procType": { + "version": { + "!type": "string", + "!span": "4449[158:26]-4456[158:33]" + }, + "type": { + "!type": "string", + "!span": "4469[158:46]-4473[158:50]" + } + }, + "contentDomain": { + "!type": "string", + "!span": "3056[111:6]-3069[111:19]", + "!doc": "special-case Content-Domain" + }, + "dekInfo": { + "algorithm": { + "!type": "string", + "!span": "4967[168:25]-4976[168:34]" + }, + "parameters": { + "!type": "string", + "!span": "4989[168:47]-4999[168:57]" + } + }, + "headers": { + "": { + "name": { + "!type": "string", + "!span": "3797[143:22]-3801[143:26]" + }, + "values": "pem.decode.!ret..headers..values" + } + }, + "body": { + "!type": "string", + "!span": "3123[114:6]-3127[114:10]" + } + } + }, + "forge.pki.privateKeyFromPem.!0": { + "read": { + "!type": "number", + "!span": "19652[656:10]-19656[656:14]" + }, + "e": "+BigInteger", + "d": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger", + "n": "+BigInteger", + "decrypt": "_modPow.!1.decrypt", + "sign": "_modPow.!1.sign" + }, + "forge.pki.rsa.createKeyPairGenerationState.!ret": { + "algorithm": { + "!type": "string", + "!span": "18660[622:6]-18669[622:15]" + }, + "state": { + "!type": "number", + "!span": "18688[623:6]-18693[623:11]" + }, + "bits": { + "!type": "number", + "!span": "18704[624:6]-18708[624:10]" + }, + "eInt": { + "!type": "number", + "!span": "18738[626:6]-18742[626:10]" + }, + "qBits": { + "!type": "number", + "!span": "18823[630:6]-18828[630:11]" + }, + "pBits": { + "!type": "number", + "!span": "18847[631:6]-18852[631:11]" + }, + "pqState": { + "!type": "number", + "!span": "18880[632:6]-18887[632:13]", + "!doc": "store p or q" + }, + "e": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "num": "+BigInteger", + "keys": { + "privateKey": "_modPow.!1", + "publicKey": "_publicKeyFromJwk.!ret" + }, + "p1": "+BigInteger", + "q1": "+BigInteger", + "phi": "+BigInteger", + "n": "+BigInteger", + "rng": { + "nextBytes": "_generateKeyPair.!0.rng.nextBytes" + } + }, + "forge.pki.RDNAttributesAsArray.!1": { + "algorithm": { + "!type": "string", + "!span": "753[36:4]-762[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "776[37:4]-787[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "797[38:4]-809[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1004[44:4]-1021[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "rsa_mgf1.!2.fullMessageLength", + "fullMessageLength": "rsa_mgf1.!2.fullMessageLength", + "start": "rsa_mgf1.!2.start", + "update": "rsa_mgf1.!2.update", + "digest": "rsa_mgf1.!2.digest" + }, + "forge.pki.RDNAttributesAsArray.!ret": { + "": { + "type": { + "!type": "string", + "!span": "15894[517:10]-15898[517:14]" + }, + "name": { + "!type": "string", + "!span": "16121[522:12]-16125[522:16]" + } + } + }, + "forge.pki.CRIAttributesAsArray.!ret": { + "": { + "type": { + "!type": "string", + "!span": "17085[558:10]-17089[558:14]" + }, + "name": { + "!type": "string", + "!span": "17276[563:12]-17280[563:16]" + }, + "extensions": { + "": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "altNames": { + "": { + "type": { + "!type": "number", + "!span": "49364[1597:10]-49368[1597:14]" + }, + "ip": { + "!type": "string", + "!span": "49804[1614:20]-49806[1614:22]", + "!doc": "convert to IPv4/IPv6 string representation" + }, + "oid": { + "!type": "string", + "!span": "49924[1618:20]-49927[1618:23]" + } + } + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + } + } + } + } + }, + "forge.pki.certificateFromPem.!ret": { + "version": { + "!type": "number", + "!span": "27761[914:7]-27768[914:14]" + }, + "serialNumber": { + "!type": "string", + "!span": "27784[915:7]-27796[915:19]" + }, + "signatureOid": { + "!type": "string", + "!span": "27812[916:7]-27824[916:19]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "27894[919:15]-27906[919:27]" + }, + "parameters": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + } + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + } + } + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + } + } + }, + "issuer": { + "hash": { + "!type": "string", + "!span": "28288[933:14]-28292[933:18]" + }, + "getField": {}, + "attributes": "pki.RDNAttributesAsArray.!ret", + "addField": "pki.certificateFromPem.!ret.issuer.addField" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "28580[944:15]-28584[944:19]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "pki.certificateFromPem.!ret.subject.getField", + "addField": "pki.certificateFromPem.!ret.subject.addField" + }, + "extensions": { + "": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "altNames": { + "": { + "type": { + "!type": "number", + "!span": "49364[1597:10]-49368[1597:14]" + }, + "ip": { + "!type": "string", + "!span": "49804[1614:20]-49806[1614:22]", + "!doc": "convert to IPv4/IPv6 string representation" + }, + "oid": { + "!type": "string", + "!span": "49924[1618:20]-49927[1618:23]" + } + } + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + } + } + }, + "sign": {}, + "signatureParameters": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + } + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + } + } + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + } + }, + "read": { + "!type": "number", + "!span": "19652[645:18]-19656[645:22]" + }, + "validity": { + "notBefore": "+Date", + "notAfter": "+Date" + }, + "publicKey": "_publicKeyFromJwk.!ret", + "md": "_createKDF.!1", + "tbsCertificate": "_fromDer.!ret", + "setSubject": "pki.certificateFromPem.!ret.setSubject", + "setIssuer": "pki.certificateFromPem.!ret.setIssuer", + "setExtensions": "pki.certificateFromPem.!ret.setExtensions", + "getExtension": "pki.certificateFromPem.!ret.getExtension", + "verify": "pki.certificateFromPem.!ret.verify", + "isIssuer": "pki.certificateFromPem.!ret.isIssuer", + "issued": "pki.certificateFromPem.!ret.issued", + "generateSubjectKeyIdentifier": "pki.certificateFromPem.!ret.generateSubjectKeyIdentifier", + "verifySubjectKeyIdentifier": "pki.certificateFromPem.!ret.verifySubjectKeyIdentifier" + }, + "forge.pki.certificateFromPem.!ret.sign.!0": { + "version": { + "!type": "number", + "!span": "54558[1755:6]-54565[1755:13]" + }, + "signatureOid": { + "!type": "string", + "!span": "54580[1756:6]-54592[1756:18]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "54659[1759:14]-54671[1759:26]" + }, + "parameters": "_readSignatureParameters.!ret" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "_dnToAsn1.!0.getField", + "addField": "_dnToAsn1.!0.addField" + }, + "publicKey": "_publicKeyFromJwk.!ret", + "attributes": "pki.CRIAttributesAsArray.!ret", + "md": "_createKDF.!1", + "certificationRequestInfo": "_fromDer.!ret", + "signatureParameters": "_readSignatureParameters.!ret", + "getAttribute": "_getAttribute.!0.getAttribute", + "addAttribute": "_getAttribute.!0.addAttribute", + "setSubject": "_getAttribute.!0.setSubject", + "setAttributes": "_getAttribute.!0.setAttributes", + "sign": "_getAttribute.!0.sign", + "verify": "_getAttribute.!0.verify" + }, + "forge.pki.getPublicKeyFingerprint.!1": { + "type": { + "!type": "string", + "!span": "37654[1236:56]-37658[1236:60]" + } + }, + "forge.pki.certificationRequestFromPem.!ret": { + "version": { + "!type": "number", + "!span": "54558[1755:6]-54565[1755:13]" + }, + "signatureOid": { + "!type": "string", + "!span": "54580[1756:6]-54592[1756:18]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "54659[1759:14]-54671[1759:26]" + }, + "parameters": "_readSignatureParameters.!ret" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "_dnToAsn1.!0.getField", + "addField": "_dnToAsn1.!0.addField" + }, + "publicKey": "_publicKeyFromJwk.!ret", + "attributes": "pki.CRIAttributesAsArray.!ret", + "getAttribute": {}, + "md": "_createKDF.!1", + "certificationRequestInfo": "_fromDer.!ret", + "signatureParameters": "_readSignatureParameters.!ret", + "addAttribute": "_getAttribute.!0.addAttribute", + "setSubject": "_getAttribute.!0.setSubject", + "setAttributes": "_getAttribute.!0.setAttributes", + "sign": "_getAttribute.!0.sign", + "verify": "_getAttribute.!0.verify" + }, + "forge.pki.certificateExtensionsFromAsn1.!0": { + "type": { + "!type": "number", + "!span": "49364[1597:10]-49368[1597:14]" + }, + "ip": { + "!type": "string", + "!span": "49804[1614:20]-49806[1614:22]", + "!doc": "convert to IPv4/IPv6 string representation" + }, + "oid": { + "!type": "string", + "!span": "49924[1618:20]-49927[1618:23]" + } + }, + "forge.pki.certificateExtensionsFromAsn1.!ret": { + "": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + }, + "altNames": { + "": "pki.certificateExtensionsFromAsn1.!0" + } + } + }, + "forge.pki.certificateExtensionFromAsn1.!ret": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + }, + "altNames": { + "": "pki.certificateExtensionsFromAsn1.!0" + } + }, + "forge.http.createClient.!0": { + "url": { + "!type": "string", + "!span": "12551[397:8]-12554[397:11]" + }, + "socketPool": { + "sockets": { + "": { + "connected": {}, + "closed": {}, + "data": {}, + "error": {}, + "connect": {}, + "options": { + "request": { + "version": { + "!type": "string", + "!span": "25249[872:10]-25256[872:17]" + }, + "body": { + "!type": "string", + "!span": "25382[875:10]-25386[875:14]", + "!doc": "inflate using flash api" + }, + "bodyDeflated": { + "!type": "bool", + "!span": "25421[876:10]-25433[876:22]" + }, + "addCookie": {}, + "code": { + "!type": "number", + "!span": "28698[994:11]-28702[994:15]" + }, + "message": { + "!type": "string", + "!span": "28719[995:11]-28726[995:18]" + }, + "headerReceived": { + "!type": "bool", + "!span": "28770[997:11]-28784[997:25]", + "!doc": "handle final line, end of header" + }, + "bodyReceived": { + "!type": "bool", + "!span": "28805[998:11]-28817[998:23]", + "!doc": "body received" + }, + "readBodyUntilClose": { + "!type": "bool", + "!span": "34861[1193:15]-34879[1193:33]" + }, + "time": { + "!type": "number", + "!span": "35036[1201:15]-35040[1201:19]" + }, + "aborted": { + "!type": "bool", + "!span": "17397[562:23]-17404[562:30]" + }, + "connectTime": { + "!type": "number", + "!span": "3048[106:13]-3059[106:24]" + }, + "getCookies": {}, + "fields": { + "": "net.socketPools..sockets..options.request.fields." + }, + "setField": "net.socketPools..sockets..options.request.setField", + "appendField": "net.socketPools..sockets..options.request.appendField", + "getField": "net.socketPools..sockets..options.request.getField", + "toString": "net.socketPools..sockets..options.request.toString", + "readHeader": "net.socketPools..sockets..options.request.readHeader", + "readBody": "net.socketPools..sockets..options.request.readBody", + "abort": "net.socketPools..sockets..options.request.abort" + }, + "error": {}, + "headerReady": {}, + "bodyReady": {}, + "response": "net.socketPools..sockets..options.request", + "connected": "net.socketPools..sockets..options.connected", + "closed": "net.socketPools..sockets..options.closed" + }, + "sending": { + "!type": "bool", + "!span": "5219[171:3]-5226[171:10]" + }, + "retries": { + "!type": "number", + "!span": "4067[126:57]-4074[128:3]" + }, + "buffer": "+ByteBuffer", + "destroy": "net.socketPools..sockets..destroy", + "close": "net.socketPools..sockets..close", + "isConnected": "net.socketPools..sockets..isConnected", + "send": "net.socketPools..sockets..send", + "receive": "net.socketPools..sockets..receive", + "bytesAvailable": "net.socketPools..sockets..bytesAvailable" + } + }, + "policyPort": { + "!type": "number", + "!span": "1268[47:4]-1278[47:14]", + "!doc": "default policy port" + }, + "handler": "net.socketPools..handler", + "destroy": "net.socketPools..destroy", + "createSocket": "net.socketPools..createSocket" + }, + "policyPort": { + "!type": "number", + "!span": "12602[399:8]-12612[399:18]" + }, + "connections": { + "!type": "number", + "!span": "12709[401:8]-12720[401:19]" + }, + "persistCookies": { + "!type": "bool", + "!span": "12848[404:8]-12862[404:22]" + }, + "primeTlsSockets": { + "!type": "bool", + "!span": "12904[405:8]-12919[405:23]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..connected.!0": { + "type": { + "!type": "string", + "!span": "2282[66:10]-2286[66:14]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2309[67:10]-2323[67:24]" + }, + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!0.socketPool.sockets..closed.!0": { + "type": { + "!type": "string", + "!span": "5447[189:9]-5451[189:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "5471[190:9]-5485[190:23]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..data.!0": { + "type": { + "!type": "string", + "!span": "2617[79:8]-2621[79:12]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2645[80:8]-2659[80:22]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..error.!0": { + "type": { + "!type": "string", + "!span": "3698[131:6]-3702[131:10]" + }, + "message": { + "!type": "string", + "!span": "3718[132:6]-3725[132:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3744[133:6]-3758[133:20]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..connect.!0": { + "host": { + "!type": "string", + "!span": "3256[129:6]-3260[129:10]" + }, + "policyPort": { + "!type": "number", + "!span": "3314[131:6]-3324[131:16]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..options.request.addCookie.!0": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..options.error.!0": { + "type": { + "!type": "string", + "!span": "7702[285:6]-7706[285:10]" + }, + "message": { + "!type": "string", + "!span": "7722[286:6]-7729[286:13]" + }, + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret": { + "url": { + "scheme": { + "!type": "string", + "!span": "59506[2274:4]-59512[2274:10]" + }, + "host": { + "!type": "string", + "!span": "59524[2275:4]-59528[2275:8]" + }, + "path": { + "!type": "string", + "!span": "59556[2277:4]-59560[2277:8]" + }, + "fullHost": { + "!type": "string", + "!span": "59592[2280:8]-59600[2280:16]" + } + }, + "policyPort": { + "!type": "number", + "!span": "13207[467:4]-13217[467:14]", + "!doc": "the policy port to use" + }, + "requests": { + "": { + "request": { + "version": { + "!type": "string", + "!span": "25249[872:10]-25256[872:17]" + }, + "body": { + "!type": "string", + "!span": "25382[875:10]-25386[875:14]", + "!doc": "inflate using flash api" + }, + "bodyDeflated": { + "!type": "bool", + "!span": "25421[876:10]-25433[876:22]" + }, + "addCookie": {}, + "code": { + "!type": "number", + "!span": "28698[994:11]-28702[994:15]" + }, + "message": { + "!type": "string", + "!span": "28719[995:11]-28726[995:18]" + }, + "headerReceived": { + "!type": "bool", + "!span": "28770[997:11]-28784[997:25]", + "!doc": "handle final line, end of header" + }, + "bodyReceived": { + "!type": "bool", + "!span": "28805[998:11]-28817[998:23]", + "!doc": "body received" + }, + "readBodyUntilClose": { + "!type": "bool", + "!span": "34861[1193:15]-34879[1193:33]" + }, + "time": { + "!type": "number", + "!span": "35036[1201:15]-35040[1201:19]" + }, + "aborted": { + "!type": "bool", + "!span": "17397[562:23]-17404[562:30]" + }, + "connectTime": { + "!type": "number", + "!span": "3048[106:13]-3059[106:24]" + }, + "getCookies": {}, + "fields": { + "": "net.socketPools..sockets..options.request.fields." + }, + "setField": "net.socketPools..sockets..options.request.setField", + "appendField": "net.socketPools..sockets..options.request.appendField", + "getField": "net.socketPools..sockets..options.request.getField", + "toString": "net.socketPools..sockets..options.request.toString", + "readHeader": "net.socketPools..sockets..options.request.readHeader", + "readBody": "net.socketPools..sockets..options.request.readBody", + "abort": "net.socketPools..sockets..options.request.abort" + }, + "error": {}, + "headerReady": {}, + "bodyReady": {}, + "response": "net.socketPools..sockets..options.request", + "connected": "net.socketPools..sockets..options.connected", + "closed": "net.socketPools..sockets..options.closed" + } + }, + "sockets": { + "": { + "connected": {}, + "closed": {}, + "data": {}, + "error": {}, + "connect": {}, + "sending": { + "!type": "bool", + "!span": "5219[171:3]-5226[171:10]" + }, + "retries": { + "!type": "number", + "!span": "4067[126:57]-4074[128:3]" + }, + "options": "net.socketPools..sockets..options", + "buffer": "+ByteBuffer", + "destroy": "net.socketPools..sockets..destroy", + "close": "net.socketPools..sockets..close", + "isConnected": "net.socketPools..sockets..isConnected", + "send": "net.socketPools..sockets..send", + "receive": "net.socketPools..sockets..receive", + "bytesAvailable": "net.socketPools..sockets..bytesAvailable" + } + }, + "secure": { + "!type": "bool", + "!span": "13475[477:4]-13481[477:10]", + "!doc": "whether or not the connections are secure" + }, + "cookies": { + "": { + "": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + } + } + }, + "persistCookies": { + "!type": "bool", + "!span": "13717[482:4]-13731[482:18]", + "!doc": "default to flash storage of cookies" + }, + "getCookie": {}, + "socketPool": "net.socketPools.", + "idle": { + "": "net.socketPools..sockets." + }, + "send": {}, + "destroy": "_getStorageId.!0.destroy", + "setCookie": "_getStorageId.!0.setCookie", + "removeCookie": "_getStorageId.!0.removeCookie", + "clearCookies": "_getStorageId.!0.clearCookies" + }, + "forge.http.createClient.!ret.requests..request.addCookie.!0": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "forge.http.createClient.!ret.requests..error.!0": { + "type": { + "!type": "string", + "!span": "7702[285:6]-7706[285:10]" + }, + "message": { + "!type": "string", + "!span": "7722[286:6]-7729[286:13]" + }, + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.sockets..connected.!0": { + "type": { + "!type": "string", + "!span": "2282[66:10]-2286[66:14]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2309[67:10]-2323[67:24]" + }, + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.sockets..closed.!0": { + "type": { + "!type": "string", + "!span": "5447[189:9]-5451[189:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "5471[190:9]-5485[190:23]" + } + }, + "forge.http.createClient.!ret.sockets..data.!0": { + "type": { + "!type": "string", + "!span": "2617[79:8]-2621[79:12]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2645[80:8]-2659[80:22]" + } + }, + "forge.http.createClient.!ret.sockets..error.!0": { + "type": { + "!type": "string", + "!span": "3698[131:6]-3702[131:10]" + }, + "message": { + "!type": "string", + "!span": "3718[132:6]-3725[132:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3744[133:6]-3758[133:20]" + } + }, + "forge.http.createClient.!ret.sockets..connect.!0": { + "host": { + "!type": "string", + "!span": "3256[129:6]-3260[129:10]" + }, + "policyPort": { + "!type": "number", + "!span": "3314[131:6]-3324[131:16]" + } + }, + "forge.http.createClient.!ret.getCookie.!ret": { + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]" + }, + "maxAge": { + "!type": "number", + "!span": "20252[674:15]-20258[674:21]" + }, + "secure": { + "!type": "bool", + "!span": "20296[675:15]-20302[675:21]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[677:15]-20402[677:23]" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "forge.http.createRequest.!ret": { + "version": { + "!type": "string", + "!span": "25249[872:10]-25256[872:17]" + }, + "body": { + "!type": "string", + "!span": "25382[875:10]-25386[875:14]", + "!doc": "inflate using flash api" + }, + "bodyDeflated": { + "!type": "bool", + "!span": "25421[876:10]-25433[876:22]" + }, + "code": { + "!type": "number", + "!span": "28698[994:11]-28702[994:15]" + }, + "message": { + "!type": "string", + "!span": "28719[995:11]-28726[995:18]" + }, + "headerReceived": { + "!type": "bool", + "!span": "28770[997:11]-28784[997:25]", + "!doc": "handle final line, end of header" + }, + "bodyReceived": { + "!type": "bool", + "!span": "28805[998:11]-28817[998:23]", + "!doc": "body received" + }, + "readBodyUntilClose": { + "!type": "bool", + "!span": "34861[1193:15]-34879[1193:33]" + }, + "time": { + "!type": "number", + "!span": "35036[1201:15]-35040[1201:19]" + }, + "aborted": { + "!type": "bool", + "!span": "17397[562:23]-17404[562:30]" + }, + "connectTime": { + "!type": "number", + "!span": "3048[106:13]-3059[106:24]" + }, + "getCookies": {}, + "fields": { + "": "net.socketPools..sockets..options.request.fields." + }, + "setField": "net.socketPools..sockets..options.request.setField", + "appendField": "net.socketPools..sockets..options.request.appendField", + "getField": "net.socketPools..sockets..options.request.getField", + "addCookie": "net.socketPools..sockets..options.request.addCookie", + "toString": "net.socketPools..sockets..options.request.toString", + "readHeader": "net.socketPools..sockets..options.request.readHeader", + "readBody": "net.socketPools..sockets..options.request.readBody", + "abort": "net.socketPools..sockets..options.request.abort" + }, + "forge.http.parseUrl.!ret": { + "scheme": { + "!type": "string", + "!span": "59506[2274:4]-59512[2274:10]" + }, + "host": { + "!type": "string", + "!span": "59524[2275:4]-59528[2275:8]" + }, + "path": { + "!type": "string", + "!span": "59556[2277:4]-59560[2277:8]" + }, + "fullHost": { + "!type": "string", + "!span": "59592[2280:8]-59600[2280:16]" + } + }, + "forge.http.withinCookieDomain.!1": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "forge.kem.rsa.create.!0": { + "reseeds": { + "!type": "number", + "!span": "1481[48:4]-1488[48:11]", + "!doc": "update reseed count" + }, + "generated": { + "!type": "number", + "!span": "1536[50:4]-1545[50:13]", + "!doc": "amount of data generated so far" + }, + "keyBytes": { + "!type": "string", + "!span": "1582[52:4]-1590[52:12]", + "!doc": "get digest for key bytes" + }, + "pools": { + "": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + } + }, + "pool": { + "!type": "number", + "!span": "1866[64:6]-1870[64:10]", + "!doc": "entropy pools are written to cyclically, starting at index 0" + }, + "seed": "forge.random.seed", + "plugin": { + "md": { + "create": "sha256.create" + }, + "formatKey": "forge.random.plugin.formatKey", + "formatSeed": "forge.random.plugin.formatSeed", + "cipher": "forge.random.plugin.cipher", + "increment": "forge.random.plugin.increment" + }, + "generate": "forge.random.generate", + "generateSync": "forge.random.generateSync", + "seedFile": "forge.random.seedFile", + "seedFileSync": "forge.random.seedFileSync", + "collect": "forge.random.collect", + "collectInt": "forge.random.collectInt", + "registerWorker": "forge.random.registerWorker", + "getBytes": "forge.random.getBytes", + "getBytesSync": "forge.random.getBytesSync", + "createInstance": "forge.random.createInstance" + }, + "forge.kem.rsa.create.!ret": { + "encrypt": { + "!type": "fn(publicKey: ?, keyLength: ?) -> forge.kem.rsa.create.!ret.encrypt.!ret", + "!span": "1730[54:6]-1737[54:13]", + "!doc": "Generates a secret key and its encapsulation.\n\n@param publicKey the RSA public key to encrypt with.\n@param keyLength the length, in bytes, of the secret key to generate.\n\n@return an object with:\n encapsulation: the ciphertext for generating the secret key, as a\n binary-encoded string of bytes.\n key: the secret key to use for encrypting a message." + }, + "decrypt": { + "!type": "fn(privateKey: ?, encapsulation: ?, keyLength: ?)", + "!span": "2879[90:6]-2886[90:13]", + "!doc": "Decrypts an encapsulated secret key.\n\n@param privateKey the RSA private key to decrypt with.\n@param encapsulation the ciphertext for generating the secret key, as\n a binary-encoded string of bytes.\n@param keyLength the length, in bytes, of the secret key to generate.\n\n@return the secret key as a binary-encoded string of bytes." + }, + "!span": "1310[41:12]-1312[41:14]" + }, + "forge.kem.rsa.create.!ret.encrypt.!ret": { + "!span": "2438[77:11]-2478[77:51]" + }, + "forge.kem.kdf1.!0": { + "algorithm": { + "!type": "string", + "!span": "2315[98:4]-2324[98:13]", + "!doc": "SHA-512 => sha512" + }, + "blockLength": { + "!type": "number", + "!span": "2372[99:4]-2383[99:15]" + }, + "digestLength": { + "!type": "number", + "!span": "2394[100:4]-2406[100:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "2611[106:4]-2628[106:21]", + "!doc": "size of message length in bytes" + }, + "messageLength128": "_createKDF.!1.fullMessageLength", + "fullMessageLength": "_createKDF.!1.fullMessageLength", + "start": "_createKDF.!1.start", + "update": "_createKDF.!1.update", + "digest": "_createKDF.!1.digest" + }, + "forge.log.logMessage.!0": { + "level": { + "!type": "string", + "!span": "4854[155:10]-4859[155:15]" + }, + "standard": { + "!type": "string", + "!span": "3143[102:12]-3151[102:20]" + }, + "standardFull": { + "!type": "string", + "!span": "4125[136:12]-4137[136:24]" + }, + "timestamp": "+Date", + "arguments": "f.!1.arguments" + }, + "forge.log.prepareFull.!0": { + "full": { + "!type": "string", + "!span": "3723[122:12]-3727[122:16]", + "!doc": "format the message" + } + }, + "forge.log.makeLogger.!0": {}, + "forge.log.makeLogger.!0.!0": { + "flags": { + "!type": "number", + "!span": "5727[190:4]-5732[190:9]" + }, + "level": { + "!type": "string", + "!span": "6301[212:15]-6306[212:20]", + "!doc": "set level" + }, + "f": "f" + }, + "forge.log.makeLogger.!ret": { + "flags": { + "!type": "number", + "!span": "5727[190:4]-5732[190:9]" + }, + "level": { + "!type": "string", + "!span": "6301[212:15]-6306[212:20]", + "!doc": "set level" + }, + "f": "f" + }, + "forge.md.algorithms.sha256.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + }, + "forge.md.sha256.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + }, + "forge.md5.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "746[36:4]-755[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "768[37:4]-779[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "789[38:4]-801[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "996[44:4]-1013[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "hash.!0.fullMessageLength", + "fullMessageLength": "hash.!0.fullMessageLength", + "start": "hash.!0.start", + "update": "hash.!0.update", + "digest": "hash.!0.digest" + }, + "forge.pem.encode.!0": { + "type": { + "!type": "string", + "!span": "27457[901:4]-27461[901:8]" + } + }, + "forge.pem.decode.!ret": { + "": { + "type": { + "!type": "string", + "!span": "3012[109:6]-3016[109:10]" + }, + "procType": { + "version": { + "!type": "string", + "!span": "4449[158:26]-4456[158:33]" + }, + "type": { + "!type": "string", + "!span": "4469[158:46]-4473[158:50]" + } + }, + "contentDomain": { + "!type": "string", + "!span": "3056[111:6]-3069[111:19]", + "!doc": "special-case Content-Domain" + }, + "dekInfo": { + "algorithm": { + "!type": "string", + "!span": "4967[168:25]-4976[168:34]" + }, + "parameters": { + "!type": "string", + "!span": "4989[168:47]-4999[168:57]" + } + }, + "headers": { + "": { + "name": { + "!type": "string", + "!span": "3797[143:22]-3801[143:26]" + }, + "values": "pem.decode.!ret..headers..values" + } + }, + "body": { + "!type": "string", + "!span": "3123[114:6]-3127[114:10]" + } + } + }, + "forge.pkcs12.pkcs12FromAsn1.!ret": { + "safeContents": { + "": { + "encrypted": { + "!type": "bool", + "!span": "15681[541:6]-15690[541:15]" + }, + "safeBags": { + "": { + "type": { + "!type": "string", + "!span": "19026[652:6]-19030[652:10]" + }, + "key": "_modPow.!1", + "asn1": "_fromDer.!ret", + "cert": "pki.certificateFromPem.!ret", + "attributes": { + "": "_decodeBagAttributes.!ret." + } + } + } + } + }, + "getBags": {}, + "getBagsByFriendlyName": {}, + "getBagsByLocalKeyId": "_decodeAuthenticatedSafe.!0.getBagsByLocalKeyId" + }, + "forge.pkcs12.toPkcs12Asn1.!3": { + "saltSize": { + "!type": "number", + "!span": "24053[798:10]-24061[798:18]" + }, + "count": { + "!type": "number", + "!span": "24097[799:10]-24102[799:15]" + }, + "algorithm": { + "!type": "string", + "!span": "24138[800:10]-24147[800:19]" + }, + "useMac": { + "!type": "bool", + "!span": "24248[802:12]-24254[802:18]" + }, + "generateLocalKeyId": { + "!type": "bool", + "!span": "24392[808:12]-24410[808:30]" + }, + "prfAlgorithm": { + "!type": "string", + "!span": "6433[245:5]-6445[245:17]" + } + }, + "forge.pkcs7.messageFromPem.!ret": { + "version": { + "!type": "number", + "!span": "18359[589:4]-18366[589:11]" + }, + "recipients": { + "": { + "version": { + "!type": "number", + "!span": "21713[700:8]-21720[700:15]" + }, + "encryptedContent": "_recipientsFromAsn1.!ret..encryptedContent" + } + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "37653[1185:6]-37662[1185:15]", + "!doc": "Keep a copy of the key & IV in the object, so the caller can\nuse it for whatever reason." + }, + "parameter": "+ByteBuffer", + "content": "+ByteBuffer", + "key": "+ByteBuffer" + }, + "findRecipient": {}, + "decrypt": {}, + "content": "+ByteBuffer", + "fromAsn1": "_fromAsn1.!0.fromAsn1", + "toAsn1": "_fromAsn1.!0.toAsn1", + "addRecipient": "_fromAsn1.!0.addRecipient", + "encrypt": "_fromAsn1.!0.encrypt", + "rawCapture": "_fromAsn1.!ret" + }, + "forge.pkcs7.messageFromPem.!ret.findRecipient.!ret": { + "serialNumber": { + "!type": "string", + "!span": "26217[836:4]-26229[836:16]" + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "26310[838:6]-26319[838:15]" + } + }, + "issuer": "pki.RDNAttributesAsArray.!ret" + }, + "forge.pkcs7.messageFromPem.!ret.decrypt.!0": { + "version": { + "!type": "number", + "!span": "3313[125:4]-3320[125:11]" + }, + "signers": { + "": { + "version": { + "!type": "number", + "!span": "9954[317:8]-9961[317:15]" + }, + "serialNumber": { + "!type": "string", + "!span": "9998[319:8]-10010[319:20]" + }, + "key": "_modPow.!1", + "issuer": "pki.RDNAttributesAsArray.!ret", + "authenticatedAttributesAsn1": "_fromDer.!ret", + "authenticatedAttributes": "_signerToAsn1.!0.authenticatedAttributes", + "unauthenticatedAttributes": "_signerToAsn1.!0.unauthenticatedAttributes" + } + }, + "certificates": { + "": "pki.certificateFromPem.!ret" + }, + "digestAlgorithmIdentifiers": { + "": "_fromDer.!ret" + }, + "contentInfo": "_fromDer.!ret", + "signerInfos": { + "": "_fromDer.!ret" + }, + "detachedContent": "_fromDer.!ret", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret", + "crls": "p7.createSignedData.!ret.crls", + "fromAsn1": "p7.createSignedData.!ret.fromAsn1", + "toAsn1": "p7.createSignedData.!ret.toAsn1", + "addSigner": "p7.createSignedData.!ret.addSigner", + "sign": "p7.createSignedData.!ret.sign", + "verify": "p7.createSignedData.!ret.verify", + "addCertificate": "p7.createSignedData.!ret.addCertificate", + "addCertificateRevokationList": "p7.createSignedData.!ret.addCertificateRevokationList" + }, + "forge.pkcs7.createSignedData.!ret": { + "version": { + "!type": "number", + "!span": "3313[125:4]-3320[125:11]" + }, + "signers": { + "": { + "version": { + "!type": "number", + "!span": "9954[317:8]-9961[317:15]" + }, + "serialNumber": { + "!type": "string", + "!span": "9998[319:8]-10010[319:20]" + }, + "key": "_modPow.!1", + "issuer": "pki.RDNAttributesAsArray.!ret", + "authenticatedAttributesAsn1": "_fromDer.!ret", + "authenticatedAttributes": "_signerToAsn1.!0.authenticatedAttributes", + "unauthenticatedAttributes": "_signerToAsn1.!0.unauthenticatedAttributes" + } + }, + "certificates": { + "": "pki.certificateFromPem.!ret" + }, + "digestAlgorithmIdentifiers": { + "": "_fromDer.!ret" + }, + "contentInfo": "_fromDer.!ret", + "signerInfos": { + "": "_fromDer.!ret" + }, + "detachedContent": "_fromDer.!ret", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret", + "crls": "p7.createSignedData.!ret.crls", + "fromAsn1": "p7.createSignedData.!ret.fromAsn1", + "toAsn1": "p7.createSignedData.!ret.toAsn1", + "addSigner": "p7.createSignedData.!ret.addSigner", + "sign": "p7.createSignedData.!ret.sign", + "verify": "p7.createSignedData.!ret.verify", + "addCertificate": "p7.createSignedData.!ret.addCertificate", + "addCertificateRevokationList": "p7.createSignedData.!ret.addCertificateRevokationList" + }, + "forge.pkcs7.createEncryptedData.!ret": { + "version": { + "!type": "number", + "!span": "17467[550:4]-17474[550:11]" + }, + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret", + "fromAsn1": "p7.createEncryptedData.!ret.fromAsn1", + "decrypt": "p7.createEncryptedData.!ret.decrypt" + }, + "forge.prime.generateProbablePrime.!1": { + "algorithm": { + "name": { + "!type": "string", + "!span": "50978[1628:6]-50982[1628:10]" + }, + "options": { + "workers": { + "!type": "number", + "!span": "51042[1630:8]-51049[1630:15]" + }, + "workLoad": { + "!type": "number", + "!span": "51081[1631:8]-51089[1631:16]" + }, + "!span": "51023[1629:6]-51030[1629:13]" + }, + "!span": "50959[1627:4]-50968[1627:13]" + }, + "!span": "50953[1626:13]-51176[1635:3]" + }, + "forge.prng.create.!ret": { + "reseeds": { + "!type": "number", + "!span": "1481[48:4]-1488[48:11]", + "!doc": "update reseed count" + }, + "generated": { + "!type": "number", + "!span": "1536[50:4]-1545[50:13]", + "!doc": "amount of data generated so far" + }, + "keyBytes": { + "!type": "string", + "!span": "1582[52:4]-1590[52:12]", + "!doc": "get digest for key bytes" + }, + "pool": { + "!type": "number", + "!span": "1866[64:6]-1870[64:10]", + "!doc": "entropy pools are written to cyclically, starting at index 0" + }, + "plugin": "forge.random.plugin", + "seed": "forge.random.seed", + "pools": { + "": "forge.random.pools." + }, + "generate": "forge.random.generate", + "generateSync": "forge.random.generateSync", + "seedFile": "forge.random.seedFile", + "seedFileSync": "forge.random.seedFileSync", + "collect": "forge.random.collect", + "collectInt": "forge.random.collectInt", + "registerWorker": "forge.random.registerWorker", + "getBytes": "forge.random.getBytes", + "getBytesSync": "forge.random.getBytesSync", + "createInstance": "forge.random.createInstance" + }, + "forge.random.pools.": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "fullMessageLength": { + "!type": "[number]", + "!span": "993[44:4]-1010[44:21]", + "!doc": "full message length (set md.messageLength64 for backwards-compatibility)" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "start": { + "!type": "fn() -> forge.random.pools.", + "!span": "1167[54:5]-1172[54:10]", + "!doc": "Starts the digest.\n\n@return this digest object." + }, + "update": { + "!type": "fn(msg: ?, encoding: ?) -> forge.random.pools.", + "!span": "2229[90:5]-2235[90:11]", + "!doc": "Updates the digest with the given message input. The given input can\ntreated as raw input (no encoding will be applied) or an encoding of\n'utf8' maybe given to encode the input using UTF-8.\n\n@param msg the message input to update with.\n@param encoding the encoding to use (default: 'raw', other: 'utf8').\n\n@return this digest object." + }, + "digest": { + "!type": "fn() -> +ByteBuffer", + "!span": "3144[125:5]-3150[125:11]", + "!doc": "Produces the digest.\n\n@return a byte buffer containing the digest value." + }, + "!span": "802[37:11]-1085[47:3]", + "!doc": "message digest object", + "messageLength64": "forge.random.pools..fullMessageLength" + }, + "forge.random.seedFile.!1": { + "!type": "fn(err: ?, bytes: ?)", + "!span": "12058[407:47]-12167[409:11]" + }, + "forge.rsa.createKeyPairGenerationState.!ret": { + "algorithm": { + "!type": "string", + "!span": "18660[622:6]-18669[622:15]" + }, + "state": { + "!type": "number", + "!span": "18688[623:6]-18693[623:11]" + }, + "bits": { + "!type": "number", + "!span": "18704[624:6]-18708[624:10]" + }, + "eInt": { + "!type": "number", + "!span": "18738[626:6]-18742[626:10]" + }, + "qBits": { + "!type": "number", + "!span": "18823[630:6]-18828[630:11]" + }, + "pBits": { + "!type": "number", + "!span": "18847[631:6]-18852[631:11]" + }, + "pqState": { + "!type": "number", + "!span": "18880[632:6]-18887[632:13]", + "!doc": "store p or q" + }, + "e": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "num": "+BigInteger", + "keys": "_generateKeyPair.!0.keys", + "p1": "+BigInteger", + "q1": "+BigInteger", + "phi": "+BigInteger", + "n": "+BigInteger", + "rng": { + "nextBytes": "_generateKeyPair.!0.rng.nextBytes" + } + }, + "forge.net.socketPools..sockets..connected.!0": { + "type": { + "!type": "string", + "!span": "2282[66:10]-2286[66:14]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2309[67:10]-2323[67:24]" + }, + "socket": "net.socketPools..sockets." + }, + "forge.net.socketPools..sockets..closed.!0": { + "type": { + "!type": "string", + "!span": "5447[189:9]-5451[189:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "5471[190:9]-5485[190:23]" + } + }, + "forge.net.socketPools..sockets..data.!0": { + "type": { + "!type": "string", + "!span": "2617[79:8]-2621[79:12]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2645[80:8]-2659[80:22]" + } + }, + "forge.net.socketPools..sockets..error.!0": { + "type": { + "!type": "string", + "!span": "3698[131:6]-3702[131:10]" + }, + "message": { + "!type": "string", + "!span": "3718[132:6]-3725[132:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3744[133:6]-3758[133:20]" + } + }, + "forge.net.socketPools..sockets..connect.!0": { + "host": { + "!type": "string", + "!span": "3256[129:6]-3260[129:10]" + }, + "policyPort": { + "!type": "number", + "!span": "3314[131:6]-3324[131:16]" + } + }, + "forge.net.socketPools..sockets..options.error.!0": { + "type": { + "!type": "string", + "!span": "7702[285:6]-7706[285:10]" + }, + "message": { + "!type": "string", + "!span": "7722[286:6]-7729[286:13]" + }, + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.net.createSocketPool.!0": { + "policyPort": { + "!type": "number", + "!span": "4170[131:4]-4180[131:14]" + }, + "msie": { + "!type": "bool", + "!span": "4226[133:4]-4230[133:8]" + } + }, + "forge.task.start.!0": { + "type": { + "!type": "string", + "!span": "7567[280:8]-7571[280:12]" + }, + "!span": "7557[279:23]-7802[290:7]", + "run": "Task.!0.run", + "success": "Task.successCallback", + "failure": "Task.failureCallback" + }, + "forge.task.createCondition.!ret": { + "tasks": { + "!span": "19063[693:4]-19068[693:9]", + "!doc": "all tasks that are blocked" + }, + "wait": { + "!type": "fn(task: ?)", + "!span": "19283[702:7]-19287[702:11]", + "!doc": "Causes the given task to block until notify is called. If the task\nis already waiting on this condition then this is a no-op.\n\n@param task the task to cause to wait." + }, + "notify": { + "!type": "fn()", + "!span": "19496[713:7]-19502[713:13]", + "!doc": "Notifies all waiting tasks to wake up." + }, + "!span": "19023[691:13]-19076[694:3]" + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initSecurityParameters.!0": { + "bulk_cipher_algorithm": { + "!type": "number", + "!span": "455[21:7]-476[21:28]" + }, + "cipher_type": { + "!type": "number", + "!span": "515[22:7]-526[22:18]" + }, + "enc_key_length": { + "!type": "number", + "!span": "558[23:7]-572[23:21]" + }, + "block_length": { + "!type": "number", + "!span": "586[24:7]-598[24:19]" + }, + "fixed_iv_length": { + "!type": "number", + "!span": "612[25:7]-627[25:22]" + }, + "record_iv_length": { + "!type": "number", + "!span": "641[26:7]-657[26:23]" + }, + "mac_algorithm": { + "!type": "number", + "!span": "671[27:7]-684[27:20]" + }, + "mac_length": { + "!type": "number", + "!span": "722[28:7]-732[28:17]" + }, + "mac_key_length": { + "!type": "number", + "!span": "746[29:7]-760[29:21]" + } + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initConnectionState.!1": { + "version": { + "major": { + "!type": "number", + "!span": "115468[3775:17]-115473[3775:22]" + }, + "minor": { + "!type": "number", + "!span": "115494[3775:43]-115499[3775:48]" + } + }, + "entity": { + "!type": "number", + "!span": "113758[3719:4]-113764[3719:10]" + }, + "sessionCache": { + "capacity": { + "!type": "number", + "!span": "111111[249:104144]-111119[249:104152]" + }, + "getSession": {}, + "": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "sp": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "version": "initConnectionState.!1.version" + }, + "cache": "tls.createSessionCache.!0", + "order": "tls.createSessionCache.!0.order", + "setSession": "tls.createSessionCache.!0.setSession" + }, + "virtualHost": { + "!type": "string", + "!span": "113932[3725:4]-113943[3725:15]" + }, + "verifyClient": { + "!type": "bool", + "!span": "113978[3726:4]-113990[3726:16]" + }, + "error": {}, + "record": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + } + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "fragment": "+ByteBuffer" + }, + "session": { + "compressionMethod": { + "!type": "number", + "!span": "59972[2042:8]-59989[2042:25]", + "!doc": "no compression" + }, + "resuming": { + "!type": "bool", + "!span": "30337[1016:14]-30345[1016:22]" + }, + "id": { + "!type": "string", + "!span": "30684[1030:12]-30686[1030:14]", + "!doc": "update session" + }, + "clientHelloVersion": { + "major": { + "!type": "number", + "!span": "82459[2709:4]-82464[2709:9]" + }, + "minor": { + "!type": "number", + "!span": "82487[2710:4]-82492[2710:9]" + } + }, + "sp": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "version": "initConnectionState.!1.version", + "md5": "hash.!0", + "sha1": "rsa_mgf1.!2", + "certificateRequest": { + "certificate_types": "+ByteBuffer", + "certificate_authorities": "+ByteBuffer" + }, + "extensions": { + "server_name": { + "serverNameList": "initConnectionState.!1.session.extensions.server_name.serverNameList" + } + } + }, + "state": { + "pending": { + "read": { + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "sequenceNumber": "deflate.!2.sequenceNumber", + "cipherFunction": "deflate.!2.cipherFunction", + "compressFunction": "deflate", + "updateSequenceNumber": "deflate.!2.updateSequenceNumber", + "update": "deflate.!2.update" + }, + "write": "deflate.!2" + }, + "current": "tls.createConnectionState.!ret" + }, + "expect": { + "!type": "number", + "!span": "115664[3783:6]-115670[3783:12]", + "!doc": "expect application data next" + }, + "records": { + "": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + } + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "fragment": "+ByteBuffer" + } + }, + "open": { + "!type": "bool", + "!span": "115777[3786:6]-115781[3786:10]", + "!doc": "connection no longer open, clear input" + }, + "handshakes": { + "!type": "number", + "!span": "115797[3787:6]-115807[3787:16]" + }, + "handshaking": { + "!type": "bool", + "!span": "115819[3788:6]-115830[3788:17]", + "!doc": "now handshaking" + }, + "isConnected": { + "!type": "bool", + "!span": "115846[3789:6]-115857[3789:17]", + "!doc": "now connected" + }, + "fail": { + "!type": "bool", + "!span": "115873[3790:6]-115877[3790:10]", + "!doc": "set fail flag" + }, + "input": "+ByteBuffer", + "tlsData": "+ByteBuffer", + "data": "+ByteBuffer", + "fragmented": "hmac_sha1.!2", + "cipherSuites": "initConnectionState.!1.cipherSuites", + "connected": "initConnectionState.!1.connected", + "verify": "initConnectionState.!1.verify", + "getSignature": "initConnectionState.!1.getSignature", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "reset": "initConnectionState.!1.reset", + "handshake": "initConnectionState.!1.handshake", + "process": "initConnectionState.!1.process", + "prepare": "initConnectionState.!1.prepare", + "prepareHeartbeatRequest": "initConnectionState.!1.prepareHeartbeatRequest", + "close": "initConnectionState.!1.close" + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initConnectionState.!1.sessionCache.getSession.!ret": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "sp": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "version": "initConnectionState.!1.version" + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initConnectionState.!1.error.!1": { + "send": { + "!type": "bool", + "!span": "110177[3577:8]-110181[3577:12]" + }, + "alert": { + "level": { + "!type": "number", + "!span": "110432[3589:8]-110437[3589:13]" + } + }, + "origin": { + "!type": "string", + "!span": "114631[3741:9]-114637[3741:15]", + "!doc": "set origin if not set" + } + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initConnectionState.!2": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_256_CBC_SHA.initSecurityParameters.!0": { + "bulk_cipher_algorithm": { + "!type": "number", + "!span": "979[37:7]-1000[37:28]" + }, + "cipher_type": { + "!type": "number", + "!span": "1039[38:7]-1050[38:18]" + }, + "enc_key_length": { + "!type": "number", + "!span": "1082[39:7]-1096[39:21]" + }, + "block_length": { + "!type": "number", + "!span": "1110[40:7]-1122[40:19]" + }, + "fixed_iv_length": { + "!type": "number", + "!span": "1136[41:7]-1151[41:22]" + }, + "record_iv_length": { + "!type": "number", + "!span": "1165[42:7]-1181[42:23]" + }, + "mac_algorithm": { + "!type": "number", + "!span": "1195[43:7]-1208[43:20]" + }, + "mac_length": { + "!type": "number", + "!span": "1246[44:7]-1256[44:17]" + }, + "mac_key_length": { + "!type": "number", + "!span": "1270[45:7]-1284[45:21]" + } + }, + "forge.tls.handleUnexpected.!0": { + "version": { + "major": { + "!type": "number", + "!span": "115468[3775:17]-115473[3775:22]" + }, + "minor": { + "!type": "number", + "!span": "115494[3775:43]-115499[3775:48]" + } + }, + "entity": { + "!type": "number", + "!span": "113758[3719:4]-113764[3719:10]" + }, + "sessionCache": { + "capacity": { + "!type": "number", + "!span": "111111[249:104144]-111119[249:104152]" + }, + "": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "version": "initConnectionState.!1.version", + "sp": "initConnectionState.!2" + }, + "cache": "tls.createSessionCache.!0", + "order": "tls.createSessionCache.!0.order", + "getSession": "tls.createSessionCache.!0.getSession", + "setSession": "tls.createSessionCache.!0.setSession" + }, + "virtualHost": { + "!type": "string", + "!span": "113932[3725:4]-113943[3725:15]" + }, + "verifyClient": { + "!type": "bool", + "!span": "113978[3726:4]-113990[3726:16]" + }, + "error": {}, + "record": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + } + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "fragment": "+ByteBuffer" + }, + "session": { + "compressionMethod": { + "!type": "number", + "!span": "59972[2042:8]-59989[2042:25]", + "!doc": "no compression" + }, + "resuming": { + "!type": "bool", + "!span": "30337[1016:14]-30345[1016:22]" + }, + "id": { + "!type": "string", + "!span": "30684[1030:12]-30686[1030:14]", + "!doc": "update session" + }, + "clientHelloVersion": { + "major": { + "!type": "number", + "!span": "82459[2709:4]-82464[2709:9]" + }, + "minor": { + "!type": "number", + "!span": "82487[2710:4]-82492[2710:9]" + } + }, + "version": "initConnectionState.!1.version", + "md5": "hash.!0", + "sha1": "rsa_mgf1.!2", + "certificateRequest": { + "certificate_types": "+ByteBuffer", + "certificate_authorities": "+ByteBuffer" + }, + "sp": "initConnectionState.!2", + "extensions": { + "server_name": { + "serverNameList": "initConnectionState.!1.session.extensions.server_name.serverNameList" + } + } + }, + "state": { + "pending": { + "read": { + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "sequenceNumber": "deflate.!2.sequenceNumber", + "cipherFunction": "deflate.!2.cipherFunction", + "compressFunction": "deflate", + "updateSequenceNumber": "deflate.!2.updateSequenceNumber", + "update": "deflate.!2.update" + }, + "write": "deflate.!2" + }, + "current": "tls.createConnectionState.!ret" + }, + "expect": { + "!type": "number", + "!span": "115664[3783:6]-115670[3783:12]", + "!doc": "expect application data next" + }, + "records": { + "": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + } + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "fragment": "+ByteBuffer" + } + }, + "open": { + "!type": "bool", + "!span": "115777[3786:6]-115781[3786:10]", + "!doc": "connection no longer open, clear input" + }, + "handshakes": { + "!type": "number", + "!span": "115797[3787:6]-115807[3787:16]" + }, + "handshaking": { + "!type": "bool", + "!span": "115819[3788:6]-115830[3788:17]", + "!doc": "now handshaking" + }, + "isConnected": { + "!type": "bool", + "!span": "115846[3789:6]-115857[3789:17]", + "!doc": "now connected" + }, + "fail": { + "!type": "bool", + "!span": "115873[3790:6]-115877[3790:10]", + "!doc": "set fail flag" + }, + "input": "+ByteBuffer", + "tlsData": "+ByteBuffer", + "data": "+ByteBuffer", + "fragmented": "hmac_sha1.!2", + "cipherSuites": "initConnectionState.!1.cipherSuites", + "connected": "initConnectionState.!1.connected", + "verify": "initConnectionState.!1.verify", + "getSignature": "initConnectionState.!1.getSignature", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "reset": "initConnectionState.!1.reset", + "handshake": "initConnectionState.!1.handshake", + "process": "initConnectionState.!1.process", + "prepare": "initConnectionState.!1.prepare", + "prepareHeartbeatRequest": "initConnectionState.!1.prepareHeartbeatRequest", + "close": "initConnectionState.!1.close" + }, + "forge.tls.handleUnexpected.!0.error.!1": { + "send": { + "!type": "bool", + "!span": "110177[3577:8]-110181[3577:12]" + }, + "alert": { + "level": { + "!type": "number", + "!span": "110432[3589:8]-110437[3589:13]" + } + }, + "origin": { + "!type": "string", + "!span": "114631[3741:9]-114637[3741:15]", + "!doc": "set origin if not set" + } + }, + "forge.tls.handleUnexpected.!1": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + } + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "fragment": "+ByteBuffer" + }, + "forge.tls.parseHelloMessage.!ret": { + "version": { + "major": { + "!type": "number", + "!span": "23963[804:8]-23968[804:13]" + }, + "minor": { + "!type": "number", + "!span": "23991[805:8]-23996[805:13]" + } + }, + "random": "+ByteBuffer", + "session_id": "+ByteBuffer", + "extensions": { + "": { + "data": "+ByteBuffer", + "type": "tls.parseHelloMessage.!ret.extensions..type" + } + }, + "cipher_suites": "+ByteBuffer", + "compression_methods": "+ByteBuffer" + }, + "forge.tls.handleServerHelloDone.!1": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + } + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "fragment": "+ByteBuffer" + }, + "forge.tls.generateKeys.!1": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "forge.tls.createConnectionState.!ret": { + "read": { + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "sequenceNumber": "deflate.!2.sequenceNumber", + "cipherFunction": "deflate.!2.cipherFunction", + "compressFunction": "deflate", + "updateSequenceNumber": "deflate.!2.updateSequenceNumber", + "update": "deflate.!2.update" + }, + "write": "deflate.!2" + }, + "forge.tls.createRecord.!1": { + "type": { + "!type": "number", + "!span": "125363[4108:6]-125367[4108:10]" + }, + "data": "+ByteBuffer" + }, + "forge.tls.createAlert.!1": { + "level": { + "!type": "number", + "!span": "95276[3096:10]-95281[3096:15]" + }, + "description": { + "!type": "number", + "!span": "95316[3097:10]-95327[3097:21]" + } + }, + "forge.tls.createSessionCache.!0": { + "capacity": { + "!type": "number", + "!span": "111111[249:104144]-111119[249:104152]" + }, + "": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "version": "initConnectionState.!1.version", + "sp": "initConnectionState.!2" + }, + "cache": "tls.createSessionCache.!0", + "order": "tls.createSessionCache.!0.order", + "getSession": "tls.createSessionCache.!0.getSession", + "setSession": "tls.createSessionCache.!0.setSession" + }, + "forge.tls.createConnection.!0": { + "server": { + "!type": "bool", + "!span": "1668[49:4]-1674[49:10]" + }, + "virtualHost": { + "!type": "string", + "!span": "1861[54:4]-1872[54:15]" + }, + "sessionCache": "tls.createSessionCache.!0", + "verify": "initConnectionState.!1.verify", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "connected": "initConnectionState.!1.connected", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed", + "error": "tls.createConnection.!0.error" + }, + "forge.tls.wrapSocket.!0": { + "virtualHost": { + "!type": "string", + "!span": "8112[302:6]-8123[302:17]" + }, + "!span": "7955[296:34]-8413[309:5]", + "sessionCache": "tls.createSessionCache.!0", + "caStore": "_initSocket.!2.caStore", + "socket": "net.socketPools..sockets.", + "verify": "initConnectionState.!1.verify", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate" + }, + "forge.tls.wrapSocket.!ret": { + "connected": { + "!type": "fn(e: net.socketPools..sockets..connected.!0)", + "!span": "1417[41:4]-1426[41:13]", + "!doc": "handle doing handshake after connecting" + }, + "closed": { + "!type": "fn(e: net.socketPools..sockets..closed.!0)", + "!span": "1468[42:4]-1474[42:10]", + "!doc": "handle closing TLS connection" + }, + "data": { + "!type": "fn(e: net.socketPools..sockets..data.!0)", + "!span": "1513[43:4]-1517[43:8]" + }, + "error": { + "!type": "fn(e: ?)", + "!span": "1554[44:4]-1559[44:9]", + "!doc": "handle error on socket" + }, + "destroy": { + "!type": "fn()", + "!span": "4398[160:12]-4405[160:19]", + "!doc": "Destroys this socket." + }, + "setSessionCache": { + "!type": "fn(cache: ?)", + "!span": "4867[174:12]-4882[174:27]", + "!doc": "Sets this socket's TLS session cache. This should be called before\nthe socket is connected or after it is closed.\n\nThe cache is an object mapping session IDs to internal opaque state.\nAn application might need to change the cache used by a particular\ntlsSocket between connections if it accesses multiple TLS hosts.\n\n@param cache the session cache to use." + }, + "connect": { + "!type": "fn(options: ?)", + "!span": "5314[188:12]-5321[188:19]", + "!doc": "Connects this socket.\n\n@param options:\n host: the host to connect to.\n port: the port to connect to.\n policyPort: the policy port to use (if non-default), 0 to\n use the flash default.\n policyUrl: the policy file URL to use (instead of port)." + }, + "close": { + "!type": "fn()", + "!span": "5428[195:12]-5433[195:17]", + "!doc": "Closes this socket." + }, + "isConnected": { + "!type": "fn() -> bool", + "!span": "5596[204:12]-5607[204:23]", + "!doc": "Determines if the socket is connected or not.\n\n@return true if connected, false if not." + }, + "send": { + "!type": "fn(bytes: string)", + "!span": "5847[215:12]-5851[215:16]", + "!doc": "Writes bytes to this socket.\n\n@param bytes the bytes (as a string) to write.\n\n@return true on success, false on failure." + }, + "receive": { + "!type": "fn(count: number) -> ?", + "!span": "6655[234:12]-6662[234:19]", + "!doc": "Reads bytes from this socket (non-blocking). Fewer than the number of\nbytes requested may be read if enough bytes are not available.\n\nThis method should be called from the data handler if there are enough\nbytes available. To see how many bytes are available, check the\n'bytesAvailable' property on the event in the data handler or call the\nbytesAvailable() function on the socket. If the browser is msie, then the\nbytesAvailable() function should be used to avoid race conditions.\nOtherwise, using the property on the data handler's event may be quicker.\n\n@param count the maximum number of bytes to read.\n\n@return the bytes read (as a string) or null on error." + }, + "bytesAvailable": { + "!type": "fn() -> number", + "!span": "6880[243:12]-6894[243:26]", + "!doc": "Gets the number of bytes available for receiving on the socket.\n\n@return the number of bytes available for receiving." + }, + "sending": { + "!type": "bool", + "!span": "5219[185:36]-5226[186:2]" + }, + "retries": { + "!type": "number", + "!span": "4067[146:1]-4074[146:8]" + }, + "!span": "1372[38:18]-1595[45:3]", + "!doc": "get raw socket", + "options": "net.socketPools..sockets..options", + "buffer": "+ByteBuffer" + }, + "forge.tls.wrapSocket.!ret.closed.!0": { + "type": { + "!type": "string", + "!span": "3524[121:6]-3528[121:10]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3545[122:6]-3559[122:20]" + }, + "!span": "3495[119:21]-3568[123:5]" + }, + "forge.util.parseFragment.!ret": { + "queryString": { + "!type": "string", + "!span": "63008[2417:4]-63019[2417:15]" + }, + "query": "?" + }, + "forge.util.makeRequest.!ret": { + "query": { + "!type": "string", + "!span": "64119[2448:4]-64124[2448:9]", + "!doc": "full query string" + }, + "getQueryLast": {}, + "getPath": "util.makeRequest.!ret.getPath", + "getQuery": "util.makeRequest.!ret.getQuery" + }, + "forge.xhr.setCookie.!0": { + "maxAge": { + "!type": "number", + "!span": "6000[192:9]-6006[192:15]", + "!doc": "default cookie expiration to never" + }, + "comment": { + "!type": "string", + "!span": "20205[658:0]-20212[659:6]" + }, + "secure": { + "!type": "bool", + "!span": "20296[663:3]-20302[663:9]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[666:0]-20402[666:8]" + }, + "path": { + "!type": "string", + "!span": "20445[668:25]-20449[669:0]" + }, + "created": { + "!type": "number", + "!span": "20583[673:4]-20590[673:11]" + } + }, + "forge.xhr.create.!ret": { + "readyState": { + "!type": "number", + "!span": "11722[366:4]-11732[366:14]", + "!doc": "7. set state to UNSENT" + }, + "responseText": { + "!type": "string", + "!span": "11792[368:4]-11804[368:16]", + "!doc": "3. set response to null" + }, + "responseXML": { + "async": { + "!type": "bool", + "!span": "18241[587:16]-18246[587:21]" + } + }, + "status": { + "!type": "number", + "!span": "11952[372:4]-11958[372:10]", + "!doc": "custom: reset status and statusText" + }, + "statusText": { + "!type": "string", + "!span": "12035[374:4]-12045[374:14]", + "!doc": "readonly, returns the HTTP status message (i.e. 'Not Found')" + }, + "cookies": "_getStorageId.!0.cookies", + "open": "xhrApi.create.!ret.open", + "setRequestHeader": "xhrApi.create.!ret.setRequestHeader", + "send": "xhrApi.create.!ret.send", + "abort": "xhrApi.create.!ret.abort", + "getAllResponseHeaders": "xhrApi.create.!ret.getAllResponseHeaders", + "getResponseHeader": "xhrApi.create.!ret.getResponseHeader" + }, + "mix.": "[number]", + "imix.": "[number]", + "_updateBlock.!2": "[number|_fromDer.!ret]", + "_createCipher.!0": { + "decrypt": { + "!type": "bool", + "!span": "4357[142:4]-4364[142:11]" + }, + "!span": "4319[139:23]-4390[144:3]" + }, + "_createCipher.!ret": "+BlockCipher", + "tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initSecurityParameters.!0": { + "bulk_cipher_algorithm": { + "!type": "number", + "!span": "455[21:7]-476[21:28]" + }, + "cipher_type": { + "!type": "number", + "!span": "515[22:7]-526[22:18]" + }, + "enc_key_length": { + "!type": "number", + "!span": "558[23:7]-572[23:21]" + }, + "block_length": { + "!type": "number", + "!span": "586[24:7]-598[24:19]" + }, + "fixed_iv_length": { + "!type": "number", + "!span": "612[25:7]-627[25:22]" + }, + "record_iv_length": { + "!type": "number", + "!span": "641[26:7]-657[26:23]" + }, + "mac_algorithm": { + "!type": "number", + "!span": "671[27:7]-684[27:20]" + }, + "mac_length": { + "!type": "number", + "!span": "722[28:7]-732[28:17]" + }, + "mac_key_length": { + "!type": "number", + "!span": "746[29:7]-760[29:21]" + } + }, + "tls.CipherSuites.TLS_RSA_WITH_AES_256_CBC_SHA.initSecurityParameters.!0": { + "bulk_cipher_algorithm": { + "!type": "number", + "!span": "979[37:7]-1000[37:28]" + }, + "cipher_type": { + "!type": "number", + "!span": "1039[38:7]-1050[38:18]" + }, + "enc_key_length": { + "!type": "number", + "!span": "1082[39:7]-1096[39:21]" + }, + "block_length": { + "!type": "number", + "!span": "1110[40:7]-1122[40:19]" + }, + "fixed_iv_length": { + "!type": "number", + "!span": "1136[41:7]-1151[41:22]" + }, + "record_iv_length": { + "!type": "number", + "!span": "1165[42:7]-1181[42:23]" + }, + "mac_algorithm": { + "!type": "number", + "!span": "1195[43:7]-1208[43:20]" + }, + "mac_length": { + "!type": "number", + "!span": "1246[44:7]-1256[44:17]" + }, + "mac_key_length": { + "!type": "number", + "!span": "1270[45:7]-1284[45:21]" + } + }, + "tls.handleUnexpected.!0": { + "version": { + "major": { + "!type": "number", + "!span": "115468[3775:17]-115473[3775:22]" + }, + "minor": { + "!type": "number", + "!span": "115494[3775:43]-115499[3775:48]" + } + }, + "entity": { + "!type": "number", + "!span": "113758[3719:4]-113764[3719:10]" + }, + "virtualHost": { + "!type": "string", + "!span": "113932[3725:4]-113943[3725:15]" + }, + "verifyClient": { + "!type": "bool", + "!span": "113978[3726:4]-113990[3726:16]" + }, + "error": {}, + "session": { + "compressionMethod": { + "!type": "number", + "!span": "59972[2042:8]-59989[2042:25]", + "!doc": "no compression" + }, + "resuming": { + "!type": "bool", + "!span": "30337[1016:14]-30345[1016:22]" + }, + "id": { + "!type": "string", + "!span": "30684[1030:12]-30686[1030:14]", + "!doc": "update session" + }, + "clientHelloVersion": { + "major": { + "!type": "number", + "!span": "82459[2709:4]-82464[2709:9]" + }, + "minor": { + "!type": "number", + "!span": "82487[2710:4]-82492[2710:9]" + } + }, + "version": "initConnectionState.!1.version", + "md5": "hash.!0", + "sha1": "rsa_mgf1.!2", + "certificateRequest": { + "certificate_types": "+ByteBuffer", + "certificate_authorities": "+ByteBuffer" + }, + "sp": "initConnectionState.!2", + "extensions": { + "server_name": { + "serverNameList": "initConnectionState.!1.session.extensions.server_name.serverNameList" + } + } + }, + "expect": { + "!type": "number", + "!span": "115664[3783:6]-115670[3783:12]", + "!doc": "expect application data next" + }, + "open": { + "!type": "bool", + "!span": "115777[3786:6]-115781[3786:10]", + "!doc": "connection no longer open, clear input" + }, + "handshakes": { + "!type": "number", + "!span": "115797[3787:6]-115807[3787:16]" + }, + "handshaking": { + "!type": "bool", + "!span": "115819[3788:6]-115830[3788:17]", + "!doc": "now handshaking" + }, + "isConnected": { + "!type": "bool", + "!span": "115846[3789:6]-115857[3789:17]", + "!doc": "now connected" + }, + "fail": { + "!type": "bool", + "!span": "115873[3790:6]-115877[3790:10]", + "!doc": "set fail flag" + }, + "sessionCache": "tls.createSessionCache.!0", + "input": "+ByteBuffer", + "tlsData": "+ByteBuffer", + "data": "+ByteBuffer", + "record": "hmac_sha1.!2", + "state": { + "pending": "tls.createConnectionState.!ret", + "current": "tls.createConnectionState.!ret" + }, + "fragmented": "hmac_sha1.!2", + "records": { + "": "H5.!1" + }, + "cipherSuites": "initConnectionState.!1.cipherSuites", + "connected": "initConnectionState.!1.connected", + "verify": "initConnectionState.!1.verify", + "getSignature": "initConnectionState.!1.getSignature", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "reset": "initConnectionState.!1.reset", + "handshake": "initConnectionState.!1.handshake", + "process": "initConnectionState.!1.process", + "prepare": "initConnectionState.!1.prepare", + "prepareHeartbeatRequest": "initConnectionState.!1.prepareHeartbeatRequest", + "close": "initConnectionState.!1.close" + }, + "tls.handleUnexpected.!0.error.!1": { + "send": { + "!type": "bool", + "!span": "110177[3577:8]-110181[3577:12]" + }, + "alert": { + "level": { + "!type": "number", + "!span": "110432[3589:8]-110437[3589:13]" + } + }, + "origin": { + "!type": "string", + "!span": "114631[3741:9]-114637[3741:15]", + "!doc": "set origin if not set" + } + }, + "tls.handleUnexpected.!1": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + } + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "fragment": "+ByteBuffer" + }, + "tls.parseHelloMessage.!ret": { + "version": { + "major": { + "!type": "number", + "!span": "23963[804:8]-23968[804:13]" + }, + "minor": { + "!type": "number", + "!span": "23991[805:8]-23996[805:13]" + }, + "!span": "23944[803:6]-23951[803:13]" + }, + "extensions": { + "!type": "[tls.parseHelloMessage.!ret.extensions.]", + "!span": "24116[809:6]-24126[809:16]" + }, + "!span": "23936[802:10]-24136[810:5]", + "random": "+ByteBuffer", + "session_id": "+ByteBuffer", + "cipher_suites": "+ByteBuffer", + "compression_methods": "+ByteBuffer" + }, + "tls.parseHelloMessage.!ret.extensions.": { + "type": { + "!type": "[number, number]", + "!span": "24628[826:10]-24632[826:14]" + }, + "!span": "24616[825:28]-24713[828:9]", + "data": "+ByteBuffer" + }, + "tls.handleServerHelloDone.!1": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + } + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "fragment": "+ByteBuffer" + }, + "tls.generateKeys.!1": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "tls.generateKeys.!ret": { + "!span": "73404[2401:13]-73632[2406:3]", + "!doc": "split the key material into the MAC and encryption keys" + }, + "tls.createConnectionState.!ret": { + "read": { + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "sequenceNumber": "deflate.!2.sequenceNumber", + "cipherFunction": "deflate.!2.cipherFunction", + "updateSequenceNumber": "deflate.!2.updateSequenceNumber", + "update": "deflate.!2.update", + "compressFunction": "deflate" + }, + "!span": "75794[2472:14]-75847[2475:3]", + "!doc": "create pending state", + "write": "deflate.!2" + }, + "tls.createRecord.!1": { + "type": { + "!type": "number", + "!span": "125363[4108:6]-125367[4108:10]" + }, + "!span": "125355[4107:37]-125510[4111:5]", + "data": "+ByteBuffer" + }, + "tls.createAlert.!1": { + "level": { + "!type": "number", + "!span": "95276[3096:10]-95281[3096:15]" + }, + "description": { + "!type": "number", + "!span": "95316[3097:10]-95327[3097:21]" + }, + "!span": "95264[3095:15]-95375[3098:9]" + }, + "tls.getClientSignature.!1": { + "!type": "fn(c: ?, signature: +ByteBuffer)", + "!span": "49436[1670:17]-50425[1706:3]", + "!doc": "create callback to handle client signature (for client-certs)" + }, + "tls.verifyCertificateChain.!1": "[+ByteBuffer|pki.certificateFromPem.!ret]", + "tls.createSessionCache.!0": { + "capacity": { + "!type": "number", + "!span": "111111[249:104144]-111119[249:104152]" + }, + "order": { + "!type": "[tls.createSessionCache.!0.|string]", + "!span": "111161[249:104194]-111166[249:104199]" + }, + "getSession": { + "!type": "fn(sessionId: string) -> tls.createSessionCache.!0.", + "!span": "111457[249:104490]-111467[249:104500]", + "!doc": "get a session from a session ID (or get any session)" + }, + "setSession": { + "!type": "fn(sessionId: string, session: tls.createSessionCache.!0.)", + "!span": "112168[249:105201]-112178[249:105211]", + "!doc": "set a session in the cache" + }, + "": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "!span": "112513[249:105546]-112516[249:105549]", + "!doc": "only need to preserve session ID, version, and security params", + "version": "initConnectionState.!1.version", + "sp": "initConnectionState.!2" + }, + "!span": "8000[298:20]-8002[298:22]", + "cache": "tls.createSessionCache.!0" + }, + "tls.createConnection.!0": { + "server": { + "!type": "bool", + "!span": "1668[49:4]-1674[49:10]" + }, + "virtualHost": { + "!type": "string", + "!span": "1861[54:4]-1872[54:15]" + }, + "error": { + "!type": "fn(c: ?, e: ?)", + "!span": "2775[87:4]-2780[87:9]" + }, + "!span": "1662[48:37]-3019[98:3]", + "sessionCache": "tls.createSessionCache.!0", + "verify": "initConnectionState.!1.verify", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "connected": "initConnectionState.!1.connected", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed" + }, + "initConnectionState.!0": "+DataBuffer", + "initConnectionState.!1": { + "version": { + "major": { + "!type": "number", + "!span": "115468[3775:17]-115473[3775:22]" + }, + "minor": { + "!type": "number", + "!span": "115494[3775:43]-115499[3775:48]" + }, + "!span": "113691[3718:4]-113698[3718:11]", + "!doc": "only update version on connection, session version not yet set" + }, + "entity": { + "!type": "number", + "!span": "113758[3719:4]-113764[3719:10]" + }, + "cipherSuites": { + "!type": "[?]", + "!span": "113866[3723:4]-113878[3723:16]", + "!doc": "setup default cipher suites" + }, + "connected": { + "!type": "fn(c: ?|initConnectionState.!1)", + "!span": "113898[3724:4]-113907[3724:13]" + }, + "virtualHost": { + "!type": "string", + "!span": "113932[3725:4]-113943[3725:15]" + }, + "verifyClient": { + "!type": "bool", + "!span": "113978[3726:4]-113990[3726:16]" + }, + "verify": { + "!type": "fn(c: ?|initConnectionState.!1, verified: ?, depth: number, certs: [+ByteBuffer|pki.certificateFromPem.!ret]) -> !1", + "!span": "114027[3727:4]-114033[3727:10]", + "!doc": "A default certificate verify function that checks a certificate common\nname against the client's URL host.\n\n@param c the TLS connection.\n@param verified true if cert is verified, otherwise alert number.\n@param depth the chain depth.\n@param certs the cert chain.\n\n@return true if verified and the common name matches the host, error\n otherwise." + }, + "getSignature": { + "!type": "fn(c: ?, b: ?, callback: fn(c: ?, signature: +ByteBuffer))", + "!span": "114251[3731:4]-114263[3731:16]", + "!doc": "create default signing function as necessary" + }, + "tlsDataReady": { + "!type": "fn(c: ?)", + "!span": "114414[3735:4]-114426[3735:16]" + }, + "dataReady": { + "!type": "fn(c: initConnectionState.!1)", + "!span": "114454[3736:4]-114463[3736:13]" + }, + "closed": { + "!type": "fn(c: initConnectionState.!1)", + "!span": "114538[3738:4]-114544[3738:10]" + }, + "error": { + "!type": "fn(c: ?, ex: ?)", + "!span": "114566[3739:4]-114571[3739:9]" + }, + "deflate": { + "!type": "fn(bytes: ?)", + "!span": "115188[3765:4]-115195[3765:11]" + }, + "inflate": { + "!type": "fn(bytes: ?) -> string", + "!span": "115226[3766:4]-115233[3766:11]" + }, + "session": { + "extensions": { + "server_name": { + "serverNameList": { + "!type": "[?]", + "!span": "59895[2038:12]-59909[2038:26]" + }, + "!span": "59868[2037:10]-59879[2037:21]" + }, + "!span": "59844[2036:8]-59854[2036:18]" + }, + "compressionMethod": { + "!type": "number", + "!span": "59972[2042:8]-59989[2042:25]", + "!doc": "no compression" + }, + "resuming": { + "!type": "bool", + "!span": "30337[1016:14]-30345[1016:22]" + }, + "id": { + "!type": "string", + "!span": "30684[1030:12]-30686[1030:14]", + "!doc": "update session" + }, + "certificateRequest": { + "!span": "44644[1500:12]-44662[1500:30]", + "!doc": "save certificate request in session", + "certificate_types": "+ByteBuffer", + "certificate_authorities": "+ByteBuffer" + }, + "clientHelloVersion": { + "major": { + "!type": "number", + "!span": "82459[2709:4]-82464[2709:9]" + }, + "minor": { + "!type": "number", + "!span": "82487[2710:4]-82492[2710:9]" + }, + "!span": "32145[1080:12]-32163[1080:30]", + "!doc": "save hello version" + }, + "!span": "115548[3777:6]-115555[3777:13]", + "!doc": "set up session", + "version": "initConnectionState.!1.version", + "md5": "hash.!0", + "sha1": "rsa_mgf1.!2", + "sp": "initConnectionState.!2" + }, + "state": { + "!span": "115600[3779:6]-115605[3779:11]", + "pending": "tls.createConnectionState.!ret", + "current": "tls.createConnectionState.!ret" + }, + "expect": { + "!type": "number", + "!span": "115664[3783:6]-115670[3783:12]", + "!doc": "expect application data next" + }, + "records": { + "!type": "[H5.!1]", + "!span": "115757[3785:6]-115764[3785:13]" + }, + "open": { + "!type": "bool", + "!span": "115777[3786:6]-115781[3786:10]", + "!doc": "connection no longer open, clear input" + }, + "handshakes": { + "!type": "number", + "!span": "115797[3787:6]-115807[3787:16]" + }, + "handshaking": { + "!type": "bool", + "!span": "115819[3788:6]-115830[3788:17]", + "!doc": "now handshaking" + }, + "isConnected": { + "!type": "bool", + "!span": "115846[3789:6]-115857[3789:17]", + "!doc": "now connected" + }, + "fail": { + "!type": "bool", + "!span": "115873[3790:6]-115877[3790:10]", + "!doc": "set fail flag" + }, + "reset": { + "!type": "fn(clearFail: bool)", + "!span": "115421[3774:4]-115426[3774:9]", + "!doc": "Resets a closed TLS connection for reuse. Called in c.close().\n\n@param clearFail true to clear the fail flag (default: true)." + }, + "handshake": { + "!type": "fn(sessionId: string)", + "!span": "120270[3937:4]-120279[3937:13]", + "!doc": "Performs a handshake using the TLS Handshake Protocol, as a client.\n\nThis method should only be called if the connection is in client mode.\n\n@param sessionId the session ID to use, null to start a new one." + }, + "process": { + "!type": "fn(data: string) -> number", + "!span": "122850[4029:4]-122857[4029:11]", + "!doc": "Called when TLS protocol data has been received from somewhere and should\nbe processed by the TLS engine.\n\n@param data the TLS protocol data, as a string, to process.\n\n@return 0 if the data could be processed, otherwise the number of bytes\n required for data to be processed." + }, + "prepare": { + "!type": "fn(data: string)", + "!span": "124204[4076:4]-124211[4076:11]", + "!doc": "Requests that application data be packaged into a TLS record. The\ntlsDataReady handler will be called when the TLS record(s) have been\nprepared.\n\n@param data the application data, as a raw 'binary' encoded string, to\n be sent; to send utf-16/utf-8 string data, use the return value\n of util.encodeUtf8(str).\n\n@return true on success, false on failure." + }, + "prepareHeartbeatRequest": { + "!type": "fn(payload: ?, payloadLength: ?)", + "!span": "125034[4099:4]-125057[4099:27]", + "!doc": "Requests that a heartbeat request be packaged into a TLS record for\ntransmission. The tlsDataReady handler will be called when TLS record(s)\nhave been prepared.\n\nWhen a heartbeat response has been received, the heartbeatReceived\nhandler will be called with the matching payload. This handler can\nbe used to clear a retransmission timer, etc.\n\n@param payload the heartbeat data to send as the payload in the message.\n@param [payloadLength] the payload length to use, defaults to the\n actual payload length.\n\n@return true on success, false on failure." + }, + "close": { + "!type": "fn(clearFail: bool)", + "!span": "125690[4120:4]-125695[4120:9]", + "!doc": "Closes the connection (sends a close_notify alert).\n\n@param clearFail true to clear the fail flag (default: true)." + }, + "!span": "113685[3717:10]-115262[3767:3]", + "!doc": "create TLS connection", + "sessionCache": "tls.createSessionCache.!0", + "input": "+ByteBuffer", + "tlsData": "+ByteBuffer", + "data": "+ByteBuffer", + "record": "hmac_sha1.!2", + "fragmented": "hmac_sha1.!2" + }, + "initConnectionState.!1.error.!1": { + "send": { + "!type": "bool", + "!span": "110177[3577:8]-110181[3577:12]" + }, + "alert": { + "level": { + "!type": "number", + "!span": "110432[3589:8]-110437[3589:13]" + }, + "!span": "110197[3578:8]-110202[3578:13]" + }, + "origin": { + "!type": "string", + "!span": "114631[3741:9]-114637[3741:15]", + "!doc": "set origin if not set" + }, + "!span": "110167[3576:12]-110312[3582:7]", + "!doc": "build tls error if not already customized" + }, + "initConnectionState.!2": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "!span": "28158[938:17]-28636[955:3]", + "!doc": "create new security parameters", + "keys": "tls.generateKeys.!ret" + }, + "encrypt_aes_cbc_sha1.!0": {}, + "decrypt_aes_cbc_sha1.!0": { + "fragment": "+ByteBuffer" + }, + "asn1.create.!4": { + "!span": "20489[621:61]-20535[623:3]", + "!doc": "add BIT STRING contents if available" + }, + "asn1.create.!ret": { + "tagClass": { + "!type": "number", + "!span": "8212[212:4]-8220[212:12]" + }, + "type": { + "!type": "number", + "!span": "8236[213:4]-8240[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "8252[214:4]-8263[214:15]" + }, + "composed": { + "!type": "bool", + "!span": "8282[215:4]-8290[215:12]" + }, + "read": { + "!type": "number", + "!span": "19652[653:42]-19656[655:1]" + }, + "original": "_fromDer.!ret" + }, + "asn1.validate.!1": { + "name": { + "!type": "string", + "!span": "12601[409:2]-12605[409:6]" + }, + "tagClass": { + "!type": "number", + "!span": "12637[410:2]-12645[410:10]" + }, + "type": { + "!type": "number", + "!span": "12671[411:2]-12675[411:6]" + }, + "constructed": { + "!type": "bool", + "!span": "12699[412:2]-12710[412:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "12720[413:2]-12731[413:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "12777[415:4]-12781[415:8]" + }, + "tagClass": { + "!type": "number", + "!span": "12823[416:4]-12831[416:12]" + }, + "type": { + "!type": "number", + "!span": "12859[417:4]-12863[417:8]" + }, + "constructed": { + "!type": "bool", + "!span": "12888[418:4]-12899[418:15]" + }, + "capture": { + "!type": "string", + "!span": "12912[419:4]-12919[419:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "13002[422:4]-13006[422:8]", + "!doc": "Name (subject) (RDNSequence)" + }, + "tagClass": { + "!type": "number", + "!span": "13048[423:4]-13056[423:12]" + }, + "type": { + "!type": "number", + "!span": "13084[424:4]-13088[424:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13114[425:4]-13125[425:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "13137[426:4]-13148[426:15]" + } + }, + "2": "publicKeyValidator", + "3": { + "name": { + "!type": "string", + "!span": "13245[431:4]-13249[431:8]" + }, + "tagClass": { + "!type": "number", + "!span": "13294[432:4]-13302[432:12]" + }, + "type": { + "!type": "number", + "!span": "13337[433:4]-13341[433:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13350[434:4]-13361[434:15]" + }, + "optional": { + "!type": "bool", + "!span": "13373[435:4]-13381[435:12]" + }, + "capture": { + "!type": "string", + "!span": "13393[436:4]-13400[436:11]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "13460[438:6]-13464[438:10]" + }, + "tagClass": { + "!type": "number", + "!span": "13511[439:6]-13519[439:14]" + }, + "type": { + "!type": "number", + "!span": "13549[440:6]-13553[440:10]" + }, + "constructed": { + "!type": "bool", + "!span": "13581[441:6]-13592[441:17]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "13624[443:8]-13628[443:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13682[444:8]-13690[444:16]" + }, + "type": { + "!type": "number", + "!span": "13722[445:8]-13726[445:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13751[446:8]-13762[446:19]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "13789[448:8]-13793[448:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13848[449:8]-13856[449:16]" + }, + "type": { + "!type": "number", + "!span": "13888[450:8]-13892[450:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13917[451:8]-13928[451:19]" + } + } + } + } + } + } + } + }, + "asn1.validate.!2": { + "!span": "51043[1649:16]-51045[1649:18]", + "!doc": "validate certification request and capture data" + }, + "asn1.validate.!3": "[string]", + "asn1.prettyPrint.!0": { + "tagClass": { + "!type": "number", + "!span": "9228[254:4]-9236[254:12]" + }, + "type": { + "!type": "number", + "!span": "9256[255:4]-9260[255:8]" + }, + "constructed": { + "!type": "bool", + "!span": "9276[256:4]-9287[256:15]" + }, + "composed": { + "!type": "bool", + "!span": "9310[257:4]-9318[257:12]" + }, + "!span": "9222[253:9]-9378[259:3]" + }, + "_fromDer.!ret": { + "tagClass": { + "!type": "number", + "!span": "8212[212:4]-8220[212:12]" + }, + "type": { + "!type": "number", + "!span": "8236[213:4]-8240[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "8252[214:4]-8263[214:15]" + }, + "composed": { + "!type": "bool", + "!span": "8282[215:4]-8290[215:12]" + }, + "read": { + "!type": "number", + "!span": "19652[653:42]-19656[655:1]" + }, + "!span": "8206[211:12]-8354[217:3]", + "!doc": "TODO: add readonly flag to avoid this overhead\nsave copy to detect changes", + "original": "_fromDer.!ret" + }, + "BlockCipher.!0": { + "key": { + "!type": "string", + "!span": "2009[76:4]-2012[76:7]" + }, + "decrypt": { + "!type": "bool", + "!span": "2023[77:4]-2030[77:11]" + }, + "!span": "1983[74:38]-2040[78:3]" + }, + "modes.ecb.prototype.unpad.!1": { + "decrypt": { + "!type": "bool", + "!span": "6102[201:10]-6109[201:17]" + }, + "overflow": { + "!type": "number", + "!span": "6182[204:10]-6190[204:18]", + "!doc": "get # of bytes that won't fill a block" + }, + "!span": "6088[200:16]-6090[200:18]", + "!doc": "build options for padding and afterFinish functions" + }, + "modes.ecb.!0": { + "blockSize": { + "!type": "number", + "!span": "4691[159:4]-4700[159:13]" + }, + "!span": "4685[158:23]-4968[168:3]", + "cipher": { + "encrypt": "modes.gcm.cipher.encrypt", + "decrypt": "modes.gcm.cipher.decrypt" + } + }, + "modes.cfb.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "6987[257:10]-6991[257:14]" + } + }, + "modes.cfb.prototype.decrypt.!0": { + "read": { + "!type": "number", + "!span": "8719[317:10]-8723[317:14]" + } + }, + "modes.ofb.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "11014[400:10]-11018[400:14]" + } + }, + "modes.ctr.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "13308[482:12]-13312[482:16]" + } + }, + "modes.gcm.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "19360[681:12]-19364[681:16]" + } + }, + "modes.gcm.prototype.multiply.!0": "[number]", + "modes.gcm.prototype.multiply.!ret": "[number]", + "modes.gcm.prototype.pow.!1": "[number]", + "modes.gcm.prototype.ghash.!1": "[number]", + "publicKeyValidator.value.0": { + "name": { + "!type": "string", + "!span": "6363[237:4]-6367[237:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6417[238:4]-6425[238:12]" + }, + "type": { + "!type": "number", + "!span": "6453[239:4]-6457[239:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6483[240:4]-6494[240:15]" + }, + "value": { + "!type": "[publicKeyValidator.value.0.value.]", + "!span": "6506[241:4]-6511[241:9]" + }, + "!span": "6357[236:10]-6692[248:3]" + }, + "publicKeyValidator.value.0.value.": { + "name": { + "!type": "string", + "!span": "6522[242:6]-6526[242:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6567[243:6]-6575[243:14]" + }, + "type": { + "!type": "number", + "!span": "6605[244:6]-6609[244:10]" + }, + "constructed": { + "!type": "bool", + "!span": "6632[245:6]-6643[245:17]" + }, + "capture": { + "!type": "string", + "!span": "6658[246:6]-6665[246:13]" + }, + "!span": "6514[241:12]-6687[247:5]" + }, + "publicKeyValidator.value.1": { + "name": { + "!type": "string", + "!span": "6724[250:4]-6728[250:8]", + "!doc": "subjectPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6775[251:4]-6783[251:12]" + }, + "type": { + "!type": "number", + "!span": "6811[252:4]-6815[252:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6842[253:4]-6853[253:15]" + }, + "value": { + "!type": "[publicKeyValidator.value.1.value.]", + "!span": "6866[254:4]-6871[254:9]" + }, + "!span": "6694[248:5]-7125[263:3]" + }, + "publicKeyValidator.value.1.value.": { + "name": { + "!type": "string", + "!span": "6904[256:6]-6908[256:10]", + "!doc": "RSAPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6970[257:6]-6978[257:14]" + }, + "type": { + "!type": "number", + "!span": "7008[258:6]-7012[258:10]" + }, + "constructed": { + "!type": "bool", + "!span": "7040[259:6]-7051[259:17]" + }, + "optional": { + "!type": "bool", + "!span": "7065[260:6]-7073[260:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "7087[261:6]-7098[261:17]" + }, + "!span": "6874[254:12]-7120[262:5]" + }, + "privateKeyValidator.value.0": { + "name": { + "!type": "string", + "!span": "2795[103:4]-2799[103:8]", + "!doc": "Version (INTEGER)" + }, + "tagClass": { + "!type": "number", + "!span": "2831[104:4]-2839[104:12]" + }, + "type": { + "!type": "number", + "!span": "2867[105:4]-2871[105:8]" + }, + "constructed": { + "!type": "bool", + "!span": "2896[106:4]-2907[106:15]" + }, + "capture": { + "!type": "string", + "!span": "2920[107:4]-2927[107:11]" + }, + "!span": "2764[101:10]-2952[108:3]" + }, + "privateKeyValidator.value.1": { + "name": { + "!type": "string", + "!span": "2987[110:4]-2991[110:8]", + "!doc": "privateKeyAlgorithm" + }, + "tagClass": { + "!type": "number", + "!span": "3035[111:4]-3043[111:12]" + }, + "type": { + "!type": "number", + "!span": "3071[112:4]-3075[112:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3101[113:4]-3112[113:15]" + }, + "value": { + "!type": "[privateKeyValidator.value.1.value.]", + "!span": "3124[114:4]-3129[114:9]" + }, + "!span": "2954[108:5]-3311[121:3]" + }, + "privateKeyValidator.value.1.value.": { + "name": { + "!type": "string", + "!span": "3140[115:6]-3144[115:10]" + }, + "tagClass": { + "!type": "number", + "!span": "3185[116:6]-3193[116:14]" + }, + "type": { + "!type": "number", + "!span": "3223[117:6]-3227[117:10]" + }, + "constructed": { + "!type": "bool", + "!span": "3250[118:6]-3261[118:17]" + }, + "capture": { + "!type": "string", + "!span": "3276[119:6]-3283[119:13]" + }, + "!span": "3132[114:12]-3306[120:5]" + }, + "privateKeyValidator.value.2": { + "name": { + "!type": "string", + "!span": "3337[123:4]-3341[123:8]", + "!doc": "PrivateKey" + }, + "tagClass": { + "!type": "number", + "!span": "3365[124:4]-3373[124:12]" + }, + "type": { + "!type": "number", + "!span": "3401[125:4]-3405[125:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3434[126:4]-3445[126:15]" + }, + "capture": { + "!type": "string", + "!span": "3458[127:4]-3465[127:11]" + }, + "!span": "3313[121:5]-3483[128:3]" + }, + "ed25519.generateKeyPair.!0": { + "!span": "5338[164:42]-5356[164:60]", + "seed": "+Float32Array" + }, + "ed25519.generateKeyPair.!ret": { + "!span": "2129[66:9]-2160[66:40]", + "publicKey": "+Float32Array", + "privateKey": "+Float32Array" + }, + "ed25519.privateKeyFromAsn1.!ret": { + "!span": "3458[102:9]-3492[102:43]" + }, + "add.!0": "[+Float32Array, +Float32Array, +Float32Array, +Float32Array]", + "cswap.!0": "[+Float32Array, +Float32Array, +Float32Array, +Float32Array]", + "cswap.!1": "[+Float32Array, +Float32Array, +Float32Array, +Float32Array]", + "pack.!1": "[+Float32Array, +Float32Array, +Float32Array, +Float32Array]", + "gf.!0": "[number]", + "form.serialize.!ret": { + "!span": "3658[137:13]-3660[137:15]" + }, + "hmac.create.!ret": { + "start": { + "!type": "fn(md: string|hash.!0, key: ?)", + "!span": "1135[45:6]-1140[45:11]", + "!doc": "Starts or restarts the HMAC with the given key and message digest.\n\n@param md the message digest to use, null to reuse the previous one,\n a string to use builtin 'sha1', 'md5', 'sha256'.\n@param key the key to use as a string, array of bytes, byte buffer,\n or null to reuse the previous key." + }, + "update": { + "!type": "fn(bytes: ?)", + "!span": "3312[123:6]-3318[123:12]", + "!doc": "Updates the HMAC with the given message bytes.\n\n@param bytes the bytes to update with." + }, + "getMac": { + "!type": "fn() -> +ByteBuffer", + "!span": "3500[132:6]-3506[132:12]", + "!doc": "Produces the Message Authentication Code (MAC).\n\n@return a byte buffer containing the digest value." + }, + "!span": "774[35:12]-776[35:14]", + "!doc": "hmac context", + "digest": "hmac.create.!ret.getMac" + }, + "http.createClient.!0": { + "url": { + "!type": "string", + "!span": "12551[397:8]-12554[397:11]" + }, + "policyPort": { + "!type": "number", + "!span": "12602[399:8]-12612[399:18]" + }, + "connections": { + "!type": "number", + "!span": "12709[401:8]-12720[401:19]" + }, + "persistCookies": { + "!type": "bool", + "!span": "12848[404:8]-12862[404:22]" + }, + "primeTlsSockets": { + "!type": "bool", + "!span": "12904[405:8]-12919[405:23]" + }, + "!span": "12541[396:40]-13131[410:7]", + "socketPool": "net.socketPools." + }, + "http.createClient.!ret": { + "policyPort": { + "!type": "number", + "!span": "13207[467:4]-13217[467:14]", + "!doc": "the policy port to use" + }, + "secure": { + "!type": "bool", + "!span": "13475[477:4]-13481[477:10]", + "!doc": "whether or not the connections are secure" + }, + "persistCookies": { + "!type": "bool", + "!span": "13717[482:4]-13731[482:18]", + "!doc": "default to flash storage of cookies" + }, + "getCookie": {}, + "url": "http.parseUrl.!ret", + "socketPool": "net.socketPools.", + "requests": { + "": "net.socketPools..sockets..options" + }, + "sockets": { + "": "net.socketPools..sockets." + }, + "idle": { + "": "net.socketPools..sockets." + }, + "cookies": "_getStorageId.!0.cookies", + "send": {}, + "destroy": "_getStorageId.!0.destroy", + "setCookie": "_getStorageId.!0.setCookie", + "removeCookie": "_getStorageId.!0.removeCookie", + "clearCookies": "_getStorageId.!0.clearCookies" + }, + "http.createClient.!ret.getCookie.!ret": { + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]" + }, + "maxAge": { + "!type": "number", + "!span": "20252[674:15]-20258[674:21]" + }, + "secure": { + "!type": "bool", + "!span": "20296[675:15]-20302[675:21]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[677:15]-20402[677:23]" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "http.createRequest.!0": { + "!span": "14846[469:40]-14891[472:5]" + }, + "http.parseUrl.!ret": { + "scheme": { + "!type": "string", + "!span": "59506[2274:4]-59512[2274:10]" + }, + "host": { + "!type": "string", + "!span": "59524[2275:4]-59528[2275:8]" + }, + "path": { + "!type": "string", + "!span": "59556[2277:4]-59560[2277:8]" + }, + "fullHost": { + "!type": "string", + "!span": "59592[2280:8]-59600[2280:16]" + }, + "!span": "59485[2272:34]-59570[2278:3]", + "!doc": "url" + }, + "http.withinCookieDomain.!1": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + }, + "!span": "36239[1241:22]-36241[1241:24]", + "!doc": "cookie may be null, a cookie object, or a domain string" + }, + "_getStorageId.!0": { + "policyPort": { + "!type": "number", + "!span": "13207[467:4]-13217[467:14]", + "!doc": "the policy port to use" + }, + "requests": { + "!type": "[net.socketPools..sockets..options]", + "!span": "13338[471:4]-13346[471:12]", + "!doc": "clear pending requests, close and destroy sockets" + }, + "sockets": { + "!type": "[net.socketPools..sockets.|forge.tls.wrapSocket.!ret]", + "!span": "13375[473:4]-13382[473:11]", + "!doc": "all sockets" + }, + "idle": { + "!type": "[net.socketPools..sockets.|forge.tls.wrapSocket.!ret]", + "!span": "13412[475:4]-13416[475:8]", + "!doc": "idle sockets" + }, + "secure": { + "!type": "bool", + "!span": "13475[477:4]-13481[477:10]", + "!doc": "whether or not the connections are secure" + }, + "cookies": { + "": { + "!span": "21338[702:25]-21349[702:36]", + "!doc": "get cookie paths", + "": "http.withinCookieDomain.!1" + }, + "!span": "13657[480:4]-13664[480:11]", + "!doc": "cookie jar (key'd off of name and then path, there is only 1 domain\nand one setting for secure per client so name+path is unique)" + }, + "persistCookies": { + "!type": "bool", + "!span": "13717[482:4]-13731[482:18]", + "!doc": "default to flash storage of cookies" + }, + "send": { + "!type": "fn(options: _getStorageId.!0.send.!0)", + "!span": "16404[562:9]-16408[562:13]", + "!doc": "Sends a request. A method 'abort' will be set on the request that\ncan be called to attempt to abort the request.\n\n@param options:\n request: the request to send.\n connected: a callback for when the connection is open.\n closed: a callback for when the connection is closed.\n headerReady: a callback for when the response header arrives.\n bodyReady: a callback for when the response body arrives.\n error: a callback for if an error occurs." + }, + "destroy": { + "!type": "fn()", + "!span": "18426[630:9]-18433[630:16]", + "!doc": "Destroys this client." + }, + "setCookie": { + "!type": "fn(cookie: http.withinCookieDomain.!1) -> bool", + "!span": "19861[664:9]-19870[664:18]", + "!doc": "Sets a cookie for use with all connections made by this client. Any\ncookie with the same name will be replaced. If the cookie's value\nis undefined, null, or the blank string, the cookie will be removed.\n\nIf the cookie's domain doesn't match this client's url host or the\ncookie's secure flag doesn't match this client's url scheme, then\nsetting the cookie will fail with an exception.\n\n@param cookie the cookie with parameters:\n name: the name of the cookie.\n value: the value of the cookie.\n comment: an optional comment string.\n maxAge: the age of the cookie in seconds relative to created time.\n secure: true if the cookie must be sent over a secure protocol.\n httpOnly: true to restrict access to the cookie from javascript\n (inaffective since the cookies are stored in javascript).\n path: the path for the cookie.\n domain: optional domain the cookie belongs to (must start with dot).\n version: optional version of the cookie.\n created: creation time, in UTC seconds, of the cookie." + }, + "getCookie": { + "!type": "fn(name: ?, path: ?) -> _getStorageId.!0.getCookie.!ret", + "!span": "21837[724:9]-21846[724:18]", + "!doc": "Gets a cookie by its name.\n\n@param name the name of the cookie to retrieve.\n@param path an optional path for the cookie (if there are multiple\n cookies with the same name but different paths).\n\n@return the cookie or null if not found." + }, + "removeCookie": { + "!type": "fn(name: ?, path: string) -> bool", + "!span": "22547[754:9]-22559[754:21]", + "!doc": "Removes a cookie.\n\n@param name the name of the cookie to remove.\n@param path an optional path for the cookie (if there are multiple\n cookies with the same name but different paths).\n\n@return true if a cookie was removed, false if not." + }, + "clearCookies": { + "!type": "fn()", + "!span": "23383[789:9]-23395[789:21]", + "!doc": "Clears all cookies stored in this client." + }, + "!span": "13107[461:15]-13823[484:3]", + "url": "http.parseUrl.!ret", + "socketPool": "net.socketPools." + }, + "_getStorageId.!0.send.!0": { + "headerReady": { + "!type": "fn(e: net.socketPools..sockets..options.headerReady.!0)", + "!span": "17078[553:12]-17089[553:23]" + }, + "!span": "17024[551:18]-17026[551:20]", + "!doc": "create send options", + "request": "net.socketPools..sockets..options.request", + "bodyReady": "net.socketPools..sockets..options.bodyReady", + "error": "net.socketPools..sockets..options.error" + }, + "_getStorageId.!0.getCookie.!ret": { + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]" + }, + "maxAge": { + "!type": "number", + "!span": "20252[674:15]-20258[674:21]" + }, + "secure": { + "!type": "bool", + "!span": "20296[675:15]-20302[675:21]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[677:15]-20402[677:23]" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "_initSocket.!2": { + "caStore": { + "certs": { + "!span": "83747[2749:4]-83752[2749:9]", + "!doc": "stored certificates" + }, + "getIssuer": { + "!type": "fn(cert: +ByteBuffer|pki.certificateFromPem.!ret) -> [?|pki.certificateFromPem.!ret]|pki.certificateFromPem.!ret", + "!span": "83997[2760:10]-84006[2760:19]", + "!doc": "Gets the certificate that issued the passed certificate or its\n'parent'.\n\n@param cert the certificate to get the parent for.\n\n@return the parent certificate or null if none was found." + }, + "addCertificate": { + "!type": "fn(cert: pki.certificateFromPem.!ret)", + "!span": "84709[2781:10]-84723[2781:24]", + "!doc": "Adds a trusted certificate to the store.\n\n@param cert the certificate to add as a trusted certificate (either a\n pki.certificate object or a PEM-formatted certificate)." + }, + "hasCertificate": { + "!type": "fn(cert: pki.certificateFromPem.!ret|+ByteBuffer) -> bool", + "!span": "85652[2812:10]-85666[2812:24]", + "!doc": "Checks to see if the given certificate is in the store.\n\n@param cert the certificate to check (either a pki.certificate or a\n PEM-formatted certificate).\n\n@return true if the certificate is in the store, false if not." + }, + "listAllCertificates": { + "!type": "fn() -> [[?|pki.certificateFromPem.!ret]|pki.certificateFromPem.!ret]", + "!span": "86435[2841:10]-86454[2841:29]", + "!doc": "Lists all of the certificates kept in the store.\n\n@return an array of all of the pki.certificate objects in the store." + }, + "removeCertificate": { + "!type": "fn(cert: pki.certificateFromPem.!ret) -> [?|pki.certificateFromPem.!ret]|pki.certificateFromPem.!ret", + "!span": "87156[2869:10]-87173[2869:27]", + "!doc": "Removes a certificate from the store.\n\n@param cert the certificate to remove (either a pki.certificate or a\n PEM-formatted certificate).\n\n@return the certificate that was removed or null if the certificate\n wasn't in store." + }, + "!span": "14916[523:6]-14923[523:13]", + "!doc": "create CA store" + }, + "virtualHost": { + "!type": "string", + "!span": "14990[525:6]-15001[525:17]" + }, + "prime": { + "!type": "bool", + "!span": "15257[530:6]-15262[530:11]" + }, + "!span": "14908[522:17]-15302[531:5]", + "!doc": "determine if TLS is used", + "verify": "initConnectionState.!1.verify", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate" + }, + "_initSocket.!2.caStore.listAllCertificates.!ret": "[[?|pki.certificateFromPem.!ret]|pki.certificateFromPem.!ret]", + "_hasCookieExpired.!0": { + "maxAge": { + "!type": "number", + "!span": "6000[192:9]-6006[192:15]", + "!doc": "default cookie expiration to never" + }, + "comment": { + "!type": "string", + "!span": "20205[658:0]-20212[659:6]" + }, + "secure": { + "!type": "bool", + "!span": "20296[663:3]-20302[663:9]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[666:0]-20402[666:8]" + }, + "path": { + "!type": "string", + "!span": "20445[668:25]-20449[669:0]" + }, + "created": { + "!type": "number", + "!span": "20583[673:4]-20590[673:11]" + } + }, + "bnpExp.!1": "+NullExp", + "bnToByteArray.!ret": "[number]", + "bnpBitwiseTo.!1": { + "!type": "fn(x: number, y: number) -> number", + "!span": "20730[689:14]-20760[689:44]" + }, + "bnDivideAndRemainder.!ret": "[+BigInteger]", + "bnGetPrng.!ret": { + "nextBytes": { + "!type": "fn(x: [number])", + "!span": "32791[1198:4]-32800[1198:13]", + "!doc": "x is an array to fill with bytes" + }, + "!span": "32745[1196:9]-32926[1203:3]" + }, + "bnGetPrng.!ret.nextBytes.!0": { + "!type": "[number]", + "!doc": "new BigInteger(int,RNG)" + }, + "_createKDF.!1": { + "algorithm": { + "!type": "string", + "!span": "2315[98:4]-2324[98:13]", + "!doc": "SHA-512 => sha512" + }, + "blockLength": { + "!type": "number", + "!span": "2372[99:4]-2383[99:15]" + }, + "digestLength": { + "!type": "number", + "!span": "2394[100:4]-2406[100:16]" + }, + "fullMessageLength": { + "!type": "[number]", + "!span": "2543[104:4]-2560[104:21]", + "!doc": "full message length (set md.messageLength128 for backwards-compatibility)" + }, + "messageLengthSize": { + "!type": "number", + "!span": "2611[106:4]-2628[106:21]", + "!doc": "size of message length in bytes" + }, + "start": { + "!type": "fn() -> _createKDF.!1", + "!span": "2718[114:5]-2723[114:10]", + "!doc": "Starts the digest.\n\n@return this digest object." + }, + "update": { + "!type": "fn(msg: ?, encoding: string) -> _createKDF.!1", + "!span": "3705[144:5]-3711[144:11]", + "!doc": "Updates the digest with the given message input. The given input can\ntreated as raw input (no encoding will be applied) or an encoding of\n'utf8' maybe given to encode the input using UTF-8.\n\n@param msg the message input to update with.\n@param encoding the encoding to use (default: 'raw', other: 'utf8').\n\n@return this digest object." + }, + "digest": { + "!type": "fn() -> +ByteBuffer", + "!span": "4616[179:5]-4622[179:11]", + "!doc": "Produces the digest.\n\n@return a byte buffer containing the digest value." + }, + "!span": "2284[96:11]-2636[107:3]", + "!doc": "message digest object", + "messageLength128": "_createKDF.!1.fullMessageLength" + }, + "sConsoleLogger.f.!1": { + "level": { + "!type": "string", + "!span": "4854[155:10]-4859[155:15]" + }, + "standard": { + "!type": "string", + "!span": "3143[102:12]-3151[102:20]" + }, + "standardFull": { + "!type": "string", + "!span": "4125[136:12]-4137[136:24]" + }, + "timestamp": "+Date", + "arguments": "f.!1.arguments" + }, + "f.!1": { + "level": { + "!type": "string", + "!span": "4854[155:10]-4859[155:15]" + }, + "arguments": { + "!type": "[?]", + "!span": "4936[158:10]-4947[158:21]", + "!doc": "convert arguments to real array, remove category and message" + }, + "standard": { + "!type": "string", + "!span": "3143[102:12]-3151[102:20]" + }, + "standardFull": { + "!type": "string", + "!span": "4125[136:12]-4137[136:24]" + }, + "!span": "4809[153:18]-5031[162:9]", + "!doc": "create message object\nNote: interpolation and standard formatting is done lazily", + "timestamp": "+Date" + }, + "md5.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "746[36:4]-755[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "768[37:4]-779[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "789[38:4]-801[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "996[44:4]-1013[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "hash.!0.fullMessageLength", + "fullMessageLength": "hash.!0.fullMessageLength", + "start": "hash.!0.start", + "update": "hash.!0.update", + "digest": "hash.!0.digest" + }, + "_update.!1": { + "!type": "[[number]|number]", + "!doc": "used for 64-bit word storage" + }, + "mgf1.create.!ret": { + "generate": { + "!type": "fn(seed: string, maskLen: ?) -> string", + "!span": "833[31:4]-841[31:12]", + "!doc": "Generate mask of specified length.\n\n@param {String} seed The seed for mask generation.\n@param maskLen Number of bytes to generate.\n@return {String} The generated mask." + }, + "!span": "609[23:12]-1625[53:3]" + }, + "pki.encryptPrivateKeyInfo.!2": { + "legacy": { + "!type": "bool", + "!span": "4915[152:5]-4921[152:11]" + }, + "algorithm": { + "!type": "string", + "!span": "4929[152:19]-4938[152:28]" + }, + "saltSize": { + "!type": "number", + "!span": "6295[196:28]-6303[196:36]" + }, + "count": { + "!type": "number", + "!span": "6339[198:30]-6344[198:35]" + }, + "prfAlgorithm": { + "!type": "string", + "!span": "6433[202:5]-6445[202:17]" + }, + "!span": "4914[152:4]-4949[152:39]" + }, + "pki.privateKeyFromPem.!0": { + "read": { + "!type": "number", + "!span": "19652[656:10]-19656[656:14]" + }, + "n": "+BigInteger", + "e": "+BigInteger", + "d": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger", + "decrypt": "_modPow.!1.decrypt", + "sign": "_modPow.!1.sign" + }, + "pki.RDNAttributesAsArray.!1": { + "algorithm": { + "!type": "string", + "!span": "753[36:4]-762[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "776[37:4]-787[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "797[38:4]-809[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1004[44:4]-1021[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "rsa_mgf1.!2.fullMessageLength", + "fullMessageLength": "rsa_mgf1.!2.fullMessageLength", + "start": "rsa_mgf1.!2.start", + "update": "rsa_mgf1.!2.update", + "digest": "rsa_mgf1.!2.digest" + }, + "pki.RDNAttributesAsArray.!ret": "[pki.RDNAttributesAsArray.!ret.]", + "pki.RDNAttributesAsArray.!ret.": { + "type": { + "!type": "string", + "!span": "15894[517:10]-15898[517:14]" + }, + "name": { + "!type": "string", + "!span": "16121[522:12]-16125[522:16]" + }, + "!span": "15853[515:12]-15855[515:14]", + "!doc": "iterate over attributes" + }, + "pki.CRIAttributesAsArray.!0": "[?]", + "pki.CRIAttributesAsArray.!ret": { + "": { + "type": { + "!type": "string", + "!span": "17085[558:10]-17089[558:14]" + }, + "name": { + "!type": "string", + "!span": "17276[563:12]-17280[563:16]" + }, + "extensions": { + "": "pki.certificateExtensionFromAsn1.!ret" + } + }, + "!type": "[_getAttribute.!ret]", + "!doc": "each attribute has a sequence with a type and a set of values" + }, + "pki.certificateFromPem.!ret": { + "version": { + "!type": "number", + "!span": "27761[914:7]-27768[914:14]" + }, + "serialNumber": { + "!type": "string", + "!span": "27784[915:7]-27796[915:19]" + }, + "signatureOid": { + "!type": "string", + "!span": "27812[916:7]-27824[916:19]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "27894[919:15]-27906[919:27]" + }, + "!span": "27865[918:7]-27872[918:14]", + "parameters": "_readSignatureParameters.!ret" + }, + "validity": { + "!span": "27922[920:7]-27930[920:15]", + "notBefore": "+Date", + "notAfter": "+Date" + }, + "issuer": { + "getField": { + "!type": "fn(sn: ?) -> _getAttribute.!ret", + "!span": "28051[925:14]-28059[925:22]" + }, + "addField": { + "!type": "fn(attr: ?)", + "!span": "28139[928:14]-28147[928:22]" + }, + "hash": { + "!type": "string", + "!span": "28288[933:14]-28292[933:18]" + }, + "!span": "28024[924:7]-28030[924:13]", + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "subject": { + "getField": { + "!type": "fn(sn: string) -> _getAttribute.!ret", + "!span": "28338[936:15]-28346[936:23]" + }, + "addField": { + "!type": "fn(attr: ?)", + "!span": "28428[939:15]-28436[939:23]" + }, + "hash": { + "!type": "string", + "!span": "28580[944:15]-28584[944:19]" + }, + "!span": "28309[935:7]-28316[935:14]", + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "setSubject": { + "!type": "fn(attrs: ?, uniqueId: ?)", + "!span": "28840[956:7]-28850[956:17]", + "!doc": "Sets the subject of this certificate.\n\n@param attrs the array of subject attributes to use.\n@param uniqueId an optional a unique ID to use." + }, + "setIssuer": { + "!type": "fn(attrs: ?, uniqueId: ?)", + "!span": "29346[974:7]-29355[974:16]", + "!doc": "Sets the issuer of this certificate.\n\n@param attrs the array of issuer attributes to use.\n@param uniqueId an optional a unique ID to use." + }, + "setExtensions": { + "!type": "fn(exts: ?)", + "!span": "29790[991:7]-29803[991:20]", + "!doc": "Sets the extensions of this certificate.\n\n@param exts the array of extensions to use." + }, + "getExtension": { + "!type": "fn(options: ?|string) -> pki.certificateExtensionFromAsn1.!ret", + "!span": "30233[1008:7]-30245[1008:19]", + "!doc": "Gets an extension by its name or id.\n\n@param options the name to use or an object with:\n name the name to use.\n id the id to use.\n\n@return the extension or null if not found." + }, + "sign": { + "!type": "fn(key: ?, md: ?)", + "!span": "30873[1032:7]-30877[1032:11]", + "!doc": "Signs this certificate using the given private key.\n\n@param key the private key to sign with.\n@param md the message digest object to use (defaults to forge.md.sha1)." + }, + "verify": { + "!type": "fn(child: +ByteBuffer|pki.certificateFromPem.!ret) -> bool", + "!span": "31818[1061:7]-31824[1061:13]", + "!doc": "Attempts verify the signature on the passed certificate using this\ncertificate's public key.\n\n@param child the certificate to verify.\n\n@return true if verified, false if not." + }, + "isIssuer": { + "!type": "fn(parent: ?) -> bool", + "!span": "35605[1176:7]-35613[1176:15]", + "!doc": "Returns true if this certificate's issuer matches the passed\ncertificate's subject. Note that no signature check is performed.\n\n@param parent the certificate to check.\n\n@return true if this certificate's issuer matches the passed certificate's\n subject." + }, + "issued": { + "!type": "fn(child: +ByteBuffer|pki.certificateFromPem.!ret) -> bool", + "!span": "36593[1211:7]-36599[1211:13]", + "!doc": "Returns true if this certificate's subject matches the issuer of the\ngiven certificate). Note that not signature check is performed.\n\n@param child the certificate to check.\n\n@return true if this certificate's subject matches the passed\n certificate's issuer." + }, + "generateSubjectKeyIdentifier": { + "!type": "fn() -> ?", + "!span": "36835[1220:7]-36863[1220:35]", + "!doc": "Generates the subjectKeyIdentifier for this certificate as byte buffer.\n\n@return the subjectKeyIdentifier for this certificate as byte buffer." + }, + "verifySubjectKeyIdentifier": { + "!type": "fn() -> bool", + "!span": "37913[1246:7]-37939[1246:33]", + "!doc": "Verifies the subjectKeyIdentifier extension value for this certificate\nagainst its public key. If no extension is found, false will be\nreturned.\n\n@return true if verified, false if not." + }, + "signatureParameters": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + } + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + } + } + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + } + }, + "read": { + "!type": "number", + "!span": "19652[645:18]-19656[645:22]" + }, + "!span": "27750[913:13]-27752[913:15]", + "!doc": "create certificate", + "extensions": "pki.certificateExtensionsFromAsn1.!ret", + "publicKey": "_publicKeyFromJwk.!ret", + "md": "_createKDF.!1", + "tbsCertificate": "_fromDer.!ret" + }, + "pki.getPublicKeyFingerprint.!1": { + "type": { + "!type": "string", + "!span": "37654[1236:56]-37658[1236:60]" + }, + "!span": "37653[1236:55]-37675[1236:77]" + }, + "pki.certificationRequestFromPem.!ret": { + "version": { + "!type": "number", + "!span": "54558[1755:6]-54565[1755:13]" + }, + "signatureOid": { + "!type": "string", + "!span": "54580[1756:6]-54592[1756:18]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "54659[1759:14]-54671[1759:26]" + }, + "parameters": "_readSignatureParameters.!ret" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "_dnToAsn1.!0.getField", + "addField": "_dnToAsn1.!0.addField" + }, + "publicKey": "_publicKeyFromJwk.!ret", + "attributes": "pki.CRIAttributesAsArray.!ret", + "getAttribute": {}, + "md": "_createKDF.!1", + "certificationRequestInfo": "_fromDer.!ret", + "signatureParameters": "_readSignatureParameters.!ret", + "addAttribute": "_getAttribute.!0.addAttribute", + "setSubject": "_getAttribute.!0.setSubject", + "setAttributes": "_getAttribute.!0.setAttributes", + "sign": "_getAttribute.!0.sign", + "verify": "_getAttribute.!0.verify" + }, + "pki.certificateExtensionsFromAsn1.!0": { + "type": { + "!type": "number", + "!span": "49364[1597:10]-49368[1597:14]" + }, + "ip": { + "!type": "string", + "!span": "49804[1614:20]-49806[1614:22]", + "!doc": "convert to IPv4/IPv6 string representation" + }, + "oid": { + "!type": "string", + "!span": "49924[1618:20]-49927[1618:23]" + }, + "!span": "49352[1596:22]-49414[1599:9]" + }, + "pki.certificateExtensionsFromAsn1.!ret": { + "!type": "[pki.certificateExtensionFromAsn1.!ret]", + "!span": "28601[946:7]-28611[946:17]", + "!doc": "set new extensions" + }, + "pki.certificateExtensionFromAsn1.!ret": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "altNames": { + "!type": "[pki.certificateExtensionsFromAsn1.!0]", + "!span": "49126[1587:8]-49134[1587:16]", + "!doc": "handle subjectAltName/issuerAltName" + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + }, + "!span": "45965[1495:10]-45967[1495:12]", + "!doc": "an extension has:\n[0] extnID OBJECT IDENTIFIER\n[1] critical BOOLEAN DEFAULT FALSE\n[2] extnValue OCTET STRING" + }, + "pki.distinguishedNameToAsn1.!0": { + "!span": "30074[961:40]-30098[961:64]", + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "pki.verifyCertificateChain.!2": { + "verify": { + "!type": "fn(vfd: bool|string, depth: number, chain: [+ByteBuffer|pki.certificateFromPem.!ret]) -> bool|string", + "!span": "108939[3537:12]-108945[3537:18]" + }, + "!span": "108834[3532:18]-108836[3532:20]", + "!doc": "Make a copy of c.verifyOptions so that we can modify options.verify\nwithout modifying c.verifyOptions." + }, + "encryptedPrivateKeyValidator.value.0": { + "name": { + "!type": "string", + "!span": "1319[52:4]-1323[52:8]" + }, + "tagClass": { + "!type": "number", + "!span": "1376[53:4]-1384[53:12]" + }, + "type": { + "!type": "number", + "!span": "1412[54:4]-1416[54:8]" + }, + "constructed": { + "!type": "bool", + "!span": "1442[55:4]-1453[55:15]" + }, + "value": { + "!type": "[encryptedPrivateKeyValidator.value.0.value.0, encryptedPrivateKeyValidator.value.0.value.1]", + "!span": "1465[56:4]-1470[56:9]" + }, + "!span": "1313[51:10]-1840[69:3]" + }, + "encryptedPrivateKeyValidator.value.0.value.0": { + "name": { + "!type": "string", + "!span": "1481[57:6]-1485[57:10]" + }, + "tagClass": { + "!type": "number", + "!span": "1526[58:6]-1534[58:14]" + }, + "type": { + "!type": "number", + "!span": "1564[59:6]-1568[59:10]" + }, + "constructed": { + "!type": "bool", + "!span": "1591[60:6]-1602[60:17]" + }, + "capture": { + "!type": "string", + "!span": "1617[61:6]-1624[61:13]" + }, + "!span": "1473[56:12]-1647[62:5]" + }, + "encryptedPrivateKeyValidator.value.0.value.1": { + "name": { + "!type": "string", + "!span": "1657[63:6]-1661[63:10]" + }, + "tagClass": { + "!type": "number", + "!span": "1703[64:6]-1711[64:14]" + }, + "type": { + "!type": "number", + "!span": "1741[65:6]-1745[65:10]" + }, + "constructed": { + "!type": "bool", + "!span": "1773[66:6]-1784[66:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "1798[67:6]-1809[67:17]" + }, + "!span": "1649[62:7]-1835[68:5]" + }, + "encryptedPrivateKeyValidator.value.1": { + "name": { + "!type": "string", + "!span": "1869[71:4]-1873[71:8]", + "!doc": "encryptedData" + }, + "tagClass": { + "!type": "number", + "!span": "1920[72:4]-1928[72:12]" + }, + "type": { + "!type": "number", + "!span": "1956[73:4]-1960[73:8]" + }, + "constructed": { + "!type": "bool", + "!span": "1989[74:4]-2000[74:15]" + }, + "capture": { + "!type": "string", + "!span": "2013[75:4]-2020[75:11]" + }, + "!span": "1842[69:5]-2041[76:3]" + }, + "PBES2AlgorithmsValidator.value.0": { + "name": { + "!type": "string", + "!span": "2315[87:4]-2319[87:8]" + }, + "tagClass": { + "!type": "number", + "!span": "2362[88:4]-2370[88:12]" + }, + "type": { + "!type": "number", + "!span": "2398[89:4]-2402[89:8]" + }, + "constructed": { + "!type": "bool", + "!span": "2428[90:4]-2439[90:15]" + }, + "value": { + "!type": "[PBES2AlgorithmsValidator.value.0.value.0, PBES2AlgorithmsValidator.value.0.value.1]", + "!span": "2451[91:4]-2456[91:9]" + }, + "!span": "2309[86:10]-3813[137:3]" + }, + "PBES2AlgorithmsValidator.value.0.value.0": { + "name": { + "!type": "string", + "!span": "2467[92:6]-2471[92:10]" + }, + "tagClass": { + "!type": "number", + "!span": "2520[93:6]-2528[93:14]" + }, + "type": { + "!type": "number", + "!span": "2558[94:6]-2562[94:10]" + }, + "constructed": { + "!type": "bool", + "!span": "2585[95:6]-2596[95:17]" + }, + "capture": { + "!type": "string", + "!span": "2611[96:6]-2618[96:13]" + }, + "!span": "2459[91:12]-2634[97:5]" + }, + "PBES2AlgorithmsValidator.value.0.value.1": { + "name": { + "!type": "string", + "!span": "2644[98:6]-2648[98:10]" + }, + "tagClass": { + "!type": "number", + "!span": "2682[99:6]-2690[99:14]" + }, + "type": { + "!type": "number", + "!span": "2720[100:6]-2724[100:10]" + }, + "constructed": { + "!type": "bool", + "!span": "2752[101:6]-2763[101:17]" + }, + "value": { + "!type": "[PBES2AlgorithmsValidator.value.0.value.1.value.0, PBES2AlgorithmsValidator.value.0.value.1.value.1, PBES2AlgorithmsValidator.value.0.value.1.value.2, PBES2AlgorithmsValidator.value.0.value.1.value.3]", + "!span": "2777[102:6]-2782[102:11]" + }, + "!span": "2636[97:7]-3808[136:5]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.0": { + "name": { + "!type": "string", + "!span": "2795[103:8]-2799[103:12]" + }, + "tagClass": { + "!type": "number", + "!span": "2840[104:8]-2848[104:16]" + }, + "type": { + "!type": "number", + "!span": "2880[105:8]-2884[105:12]" + }, + "constructed": { + "!type": "bool", + "!span": "2917[106:8]-2928[106:19]" + }, + "capture": { + "!type": "string", + "!span": "2945[107:8]-2952[107:15]" + }, + "!span": "2785[102:14]-2971[108:7]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.1": { + "name": { + "!type": "string", + "!span": "2983[109:8]-2987[109:12]" + }, + "tagClass": { + "!type": "number", + "!span": "3038[110:8]-3046[110:16]" + }, + "type": { + "!type": "number", + "!span": "3078[111:8]-3082[111:12]" + }, + "constructed": { + "!type": "bool", + "!span": "3111[112:8]-3122[112:19]" + }, + "capture": { + "!type": "string", + "!span": "3139[113:8]-3146[113:15]" + }, + "!span": "2973[108:9]-3175[114:7]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.2": { + "name": { + "!type": "string", + "!span": "3187[115:8]-3191[115:12]" + }, + "tagClass": { + "!type": "number", + "!span": "3237[116:8]-3245[116:16]" + }, + "type": { + "!type": "number", + "!span": "3277[117:8]-3281[117:12]" + }, + "constructed": { + "!type": "bool", + "!span": "3310[118:8]-3321[118:19]" + }, + "optional": { + "!type": "bool", + "!span": "3338[119:8]-3346[119:16]" + }, + "capture": { + "!type": "string", + "!span": "3362[120:8]-3369[120:15]" + }, + "!span": "3177[114:9]-3390[121:7]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.3": { + "name": { + "!type": "string", + "!span": "3417[123:8]-3421[123:12]", + "!doc": "prf" + }, + "tagClass": { + "!type": "number", + "!span": "3461[124:8]-3469[124:16]" + }, + "type": { + "!type": "number", + "!span": "3501[125:8]-3505[125:12]" + }, + "constructed": { + "!type": "bool", + "!span": "3535[126:8]-3546[126:19]" + }, + "optional": { + "!type": "bool", + "!span": "3562[127:8]-3570[127:16]" + }, + "value": { + "!type": "[PBES2AlgorithmsValidator.value.0.value.1.value.3.value.]", + "!span": "3586[128:8]-3591[128:13]" + }, + "!span": "3392[121:9]-3801[135:7]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.3.value.": { + "name": { + "!type": "string", + "!span": "3606[129:10]-3610[129:14]" + }, + "tagClass": { + "!type": "number", + "!span": "3662[130:10]-3670[130:18]" + }, + "type": { + "!type": "number", + "!span": "3704[131:10]-3708[131:14]" + }, + "constructed": { + "!type": "bool", + "!span": "3735[132:10]-3746[132:21]" + }, + "capture": { + "!type": "string", + "!span": "3765[133:10]-3772[133:17]" + }, + "!span": "3594[128:16]-3792[134:9]" + }, + "PBES2AlgorithmsValidator.value.1": { + "name": { + "!type": "string", + "!span": "3821[138:4]-3825[138:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3867[139:4]-3875[139:12]" + }, + "type": { + "!type": "number", + "!span": "3903[140:4]-3907[140:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3933[141:4]-3944[141:15]" + }, + "value": { + "!type": "[PBES2AlgorithmsValidator.value.1.value.0, PBES2AlgorithmsValidator.value.1.value.1]", + "!span": "3956[142:4]-3961[142:9]" + }, + "!span": "3815[137:5]-4325[155:3]" + }, + "PBES2AlgorithmsValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "3972[143:6]-3976[143:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4024[144:6]-4032[144:14]" + }, + "type": { + "!type": "number", + "!span": "4062[145:6]-4066[145:10]" + }, + "constructed": { + "!type": "bool", + "!span": "4089[146:6]-4100[146:17]" + }, + "capture": { + "!type": "string", + "!span": "4115[147:6]-4122[147:13]" + }, + "!span": "3964[142:12]-4138[148:5]" + }, + "PBES2AlgorithmsValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "4148[149:6]-4152[149:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4199[150:6]-4207[150:14]" + }, + "type": { + "!type": "number", + "!span": "4237[151:6]-4241[151:10]" + }, + "constructed": { + "!type": "bool", + "!span": "4272[152:6]-4283[152:17]" + }, + "capture": { + "!type": "string", + "!span": "4298[153:6]-4305[153:13]" + }, + "!span": "4140[148:7]-4320[154:5]" + }, + "pkcs12PbeParamsValidator.value.0": { + "name": { + "!type": "string", + "!span": "4491[164:4]-4495[164:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4526[165:4]-4534[165:12]" + }, + "type": { + "!type": "number", + "!span": "4562[166:4]-4566[166:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4595[167:4]-4606[167:15]" + }, + "capture": { + "!type": "string", + "!span": "4619[168:4]-4626[168:11]" + }, + "!span": "4485[163:10]-4638[169:3]" + }, + "pkcs12PbeParamsValidator.value.1": { + "name": { + "!type": "string", + "!span": "4646[170:4]-4650[170:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4687[171:4]-4695[171:12]" + }, + "type": { + "!type": "number", + "!span": "4723[172:4]-4727[172:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4752[173:4]-4763[173:15]" + }, + "capture": { + "!type": "string", + "!span": "4776[174:4]-4783[174:11]" + }, + "!span": "4640[169:5]-4801[175:3]" + }, + "hash.!0": { + "algorithm": { + "!type": "string", + "!span": "746[36:4]-755[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "768[37:4]-779[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "789[38:4]-801[38:16]" + }, + "fullMessageLength": { + "!type": "[number]", + "!span": "928[42:4]-945[42:21]", + "!doc": "full message length (set md.messageLength64 for backwards-compatibility)" + }, + "messageLengthSize": { + "!type": "number", + "!span": "996[44:4]-1013[44:21]", + "!doc": "size of message length in bytes" + }, + "start": { + "!type": "fn() -> hash.!0", + "!span": "1102[52:5]-1107[52:10]", + "!doc": "Starts the digest.\n\n@return this digest object." + }, + "update": { + "!type": "fn(msg: ?, encoding: ?) -> hash.!0", + "!span": "2076[84:5]-2082[84:11]", + "!doc": "Updates the digest with the given message input. The given input can\ntreated as raw input (no encoding will be applied) or an encoding of\n'utf8' maybe given to encode the input using UTF-8.\n\n@param msg the message input to update with.\n@param encoding the encoding to use (default: 'raw', other: 'utf8').\n\n@return this digest object." + }, + "digest": { + "!type": "fn() -> +ByteBuffer", + "!span": "2989[119:5]-2995[119:11]", + "!doc": "Produces the digest.\n\n@return a byte buffer containing the digest value." + }, + "!span": "740[35:11]-1020[45:3]", + "!doc": "message digest object", + "messageLength64": "hash.!0.fullMessageLength" + }, + "pem.encode.!0": { + "type": { + "!type": "string", + "!span": "27457[901:4]-27461[901:8]" + }, + "!span": "27451[900:12]-27558[903:3]", + "!doc": "convert to ASN.1, then DER, then PEM-encode" + }, + "pem.encode.!1": { + "!span": "27591[904:31]-27609[904:49]" + }, + "pem.decode.!ret": "[pem.decode.!ret.]", + "pem.decode.!ret.": { + "type": { + "!type": "string", + "!span": "3012[109:6]-3016[109:10]" + }, + "procType": { + "version": { + "!type": "string", + "!span": "4449[158:26]-4456[158:33]" + }, + "type": { + "!type": "string", + "!span": "4469[158:46]-4473[158:50]" + }, + "!span": "3034[110:6]-3042[110:14]" + }, + "contentDomain": { + "!type": "string", + "!span": "3056[111:6]-3069[111:19]", + "!doc": "special-case Content-Domain" + }, + "dekInfo": { + "algorithm": { + "!type": "string", + "!span": "4967[168:25]-4976[168:34]" + }, + "parameters": { + "!type": "string", + "!span": "4989[168:47]-4999[168:57]" + }, + "!span": "3083[112:6]-3090[112:13]" + }, + "headers": { + "!type": "[pem.decode.!ret..headers.]", + "!span": "3104[113:6]-3111[113:13]" + }, + "body": { + "!type": "string", + "!span": "3123[114:6]-3127[114:10]" + }, + "!span": "3004[108:14]-3164[115:5]" + }, + "pem.decode.!ret..headers.": { + "name": { + "!type": "string", + "!span": "3797[143:22]-3801[143:26]" + }, + "values": { + "!type": "[string]", + "!span": "3813[143:38]-3819[143:44]" + }, + "!span": "3796[143:21]-3824[143:49]" + }, + "foldHeader.!0": { + "name": { + "!type": "string", + "!span": "1829[61:14]-1833[61:18]" + }, + "values": { + "!type": "[string]", + "!span": "1847[61:32]-1853[61:38]" + }, + "!span": "1828[61:13]-1879[61:64]", + "!doc": "encode special headers" + }, + "rsa_mgf1.!2": { + "algorithm": { + "!type": "string", + "!span": "753[36:4]-762[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "776[37:4]-787[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "797[38:4]-809[38:16]" + }, + "fullMessageLength": { + "!type": "[number]", + "!span": "936[42:4]-953[42:21]", + "!doc": "full message length (set md.messageLength64 for backwards-compatibility)" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1004[44:4]-1021[44:21]", + "!doc": "size of message length in bytes" + }, + "start": { + "!type": "fn() -> rsa_mgf1.!2", + "!span": "1110[52:5]-1115[52:10]", + "!doc": "Starts the digest.\n\n@return this digest object." + }, + "update": { + "!type": "fn(msg: ?, encoding: string) -> rsa_mgf1.!2", + "!span": "2106[85:5]-2112[85:11]", + "!doc": "Updates the digest with the given message input. The given input can\ntreated as raw input (no encoding will be applied) or an encoding of\n'utf8' maybe given to encode the input using UTF-8.\n\n@param msg the message input to update with.\n@param encoding the encoding to use (default: 'raw', other: 'utf8').\n\n@return this digest object." + }, + "digest": { + "!type": "fn() -> +ByteBuffer", + "!span": "3021[120:5]-3027[120:11]", + "!doc": "Produces the digest.\n\n@return a byte buffer containing the digest value." + }, + "!span": "747[35:11]-1028[45:3]", + "!doc": "message digest object", + "messageLength64": "rsa_mgf1.!2.fullMessageLength" + }, + "p12.pkcs12FromAsn1.!ret": { + "safeContents": { + "": { + "encrypted": { + "!type": "bool", + "!span": "15681[541:6]-15690[541:15]" + }, + "safeBags": { + "": { + "type": { + "!type": "string", + "!span": "19026[652:6]-19030[652:10]" + }, + "key": "_modPow.!1", + "asn1": "_fromDer.!ret", + "cert": "pki.certificateFromPem.!ret", + "attributes": { + "": "_decodeBagAttributes.!ret." + } + } + } + } + }, + "getBags": {}, + "getBagsByFriendlyName": {}, + "getBagsByLocalKeyId": "_decodeAuthenticatedSafe.!0.getBagsByLocalKeyId" + }, + "p12.toPkcs12Asn1.!3": { + "saltSize": { + "!type": "number", + "!span": "24053[798:10]-24061[798:18]" + }, + "count": { + "!type": "number", + "!span": "24097[799:10]-24102[799:15]" + }, + "algorithm": { + "!type": "string", + "!span": "24138[800:10]-24147[800:19]" + }, + "useMac": { + "!type": "bool", + "!span": "24248[802:12]-24254[802:18]" + }, + "generateLocalKeyId": { + "!type": "bool", + "!span": "24392[808:12]-24410[808:30]" + }, + "prfAlgorithm": { + "!type": "string", + "!span": "6433[245:5]-6445[245:17]" + }, + "!span": "24039[797:23]-24041[797:25]", + "!doc": "set default options" + }, + "contentInfoValidator.value.0": { + "name": { + "!type": "string", + "!span": "3818[127:4]-3822[127:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3855[128:4]-3863[128:12]" + }, + "type": { + "!type": "number", + "!span": "3891[129:4]-3895[129:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3916[130:4]-3927[130:15]" + }, + "capture": { + "!type": "string", + "!span": "3940[131:4]-3947[131:11]" + }, + "!span": "3812[126:10]-3966[132:3]" + }, + "contentInfoValidator.value.1": { + "name": { + "!type": "string", + "!span": "3974[133:4]-3978[133:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4007[134:4]-4015[134:12]" + }, + "type": { + "!type": "number", + "!span": "4050[135:4]-4054[135:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4063[136:4]-4074[136:15]" + }, + "optional": { + "!type": "bool", + "!span": "4086[137:4]-4094[137:12]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4106[138:4]-4117[138:15]" + }, + "!span": "3968[132:5]-4132[139:3]" + }, + "pfxValidator.value.0": { + "name": { + "!type": "string", + "!span": "3726[139:4]-3730[139:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3751[140:4]-3759[140:12]" + }, + "type": { + "!type": "number", + "!span": "3787[141:4]-3791[141:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3816[142:4]-3827[142:15]" + }, + "capture": { + "!type": "string", + "!span": "3840[143:4]-3847[143:11]" + }, + "!span": "3720[138:10]-3862[144:3]" + }, + "pfxValidator.value.2": { + "name": { + "!type": "string", + "!span": "3894[146:4]-3898[146:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3919[147:4]-3927[147:12]" + }, + "type": { + "!type": "number", + "!span": "3955[148:4]-3959[148:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3985[149:4]-3996[149:15]" + }, + "optional": { + "!type": "bool", + "!span": "4008[150:4]-4016[150:12]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4028[151:4]-4039[151:15]" + }, + "value": { + "!type": "[pfxValidator.value.2.value.0, pfxValidator.value.2.value.1, pfxValidator.value.2.value.2]", + "!span": "4052[152:4]-4057[152:9]" + }, + "!span": "3888[145:24]-5358[194:3]" + }, + "pfxValidator.value.2.value.0": { + "name": { + "!type": "string", + "!span": "4068[153:6]-4072[153:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4099[154:6]-4107[154:14]" + }, + "type": { + "!type": "number", + "!span": "4137[155:6]-4141[155:10]" + }, + "constructed": { + "!type": "bool", + "!span": "4184[156:6]-4195[156:17]" + }, + "value": { + "!type": "[pfxValidator.value.2.value.0.value.0, pfxValidator.value.2.value.0.value.1]", + "!span": "4209[157:6]-4214[157:11]" + }, + "!span": "4060[152:12]-4990[180:5]" + }, + "pfxValidator.value.2.value.0.value.0": { + "name": { + "!type": "string", + "!span": "4227[158:8]-4231[158:12]" + }, + "tagClass": { + "!type": "number", + "!span": "4276[159:8]-4284[159:16]" + }, + "type": { + "!type": "number", + "!span": "4316[160:8]-4320[160:12]" + }, + "constructed": { + "!type": "bool", + "!span": "4380[161:8]-4391[161:19]" + }, + "value": { + "!type": "[pfxValidator.value.2.value.0.value.0.value.0, pfxValidator.value.2.value.0.value.0.value.1]", + "!span": "4407[162:8]-4412[162:13]" + }, + "!span": "4217[157:14]-4798[173:7]" + }, + "pfxValidator.value.2.value.0.value.0.value.0": { + "name": { + "!type": "string", + "!span": "4427[163:10]-4431[163:14]" + }, + "tagClass": { + "!type": "number", + "!span": "4488[164:10]-4496[164:18]" + }, + "type": { + "!type": "number", + "!span": "4530[165:10]-4534[165:14]" + }, + "constructed": { + "!type": "bool", + "!span": "4561[166:10]-4572[166:21]" + }, + "capture": { + "!type": "string", + "!span": "4591[167:10]-4598[167:17]" + }, + "!span": "4415[162:16]-4624[168:9]" + }, + "pfxValidator.value.2.value.0.value.0.value.1": { + "name": { + "!type": "string", + "!span": "4638[169:10]-4642[169:14]" + }, + "tagClass": { + "!type": "number", + "!span": "4700[170:10]-4708[170:18]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4742[171:10]-4753[171:21]" + }, + "!span": "4626[168:11]-4789[172:9]" + }, + "pfxValidator.value.2.value.0.value.1": { + "name": { + "!type": "string", + "!span": "4810[174:8]-4814[174:12]" + }, + "tagClass": { + "!type": "number", + "!span": "4850[175:8]-4858[175:16]" + }, + "type": { + "!type": "number", + "!span": "4890[176:8]-4894[176:12]" + }, + "constructed": { + "!type": "bool", + "!span": "4927[177:8]-4938[177:19]" + }, + "capture": { + "!type": "string", + "!span": "4955[178:8]-4962[178:15]" + }, + "!span": "4800[173:9]-4983[179:7]" + }, + "pfxValidator.value.2.value.1": { + "name": { + "!type": "string", + "!span": "5000[181:6]-5004[181:10]" + }, + "tagClass": { + "!type": "number", + "!span": "5035[182:6]-5043[182:14]" + }, + "type": { + "!type": "number", + "!span": "5073[183:6]-5077[183:10]" + }, + "constructed": { + "!type": "bool", + "!span": "5108[184:6]-5119[184:17]" + }, + "capture": { + "!type": "string", + "!span": "5134[185:6]-5141[185:13]" + }, + "!span": "4992[180:7]-5158[186:5]" + }, + "pfxValidator.value.2.value.2": { + "name": { + "!type": "string", + "!span": "5168[187:6]-5172[187:10]" + }, + "tagClass": { + "!type": "number", + "!span": "5206[188:6]-5214[188:14]" + }, + "type": { + "!type": "number", + "!span": "5244[189:6]-5248[189:10]" + }, + "constructed": { + "!type": "bool", + "!span": "5275[190:6]-5286[190:17]" + }, + "optional": { + "!type": "bool", + "!span": "5301[191:6]-5309[191:14]" + }, + "capture": { + "!type": "string", + "!span": "5323[192:6]-5330[192:13]" + }, + "!span": "5160[186:7]-5353[193:5]" + }, + "safeBagValidator.value.0": { + "name": { + "!type": "string", + "!span": "5507[203:4]-5511[203:8]" + }, + "tagClass": { + "!type": "number", + "!span": "5534[204:4]-5542[204:12]" + }, + "type": { + "!type": "number", + "!span": "5570[205:4]-5574[205:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5595[206:4]-5606[206:15]" + }, + "capture": { + "!type": "string", + "!span": "5619[207:4]-5626[207:11]" + }, + "!span": "5501[202:10]-5639[208:3]" + }, + "safeBagValidator.value.1": { + "name": { + "!type": "string", + "!span": "5647[209:4]-5651[209:8]" + }, + "tagClass": { + "!type": "number", + "!span": "5677[210:4]-5685[210:12]" + }, + "constructed": { + "!type": "bool", + "!span": "5720[211:4]-5731[211:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "5743[212:4]-5754[212:15]" + }, + "!span": "5641[208:5]-5770[213:3]" + }, + "safeBagValidator.value.2": { + "name": { + "!type": "string", + "!span": "5778[214:4]-5782[214:8]" + }, + "tagClass": { + "!type": "number", + "!span": "5813[215:4]-5821[215:12]" + }, + "type": { + "!type": "number", + "!span": "5849[216:4]-5853[216:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5874[217:4]-5885[217:15]" + }, + "optional": { + "!type": "bool", + "!span": "5897[218:4]-5905[218:12]" + }, + "capture": { + "!type": "string", + "!span": "5917[219:4]-5924[219:11]" + }, + "!span": "5772[213:5]-5945[220:3]" + }, + "attributeValidator.value.0": { + "name": { + "!type": "string", + "!span": "6098[229:4]-6102[229:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6128[230:4]-6136[230:12]" + }, + "type": { + "!type": "number", + "!span": "6164[231:4]-6168[231:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6189[232:4]-6200[232:15]" + }, + "capture": { + "!type": "string", + "!span": "6213[233:4]-6220[233:11]" + }, + "!span": "6092[228:10]-6231[234:3]" + }, + "attributeValidator.value.1": { + "name": { + "!type": "string", + "!span": "6239[235:4]-6243[235:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6273[236:4]-6281[236:12]" + }, + "type": { + "!type": "number", + "!span": "6309[237:4]-6313[237:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6334[238:4]-6345[238:15]" + }, + "capture": { + "!type": "string", + "!span": "6357[239:4]-6364[239:11]" + }, + "!span": "6233[234:5]-6378[240:3]" + }, + "certBagValidator.value.0": { + "name": { + "!type": "string", + "!span": "6527[249:4]-6531[249:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6555[250:4]-6563[250:12]" + }, + "type": { + "!type": "number", + "!span": "6591[251:4]-6595[251:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6616[252:4]-6627[252:15]" + }, + "capture": { + "!type": "string", + "!span": "6640[253:4]-6647[253:11]" + }, + "!span": "6521[248:10]-6661[254:3]" + }, + "certBagValidator.value.1": { + "name": { + "!type": "string", + "!span": "6669[255:4]-6673[255:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6700[256:4]-6708[256:12]" + }, + "constructed": { + "!type": "bool", + "!span": "6743[257:4]-6754[257:15]" + }, + "value": { + "!type": "[certBagValidator.value.1.value.]", + "!span": "6892[260:4]-6897[260:9]", + "!doc": "So far we only support X.509 certificates (which are wrapped in\nan OCTET STRING, hence hard code that here)." + }, + "!span": "6663[254:5]-7070[267:3]" + }, + "certBagValidator.value.1.value.": { + "name": { + "!type": "string", + "!span": "6908[261:6]-6912[261:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6944[262:6]-6952[262:14]" + }, + "constructed": { + "!type": "bool", + "!span": "7018[264:6]-7029[264:17]" + }, + "capture": { + "!type": "string", + "!span": "7044[265:6]-7051[265:13]" + }, + "!span": "6900[260:12]-7065[266:5]" + }, + "_getBagsByAttribute.!0": { + "!type": "[_getBagsByAttribute.!0.]", + "!span": "9004[336:4]-9016[336:16]" + }, + "_getBagsByAttribute.!0.": { + "encrypted": { + "!type": "bool", + "!span": "15681[541:6]-15690[541:15]" + }, + "safeBags": { + "": { + "type": { + "!type": "string", + "!span": "19026[652:6]-19030[652:10]" + }, + "key": "_modPow.!1", + "asn1": "_fromDer.!ret", + "cert": "pki.certificateFromPem.!ret", + "attributes": { + "": "_decodeBagAttributes.!ret." + } + } + }, + "!span": "15673[540:14]-15703[542:5]" + }, + "_getBagsByAttribute.!ret": { + "!type": "[_getBagsByAttribute.!ret.]", + "!span": "10006[364:13]-10020[364:27]" + }, + "_getBagsByAttribute.!ret.": { + "type": { + "!type": "string", + "!span": "19026[652:6]-19030[652:10]" + }, + "!span": "19018[651:14]-19129[654:5]", + "!doc": "Create bag object and push to result array.", + "key": "_modPow.!1", + "asn1": "_fromDer.!ret", + "cert": "pki.certificateFromPem.!ret", + "attributes": { + "": "_decodeBagAttributes.!ret." + } + }, + "_decodePkcs7Data.!0": { + "constructed": { + "!type": "bool", + "!span": "14440[502:25]-14451[502:36]" + }, + "composed": { + "!type": "bool", + "!span": "14424[502:9]-14432[502:17]" + } + }, + "_decodeAuthenticatedSafe.!0": { + "getBags": { + "!type": "fn(filter: ?) -> _decodeAuthenticatedSafe.!0.getBags.!ret", + "!span": "9595[351:4]-9602[351:11]", + "!doc": "Gets bags with matching attributes.\n\n@param filter the attributes to filter by:\n [localKeyId] the localKeyId to search for.\n [localKeyIdHex] the localKeyId in hex to search for.\n [friendlyName] the friendly name to search for.\n [bagType] bag type to narrow each attribute search by.\n\n@return a map of attribute type to an array of matching bags or, if no\n attribute was given but a bag type, the map key will be the\n bag type." + }, + "getBagsByFriendlyName": { + "!type": "fn(friendlyName: ?, bagType: ?) -> [_getBagsByAttribute.!ret.]", + "!span": "10819[392:4]-10840[392:25]", + "!doc": "DEPRECATED: use getBags() instead.\n\nGet bags with matching friendlyName attribute.\n\n@param friendlyName the friendly name to search for.\n@param [bagType] bag type to narrow search by.\n\n@return an array of bags with matching friendlyName attribute." + }, + "getBagsByLocalKeyId": { + "!type": "fn(localKeyId: ?, bagType: ?) -> [_getBagsByAttribute.!ret.]", + "!span": "11296[407:4]-11315[407:23]", + "!doc": "DEPRECATED: use getBags() instead.\n\nGet bags with matching localKeyId attribute.\n\n@param localKeyId the localKeyId to search for.\n@param [bagType] bag type to narrow search by.\n\n@return an array of bags with matching localKeyId attribute." + }, + "!span": "8954[334:12]-11454[411:3]", + "safeContents": "_getBagsByAttribute.!0" + }, + "_decodeAuthenticatedSafe.!0.getBags.!ret": { + "!span": "9640[352:17]-9642[352:19]", + "": "_getBagsByAttribute.!ret", + "localKeyId": "_getBagsByAttribute.!ret", + "friendlyName": "_getBagsByAttribute.!ret" + }, + "_decodeSafeContents.!ret": { + "!type": "[_getBagsByAttribute.!ret.]", + "!span": "16404[563:8]-16412[563:16]" + }, + "_decodeBagAttributes.!ret": { + "": { + "!type": "[?]", + "!span": "22423[756:19]-22436[756:32]" + }, + "!span": "21904[738:21]-21906[738:23]" + }, + "p7.messageFromPem.!ret": { + "version": { + "!type": "number", + "!span": "18359[589:4]-18366[589:11]" + }, + "recipients": { + "": { + "version": { + "!type": "number", + "!span": "21713[700:8]-21720[700:15]" + }, + "encryptedContent": "_recipientsFromAsn1.!ret..encryptedContent" + } + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "37653[1185:6]-37662[1185:15]", + "!doc": "Keep a copy of the key & IV in the object, so the caller can\nuse it for whatever reason." + }, + "parameter": "+ByteBuffer", + "content": "+ByteBuffer", + "key": "+ByteBuffer" + }, + "findRecipient": {}, + "content": "+ByteBuffer", + "fromAsn1": "_fromAsn1.!0.fromAsn1", + "toAsn1": "_fromAsn1.!0.toAsn1", + "decrypt": "_fromAsn1.!0.decrypt", + "addRecipient": "_fromAsn1.!0.addRecipient", + "encrypt": "_fromAsn1.!0.encrypt", + "rawCapture": "_fromAsn1.!ret" + }, + "p7.messageFromPem.!ret.findRecipient.!ret": { + "serialNumber": { + "!type": "string", + "!span": "26217[836:4]-26229[836:16]" + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "26310[838:6]-26319[838:15]" + } + }, + "issuer": "pki.RDNAttributesAsArray.!ret" + }, + "p7.createSignedData.!ret": { + "version": { + "!type": "number", + "!span": "3313[125:4]-3320[125:11]" + }, + "certificates": { + "!type": "[pki.certificateFromPem.!ret]", + "!span": "3329[126:4]-3341[126:16]" + }, + "crls": { + "!type": "[?]", + "!span": "3351[127:4]-3355[127:8]" + }, + "signers": { + "": { + "version": { + "!type": "number", + "!span": "9954[317:8]-9961[317:15]" + }, + "serialNumber": { + "!type": "string", + "!span": "9998[319:8]-10010[319:20]" + }, + "key": "_modPow.!1", + "issuer": "pki.RDNAttributesAsArray.!ret", + "authenticatedAttributesAsn1": "_fromDer.!ret", + "authenticatedAttributes": "_signerToAsn1.!0.authenticatedAttributes", + "unauthenticatedAttributes": "_signerToAsn1.!0.unauthenticatedAttributes" + } + }, + "digestAlgorithmIdentifiers": { + "!type": "[_fromDer.!ret]", + "!span": "3464[131:4]-3490[131:30]", + "!doc": "add unique digest algorithm identifiers" + }, + "fromAsn1": { + "!type": "fn(obj: ?)", + "!span": "3545[135:4]-3553[135:12]" + }, + "toAsn1": { + "!type": "fn() -> _fromDer.!ret", + "!span": "4114[154:4]-4120[154:10]" + }, + "addSigner": { + "!type": "fn(signer: ?)", + "!span": "7603[248:4]-7612[248:13]", + "!doc": "Add (another) entity to list of signers.\n\nNote: If authenticatedAttributes are provided, then, per RFC 2315,\nthey must include at least two attributes: content type and\nmessage digest. The message digest attribute value will be\nauto-calculated during signing and will be ignored if provided.\n\nHere's an example of providing these two attributes:\n\nforge.pkcs7.createSignedData();\np7.addSigner({\n issuer: cert.issuer.attributes,\n serialNumber: cert.serialNumber,\n key: privateKey,\n digestAlgorithm: forge.pki.oids.sha1,\n authenticatedAttributes: [{\n type: forge.pki.oids.contentType,\n value: forge.pki.oids.data\n }, {\n type: forge.pki.oids.messageDigest\n }]\n});\n\nTODO: Support [subjectKeyIdentifier] as signer's ID.\n\n@param signer the signer information:\n key the signer's private key.\n [certificate] a certificate containing the public key\n associated with the signer's private key; use this option as\n an alternative to specifying signer.issuer and\n signer.serialNumber.\n [issuer] the issuer attributes (eg: cert.issuer.attributes).\n [serialNumber] the signer's certificate's serial number in\n hexadecimal (eg: cert.serialNumber).\n [digestAlgorithm] the message digest OID, as a string, to use\n (eg: forge.pki.oids.sha1).\n [authenticatedAttributes] an optional array of attributes\n to also sign along with the content." + }, + "sign": { + "!type": "fn(options: ?)", + "!span": "10457[333:4]-10461[333:8]", + "!doc": "Signs the content.\n@param options Options to apply when signing:\n [detached] boolean. If signing should be done in detached mode. Defaults to false." + }, + "verify": { + "!type": "fn()", + "!span": "12010[379:4]-12016[379:10]" + }, + "addCertificate": { + "!type": "fn(cert: pki.certificateFromPem.!ret)", + "!span": "12212[388:4]-12226[388:18]", + "!doc": "Add a certificate.\n\n@param cert the certificate to add." + }, + "addCertificateRevokationList": { + "!type": "fn(crl: ?)", + "!span": "12537[401:4]-12565[401:32]", + "!doc": "Add a certificate revokation list.\n\n@param crl the certificate revokation list to add." + }, + "!span": "3270[123:8]-12658[404:3]", + "contentInfo": "_fromDer.!ret", + "signerInfos": { + "": "_fromDer.!ret" + }, + "detachedContent": "_fromDer.!ret", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret" + }, + "p7.createEncryptedData.!ret": { + "version": { + "!type": "number", + "!span": "17467[550:4]-17474[550:11]" + }, + "fromAsn1": { + "!type": "fn(obj: ?)", + "!span": "17724[560:4]-17732[560:12]", + "!doc": "Reads an EncryptedData content block (in ASN.1 format)\n\n@param obj The ASN.1 representation of the EncryptedData content block" + }, + "decrypt": { + "!type": "fn(key: ?)", + "!span": "17996[570:4]-18003[570:11]", + "!doc": "Decrypt encrypted content\n\n@param key The (symmetric) key as a byte buffer" + }, + "!span": "17421[548:8]-18136[576:3]", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret" + }, + "_recipientFromAsn1.!ret": { + "serialNumber": { + "!type": "string", + "!span": "26217[836:4]-26229[836:16]" + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "26310[838:6]-26319[838:15]" + }, + "!span": "26284[837:4]-26300[837:20]" + }, + "!span": "26107[833:9]-26442[842:3]", + "issuer": "pki.RDNAttributesAsArray.!ret" + }, + "_recipientsFromAsn1.!ret": { + "!type": "[_recipientFromAsn1.!ret]", + "!span": "18375[590:4]-18385[590:14]" + }, + "_recipientsFromAsn1.!ret.": { + "version": { + "!type": "number", + "!span": "21713[700:8]-21720[700:15]" + }, + "encryptedContent": { + "!span": "21814[703:8]-21830[703:24]" + }, + "!span": "21703[699:26]-22137[710:7]" + }, + "_recipientsToAsn1.!ret": "[_fromDer.!ret]", + "_signerFromAsn1.!ret": { + "serialNumber": { + "!type": "string", + "!span": "29019[930:4]-29031[930:16]" + }, + "digestAlgorithm": { + "!type": "string", + "!span": "29086[931:4]-29101[931:19]" + }, + "signatureAlgorithm": { + "!type": "string", + "!span": "29147[932:4]-29165[932:22]" + }, + "authenticatedAttributes": { + "!type": "[?]", + "!span": "29248[934:4]-29271[934:27]" + }, + "unauthenticatedAttributes": { + "!type": "[?]", + "!span": "29281[935:4]-29306[935:29]" + }, + "!span": "28909[927:13]-29314[936:3]", + "issuer": "pki.RDNAttributesAsArray.!ret" + }, + "_signerToAsn1.!0": { + "version": { + "!type": "number", + "!span": "9954[317:8]-9961[317:15]" + }, + "serialNumber": { + "!type": "string", + "!span": "9998[319:8]-10010[319:20]" + }, + "authenticatedAttributes": { + "!type": "[?]", + "!span": "10159[323:8]-10182[323:31]", + "!doc": "if authenticatedAttributes is present, then the attributes\nmust contain at least PKCS #9 content-type and message-digest" + }, + "unauthenticatedAttributes": { + "!type": "[?]", + "!span": "10217[324:8]-10242[324:33]" + }, + "!span": "9926[315:23]-10254[325:7]", + "key": "_modPow.!1", + "issuer": "pki.RDNAttributesAsArray.!ret", + "authenticatedAttributesAsn1": "_fromDer.!ret" + }, + "_signersFromAsn1.!ret": "[_signerFromAsn1.!ret]", + "_signersToAsn1.!0": { + "!type": "[_signerToAsn1.!0]", + "!span": "3416[129:4]-3423[129:11]", + "!doc": "TODO: add json-formatted signer stuff here?" + }, + "_signersToAsn1.!ret": { + "!type": "[_fromDer.!ret]", + "!span": "3523[133:4]-3534[133:15]", + "!doc": "add signer info" + }, + "_attributeToAsn1.!0": { + "value": "+Date" + }, + "_encryptedContentToAsn1.!0": { + "algorithm": { + "!type": "string", + "!span": "37653[1185:6]-37662[1185:15]", + "!doc": "Keep a copy of the key & IV in the object, so the caller can\nuse it for whatever reason." + }, + "!span": "37645[1184:27]-37824[1188:5]", + "parameter": "+ByteBuffer", + "content": "+ByteBuffer", + "key": "+ByteBuffer" + }, + "_encryptedContentToAsn1.!ret": "[_fromDer.!ret, _fromDer.!ret, _fromDer.!ret]", + "_fromAsn1.!0": { + "version": { + "!type": "number", + "!span": "18359[589:4]-18366[589:11]" + }, + "fromAsn1": { + "!type": "fn(obj: ?)", + "!span": "18637[600:4]-18645[600:12]", + "!doc": "Reads an EnvelopedData content block (in ASN.1 format)\n\n@param obj the ASN.1 representation of the EnvelopedData content block." + }, + "toAsn1": { + "!type": "fn() -> _fromDer.!ret", + "!span": "18885[606:4]-18891[606:10]" + }, + "findRecipient": { + "!type": "fn(cert: ?) -> _recipientsFromAsn1.!ret.", + "!span": "19996[636:4]-20009[636:17]", + "!doc": "Find recipient by X.509 certificate's issuer.\n\n@param cert the certificate with the issuer to look for.\n\n@return the recipient object." + }, + "decrypt": { + "!type": "fn(recipient: ?, privKey: ?)", + "!span": "20858[674:4]-20865[674:11]", + "!doc": "Decrypt enveloped content\n\n@param recipient The recipient object related to the private key\n@param privKey The (RSA) private key object" + }, + "addRecipient": { + "!type": "fn(cert: ?)", + "!span": "21646[698:4]-21658[698:16]", + "!doc": "Add (another) entity to list of recipients.\n\n@param cert The certificate of the entity to add." + }, + "encrypt": { + "!type": "fn(key: +ByteBuffer, cipher: string)", + "!span": "22745[726:4]-22752[726:11]", + "!doc": "Encrypt enveloped content.\n\nThis function supports two optional arguments, cipher and key, which\ncan be used to influence symmetric encryption. Unless cipher is\nprovided, the cipher specified in encryptedContent.algorithm is used\n(defaults to AES-256-CBC). If no key is provided, encryptedContent.key\nis (re-)used. If that one's not set, a random key will be generated\nautomatically.\n\n@param [key] The key to be used for symmetric encryption.\n@param [cipher] The OID of the symmetric cipher to use." + }, + "!span": "18313[587:8]-25560[811:3]", + "recipients": "_recipientsFromAsn1.!ret", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret" + }, + "_fromAsn1.!ret": { + "!span": "36582[1155:16]-36584[1155:18]", + "!doc": "validate EnvelopedData content block and capture data" + }, + "p7v.envelopedDataValidator.value.0": { + "name": { + "!type": "string", + "!span": "6217[211:4]-6221[211:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6252[212:4]-6260[212:12]" + }, + "type": { + "!type": "number", + "!span": "6288[213:4]-6292[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6317[214:4]-6328[214:15]" + }, + "capture": { + "!type": "string", + "!span": "6341[215:4]-6348[215:11]" + }, + "!span": "6211[210:10]-6363[216:3]" + }, + "p7v.envelopedDataValidator.value.1": { + "name": { + "!type": "string", + "!span": "6371[217:4]-6375[217:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6413[218:4]-6421[218:12]" + }, + "type": { + "!type": "number", + "!span": "6449[219:4]-6453[219:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6474[220:4]-6485[220:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6497[221:4]-6508[221:15]" + }, + "!span": "6365[216:5]-6530[222:3]" + }, + "p7v.encryptedDataValidator.value.": { + "name": { + "!type": "string", + "!span": "6729[231:4]-6733[231:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6764[232:4]-6772[232:12]" + }, + "type": { + "!type": "number", + "!span": "6800[233:4]-6804[233:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6829[234:4]-6840[234:15]" + }, + "capture": { + "!type": "string", + "!span": "6853[235:4]-6860[235:11]" + }, + "!span": "6723[230:10]-6875[236:3]" + }, + "p7v.recipientInfoValidator.value.0": { + "name": { + "!type": "string", + "!span": "10109[361:4]-10113[361:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10144[362:4]-10152[362:12]" + }, + "type": { + "!type": "number", + "!span": "10180[363:4]-10184[363:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10209[364:4]-10220[364:15]" + }, + "capture": { + "!type": "string", + "!span": "10233[365:4]-10240[365:11]" + }, + "!span": "10103[360:10]-10255[366:3]" + }, + "p7v.recipientInfoValidator.value.1": { + "name": { + "!type": "string", + "!span": "10263[367:4]-10267[367:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10306[368:4]-10314[368:12]" + }, + "type": { + "!type": "number", + "!span": "10342[369:4]-10346[369:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10372[370:4]-10383[370:15]" + }, + "value": { + "!type": "[p7v.recipientInfoValidator.value.1.value.0, p7v.recipientInfoValidator.value.1.value.1]", + "!span": "10395[371:4]-10400[371:9]" + }, + "!span": "10257[366:5]-10776[384:3]" + }, + "p7v.recipientInfoValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "10411[372:6]-10415[372:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10463[373:6]-10471[373:14]" + }, + "type": { + "!type": "number", + "!span": "10501[374:6]-10505[374:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10533[375:6]-10544[375:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "10558[376:6]-10569[376:17]" + }, + "!span": "10403[371:12]-10585[377:5]" + }, + "p7v.recipientInfoValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "10595[378:6]-10599[378:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10653[379:6]-10661[379:14]" + }, + "type": { + "!type": "number", + "!span": "10691[380:6]-10695[380:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10722[381:6]-10733[381:17]" + }, + "capture": { + "!type": "string", + "!span": "10748[382:6]-10755[382:13]" + }, + "!span": "10587[377:7]-10771[383:5]" + }, + "p7v.recipientInfoValidator.value.2": { + "name": { + "!type": "string", + "!span": "10784[385:4]-10788[385:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10834[386:4]-10842[386:12]" + }, + "type": { + "!type": "number", + "!span": "10870[387:4]-10874[387:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10900[388:4]-10911[388:15]" + }, + "value": { + "!type": "[p7v.recipientInfoValidator.value.2.value.0, p7v.recipientInfoValidator.value.2.value.1]", + "!span": "10923[389:4]-10928[389:9]" + }, + "!span": "10778[384:5]-11295[401:3]" + }, + "p7v.recipientInfoValidator.value.2.value.0": { + "name": { + "!type": "string", + "!span": "10939[390:6]-10943[390:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11001[391:6]-11009[391:14]" + }, + "type": { + "!type": "number", + "!span": "11039[392:6]-11043[392:10]" + }, + "constructed": { + "!type": "bool", + "!span": "11066[393:6]-11077[393:17]" + }, + "capture": { + "!type": "string", + "!span": "11092[394:6]-11099[394:13]" + }, + "!span": "10931[389:12]-11121[395:5]" + }, + "p7v.recipientInfoValidator.value.2.value.1": { + "name": { + "!type": "string", + "!span": "11131[396:6]-11135[396:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11193[397:6]-11201[397:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11231[398:6]-11242[398:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "11257[399:6]-11268[399:17]" + }, + "!span": "11123[395:7]-11290[400:5]" + }, + "p7v.recipientInfoValidator.value.3": { + "name": { + "!type": "string", + "!span": "11303[402:4]-11307[402:8]" + }, + "tagClass": { + "!type": "number", + "!span": "11343[403:4]-11351[403:12]" + }, + "type": { + "!type": "number", + "!span": "11379[404:4]-11383[404:8]" + }, + "constructed": { + "!type": "bool", + "!span": "11412[405:4]-11423[405:15]" + }, + "capture": { + "!type": "string", + "!span": "11436[406:4]-11443[406:11]" + }, + "!span": "11297[401:5]-11457[407:3]" + }, + "encryptedContentInfoValidator.value.0": { + "name": { + "!type": "string", + "!span": "4356[149:4]-4360[149:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4402[150:4]-4410[150:12]" + }, + "type": { + "!type": "number", + "!span": "4438[151:4]-4442[151:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4463[152:4]-4474[152:15]" + }, + "capture": { + "!type": "string", + "!span": "4487[153:4]-4494[153:11]" + }, + "!span": "4350[148:10]-4513[154:3]" + }, + "encryptedContentInfoValidator.value.1": { + "name": { + "!type": "string", + "!span": "4521[155:4]-4525[155:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4582[156:4]-4590[156:12]" + }, + "type": { + "!type": "number", + "!span": "4618[157:4]-4622[157:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4648[158:4]-4659[158:15]" + }, + "value": { + "!type": "[encryptedContentInfoValidator.value.1.value.0, encryptedContentInfoValidator.value.1.value.1]", + "!span": "4671[159:4]-4676[159:9]" + }, + "!span": "4515[154:5]-5039[170:3]" + }, + "encryptedContentInfoValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "4687[160:6]-4691[160:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4760[161:6]-4768[161:14]" + }, + "type": { + "!type": "number", + "!span": "4798[162:6]-4802[162:10]" + }, + "constructed": { + "!type": "bool", + "!span": "4825[163:6]-4836[163:17]" + }, + "capture": { + "!type": "string", + "!span": "4851[164:6]-4858[164:13]" + }, + "!span": "4679[159:12]-4880[165:5]" + }, + "encryptedContentInfoValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "4890[166:6]-4894[166:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4963[167:6]-4971[167:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "5001[168:6]-5012[168:17]" + }, + "!span": "4882[165:7]-5034[169:5]" + }, + "encryptedContentInfoValidator.value.2": { + "name": { + "!type": "string", + "!span": "5047[171:4]-5051[171:8]" + }, + "tagClass": { + "!type": "number", + "!span": "5098[172:4]-5106[172:12]" + }, + "type": { + "!type": "number", + "!span": "5141[173:4]-5145[173:8]" + }, + "capture": { + "!type": "string", + "!span": "5984[200:4]-5991[200:11]", + "!doc": "The PKCS#7 structure output by OpenSSL somewhat differs from what\nother implementations do generate.\n\nOpenSSL generates a structure like this:\nSEQUENCE {\n ...\n [0]\n 26 DA 67 D2 17 9C 45 3C B1 2A A8 59 2F 29 33 38\n C3 C3 DF 86 71 74 7A 19 9F 40 D0 29 BE 85 90 45\n ...\n}\n\nWhereas other implementations (and this PKCS#7 module) generate:\nSEQUENCE {\n ...\n [0] {\n OCTET STRING\n 26 DA 67 D2 17 9C 45 3C B1 2A A8 59 2F 29 33 38\n C3 C3 DF 86 71 74 7A 19 9F 40 D0 29 BE 85 90 45\n ...\n }\n}\n\nIn order to support both, we just capture the context specific\nfield here. The OCTET STRING bit is removed below." + }, + "captureAsn1": { + "!type": "string", + "!span": "6017[201:4]-6028[201:15]" + }, + "!span": "5041[170:5]-6056[202:3]" + }, + "signerValidator.value.": { + "name": { + "!type": "string", + "!span": "8776[305:4]-8780[305:8]" + }, + "tagClass": { + "!type": "number", + "!span": "8826[306:4]-8834[306:12]" + }, + "type": { + "!type": "number", + "!span": "8869[307:4]-8873[307:8]" + }, + "constructed": { + "!type": "bool", + "!span": "8882[308:4]-8893[308:15]" + }, + "optional": { + "!type": "bool", + "!span": "8905[309:4]-8913[309:12]" + }, + "capture": { + "!type": "string", + "!span": "8925[310:4]-8932[310:11]" + }, + "!span": "8770[304:5]-8965[311:3]" + }, + "findPrime.!0": { + "hex": { + "!type": "string", + "!span": "7507[242:8]-7510[242:11]" + }, + "workLoad": { + "!type": "number", + "!span": "7525[243:8]-7533[243:16]" + }, + "!span": "7497[241:27]-7551[244:7]" + }, + "findPrime.!ret": { + "found": { + "!type": "bool", + "!span": "2181[54:10]-2186[54:15]" + }, + "!span": "2180[54:9]-2194[54:23]" + }, + "getPrng.!ret": { + "nextBytes": { + "!type": "fn(x: [number])", + "!span": "4032[136:4]-4041[136:13]", + "!doc": "x is an array to fill with bytes" + }, + "!span": "3986[134:9]-4165[141:3]" + }, + "pss.create.!0": { + "!span": "1211[36:14]-1298[40:5]" + }, + "pss.create.!ret": { + "encode": { + "!type": "fn(md: ?, modBits: ?) -> string", + "!span": "2345[81:9]-2351[81:15]", + "!doc": "Encodes a PSS signature.\n\nThis function implements EMSA-PSS-ENCODE as per RFC 3447, section 9.1.1.\n\n@param md the message digest object with the hash to sign.\n@param modsBits the length of the RSA modulus in bits.\n\n@return the encoded message as a binary-encoded string of length\n ceil((modBits - 1) / 8)." + }, + "verify": { + "!type": "fn(mHash: ?, em: ?, modBits: number) -> bool", + "!span": "4914[159:9]-4920[159:15]", + "!doc": "Verifies a PSS signature.\n\nThis function implements EMSA-PSS-VERIFY as per RFC 3447, section 9.1.2.\n\n@param mHash the message digest hash, as a binary-encoded string, to\n compare against the signature.\n@param em the encoded message, as a binary-encoded string\n (RSA decryption result).\n@param modsBits the length of the RSA modulus in bits.\n\n@return true if the signature was verified, false if not." + }, + "!span": "1962[68:15]-1964[68:17]" + }, + "createCipher.!ret": { + "start": { + "!type": "fn(iv: +ByteBuffer|string, output: ?)", + "!span": "7536[243:4]-7541[243:9]", + "!doc": "Starts or restarts the encryption or decryption process, whichever\nwas previously configured.\n\nTo use the cipher in CBC mode, iv may be given either as a string\nof bytes, or as a byte buffer. For ECB mode, give null as iv.\n\n@param iv the initialization vector to use, null for ECB mode.\n@param output the output the buffer to write to, null to create one." + }, + "update": { + "!type": "fn(input: +ByteBuffer)", + "!span": "7985[264:4]-7991[264:10]", + "!doc": "Updates the next block.\n\n@param input the buffer to read from." + }, + "finish": { + "!type": "fn(pad: ?) -> bool", + "!span": "8624[289:4]-8630[289:10]", + "!doc": "Finishes encrypting or decrypting.\n\n@param pad a padding function to use, null for PKCS#7 padding,\n signature(blockSize, buffer, decrypt).\n\n@return true if successful, false on error." + }, + "!span": "7103[232:11]-9727[332:3]", + "!doc": "Create cipher object", + "output": "+ByteBuffer" + }, + "util.nextTick.!0": { + "!type": "fn()", + "!span": "3394[115:35]-3445[117:9]" + }, + "util.parseFragment.!ret": { + "queryString": { + "!type": "string", + "!span": "63008[2417:4]-63019[2417:15]" + }, + "!span": "62982[2415:9]-63061[2420:3]", + "query": "?" + }, + "util.makeRequest.!ret": { + "query": { + "!type": "string", + "!span": "64119[2448:4]-64124[2448:9]", + "!doc": "full query string" + }, + "getPath": { + "!type": "fn(i: ?)", + "!span": "64302[2456:4]-64309[2456:11]", + "!doc": "Get path or element in path.\n\n@param i optional path index.\n\n@return path or part of path if i provided." + }, + "getQuery": { + "!type": "fn(k: ?, i: ?) -> ?|[?]", + "!span": "64641[2467:4]-64649[2467:12]", + "!doc": "Get query, values for a key, or value for a key index.\n\n@param k optional query key.\n@param i optional query key index.\n\n@return query, values for a key, or value for a key index." + }, + "getQueryLast": { + "!type": "fn(k: ?, _default: ?) -> !1", + "!span": "64917[2479:4]-64929[2479:16]" + }, + "!span": "64037[2444:12]-65136[2489:3]" + }, + "util.makeRequest.!ret.getQueryLast.!1": "[?]", + "util.estimateCores.!0": { + "!type": "fn(err: ?, cores: number)", + "!span": "5386[168:36]-5529[175:5]" + }, + "rsaPrivateKeyValidator.value.": { + "name": { + "!type": "string", + "!span": "5282[196:4]-5286[196:8]", + "!doc": "coefficient ((inverse of q) mod p)" + }, + "tagClass": { + "!type": "number", + "!span": "5321[197:4]-5329[197:12]" + }, + "type": { + "!type": "number", + "!span": "5357[198:4]-5361[198:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5386[199:4]-5397[199:15]" + }, + "capture": { + "!type": "string", + "!span": "5410[200:4]-5417[200:11]" + }, + "!span": "5234[194:5]-5446[201:3]" + }, + "rsaPublicKeyValidator.value.0": { + "name": { + "!type": "string", + "!span": "5677[213:4]-5681[213:8]", + "!doc": "modulus (n)" + }, + "tagClass": { + "!type": "number", + "!span": "5711[214:4]-5719[214:12]" + }, + "type": { + "!type": "number", + "!span": "5747[215:4]-5751[215:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5776[216:4]-5787[216:15]" + }, + "capture": { + "!type": "string", + "!span": "5800[217:4]-5807[217:11]" + }, + "!span": "5652[211:10]-5831[218:3]" + }, + "rsaPublicKeyValidator.value.1": { + "name": { + "!type": "string", + "!span": "5865[220:4]-5869[220:8]", + "!doc": "publicExponent (e)" + }, + "tagClass": { + "!type": "number", + "!span": "5900[221:4]-5908[221:12]" + }, + "type": { + "!type": "number", + "!span": "5936[222:4]-5940[222:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5965[223:4]-5976[223:15]" + }, + "capture": { + "!type": "string", + "!span": "5989[224:4]-5996[224:11]" + }, + "!span": "5833[218:5]-6021[225:3]" + }, + "_modPow.!1": { + "decrypt": { + "!type": "fn(data: ?, scheme: ?, schemeOptions: ?) -> ?", + "!span": "36684[1174:6]-36691[1174:13]", + "!doc": "Decrypts the given data with this private key. The decryption scheme\nmust match the one used to encrypt the data.\n\n@param data the byte string to decrypt.\n@param scheme the decryption scheme to use:\n 'RSAES-PKCS1-V1_5' (default),\n 'RSA-OAEP',\n 'RAW', 'NONE', or null to perform raw RSA decryption.\n@param schemeOptions any scheme-specific options.\n\n@return the decrypted byte string." + }, + "sign": { + "!type": "fn(md: +ByteBuffer, scheme: ?) -> ?", + "!span": "38365[1221:6]-38369[1221:10]", + "!doc": "Signs the given digest, producing a signature.\n\nPKCS#1 supports multiple (currently two) signature schemes:\nRSASSA-PKCS1-V1_5 and RSASSA-PSS.\n\nBy default this implementation uses the \"old scheme\", i.e.\nRSASSA-PKCS1-V1_5. In order to generate a PSS signature, provide\nan instance of Forge PSS object as the scheme parameter.\n\n@param md the message digest object with the hash to sign.\n@param scheme the signature scheme to use:\n 'RSASSA-PKCS1-V1_5' or undefined for RSASSA PKCS#1 v1.5,\n a Forge PSS object for RSASSA-PSS,\n 'NONE' or null for none, DigestInfo will not be used but\n PKCS#1 v1.5 padding will still be used.\n\n@return the signature as a byte string." + }, + "read": { + "!type": "number", + "!span": "19652[656:10]-19656[656:14]" + }, + "!span": "36108[1150:12]-36202[1159:3]", + "n": "+BigInteger", + "e": "+BigInteger", + "d": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger" + }, + "_generateKeyPair.!0": { + "algorithm": { + "!type": "string", + "!span": "18660[622:6]-18669[622:15]" + }, + "state": { + "!type": "number", + "!span": "18688[623:6]-18693[623:11]" + }, + "bits": { + "!type": "number", + "!span": "18704[624:6]-18708[624:10]" + }, + "rng": { + "nextBytes": { + "!type": "fn(x: [number])", + "!span": "18345[608:4]-18354[608:13]", + "!doc": "x is an array to fill with bytes" + }, + "!span": "18722[625:6]-18725[625:9]" + }, + "eInt": { + "!type": "number", + "!span": "18738[626:6]-18742[626:10]" + }, + "qBits": { + "!type": "number", + "!span": "18823[630:6]-18828[630:11]" + }, + "pBits": { + "!type": "number", + "!span": "18847[631:6]-18852[631:11]" + }, + "pqState": { + "!type": "number", + "!span": "18880[632:6]-18887[632:13]", + "!doc": "store p or q" + }, + "keys": { + "!span": "18915[634:6]-18919[634:10]", + "privateKey": "_modPow.!1", + "publicKey": "_publicKeyFromJwk.!ret" + }, + "!span": "18652[621:11]-18931[635:5]", + "!doc": "create PRIMEINC algorithm state", + "e": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "num": "+BigInteger", + "p1": "+BigInteger", + "q1": "+BigInteger", + "phi": "+BigInteger", + "n": "+BigInteger" + }, + "_publicKeyFromJwk.!ret": { + "encrypt": { + "!type": "fn(data: ?, scheme: ?, schemeOptions: ?) -> ?", + "!span": "32241[1036:6]-32248[1036:13]", + "!doc": "Encrypts the given data with this public key. Newer applications\nshould use the 'RSA-OAEP' decryption scheme, 'RSAES-PKCS1-V1_5' is for\nlegacy applications.\n\n@param data the byte string to encrypt.\n@param scheme the encryption scheme to use:\n 'RSAES-PKCS1-V1_5' (default),\n 'RSA-OAEP',\n 'RAW', 'NONE', or null to perform raw RSA encryption,\n an object with an 'encode' property set to a function\n with the signature 'function(data, key)' that returns\n a binary-encoded string representing the encoded data.\n@param schemeOptions any scheme-specific options.\n\n@return the encrypted byte string." + }, + "verify": { + "!type": "fn(digest: ?, signature: ?, scheme: ?) -> bool", + "!span": "34488[1097:6]-34494[1097:12]", + "!doc": "Verifies the given signature against the given digest.\n\nPKCS#1 supports multiple (currently two) signature schemes:\nRSASSA-PKCS1-V1_5 and RSASSA-PSS.\n\nBy default this implementation uses the \"old scheme\", i.e.\nRSASSA-PKCS1-V1_5, in which case once RSA-decrypted, the\nsignature is an OCTET STRING that holds a DigestInfo.\n\nDigestInfo ::= SEQUENCE {\n digestAlgorithm DigestAlgorithmIdentifier,\n digest Digest\n}\nDigestAlgorithmIdentifier ::= AlgorithmIdentifier\nDigest ::= OCTET STRING\n\nTo perform PSS signature verification, provide an instance\nof Forge PSS object as the scheme parameter.\n\n@param digest the message digest hash to compare against the signature,\n as a binary-encoded string.\n@param signature the signature to verify, as a binary-encoded string.\n@param scheme signature verification scheme to use:\n 'RSASSA-PKCS1-V1_5' or undefined for RSASSA PKCS#1 v1.5,\n a Forge PSS object for RSASSA-PSS,\n 'NONE' or null for none, DigestInfo will not be expected, but\n PKCS#1 v1.5 padding will still be used.\n\n@return true if the signature was verified, false if not." + }, + "!span": "31482[1014:12]-31506[1017:3]", + "n": "+BigInteger", + "e": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger" + }, + "_states.SHA-512.": "[number]", + "_states.SHA-384.": "[number]", + "_states.SHA-512/256.": "[number]", + "_states.SHA-512/224.": "[number]", + "net.socketPools..sockets..connected.!0": { + "type": { + "!type": "string", + "!span": "2282[66:10]-2286[66:14]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2309[67:10]-2323[67:24]" + }, + "!span": "2245[64:28]-2350[68:9]", + "socket": "net.socketPools..sockets." + }, + "net.socketPools..sockets..closed.!0": { + "type": { + "!type": "string", + "!span": "5447[189:9]-5451[189:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "5471[190:9]-5485[190:23]" + }, + "!span": "5412[187:21]-5497[191:8]" + }, + "net.socketPools..sockets..data.!0": { + "type": { + "!type": "string", + "!span": "2617[79:8]-2621[79:12]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2645[80:8]-2659[80:22]" + }, + "!span": "2584[77:21]-2684[81:7]" + }, + "net.socketPools..sockets..error.!0": { + "type": { + "!type": "string", + "!span": "3698[131:6]-3702[131:10]" + }, + "message": { + "!type": "string", + "!span": "3718[132:6]-3725[132:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3744[133:6]-3758[133:20]" + }, + "!span": "3669[129:20]-3767[134:5]" + }, + "net.socketPools..sockets..connect.!0": { + "host": { + "!type": "string", + "!span": "3256[129:6]-3260[129:10]" + }, + "policyPort": { + "!type": "number", + "!span": "3314[131:6]-3324[131:16]" + }, + "!span": "3248[128:19]-3384[133:5]" + }, + "net.socketPools..sockets..options.request.getCookies.!ret": "[http.withinCookieDomain.!1]", + "net.socketPools..sockets..options.headerReady.!0": { + "!span": "6721[253:39]-6846[257:13]", + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "net.socketPools..sockets..options.bodyReady.!0": { + "!span": "7060[264:35]-7177[268:11]", + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "net.socketPools..sockets..options.error.!0": { + "type": { + "!type": "string", + "!span": "7702[285:6]-7706[285:10]" + }, + "message": { + "!type": "string", + "!span": "7722[286:6]-7729[286:13]" + }, + "!span": "7694[284:25]-7848[290:5]", + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "net.createSocketPool.!0": { + "policyPort": { + "!type": "number", + "!span": "4170[131:4]-4180[131:14]" + }, + "msie": { + "!type": "bool", + "!span": "4226[133:4]-4230[133:8]" + }, + "!span": "4134[129:29]-4257[134:3]" + }, + "Task.prototype.fail.!0": { + "error": { + "!type": "bool", + "!span": "11925[445:9]-11930[445:14]", + "!doc": "propagate task info" + }, + "swapTime": { + "!type": "number", + "!span": "11954[446:9]-11962[446:17]" + }, + "state": { + "!type": "string", + "!span": "14796[557:7]-14801[557:12]" + } + }, + "Task.!0": { + "run": { + "!type": "fn(task: +Task)", + "!span": "17750[647:4]-17753[647:7]", + "!doc": "save run function" + }, + "name": { + "!type": "string", + "!span": "17772[648:4]-17776[648:8]" + }, + "!span": "17744[646:22]-17809[649:3]" + }, + "hmac_sha1.!1": { + "!type": "[http.withinCookieDomain.!1|hmac_sha1.!1, http.withinCookieDomain.!1]", + "!doc": "get cookie from default domain" + }, + "hmac_sha1.!2": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + }, + "!span": "117313[3842:8]-117320[3842:15]" + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "!span": "117276[3840:17]-117497[3849:7]", + "!doc": "cache the record, clear its fragment, and reset the buffer read\npointer before the type and length were read", + "fragment": "+ByteBuffer" + }, + "deflate.!2": { + "sequenceNumber": { + "!type": "[number]", + "!span": "75257[2453:6]-75271[2453:20]", + "!doc": "two 32-bit numbers, first is most significant" + }, + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "cipherFunction": { + "!type": "fn(record: hmac_sha1.!2) -> bool", + "!span": "75377[2458:6]-75391[2458:20]" + }, + "updateSequenceNumber": { + "!type": "fn()", + "!span": "75519[2461:6]-75539[2461:26]" + }, + "update": { + "!type": "fn(c: ?, record: hmac_sha1.!2) -> bool", + "!span": "75935[2478:13]-75941[2478:19]", + "!doc": "update function in write mode will compress then encrypt a record" + }, + "!span": "75194[2451:15]-75756[2469:5]", + "!doc": "change current write state to pending write state", + "compressFunction": "deflate" + }, + "ctTable.": { + "!type": "[[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2) -> number, fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2) -> number]]", + "!doc": "map server current expect state and content type to function" + }, + "ctTable..": "[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2) -> number, fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2) -> number]", + "H5.!1": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + }, + "!span": "79861[2610:4]-79868[2610:11]" + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "!span": "79831[2608:15]-80003[2616:3]", + "!doc": "create client key exchange message", + "fragment": "+ByteBuffer" + }, + "hsTable.": "[[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2)|fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2, length: ?)]|[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2)]]", + "hsTable..": "[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2)]", + "_getStorageObject.!ret": { + "!span": "54204[2065:10]-54206[2065:12]", + "!doc": "json-encode and base64-encode object" + }, + "_callStorageFunction.!1": "[string]", + "x509CertificateValidator.value.0": { + "name": { + "!type": "string", + "!span": "4613[156:4]-4617[156:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4653[157:4]-4661[157:12]" + }, + "type": { + "!type": "number", + "!span": "4689[158:4]-4693[158:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4719[159:4]-4730[159:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4742[160:4]-4753[160:15]" + }, + "value": { + "!type": "[?]", + "!span": "4777[161:4]-4782[161:9]" + }, + "!span": "4607[155:10]-9333[294:3]" + }, + "x509CertificateValidator.value.1": { + "name": { + "!type": "string", + "!span": "9390[296:4]-9394[296:8]", + "!doc": "AlgorithmIdentifier (signature algorithm)" + }, + "tagClass": { + "!type": "number", + "!span": "9434[297:4]-9442[297:12]" + }, + "type": { + "!type": "number", + "!span": "9470[298:4]-9474[298:8]" + }, + "constructed": { + "!type": "bool", + "!span": "9500[299:4]-9511[299:15]" + }, + "value": { + "!type": "[x509CertificateValidator.value.1.value.0, x509CertificateValidator.value.1.value.1]", + "!span": "9523[300:4]-9528[300:9]" + }, + "!span": "9335[294:5]-9916[313:3]" + }, + "x509CertificateValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "9558[302:6]-9562[302:10]", + "!doc": "algorithm" + }, + "tagClass": { + "!type": "number", + "!span": "9614[303:6]-9622[303:14]" + }, + "type": { + "!type": "number", + "!span": "9652[304:6]-9656[304:10]" + }, + "constructed": { + "!type": "bool", + "!span": "9679[305:6]-9690[305:17]" + }, + "capture": { + "!type": "string", + "!span": "9705[306:6]-9712[306:13]" + }, + "!span": "9531[300:12]-9738[307:5]" + }, + "x509CertificateValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "9748[308:6]-9752[308:10]" + }, + "tagClass": { + "!type": "number", + "!span": "9811[309:6]-9819[309:14]" + }, + "optional": { + "!type": "bool", + "!span": "9849[310:6]-9857[310:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "9871[311:6]-9882[311:17]" + }, + "!span": "9740[307:7]-9911[312:5]" + }, + "x509CertificateValidator.value.2": { + "name": { + "!type": "string", + "!span": "9946[315:4]-9950[315:8]", + "!doc": "SignatureValue" + }, + "tagClass": { + "!type": "number", + "!span": "9986[316:4]-9994[316:12]" + }, + "type": { + "!type": "number", + "!span": "10022[317:4]-10026[317:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10053[318:4]-10064[318:15]" + }, + "captureBitStringValue": { + "!type": "string", + "!span": "10077[319:4]-10098[319:25]" + }, + "!span": "9918[313:5]-10119[320:3]" + }, + "rsassaPssParameterValidator.value.0": { + "name": { + "!type": "string", + "!span": "10278[329:4]-10282[329:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10312[330:4]-10320[330:12]" + }, + "type": { + "!type": "number", + "!span": "10355[331:4]-10359[331:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10368[332:4]-10379[332:15]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.0.value.]", + "!span": "10391[333:4]-10396[333:9]" + }, + "!span": "10272[328:10]-10863[348:3]" + }, + "rsassaPssParameterValidator.value.0.value.": { + "name": { + "!type": "string", + "!span": "10407[334:6]-10411[334:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10463[335:6]-10471[335:14]" + }, + "constructed": { + "!type": "bool", + "!span": "10534[337:6]-10545[337:17]" + }, + "optional": { + "!type": "bool", + "!span": "10559[338:6]-10567[338:14]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.0.value..value.]", + "!span": "10581[339:6]-10586[339:11]" + }, + "!span": "10399[333:12]-10858[347:5]" + }, + "rsassaPssParameterValidator.value.0.value..value.": { + "name": { + "!type": "string", + "!span": "10599[340:8]-10603[340:12]" + }, + "tagClass": { + "!type": "number", + "!span": "10667[341:8]-10675[341:16]" + }, + "type": { + "!type": "number", + "!span": "10707[342:8]-10711[342:12]" + }, + "constructed": { + "!type": "bool", + "!span": "10736[343:8]-10747[343:19]" + }, + "capture": { + "!type": "string", + "!span": "10764[344:8]-10771[344:15]" + }, + "!span": "10589[339:14]-10851[346:7]" + }, + "rsassaPssParameterValidator.value.1": { + "name": { + "!type": "string", + "!span": "10871[349:4]-10875[349:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10908[350:4]-10916[350:12]" + }, + "type": { + "!type": "number", + "!span": "10951[351:4]-10955[351:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10964[352:4]-10975[352:15]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.1.value.]", + "!span": "10987[353:4]-10992[353:9]" + }, + "!span": "10865[348:5]-11898[380:3]" + }, + "rsassaPssParameterValidator.value.1.value.": { + "name": { + "!type": "string", + "!span": "11003[354:6]-11007[354:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11062[355:6]-11070[355:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11133[357:6]-11144[357:17]" + }, + "optional": { + "!type": "bool", + "!span": "11158[358:6]-11166[358:14]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.1.value..value.0, rsassaPssParameterValidator.value.1.value..value.1]", + "!span": "11180[359:6]-11185[359:11]" + }, + "!span": "10995[353:12]-11893[379:5]" + }, + "rsassaPssParameterValidator.value.1.value..value.0": { + "name": { + "!type": "string", + "!span": "11198[360:8]-11202[360:12]" + }, + "tagClass": { + "!type": "number", + "!span": "11269[361:8]-11277[361:16]" + }, + "type": { + "!type": "number", + "!span": "11309[362:8]-11313[362:12]" + }, + "constructed": { + "!type": "bool", + "!span": "11338[363:8]-11349[363:19]" + }, + "capture": { + "!type": "string", + "!span": "11366[364:8]-11373[364:15]" + }, + "!span": "11188[359:14]-11395[365:7]" + }, + "rsassaPssParameterValidator.value.1.value..value.1": { + "name": { + "!type": "string", + "!span": "11407[366:8]-11411[366:12]" + }, + "tagClass": { + "!type": "number", + "!span": "11475[367:8]-11483[367:16]" + }, + "type": { + "!type": "number", + "!span": "11515[368:8]-11519[368:12]" + }, + "constructed": { + "!type": "bool", + "!span": "11549[369:8]-11560[369:19]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.1.value..value.1.value.]", + "!span": "11576[370:8]-11581[370:13]" + }, + "!span": "11397[365:9]-11886[378:7]" + }, + "rsassaPssParameterValidator.value.1.value..value.1.value.": { + "name": { + "!type": "string", + "!span": "11596[371:10]-11600[371:14]" + }, + "tagClass": { + "!type": "number", + "!span": "11676[372:10]-11684[372:18]" + }, + "type": { + "!type": "number", + "!span": "11718[373:10]-11722[373:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11749[374:10]-11760[374:21]" + }, + "capture": { + "!type": "string", + "!span": "11779[375:10]-11786[375:17]" + }, + "!span": "11584[370:16]-11877[377:9]" + }, + "rsassaPssParameterValidator.value.2": { + "name": { + "!type": "string", + "!span": "11906[381:4]-11910[381:8]" + }, + "tagClass": { + "!type": "number", + "!span": "11937[382:4]-11945[382:12]" + }, + "type": { + "!type": "number", + "!span": "11980[383:4]-11984[383:8]" + }, + "optional": { + "!type": "bool", + "!span": "11993[384:4]-12001[384:12]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.2.value.]", + "!span": "12013[385:4]-12018[385:9]" + }, + "!span": "11900[380:5]-12201[392:3]" + }, + "rsassaPssParameterValidator.value.2.value.": { + "name": { + "!type": "string", + "!span": "12029[386:6]-12033[386:10]" + }, + "tagClass": { + "!type": "number", + "!span": "12073[387:6]-12081[387:14]" + }, + "constructed": { + "!type": "bool", + "!span": "12143[389:6]-12154[389:17]" + }, + "capture": { + "!type": "string", + "!span": "12169[390:6]-12176[390:13]" + }, + "!span": "12021[385:12]-12196[391:5]" + }, + "rsassaPssParameterValidator.value.3": { + "name": { + "!type": "string", + "!span": "12209[393:4]-12213[393:8]" + }, + "tagClass": { + "!type": "number", + "!span": "12242[394:4]-12250[394:12]" + }, + "type": { + "!type": "number", + "!span": "12285[395:4]-12289[395:8]" + }, + "optional": { + "!type": "bool", + "!span": "12298[396:4]-12306[396:12]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.3.value.]", + "!span": "12318[397:4]-12323[397:9]" + }, + "!span": "12203[392:5]-12497[404:3]" + }, + "rsassaPssParameterValidator.value.3.value.": { + "name": { + "!type": "string", + "!span": "12334[398:6]-12338[398:10]" + }, + "tagClass": { + "!type": "number", + "!span": "12372[399:6]-12380[399:14]" + }, + "constructed": { + "!type": "bool", + "!span": "12442[401:6]-12453[401:17]" + }, + "capture": { + "!type": "string", + "!span": "12468[402:6]-12475[402:13]" + }, + "!span": "12326[397:12]-12492[403:5]" + }, + "certificationRequestInfoValidator.value.0": { + "name": { + "!type": "string", + "!span": "12777[415:4]-12781[415:8]" + }, + "tagClass": { + "!type": "number", + "!span": "12823[416:4]-12831[416:12]" + }, + "type": { + "!type": "number", + "!span": "12859[417:4]-12863[417:8]" + }, + "constructed": { + "!type": "bool", + "!span": "12888[418:4]-12899[418:15]" + }, + "capture": { + "!type": "string", + "!span": "12912[419:4]-12919[419:11]" + }, + "!span": "12771[414:10]-12958[420:3]" + }, + "certificationRequestInfoValidator.value.1": { + "name": { + "!type": "string", + "!span": "13002[422:4]-13006[422:8]", + "!doc": "Name (subject) (RDNSequence)" + }, + "tagClass": { + "!type": "number", + "!span": "13048[423:4]-13056[423:12]" + }, + "type": { + "!type": "number", + "!span": "13084[424:4]-13088[424:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13114[425:4]-13125[425:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "13137[426:4]-13148[426:15]" + }, + "!span": "12960[420:5]-13187[427:3]" + }, + "certificationRequestInfoValidator.value.3": { + "name": { + "!type": "string", + "!span": "13245[431:4]-13249[431:8]" + }, + "tagClass": { + "!type": "number", + "!span": "13294[432:4]-13302[432:12]" + }, + "type": { + "!type": "number", + "!span": "13337[433:4]-13341[433:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13350[434:4]-13361[434:15]" + }, + "optional": { + "!type": "bool", + "!span": "13373[435:4]-13381[435:12]" + }, + "capture": { + "!type": "string", + "!span": "13393[436:4]-13400[436:11]" + }, + "value": { + "!type": "[certificationRequestInfoValidator.value.3.value.]", + "!span": "13444[437:4]-13449[437:9]" + }, + "!span": "13239[430:2]-13954[454:3]" + }, + "certificationRequestInfoValidator.value.3.value.": { + "name": { + "!type": "string", + "!span": "13460[438:6]-13464[438:10]" + }, + "tagClass": { + "!type": "number", + "!span": "13511[439:6]-13519[439:14]" + }, + "type": { + "!type": "number", + "!span": "13549[440:6]-13553[440:10]" + }, + "constructed": { + "!type": "bool", + "!span": "13581[441:6]-13592[441:17]" + }, + "value": { + "!type": "[certificationRequestInfoValidator.value.3.value..value.0, certificationRequestInfoValidator.value.3.value..value.1]", + "!span": "13606[442:6]-13611[442:11]" + }, + "!span": "13452[437:12]-13949[453:5]" + }, + "certificationRequestInfoValidator.value.3.value..value.0": { + "name": { + "!type": "string", + "!span": "13624[443:8]-13628[443:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13682[444:8]-13690[444:16]" + }, + "type": { + "!type": "number", + "!span": "13722[445:8]-13726[445:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13751[446:8]-13762[446:19]" + }, + "!span": "13614[442:14]-13777[447:7]" + }, + "certificationRequestInfoValidator.value.3.value..value.1": { + "name": { + "!type": "string", + "!span": "13789[448:8]-13793[448:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13848[449:8]-13856[449:16]" + }, + "type": { + "!type": "number", + "!span": "13888[450:8]-13892[450:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13917[451:8]-13928[451:19]" + }, + "!span": "13779[447:9]-13942[452:7]" + }, + "certificationRequestValidator.value.1": { + "name": { + "!type": "string", + "!span": "14294[467:6]-14298[467:10]", + "!doc": "AlgorithmIdentifier (signature algorithm)" + }, + "tagClass": { + "!type": "number", + "!span": "14349[468:6]-14357[468:14]" + }, + "type": { + "!type": "number", + "!span": "14387[469:6]-14391[469:10]" + }, + "constructed": { + "!type": "bool", + "!span": "14419[470:6]-14430[470:17]" + }, + "value": { + "!type": "[certificationRequestValidator.value.1.value.0, certificationRequestValidator.value.1.value.1]", + "!span": "14444[471:6]-14449[471:11]" + }, + "!span": "14235[465:39]-14873[484:5]" + }, + "certificationRequestValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "14483[473:8]-14487[473:12]", + "!doc": "algorithm" + }, + "tagClass": { + "!type": "number", + "!span": "14550[474:8]-14558[474:16]" + }, + "type": { + "!type": "number", + "!span": "14590[475:8]-14594[475:12]" + }, + "constructed": { + "!type": "bool", + "!span": "14619[476:8]-14630[476:19]" + }, + "capture": { + "!type": "string", + "!span": "14647[477:8]-14654[477:15]" + }, + "!span": "14452[471:14]-14681[478:7]" + }, + "certificationRequestValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "14693[479:8]-14697[479:12]" + }, + "tagClass": { + "!type": "number", + "!span": "14761[480:8]-14769[480:16]" + }, + "optional": { + "!type": "bool", + "!span": "14801[481:8]-14809[481:16]" + }, + "captureAsn1": { + "!type": "string", + "!span": "14825[482:8]-14836[482:19]" + }, + "!span": "14683[478:9]-14866[483:7]" + }, + "certificationRequestValidator.value.2": { + "name": { + "!type": "string", + "!span": "14902[486:6]-14906[486:10]", + "!doc": "signature" + }, + "tagClass": { + "!type": "number", + "!span": "14948[487:6]-14956[487:14]" + }, + "type": { + "!type": "number", + "!span": "14986[488:6]-14990[488:10]" + }, + "constructed": { + "!type": "bool", + "!span": "15019[489:6]-15030[489:17]" + }, + "captureBitStringValue": { + "!type": "string", + "!span": "15045[490:6]-15066[490:27]" + }, + "!span": "14875[484:7]-15088[491:5]" + }, + "_getAttribute.!0": { + "version": { + "!type": "number", + "!span": "54558[1755:6]-54565[1755:13]" + }, + "signatureOid": { + "!type": "string", + "!span": "54580[1756:6]-54592[1756:18]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "54659[1759:14]-54671[1759:26]" + }, + "!span": "54631[1758:6]-54638[1758:13]", + "parameters": "_readSignatureParameters.!ret" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "_dnToAsn1.!0.getField", + "addField": "_dnToAsn1.!0.addField" + }, + "getAttribute": { + "!type": "fn(sn: ?) -> _getAttribute.!ret", + "!span": "55019[1774:6]-55031[1774:18]", + "!doc": "convert attributes from ASN.1" + }, + "addAttribute": { + "!type": "fn(attr: ?)", + "!span": "55095[1777:6]-55107[1777:18]" + }, + "setSubject": { + "!type": "fn(attrs: ?)", + "!span": "55347[1788:6]-55357[1788:16]", + "!doc": "Sets the subject of this certification request.\n\n@param attrs the array of subject attributes to use." + }, + "setAttributes": { + "!type": "fn(attrs: ?)", + "!span": "55635[1800:6]-55648[1800:19]", + "!doc": "Sets the attributes of this certification request.\n\n@param attrs the array of attributes to use." + }, + "sign": { + "!type": "fn(key: ?, md: ?)", + "!span": "55973[1812:6]-55977[1812:10]", + "!doc": "Signs this certification request using the given private key.\n\n@param key the private key to sign with.\n@param md the message digest object to use (defaults to forge.md.sha1)." + }, + "verify": { + "!type": "fn() -> bool", + "!span": "57085[1844:6]-57091[1844:12]", + "!doc": "Attempts verify the signature on the passed certification request using\nits public key.\n\nA CSR that has been exported to a file in PEM format can be verified using\nOpenSSL using this command:\n\nopenssl req -in -verify -noout -text\n\n@return true if verified, false if not." + }, + "signatureParameters": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + } + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + } + } + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + } + }, + "!span": "54548[1754:12]-54550[1754:14]", + "!doc": "create certification request", + "publicKey": "_publicKeyFromJwk.!ret", + "attributes": "pki.CRIAttributesAsArray.!ret", + "md": "_createKDF.!1", + "certificationRequestInfo": "_fromDer.!ret" + }, + "_getAttribute.!1": { + "!span": "18162[595:14]-18182[595:34]", + "shortName": "_getAttribute.!1" + }, + "_getAttribute.!ret": { + "type": { + "!type": "string", + "!span": "17085[558:10]-17089[558:14]" + }, + "name": { + "!type": "string", + "!span": "17276[563:12]-17280[563:16]" + }, + "extensions": { + "!type": "[pki.certificateExtensionFromAsn1.!ret]", + "!span": "17489[570:12]-17499[570:22]" + }, + "!span": "17071[557:16]-17073[557:18]" + }, + "_readSignatureParameters.!ret": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + }, + "!span": "19735[651:6]-19739[651:10]" + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + }, + "!span": "19844[656:8]-19848[656:12]" + }, + "!span": "19793[654:6]-19796[654:9]" + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + }, + "!span": "19727[650:13]-19934[661:5]" + }, + "_dnToAsn1.!0": { + "getField": { + "!type": "fn(sn: ?) -> _getAttribute.!ret", + "!span": "54715[1762:14]-54723[1762:22]" + }, + "addField": { + "!type": "fn(attr: ?)", + "!span": "54803[1765:14]-54811[1765:22]" + }, + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "!span": "54697[1761:16]-54699[1761:18]", + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "_getAttributesAsJson.!ret": { + "": { + "!type": "[_getAttributesAsJson.!ret., ?]", + "!span": "62302[2012:13]-62316[2012:27]" + }, + "!span": "61856[2000:13]-61858[2000:15]" + }, + "_fillMissingFields.!0": "[?]", + "_fillMissingExtensionFields.!0": { + "name": { + "!type": "string", + "!span": "64592[2096:8]-64596[2096:12]" + }, + "id": { + "!type": "string", + "!span": "64734[2103:8]-64736[2103:10]" + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "69648[2290:6]-69668[2290:26]" + }, + "value": "_fromDer.!ret" + }, + "_fillMissingExtensionFields.!1": { + "!span": "29909[993:43]-29921[993:55]", + "cert": "pki.certificateFromPem.!ret" + }, + "xhrApi.create.!ret": { + "readyState": { + "!type": "number", + "!span": "11722[366:4]-11732[366:14]", + "!doc": "7. set state to UNSENT" + }, + "responseText": { + "!type": "string", + "!span": "11792[368:4]-11804[368:16]", + "!doc": "3. set response to null" + }, + "responseXML": { + "async": { + "!type": "bool", + "!span": "18241[587:16]-18246[587:21]" + }, + "!span": "11872[370:4]-11883[370:15]", + "!doc": "a Document for response entity-bodies that are XML" + }, + "status": { + "!type": "number", + "!span": "11952[372:4]-11958[372:10]", + "!doc": "custom: reset status and statusText" + }, + "statusText": { + "!type": "string", + "!span": "12035[374:4]-12045[374:14]", + "!doc": "readonly, returns the HTTP status message (i.e. 'Not Found')" + }, + "open": { + "!type": "fn(method: ?, url: ?, async: ?, user: ?, password: ?)", + "!span": "13513[424:6]-13517[424:10]", + "!doc": "Opens the request. This method will create the HTTP request to send.\n\n@param method the HTTP method (i.e. 'GET').\n@param url the relative url (the HTTP request path).\n@param async always true, ignored.\n@param user always null, ignored.\n@param password always null, ignored." + }, + "setRequestHeader": { + "!type": "fn(header: ?, value: ?)", + "!span": "15241[489:6]-15257[489:22]", + "!doc": "Adds an HTTP header field to the request.\n\n@param header the name of the header field.\n@param value the value of the header field." + }, + "send": { + "!type": "fn(data: ?)", + "!span": "15747[506:6]-15751[506:10]", + "!doc": "Sends the request and any associated data.\n\n@param data a string or Document object to send, null to send no data." + }, + "abort": { + "!type": "fn()", + "!span": "20103[654:6]-20108[654:11]", + "!doc": "Aborts the request." + }, + "getAllResponseHeaders": { + "!type": "fn() -> string", + "!span": "21224[699:6]-21245[699:27]", + "!doc": "Gets all response headers as a string.\n\n@return the HTTP-encoded response header fields." + }, + "getResponseHeader": { + "!type": "fn(header: ?) -> [string]|string", + "!span": "21758[719:6]-21775[719:23]", + "!doc": "Gets a single header field value or, if there are multiple\nfields with the same name, a comma-separated list of header\nvalues.\n\n@return the header field value(s) or null." + }, + "!span": "11622[362:12]-12053[375:3]", + "!doc": "create public xhr interface", + "cookies": "_getStorageId.!0.cookies" + }, + "BlockCipher._op.!0": { + "read": { + "!type": "number", + "!span": "19360[681:12]-19364[681:16]" + } + }, + "BlockCipher.start.!1": { + "!span": "20298[486:16]-20300[486:18]", + "output": "BlockCipher.start.!1" + }, + "modes.gcm._m.": "[[number]]", + "modes.gcm._m..": "[number, number, number, number]", + "forge.aes.Algorithm.!1.prototype.generateHashTable.!ret": { + "": { + "": "modes.gcm._m.." + } + }, + "forge.aes.Algorithm.!1.prototype.generateSubHashTable.!ret": { + "": "modes.gcm._m.." + }, + "forge.cipher.modes.cbc.prototype.start.!0": { + "output": "BlockCipher.start.!1" + }, + "forge.cipher.modes.gcm.prototype.generateHashTable.!ret": { + "": { + "": "modes.gcm._m.." + } + }, + "forge.cipher.modes.gcm.prototype.generateSubHashTable.!ret": { + "": "modes.gcm._m.." + }, + "forge.pki.ed25519.generateKeyPair.!ret": { + "publicKey": "+Float32Array", + "privateKey": "+Float32Array" + }, + "forge.pki.pbe.getCipher.!ret": { + "output": "+ByteBuffer", + "start": "createCipher.!ret.start", + "update": "createCipher.!ret.update", + "finish": "createCipher.!ret.finish" + }, + "forge.pki.setRsaPublicKey.!ret": { + "n": "+BigInteger", + "e": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger", + "encrypt": "_publicKeyFromJwk.!ret.encrypt", + "verify": "_publicKeyFromJwk.!ret.verify" + }, + "forge.pki.rsa.generateKeyPair.!ret": { + "privateKey": "_modPow.!1", + "publicKey": "_publicKeyFromJwk.!ret" + }, + "forge.pki.certificateFromPem.!ret.issuer.getField.!0": { + "shortName": "_getAttribute.!1" + }, + "forge.pki.certificationRequestFromPem.!ret.getAttribute.!0": { + "shortName": "_getAttribute.!1" + }, + "forge.pki.distinguishedNameToAsn1.!0": { + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "forge.pki.verifyCertificateChain.!1": { + "": "pki.certificateFromPem.!ret" + }, + "forge.ed25519.generateKeyPair.!0": { + "seed": "+Float32Array" + }, + "forge.ed25519.generateKeyPair.!ret": { + "publicKey": "+Float32Array", + "privateKey": "+Float32Array" + }, + "forge.hmac.create.!ret": { + "digest": "hmac.create.!ret.getMac", + "start": "hmac.create.!ret.start", + "update": "hmac.create.!ret.update", + "getMac": "hmac.create.!ret.getMac" + }, + "forge.http.createClient.!0.socketPool.sockets..options.request.getCookies.!ret": { + "": "http.withinCookieDomain.!1" + }, + "forge.http.createClient.!0.socketPool.sockets..options.headerReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!0.socketPool.sockets..options.bodyReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.requests..request.getCookies.!ret": { + "": "http.withinCookieDomain.!1" + }, + "forge.http.createClient.!ret.requests..headerReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.requests..bodyReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.send.!0": { + "request": "net.socketPools..sockets..options.request", + "bodyReady": "net.socketPools..sockets..options.bodyReady", + "error": "net.socketPools..sockets..options.error", + "headerReady": "_getStorageId.!0.send.!0.headerReady" + }, + "forge.http.createRequest.!ret.getCookies.!ret": { + "": "http.withinCookieDomain.!1" + }, + "forge.jsbn.BigInteger.prototype.divideAndRemainder.!ret": { + "": "+BigInteger" + }, + "forge.mgf.mgf1.create.!ret": { + "generate": "mgf1.create.!ret.generate" + }, + "forge.pbe.getCipher.!ret": { + "output": "+ByteBuffer", + "start": "createCipher.!ret.start", + "update": "createCipher.!ret.update", + "finish": "createCipher.!ret.finish" + }, + "forge.pkcs12.pkcs12FromAsn1.!ret.getBags.!ret": { + "": { + "": "_getBagsByAttribute.!ret." + }, + "localKeyId": "_getBagsByAttribute.!ret", + "friendlyName": "_getBagsByAttribute.!ret" + }, + "forge.pkcs12.pkcs12FromAsn1.!ret.getBagsByFriendlyName.!ret": { + "": "_getBagsByAttribute.!ret." + }, + "forge.prng.create.!0": { + "md": "sha256", + "formatKey": "forge.random.plugin.formatKey", + "formatSeed": "forge.random.plugin.formatSeed", + "cipher": "forge.random.plugin.cipher", + "increment": "forge.random.plugin.increment" + }, + "forge.rsa.generateKeyPair.!ret": { + "privateKey": "_modPow.!1", + "publicKey": "_publicKeyFromJwk.!ret" + }, + "forge.net.socketPools..sockets..options.request.getCookies.!ret": { + "": "http.withinCookieDomain.!1" + }, + "forge.net.socketPools..sockets..options.headerReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.net.socketPools..sockets..options.bodyReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.tls.hmac_sha1.!1": { + "1": "http.withinCookieDomain.!1" + }, + "forge.util.setItem.!3": { + "": { + "": "http.withinCookieDomain.!1" + } + }, + "forge.util.makeRequest.!ret.getQueryLast.!1": { + "": "util.makeRequest.!ret.getQueryLast.!1" + }, + "forge.util.deflate.!0": { + "encode": "api.encode", + "decode": "api.decode" + }, + "modes.cbc.prototype.start.!0": { + "output": "BlockCipher.start.!1" + }, + "modes.gcm.prototype.generateHashTable.!ret": { + "": { + "": "modes.gcm._m.." + } + }, + "modes.gcm.prototype.generateSubHashTable.!ret": { + "": "modes.gcm._m.." + }, + "BigInteger.prototype.divideAndRemainder.!ret": { + "": "+BigInteger" + }, + "http.createClient.!ret.send.!0": { + "request": "net.socketPools..sockets..options.request", + "bodyReady": "net.socketPools..sockets..options.bodyReady", + "error": "net.socketPools..sockets..options.error", + "headerReady": "_getStorageId.!0.send.!0.headerReady" + }, + "forge.pki.createCaStore.!ret": { + "certs": "_initSocket.!2.caStore.certs", + "getIssuer": "_initSocket.!2.caStore.getIssuer", + "addCertificate": "_initSocket.!2.caStore.addCertificate", + "hasCertificate": "_initSocket.!2.caStore.hasCertificate", + "listAllCertificates": "_initSocket.!2.caStore.listAllCertificates", + "removeCertificate": "_initSocket.!2.caStore.removeCertificate" + }, + "forge.mgf1.create.!ret": { + "generate": "mgf1.create.!ret.generate" + }, + "pki.setRsaPublicKey.!ret": { + "n": "+BigInteger", + "e": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger", + "encrypt": "_publicKeyFromJwk.!ret.encrypt", + "verify": "_publicKeyFromJwk.!ret.verify" + }, + "pki.certificationRequestFromPem.!ret.getAttribute.!0": { + "shortName": "_getAttribute.!1" + }, + "forge.pki.verifyCertificateChain.!2": { + "verify": "pki.verifyCertificateChain.!2.verify" + }, + "p12.pkcs12FromAsn1.!ret.getBags.!ret": { + "": "_getBagsByAttribute.!ret", + "localKeyId": "_getBagsByAttribute.!ret", + "friendlyName": "_getBagsByAttribute.!ret" + }, + "p12.pkcs12FromAsn1.!ret.getBagsByFriendlyName.!ret": { + "": "_getBagsByAttribute.!ret." + }, + "forge.pss.create.!ret": { + "encode": "pss.create.!ret.encode", + "verify": "pss.create.!ret.verify" + }, + "_getAttribute.!0.getAttribute.!0": { + "shortName": "_getAttribute.!1" + } + }, + "forge": { + "aes": { + "startEncrypting": { + "!type": "fn(key: ?, iv: ?, output: ?, mode: ?) -> ?|+BlockCipher", + "!span": "1267[44:10]-1282[44:25]", + "!doc": "Deprecated. Instead, use:\n\nvar cipher = forge.cipher.createCipher('AES-', key);\ncipher.start({iv: iv});\n\nCreates an AES cipher object to encrypt data using the given symmetric key.\nThe output will be stored in the 'output' member of the returned cipher.\n\nThe key and iv may be given as a string of bytes, an array of bytes,\na byte buffer, or an array of 32-bit words.\n\n@param key the symmetric key to use.\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "createEncryptionCipher": { + "!type": "fn(key: string|+ByteBuffer, mode: string) -> ?|+BlockCipher", + "!span": "1900[70:10]-1922[70:32]", + "!doc": "Deprecated. Instead, use:\n\nvar cipher = forge.cipher.createCipher('AES-', key);\n\nCreates an AES cipher object to encrypt data using the given symmetric key.\n\nThe key may be given as a string of bytes, an array of bytes, a\nbyte buffer, or an array of 32-bit words.\n\n@param key the symmetric key to use.\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "startDecrypting": { + "!type": "fn(key: ?, iv: ?, output: ?, mode: ?) -> ?|+BlockCipher", + "!span": "2707[98:10]-2722[98:25]", + "!doc": "Deprecated. Instead, use:\n\nvar decipher = forge.cipher.createDecipher('AES-', key);\ndecipher.start({iv: iv});\n\nCreates an AES cipher object to decrypt data using the given symmetric key.\nThe output will be stored in the 'output' member of the returned cipher.\n\nThe key and iv may be given as a string of bytes, an array of bytes,\na byte buffer, or an array of 32-bit words.\n\n@param key the symmetric key to use.\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "createDecryptionCipher": { + "!type": "fn(key: string|+ByteBuffer, mode: ?) -> ?|+BlockCipher", + "!span": "3343[124:10]-3365[124:32]", + "!doc": "Deprecated. Instead, use:\n\nvar decipher = forge.cipher.createDecipher('AES-', key);\n\nCreates an AES cipher object to decrypt data using the given symmetric key.\n\nThe key may be given as a string of bytes, an array of bytes, a\nbyte buffer, or an array of 32-bit words.\n\n@param key the symmetric key to use.\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "Algorithm": { + "prototype": { + "initialize": { + "!type": "fn(options: ?)", + "!span": "4425[169:30]-4435[169:40]", + "!doc": "Initializes this AES algorithm by expanding its key.\n\n@param options the options to use.\n key the key to use with this algorithm.\n decrypt true if the algorithm should be initialized for decryption,\n false for encryption." + } + }, + "!type": "fn(name: string, mode: fn(options: ?))", + "!span": "3682[141:10]-3691[141:19]", + "!doc": "Creates a new AES cipher algorithm object.\n\n@param name the name of the algorithm.\n@param mode the mode factory function.\n\n@return the AES algorithm object." + }, + "_expandKey": { + "!type": "fn(key: [?]|string, decrypt: bool) -> ?", + "!span": "6340[234:10]-6350[234:20]", + "!doc": "Expands a key. Typically only used for testing.\n\n@param key the symmetric key to expand, as an array of 32-bit words.\n@param decrypt true to expand for decryption, false for encryption.\n\n@return the expanded key." + }, + "!span": "591[23:23]-594[23:26]", + "!doc": "AES API", + "_updateBlock": "_updateBlock" + }, + "asn1": { + "Class": { + "UNIVERSAL": { + "!type": "number", + "!span": "6382[146:2]-6391[146:11]" + }, + "APPLICATION": { + "!type": "number", + "!span": "6408[147:2]-6419[147:13]" + }, + "CONTEXT_SPECIFIC": { + "!type": "number", + "!span": "6434[148:2]-6450[148:18]" + }, + "PRIVATE": { + "!type": "number", + "!span": "6460[149:2]-6467[149:9]" + } + }, + "Type": { + "NONE": { + "!type": "number", + "!span": "6646[157:2]-6650[157:6]" + }, + "BOOLEAN": { + "!type": "number", + "!span": "6669[158:2]-6676[158:9]" + }, + "INTEGER": { + "!type": "number", + "!span": "6692[159:2]-6699[159:9]" + }, + "BITSTRING": { + "!type": "number", + "!span": "6715[160:2]-6724[160:11]" + }, + "OCTETSTRING": { + "!type": "number", + "!span": "6738[161:2]-6749[161:13]" + }, + "NULL": { + "!type": "number", + "!span": "6761[162:2]-6765[162:6]" + }, + "OID": { + "!type": "number", + "!span": "6784[163:2]-6787[163:5]" + }, + "ODESC": { + "!type": "number", + "!span": "6807[164:2]-6812[164:7]" + }, + "EXTERNAL": { + "!type": "number", + "!span": "6830[165:2]-6838[165:10]" + }, + "REAL": { + "!type": "number", + "!span": "6853[166:2]-6857[166:6]" + }, + "ENUMERATED": { + "!type": "number", + "!span": "6876[167:2]-6886[167:12]" + }, + "EMBEDDED": { + "!type": "number", + "!span": "6899[168:2]-6907[168:10]" + }, + "UTF8": { + "!type": "number", + "!span": "6922[169:2]-6926[169:6]" + }, + "ROID": { + "!type": "number", + "!span": "6945[170:2]-6949[170:6]" + }, + "SEQUENCE": { + "!type": "number", + "!span": "6968[171:2]-6976[171:10]" + }, + "SET": { + "!type": "number", + "!span": "6991[172:2]-6994[172:5]" + }, + "PRINTABLESTRING": { + "!type": "number", + "!span": "7014[173:2]-7029[173:17]" + }, + "IA5STRING": { + "!type": "number", + "!span": "7037[174:2]-7046[174:11]" + }, + "UTCTIME": { + "!type": "number", + "!span": "7060[175:2]-7067[175:9]" + }, + "GENERALIZEDTIME": { + "!type": "number", + "!span": "7083[176:2]-7098[176:17]" + }, + "BMPSTRING": { + "!type": "number", + "!span": "7106[177:2]-7115[177:11]" + } + }, + "create": {}, + "validate": {}, + "prettyPrint": {}, + "copy": "asn1.copy", + "equals": "asn1.equals", + "getBerValueLength": "asn1.getBerValueLength", + "fromDer": "asn1.fromDer", + "toDer": "asn1.toDer", + "oidToDer": "asn1.oidToDer", + "derToOid": "asn1.derToOid", + "utcTimeToDate": "asn1.utcTimeToDate", + "generalizedTimeToDate": "asn1.generalizedTimeToDate", + "dateToUtcTime": "asn1.dateToUtcTime", + "dateToGeneralizedTime": "asn1.dateToGeneralizedTime", + "integerToDer": "asn1.integerToDer", + "derToInteger": "asn1.derToInteger" + }, + "cipher": { + "algorithms": { + "": { + "!type": "fn() -> +forge.des.Algorithm", + "!span": "2382[90:26]-2386[90:30]" + }, + "!span": "249[13:22]-259[13:32]", + "!doc": "registered algorithms" + }, + "createCipher": { + "!type": "fn(algorithm: string, key: string) -> +BlockCipher", + "!span": "781[30:15]-793[30:27]", + "!doc": "Creates a cipher object that can be used to encrypt data using the given\nalgorithm and key. The algorithm may be provided as a string value for a\npreviously registered algorithm or it may be given as a cipher algorithm\nAPI object.\n\n@param algorithm the algorithm to use, either a string or an algorithm API\n object.\n@param key the key to use, as a binary-encoded string of bytes or a\n byte buffer.\n\n@return the cipher." + }, + "createDecipher": { + "!type": "fn(algorithm: string, key: string) -> +BlockCipher", + "!span": "1658[67:0]-1672[69:10]", + "!doc": "Creates a decipher object that can be used to decrypt data using the given\nalgorithm and key. The algorithm may be provided as a string value for a\npreviously registered algorithm or it may be given as a cipher algorithm\nAPI object.\n\n@param algorithm the algorithm to use, either a string or an algorithm API\n object.\n@param key the key to use, as a binary-encoded string of bytes or a\n byte buffer.\n\n@return the cipher." + }, + "registerAlgorithm": { + "!type": "fn(name: string, algorithm: fn() -> +forge.des.Algorithm)", + "!span": "2279[87:29]-2296[88:8]", + "!doc": "Registers an algorithm by name. If the name was already registered, the\nalgorithm API object will be overwritten.\n\n@param name the name of the algorithm.\n@param algorithm the algorithm API object." + }, + "getAlgorithm": { + "!type": "fn(name: ?) -> fn() -> +forge.des.Algorithm", + "!span": "2563[102:30]-2575[102:42]", + "!doc": "Gets a registered algorithm by name.\n\n@param name the name of the algorithm.\n\n@return the algorithm, if found, null if not." + }, + "BlockCipher": { + "prototype": { + "start": "BlockCipher.prototype.start", + "update": "BlockCipher.prototype.update", + "finish": "BlockCipher.prototype.finish" + } + }, + "modes": { + "ecb": { + "prototype": { + "unpad": {}, + "start": "modes.ecb.prototype.start", + "encrypt": "modes.ecb.prototype.encrypt", + "decrypt": "modes.ecb.prototype.decrypt", + "pad": "modes.ecb.prototype.pad" + } + }, + "cfb": { + "prototype": { + "encrypt": {}, + "decrypt": {}, + "start": "modes.cfb.prototype.start" + } + }, + "ofb": { + "prototype": { + "encrypt": {}, + "decrypt": "modes.ofb.prototype.encrypt", + "start": "modes.ofb.prototype.start" + } + }, + "ctr": { + "prototype": { + "encrypt": {}, + "decrypt": "modes.ctr.prototype.encrypt", + "start": "modes.ctr.prototype.start" + } + }, + "gcm": { + "prototype": { + "encrypt": {}, + "generateHashTable": {}, + "generateSubHashTable": {}, + "start": "modes.gcm.prototype.start", + "decrypt": "modes.gcm.prototype.decrypt", + "afterFinish": "modes.gcm.prototype.afterFinish", + "multiply": "modes.gcm.prototype.multiply", + "pow": "modes.gcm.prototype.pow", + "tableMultiply": "modes.gcm.prototype.tableMultiply", + "ghash": "modes.gcm.prototype.ghash" + } + }, + "cbc": { + "prototype": { + "start": {}, + "encrypt": "modes.cbc.prototype.encrypt", + "decrypt": "modes.cbc.prototype.decrypt", + "pad": "modes.cbc.prototype.pad", + "unpad": "modes.cbc.prototype.unpad" + } + } + }, + "!span": "181[10:23]-187[10:29]" + }, + "des": { + "startEncrypting": { + "!type": "fn(key: ?, iv: ?, output: ?, mode: ?) -> ?|+BlockCipher", + "!span": "2115[59:10]-2130[59:25]", + "!doc": "Deprecated. Instead, use:\n\nvar cipher = forge.cipher.createCipher('DES-', key);\ncipher.start({iv: iv});\n\nCreates an DES cipher object to encrypt data using the given symmetric key.\nThe output will be stored in the 'output' member of the returned cipher.\n\nThe key and iv may be given as binary-encoded strings of bytes or\nbyte buffers.\n\n@param key the symmetric key to use (64 or 192 bits).\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n@param mode the cipher mode to use (default: 'CBC' if IV is\n given, 'ECB' if null).\n\n@return the cipher." + }, + "createEncryptionCipher": { + "!type": "fn(key: string|+ByteBuffer, mode: ?) -> ?|+BlockCipher", + "!span": "2764[84:10]-2786[84:32]", + "!doc": "Deprecated. Instead, use:\n\nvar cipher = forge.cipher.createCipher('DES-', key);\n\nCreates an DES cipher object to encrypt data using the given symmetric key.\n\nThe key may be given as a binary-encoded string of bytes or a byte buffer.\n\n@param key the symmetric key to use (64 or 192 bits).\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "startDecrypting": { + "!type": "fn(key: +ByteBuffer, iv: +ByteBuffer, output: ?, mode: ?) -> ?|+BlockCipher", + "!span": "3597[113:10]-3612[113:25]", + "!doc": "Deprecated. Instead, use:\n\nvar decipher = forge.cipher.createDecipher('DES-', key);\ndecipher.start({iv: iv});\n\nCreates an DES cipher object to decrypt data using the given symmetric key.\nThe output will be stored in the 'output' member of the returned cipher.\n\nThe key and iv may be given as binary-encoded strings of bytes or\nbyte buffers.\n\n@param key the symmetric key to use (64 or 192 bits).\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n@param mode the cipher mode to use (default: 'CBC' if IV is\n given, 'ECB' if null).\n\n@return the cipher." + }, + "createDecryptionCipher": { + "!type": "fn(key: string|+ByteBuffer, mode: ?) -> ?|+BlockCipher", + "!span": "4249[138:10]-4271[138:32]", + "!doc": "Deprecated. Instead, use:\n\nvar decipher = forge.cipher.createDecipher('DES-', key);\n\nCreates an DES cipher object to decrypt data using the given symmetric key.\n\nThe key may be given as a binary-encoded string of bytes or a byte buffer.\n\n@param key the symmetric key to use (64 or 192 bits).\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "Algorithm": { + "prototype": { + "initialize": { + "!type": "fn(options: ?)", + "!span": "5300[180:30]-5310[180:40]", + "!doc": "Initializes this DES algorithm by expanding its key.\n\n@param options the options to use.\n key the key to use with this algorithm.\n decrypt true if the algorithm should be initialized for decryption,\n false for encryption." + } + }, + "!type": "fn(name: string, mode: fn(options: ?))", + "!span": "4588[155:10]-4597[155:19]", + "!doc": "Creates a new DES cipher algorithm object.\n\n@param name the name of the algorithm.\n@param mode the mode factory function.\n\n@return the DES algorithm object.", + "_keys": { + "!type": "[number]", + "!span": "5647[193:7]-5652[193:12]", + "!doc": "do key expansion to 16 or 48 subkeys (single or triple DES)" + }, + "_init": { + "!type": "bool", + "!span": "5680[194:7]-5685[194:12]" + }, + "name": { + "!type": "string", + "!span": "4649[157:7]-4653[157:11]" + } + }, + "!span": "1413[37:23]-1416[37:26]", + "!doc": "DES API" + }, + "pki": { + "ed25519": { + "constants": { + "PUBLIC_KEY_BYTE_LENGTH": { + "!type": "number", + "!span": "1017[35:18]-1039[35:40]" + }, + "PRIVATE_KEY_BYTE_LENGTH": { + "!type": "number", + "!span": "1064[36:18]-1087[36:41]" + }, + "SEED_BYTE_LENGTH": { + "!type": "number", + "!span": "1112[37:18]-1128[37:34]" + }, + "SIGN_BYTE_LENGTH": { + "!type": "number", + "!span": "1153[38:18]-1169[38:34]" + }, + "HASH_BYTE_LENGTH": { + "!type": "number", + "!span": "1194[39:18]-1210[39:34]" + } + }, + "generateKeyPair": {}, + "privateKeyFromAsn1": "ed25519.privateKeyFromAsn1", + "publicKeyFromAsn1": "ed25519.publicKeyFromAsn1", + "publicKeyFromPrivateKey": "ed25519.publicKeyFromPrivateKey", + "sign": "ed25519.sign", + "verify": "ed25519.verify" + }, + "oids": { + "": { + "!type": "string", + "!span": "331[14:7]-333[14:9]" + } + }, + "pbe": { + "generatePkcs12Key": {}, + "opensslDeriveBytes": {}, + "getCipher": {}, + "getCipherForPBES2": "forge.pbe.getCipherForPBES2", + "getCipherForPKCS12PBE": "forge.pbe.getCipherForPKCS12PBE" + }, + "encryptPrivateKeyInfo": {}, + "encryptedPrivateKeyFromPem": {}, + "privateKeyFromPem": {}, + "rsa": { + "publicKeyValidator": { + "name": { + "!type": "string", + "!span": "6195[231:2]-6199[231:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6227[232:2]-6235[232:10]" + }, + "type": { + "!type": "number", + "!span": "6261[233:2]-6265[233:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6289[234:2]-6300[234:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6310[235:2]-6321[235:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6363[237:4]-6367[237:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6417[238:4]-6425[238:12]" + }, + "type": { + "!type": "number", + "!span": "6453[239:4]-6457[239:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6483[240:4]-6494[240:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6522[242:6]-6526[242:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6567[243:6]-6575[243:14]" + }, + "type": { + "!type": "number", + "!span": "6605[244:6]-6609[244:10]" + }, + "constructed": { + "!type": "bool", + "!span": "6632[245:6]-6643[245:17]" + }, + "capture": { + "!type": "string", + "!span": "6658[246:6]-6665[246:13]" + } + } + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6724[250:4]-6728[250:8]", + "!doc": "subjectPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6775[251:4]-6783[251:12]" + }, + "type": { + "!type": "number", + "!span": "6811[252:4]-6815[252:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6842[253:4]-6853[253:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6904[256:6]-6908[256:10]", + "!doc": "RSAPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6970[257:6]-6978[257:14]" + }, + "type": { + "!type": "number", + "!span": "7008[258:6]-7012[258:10]" + }, + "constructed": { + "!type": "bool", + "!span": "7040[259:6]-7051[259:17]" + }, + "optional": { + "!type": "bool", + "!span": "7065[260:6]-7073[260:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "7087[261:6]-7098[261:17]" + } + } + } + } + } + }, + "createKeyPairGenerationState": {}, + "generateKeyPair": {}, + "setPublicKey": "pki.setRsaPublicKey", + "setPrivateKey": "pki.setRsaPrivateKey", + "encrypt": "forge.rsa.encrypt", + "decrypt": "forge.rsa.decrypt", + "stepKeyPairGenerationState": "forge.rsa.stepKeyPairGenerationState" + }, + "RDNAttributesAsArray": {}, + "CRIAttributesAsArray": {}, + "certificateFromPem": {}, + "getPublicKeyFingerprint": {}, + "certificationRequestFromPem": {}, + "certificateExtensionsFromAsn1": {}, + "certificateExtensionFromAsn1": {}, + "certificateError": { + "bad_certificate": { + "!type": "string", + "!span": "88809[2935:2]-88824[2935:17]" + }, + "unsupported_certificate": { + "!type": "string", + "!span": "88856[2936:2]-88879[2936:25]" + }, + "certificate_revoked": { + "!type": "string", + "!span": "88919[2937:2]-88938[2937:21]" + }, + "certificate_expired": { + "!type": "string", + "!span": "88974[2938:2]-88993[2938:21]" + }, + "certificate_unknown": { + "!type": "string", + "!span": "89029[2939:2]-89048[2939:21]" + }, + "unknown_ca": { + "!type": "string", + "!span": "89084[2940:2]-89094[2940:12]" + } + }, + "setRsaPublicKey": {}, + "privateKeyToAsn1": "pki.privateKeyToRSAPrivateKey", + "publicKeyToAsn1": "pki.publicKeyToSubjectPublicKeyInfo", + "distinguishedNameToAsn1": {}, + "verifyCertificateChain": {}, + "createCaStore": {}, + "decryptPrivateKeyInfo": "pki.decryptPrivateKeyInfo", + "encryptedPrivateKeyToPem": "pki.encryptedPrivateKeyToPem", + "encryptRsaPrivateKey": "pki.encryptRsaPrivateKey", + "decryptRsaPrivateKey": "pki.decryptRsaPrivateKey", + "pemToDer": "pki.pemToDer", + "privateKeyToPem": "pki.privateKeyToPem", + "privateKeyInfoToPem": "pki.privateKeyInfoToPem", + "setRsaPrivateKey": "pki.setRsaPrivateKey", + "wrapRsaPrivateKey": "pki.wrapRsaPrivateKey", + "privateKeyFromAsn1": "pki.privateKeyFromAsn1", + "privateKeyToRSAPrivateKey": "pki.privateKeyToRSAPrivateKey", + "publicKeyFromAsn1": "pki.publicKeyFromAsn1", + "publicKeyToSubjectPublicKeyInfo": "pki.publicKeyToSubjectPublicKeyInfo", + "publicKeyToRSAPublicKey": "pki.publicKeyToRSAPublicKey", + "certificateToPem": "pki.certificateToPem", + "publicKeyFromPem": "pki.publicKeyFromPem", + "publicKeyToPem": "pki.publicKeyToPem", + "publicKeyToRSAPublicKeyPem": "pki.publicKeyToRSAPublicKeyPem", + "certificationRequestToPem": "pki.certificationRequestToPem", + "createCertificate": "pki.createCertificate", + "certificateFromAsn1": "pki.certificateFromAsn1", + "certificationRequestFromAsn1": "pki.certificationRequestFromAsn1", + "createCertificationRequest": "pki.createCertificationRequest", + "getTBSCertificate": "pki.getTBSCertificate", + "getCertificationRequestInfo": "pki.getCertificationRequestInfo", + "certificateToAsn1": "pki.certificateToAsn1", + "certificateExtensionsToAsn1": "pki.certificateExtensionsToAsn1", + "certificateExtensionToAsn1": "pki.certificateExtensionToAsn1", + "certificationRequestToAsn1": "pki.certificationRequestToAsn1" + }, + "ed25519": { + "constants": { + "PUBLIC_KEY_BYTE_LENGTH": { + "!type": "number", + "!span": "1017[35:18]-1039[35:40]" + }, + "PRIVATE_KEY_BYTE_LENGTH": { + "!type": "number", + "!span": "1064[36:18]-1087[36:41]" + }, + "SEED_BYTE_LENGTH": { + "!type": "number", + "!span": "1112[37:18]-1128[37:34]" + }, + "SIGN_BYTE_LENGTH": { + "!type": "number", + "!span": "1153[38:18]-1169[38:34]" + }, + "HASH_BYTE_LENGTH": { + "!type": "number", + "!span": "1194[39:18]-1210[39:34]" + } + }, + "generateKeyPair": {}, + "privateKeyFromAsn1": "ed25519.privateKeyFromAsn1", + "publicKeyFromAsn1": "ed25519.publicKeyFromAsn1", + "publicKeyFromPrivateKey": "ed25519.publicKeyFromPrivateKey", + "sign": "ed25519.sign", + "verify": "ed25519.verify" + }, + "jsbn": { + "BigInteger": { + "prototype": { + "DB": { + "!type": "number", + "!span": "4167[134:21]-4169[134:23]" + }, + "DM": { + "!type": "number", + "!span": "4200[135:21]-4202[135:23]" + }, + "DV": { + "!type": "number", + "!span": "4242[136:21]-4244[136:23]" + }, + "FV": { + "!type": "number", + "!span": "4297[139:21]-4299[139:23]" + }, + "F1": { + "!type": "number", + "!span": "4342[140:21]-4344[140:23]" + }, + "F2": { + "!type": "number", + "!span": "4381[141:21]-4383[141:23]" + }, + "divideAndRemainder": {}, + "am": "am1", + "copyTo": "bnpCopyTo", + "fromInt": "bnpFromInt", + "fromString": "bnpFromString", + "clamp": "bnpClamp", + "dlShiftTo": "bnpDLShiftTo", + "drShiftTo": "bnpDRShiftTo", + "lShiftTo": "bnpLShiftTo", + "rShiftTo": "bnpRShiftTo", + "subTo": "bnpSubTo", + "multiplyTo": "bnpMultiplyTo", + "squareTo": "bnpSquareTo", + "divRemTo": "bnpDivRemTo", + "invDigit": "bnpInvDigit", + "isEven": "bnpIsEven", + "exp": "bnpExp", + "toString": "bnToString", + "negate": "bnNegate", + "abs": "bnAbs", + "compareTo": "bnCompareTo", + "bitLength": "bnBitLength", + "mod": "bnMod", + "modPowInt": "bnModPowInt", + "chunkSize": "bnpChunkSize", + "toRadix": "bnpToRadix", + "fromRadix": "bnpFromRadix", + "fromNumber": "bnpFromNumber", + "bitwiseTo": "bnpBitwiseTo", + "changeBit": "bnpChangeBit", + "addTo": "bnpAddTo", + "dMultiply": "bnpDMultiply", + "dAddOffset": "bnpDAddOffset", + "multiplyLowerTo": "bnpMultiplyLowerTo", + "multiplyUpperTo": "bnpMultiplyUpperTo", + "modInt": "bnpModInt", + "millerRabin": "bnpMillerRabin", + "clone": "bnClone", + "intValue": "bnIntValue", + "byteValue": "bnByteValue", + "shortValue": "bnShortValue", + "signum": "bnSigNum", + "toByteArray": "bnToByteArray", + "equals": "bnEquals", + "min": "bnMin", + "max": "bnMax", + "and": "bnAnd", + "or": "bnOr", + "xor": "bnXor", + "andNot": "bnAndNot", + "not": "bnNot", + "shiftLeft": "bnShiftLeft", + "shiftRight": "bnShiftRight", + "getLowestSetBit": "bnGetLowestSetBit", + "bitCount": "bnBitCount", + "testBit": "bnTestBit", + "setBit": "bnSetBit", + "clearBit": "bnClearBit", + "flipBit": "bnFlipBit", + "add": "bnAdd", + "subtract": "bnSubtract", + "multiply": "bnMultiply", + "divide": "bnDivide", + "remainder": "bnRemainder", + "modPow": "bnModPow", + "modInverse": "bnModInverse", + "pow": "bnPow", + "gcd": "bnGCD", + "isProbablePrime": "bnIsProbablePrime" + }, + "ONE": "+BigInteger", + "ZERO": "+BigInteger" + }, + "!span": "1779[50:23]-1783[50:27]" + }, + "kem": { + "rsa": { + "create": { + "!type": "fn(kdf: ?, options: ?) -> forge.kem.rsa.create.!ret", + "!span": "1193[37:14]-1199[37:20]", + "!doc": "Creates an RSA KEM API object for generating a secret asymmetric key.\n\nThe symmetric key may be generated via a call to 'encrypt', which will\nproduce a ciphertext to be transmitted to the recipient and a key to be\nkept secret. The ciphertext is a parameter to be passed to 'decrypt' which\nwill produce the same secret key for the recipient to use to decrypt a\nmessage that was encrypted with the secret key.\n\n@param kdf the KDF API to use (eg: new forge.kem.kdf1()).\n@param options the options to use.\n [prng] a custom crypto-secure pseudo-random number generator to use,\n that must define \"getBytesSync\"." + }, + "!span": "502[21:10]-505[21:13]", + "!doc": "The API for the RSA Key Encapsulation Mechanism (RSA-KEM) from ISO 18033-2." + }, + "kdf1": { + "!type": "fn(md: ?, digestLength: ?)", + "!span": "3474[110:10]-3478[110:14]", + "!doc": "Creates a key derivation API object that implements KDF1 per ISO 18033-2.\n\n@param md the hash API to use.\n@param [digestLength] an optional digest length that must be positive and\n less than or equal to md.digestLength.\n\n@return a KDF1 API object." + }, + "kdf2": { + "!type": "fn(md: ?, digestLength: ?)", + "!span": "3867[123:10]-3871[123:14]", + "!doc": "Creates a key derivation API object that implements KDF2 per ISO 18033-2.\n\n@param md the hash API to use.\n@param [digestLength] an optional digest length that must be positive and\n less than or equal to md.digestLength.\n\n@return a KDF2 API object." + }, + "generate": { + "!type": "fn(x: ?, length: ?) -> ?", + "!span": "4516[145:6]-4524[145:14]", + "!doc": "Generate a key of the specified length.\n\n@param x the binary-encoded byte string to generate a key from.\n@param length the number of bytes to generate (the size of the key).\n\n@return the key as a binary-encoded string." + }, + "!span": "340[14:23]-343[14:26]" + }, + "md": { + "algorithms": { + "sha256": { + "create": {} + }, + "!span": "213[10:9]-223[10:19]", + "md5": { + "create": "md5.create" + }, + "sha1": { + "create": "sha1.create" + }, + "sha384": { + "create": "sha384.create" + }, + "sha512/256": { + "create": "forge.md.sha512/256.create" + }, + "sha512/224": { + "create": "forge.md.sha512/224.create" + } + }, + "sha256": { + "create": {} + }, + "sha512/256": { + "create": { + "!type": "fn() -> _createKDF.!1", + "!span": "787[30:2]-793[30:8]" + }, + "!span": "865[34:9]-877[34:21]", + "!doc": "SHA-512/256" + }, + "sha512/224": { + "create": { + "!type": "fn() -> _createKDF.!1", + "!span": "1005[39:2]-1011[39:8]" + }, + "!span": "1083[43:9]-1095[43:21]", + "!doc": "SHA-512/224" + }, + "!span": "183[9:23]-185[9:25]", + "md5": { + "create": "md5.create" + }, + "sha1": { + "create": "sha1.create" + }, + "sha384": { + "create": "sha384.create" + } + }, + "md5": { + "create": {} + }, + "mgf": { + "!span": "222[10:23]-225[10:26]", + "mgf1": { + "create": {} + } + }, + "oids": { + "": { + "!type": "string", + "!span": "331[14:7]-333[14:9]" + } + }, + "pbe": { + "getCipher": { + "!type": "fn(oid: string, params: ?, password: bool|string) -> ?", + "!span": "22714[753:8]-22723[753:17]", + "!doc": "Get new Forge cipher object instance.\n\n@param oid the OID (in string notation).\n@param params the ASN.1 params object.\n@param password the password to decrypt with.\n\n@return new cipher object instance." + }, + "getCipherForPBES2": { + "!type": "fn(oid: string, params: ?, password: bool|string) -> ?|+BlockCipher", + "!span": "23692[786:8]-23709[786:25]", + "!doc": "Get new Forge cipher object instance according to PBES2 params block.\n\nThe returned cipher instance is already started using the IV\nfrom PBES2 parameter block.\n\n@param oid the PKCS#5 PBKDF2 OID (in string notation).\n@param params the ASN.1 PBES2-params object.\n@param password the password to decrypt with.\n\n@return new cipher object instance." + }, + "getCipherForPKCS12PBE": { + "!type": "fn(oid: string, params: ?, password: bool|string) -> ?", + "!span": "26289[873:8]-26310[873:29]", + "!doc": "Get new Forge cipher object instance for PKCS#12 PBE.\n\nThe returned cipher instance is already started using the key & IV\nderived from the provided password and PKCS#12 PBE salt.\n\n@param oid The PKCS#12 PBE OID (in string notation).\n@param params The ASN.1 PKCS#12 PBE-params object.\n@param password The password to decrypt with.\n\n@return the new cipher object instance." + }, + "opensslDeriveBytes": { + "!type": "fn(password: ?, salt: string, dkLen: number, md: hash.!0) -> string", + "!span": "28120[932:8]-28138[932:26]", + "!doc": "OpenSSL's legacy key derivation function.\n\nSee: http://www.openssl.org/docs/crypto/EVP_BytesToKey.html\n\n@param password the password to derive the key from.\n@param salt the salt to use, null for none.\n@param dkLen the number of bytes needed for the derived key.\n@param [options] the options to use:\n [md] an optional message digest object to use." + }, + "!span": "1000[41:33]-1003[41:36]", + "generatePkcs12Key": "p12.generateKey" + }, + "pbkdf2": { + "!type": "fn(p: bool|string, s: ?, c: number|+ByteBuffer, dkLen: number, md: string, callback: string) -> !4.!ret", + "!span": "1164[37:23]-1170[37:29]", + "!doc": "Derives a key from a password.\n\n@param p the password as a binary-encoded string of bytes.\n@param s the salt as a binary-encoded string of bytes.\n@param c the iteration count, a positive integer.\n@param dkLen the intended length, in bytes, of the derived key,\n (max: 2^32 - 1) * hash length of the PRF.\n@param [md] the message digest (or algorithm identifier as a string) to use\n in the PRF, defaults to SHA-1.\n@param [callback(err, key)] presence triggers asynchronous version, called\n once the operation completes.\n\n@return the derived key, as a binary-encoded string of bytes, for the\n synchronous version (if no callback is specified)." + }, + "pem": { + "encode": {}, + "decode": {} + }, + "pkcs12": { + "pkcs12FromAsn1": {}, + "toPkcs12Asn1": {}, + "generateKey": "p12.generateKey" + }, + "pkcs7": { + "messageFromPem": {}, + "createSignedData": {}, + "createEncryptedData": {}, + "asn1": { + "contentInfoValidator": { + "name": { + "!type": "string", + "!span": "3698[122:2]-3702[122:6]" + }, + "tagClass": { + "!type": "number", + "!span": "3721[123:2]-3729[123:10]" + }, + "type": { + "!type": "number", + "!span": "3755[124:2]-3759[124:6]" + }, + "constructed": { + "!type": "bool", + "!span": "3783[125:2]-3794[125:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "3818[127:4]-3822[127:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3855[128:4]-3863[128:12]" + }, + "type": { + "!type": "number", + "!span": "3891[129:4]-3895[129:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3916[130:4]-3927[130:15]" + }, + "capture": { + "!type": "string", + "!span": "3940[131:4]-3947[131:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "3974[133:4]-3978[133:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4007[134:4]-4015[134:12]" + }, + "type": { + "!type": "number", + "!span": "4050[135:4]-4054[135:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4063[136:4]-4074[136:15]" + }, + "optional": { + "!type": "bool", + "!span": "4086[137:4]-4094[137:12]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4106[138:4]-4117[138:15]" + } + } + } + }, + "envelopedDataValidator": { + "name": { + "!type": "string", + "!span": "6095[206:2]-6099[206:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6120[207:2]-6128[207:10]" + }, + "type": { + "!type": "number", + "!span": "6154[208:2]-6158[208:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6182[209:2]-6193[209:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6217[211:4]-6221[211:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6252[212:4]-6260[212:12]" + }, + "type": { + "!type": "number", + "!span": "6288[213:4]-6292[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6317[214:4]-6328[214:15]" + }, + "capture": { + "!type": "string", + "!span": "6341[215:4]-6348[215:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6371[217:4]-6375[217:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6413[218:4]-6421[218:12]" + }, + "type": { + "!type": "number", + "!span": "6449[219:4]-6453[219:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6474[220:4]-6485[220:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6497[221:4]-6508[221:15]" + } + } + } + }, + "encryptedDataValidator": { + "name": { + "!type": "string", + "!span": "6607[226:2]-6611[226:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6632[227:2]-6640[227:10]" + }, + "type": { + "!type": "number", + "!span": "6666[228:2]-6670[228:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6694[229:2]-6705[229:13]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6729[231:4]-6733[231:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6764[232:4]-6772[232:12]" + }, + "type": { + "!type": "number", + "!span": "6800[233:4]-6804[233:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6829[234:4]-6840[234:15]" + }, + "capture": { + "!type": "string", + "!span": "6853[235:4]-6860[235:11]" + } + } + } + }, + "signedDataValidator": { + "name": { + "!type": "string", + "!span": "9001[315:2]-9005[315:6]" + }, + "tagClass": { + "!type": "number", + "!span": "9023[316:2]-9031[316:10]" + }, + "type": { + "!type": "number", + "!span": "9057[317:2]-9061[317:6]" + }, + "constructed": { + "!type": "bool", + "!span": "9085[318:2]-9096[318:13]" + }, + "value": { + "": "contentInfoValidator" + } + }, + "recipientInfoValidator": { + "name": { + "!type": "string", + "!span": "9987[356:2]-9991[356:6]" + }, + "tagClass": { + "!type": "number", + "!span": "10012[357:2]-10020[357:10]" + }, + "type": { + "!type": "number", + "!span": "10046[358:2]-10050[358:6]" + }, + "constructed": { + "!type": "bool", + "!span": "10074[359:2]-10085[359:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10109[361:4]-10113[361:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10144[362:4]-10152[362:12]" + }, + "type": { + "!type": "number", + "!span": "10180[363:4]-10184[363:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10209[364:4]-10220[364:15]" + }, + "capture": { + "!type": "string", + "!span": "10233[365:4]-10240[365:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "10263[367:4]-10267[367:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10306[368:4]-10314[368:12]" + }, + "type": { + "!type": "number", + "!span": "10342[369:4]-10346[369:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10372[370:4]-10383[370:15]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10411[372:6]-10415[372:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10463[373:6]-10471[373:14]" + }, + "type": { + "!type": "number", + "!span": "10501[374:6]-10505[374:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10533[375:6]-10544[375:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "10558[376:6]-10569[376:17]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "10595[378:6]-10599[378:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10653[379:6]-10661[379:14]" + }, + "type": { + "!type": "number", + "!span": "10691[380:6]-10695[380:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10722[381:6]-10733[381:17]" + }, + "capture": { + "!type": "string", + "!span": "10748[382:6]-10755[382:13]" + } + } + } + }, + "2": { + "name": { + "!type": "string", + "!span": "10784[385:4]-10788[385:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10834[386:4]-10842[386:12]" + }, + "type": { + "!type": "number", + "!span": "10870[387:4]-10874[387:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10900[388:4]-10911[388:15]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10939[390:6]-10943[390:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11001[391:6]-11009[391:14]" + }, + "type": { + "!type": "number", + "!span": "11039[392:6]-11043[392:10]" + }, + "constructed": { + "!type": "bool", + "!span": "11066[393:6]-11077[393:17]" + }, + "capture": { + "!type": "string", + "!span": "11092[394:6]-11099[394:13]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "11131[396:6]-11135[396:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11193[397:6]-11201[397:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11231[398:6]-11242[398:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "11257[399:6]-11268[399:17]" + } + } + } + }, + "3": { + "name": { + "!type": "string", + "!span": "11303[402:4]-11307[402:8]" + }, + "tagClass": { + "!type": "number", + "!span": "11343[403:4]-11351[403:12]" + }, + "type": { + "!type": "number", + "!span": "11379[404:4]-11383[404:8]" + }, + "constructed": { + "!type": "bool", + "!span": "11412[405:4]-11423[405:15]" + }, + "capture": { + "!type": "string", + "!span": "11436[406:4]-11443[406:11]" + } + } + } + } + }, + "messageToPem": "p7.messageToPem", + "messageFromAsn1": "p7.messageFromAsn1", + "createEnvelopedData": "p7.createEnvelopedData" + }, + "pkcs7asn1": { + "contentInfoValidator": { + "name": { + "!type": "string", + "!span": "3698[122:2]-3702[122:6]" + }, + "tagClass": { + "!type": "number", + "!span": "3721[123:2]-3729[123:10]" + }, + "type": { + "!type": "number", + "!span": "3755[124:2]-3759[124:6]" + }, + "constructed": { + "!type": "bool", + "!span": "3783[125:2]-3794[125:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "3818[127:4]-3822[127:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3855[128:4]-3863[128:12]" + }, + "type": { + "!type": "number", + "!span": "3891[129:4]-3895[129:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3916[130:4]-3927[130:15]" + }, + "capture": { + "!type": "string", + "!span": "3940[131:4]-3947[131:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "3974[133:4]-3978[133:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4007[134:4]-4015[134:12]" + }, + "type": { + "!type": "number", + "!span": "4050[135:4]-4054[135:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4063[136:4]-4074[136:15]" + }, + "optional": { + "!type": "bool", + "!span": "4086[137:4]-4094[137:12]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4106[138:4]-4117[138:15]" + } + } + } + }, + "envelopedDataValidator": { + "name": { + "!type": "string", + "!span": "6095[206:2]-6099[206:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6120[207:2]-6128[207:10]" + }, + "type": { + "!type": "number", + "!span": "6154[208:2]-6158[208:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6182[209:2]-6193[209:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6217[211:4]-6221[211:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6252[212:4]-6260[212:12]" + }, + "type": { + "!type": "number", + "!span": "6288[213:4]-6292[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6317[214:4]-6328[214:15]" + }, + "capture": { + "!type": "string", + "!span": "6341[215:4]-6348[215:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6371[217:4]-6375[217:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6413[218:4]-6421[218:12]" + }, + "type": { + "!type": "number", + "!span": "6449[219:4]-6453[219:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6474[220:4]-6485[220:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6497[221:4]-6508[221:15]" + } + } + } + }, + "encryptedDataValidator": { + "name": { + "!type": "string", + "!span": "6607[226:2]-6611[226:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6632[227:2]-6640[227:10]" + }, + "type": { + "!type": "number", + "!span": "6666[228:2]-6670[228:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6694[229:2]-6705[229:13]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6729[231:4]-6733[231:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6764[232:4]-6772[232:12]" + }, + "type": { + "!type": "number", + "!span": "6800[233:4]-6804[233:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6829[234:4]-6840[234:15]" + }, + "capture": { + "!type": "string", + "!span": "6853[235:4]-6860[235:11]" + } + } + } + }, + "signedDataValidator": { + "name": { + "!type": "string", + "!span": "9001[315:2]-9005[315:6]" + }, + "tagClass": { + "!type": "number", + "!span": "9023[316:2]-9031[316:10]" + }, + "type": { + "!type": "number", + "!span": "9057[317:2]-9061[317:6]" + }, + "constructed": { + "!type": "bool", + "!span": "9085[318:2]-9096[318:13]" + }, + "value": { + "": "contentInfoValidator" + } + }, + "recipientInfoValidator": { + "name": { + "!type": "string", + "!span": "9987[356:2]-9991[356:6]" + }, + "tagClass": { + "!type": "number", + "!span": "10012[357:2]-10020[357:10]" + }, + "type": { + "!type": "number", + "!span": "10046[358:2]-10050[358:6]" + }, + "constructed": { + "!type": "bool", + "!span": "10074[359:2]-10085[359:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10109[361:4]-10113[361:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10144[362:4]-10152[362:12]" + }, + "type": { + "!type": "number", + "!span": "10180[363:4]-10184[363:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10209[364:4]-10220[364:15]" + }, + "capture": { + "!type": "string", + "!span": "10233[365:4]-10240[365:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "10263[367:4]-10267[367:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10306[368:4]-10314[368:12]" + }, + "type": { + "!type": "number", + "!span": "10342[369:4]-10346[369:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10372[370:4]-10383[370:15]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10411[372:6]-10415[372:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10463[373:6]-10471[373:14]" + }, + "type": { + "!type": "number", + "!span": "10501[374:6]-10505[374:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10533[375:6]-10544[375:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "10558[376:6]-10569[376:17]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "10595[378:6]-10599[378:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10653[379:6]-10661[379:14]" + }, + "type": { + "!type": "number", + "!span": "10691[380:6]-10695[380:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10722[381:6]-10733[381:17]" + }, + "capture": { + "!type": "string", + "!span": "10748[382:6]-10755[382:13]" + } + } + } + }, + "2": { + "name": { + "!type": "string", + "!span": "10784[385:4]-10788[385:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10834[386:4]-10842[386:12]" + }, + "type": { + "!type": "number", + "!span": "10870[387:4]-10874[387:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10900[388:4]-10911[388:15]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10939[390:6]-10943[390:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11001[391:6]-11009[391:14]" + }, + "type": { + "!type": "number", + "!span": "11039[392:6]-11043[392:10]" + }, + "constructed": { + "!type": "bool", + "!span": "11066[393:6]-11077[393:17]" + }, + "capture": { + "!type": "string", + "!span": "11092[394:6]-11099[394:13]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "11131[396:6]-11135[396:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11193[397:6]-11201[397:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11231[398:6]-11242[398:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "11257[399:6]-11268[399:17]" + } + } + } + }, + "3": { + "name": { + "!type": "string", + "!span": "11303[402:4]-11307[402:8]" + }, + "tagClass": { + "!type": "number", + "!span": "11343[403:4]-11351[403:12]" + }, + "type": { + "!type": "number", + "!span": "11379[404:4]-11383[404:8]" + }, + "constructed": { + "!type": "bool", + "!span": "11412[405:4]-11423[405:15]" + }, + "capture": { + "!type": "string", + "!span": "11436[406:4]-11443[406:11]" + } + } + } + } + }, + "prime": { + "generateProbablePrime": { + "!type": "fn(bits: number, options: forge.prime.generateProbablePrime.!1, callback: forge.prime.generateProbablePrime.!1|fn(err: ?, num: +BigInteger))", + "!span": "1765[60:6]-1786[60:27]", + "!doc": "Generates a random probable prime with the given number of bits.\n\nAlternative algorithms can be specified by name as a string or as an\nobject with custom options like so:\n\n{\n name: 'PRIMEINC',\n options: {\n maxBlockTime: ,\n millerRabinTests: ,\n workerScript: ,\n workers: .\n workLoad: the size of the work load, ie: number of possible prime\n numbers for each web worker to check per work assignment,\n (default: 100).\n }\n}\n\n@param bits the number of bits for the prime number.\n@param options the options to use.\n [algorithm] the algorithm to use (default: 'PRIMEINC').\n [prng] a custom crypto-secure pseudo-random number generator to use,\n that must define \"getBytesSync\".\n\n@return callback(err, num) called once the operation completes." + }, + "!span": "365[21:35]-370[21:40]", + "!doc": "PRIME API" + }, + "prng": { + "create": {} + }, + "random": { + "plugin": { + "formatKey": { + "!type": "fn(key: ?) -> ?", + "!span": "1046[35:9]-1055[35:18]" + }, + "formatSeed": { + "!type": "fn(seed: ?) -> [number|_fromDer.!ret]", + "!span": "1373[47:9]-1383[47:19]" + }, + "cipher": { + "!type": "fn(key: ?, seed: [number|_fromDer.!ret]) -> ?", + "!span": "1647[57:9]-1653[57:15]" + }, + "increment": { + "!type": "fn(seed: [number|_fromDer.!ret]) -> !0", + "!span": "1990[65:9]-1999[65:18]" + }, + "!span": "1382[43:4]-1388[43:10]", + "md": "sha256" + }, + "seed": { + "!type": "[number|_fromDer.!ret]", + "!span": "1417[45:4]-1421[45:8]" + }, + "reseeds": { + "!type": "number", + "!span": "1481[48:4]-1488[48:11]", + "!doc": "update reseed count" + }, + "generated": { + "!type": "number", + "!span": "1536[50:4]-1545[50:13]", + "!doc": "amount of data generated so far" + }, + "keyBytes": { + "!type": "string", + "!span": "1582[52:4]-1590[52:12]", + "!doc": "get digest for key bytes" + }, + "pools": { + "!type": "[forge.random.pools.]", + "!span": "1778[61:6]-1783[61:11]" + }, + "pool": { + "!type": "number", + "!span": "1866[64:6]-1870[64:10]", + "!doc": "entropy pools are written to cyclically, starting at index 0" + }, + "generate": { + "!type": "fn(count: number|string, callback: ?) -> ?", + "!span": "2262[76:6]-2270[76:14]", + "!doc": "Generates random bytes. The bytes may be generated synchronously or\nasynchronously. Web workers must use the asynchronous interface or\nelse the behavior is undefined.\n\n@param count the number of random bytes to generate.\n@param [callback(err, bytes)] called once the operation completes.\n\n@return count random bytes as a string." + }, + "generateSync": { + "!type": "fn(count: number|string) -> ?", + "!span": "3996[140:6]-4008[140:18]", + "!doc": "Generates random bytes synchronously.\n\n@param count the number of random bytes to generate.\n\n@return count random bytes as a string." + }, + "seedFile": { + "!type": "fn(needed: number, callback: fn(err: ?, bytes: ?))", + "!span": "9685[329:8]-9693[329:16]", + "!doc": "use nodejs async API" + }, + "seedFileSync": { + "!type": "fn(needed: number) -> ?", + "!span": "9936[338:8]-9948[338:20]", + "!doc": "use nodejs sync API" + }, + "collect": { + "!type": "fn(bytes: ?)", + "!span": "10372[357:6]-10379[357:13]", + "!doc": "Adds entropy to a prng ctx's accumulator.\n\n@param bytes the bytes of entropy as a string." + }, + "collectInt": { + "!type": "fn(i: number, n: number)", + "!span": "10789[372:6]-10799[372:16]", + "!doc": "Collects an integer of n bits.\n\n@param i the integer entropy.\n@param n the number of bits in the integer." + }, + "registerWorker": { + "!type": "fn(worker: ?)", + "!span": "11316[388:6]-11330[388:20]", + "!doc": "Registers a Web Worker to receive immediate entropy from the main thread.\nThis method is required until Web Workers can access the native crypto\nAPI. This method should be called twice for each created worker, once in\nthe main thread, and once in the worker itself.\n\n@param worker the worker to register." + }, + "getBytes": { + "!type": "fn(count: number, callback: ?) -> ?", + "!span": "2732[90:6]-2740[90:14]", + "!doc": "Gets random bytes. If a native secure crypto API is unavailable, this\nmethod tries to make the bytes more unpredictable by drawing from data that\ncan be collected from the user of the browser, eg: mouse movement.\n\nIf a callback is given, this method will be called asynchronously.\n\n@param count the number of random bytes to get.\n@param [callback(err, bytes)] called once the operation completes.\n\n@return the random bytes in a string." + }, + "getBytesSync": { + "!type": "fn(count: number|string) -> ?", + "!span": "3191[104:6]-3203[104:18]", + "!doc": "Gets random bytes asynchronously. If a native secure crypto API is\nunavailable, this method tries to make the bytes more unpredictable by\ndrawing from data that can be collected from the user of the browser,\neg: mouse movement.\n\n@param count the number of random bytes to get.\n\n@return the random bytes in a string." + }, + "createInstance": { + "!type": "fn() -> forge.random", + "!span": "5318[184:13]-5332[184:27]", + "!doc": "expose spawn PRNG" + }, + "!span": "5158[175:8]-5164[175:14]" + }, + "rc2": { + "expandKey": { + "!type": "fn(key: string|+ByteBuffer, effKeyBits: number) -> !0", + "!span": "2951[72:10]-2960[72:19]", + "!doc": "Perform RC2 key expansion as per RFC #2268, section 2.\n\n@param key variable-length user key (between 1 and 128 bytes)\n@param effKeyBits number of effective key bits (default: 128)\n@return the expanded RC2 key (ByteBuffer of 128 bytes)" + }, + "startEncrypting": { + "!type": "fn(key: ?, iv: ?, output: ?) -> createCipher.!ret", + "!span": "10256[351:10]-10271[351:25]", + "!doc": "Creates an RC2 cipher object to encrypt data in ECB or CBC mode using the\ngiven symmetric key. The output will be stored in the 'output' member\nof the returned cipher.\n\nThe key and iv may be given as a string of bytes or a byte buffer.\nThe cipher is initialized to use 128 effective key bits.\n\n@param key the symmetric key to use.\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n\n@return the cipher." + }, + "createEncryptionCipher": { + "!type": "fn(key: ?, bits: number) -> createCipher.!ret", + "!span": "10759[370:10]-10781[370:32]", + "!doc": "Creates an RC2 cipher object to encrypt data in ECB or CBC mode using the\ngiven symmetric key.\n\nThe key may be given as a string of bytes or a byte buffer.\n\nTo start encrypting call start() on the cipher with an iv and optional\noutput buffer.\n\n@param key the symmetric key to use.\n\n@return the cipher." + }, + "startDecrypting": { + "!type": "fn(key: ?, iv: ?, output: ?) -> createCipher.!ret", + "!span": "11355[388:10]-11370[388:25]", + "!doc": "Creates an RC2 cipher object to decrypt data in ECB or CBC mode using the\ngiven symmetric key. The output will be stored in the 'output' member\nof the returned cipher.\n\nThe key and iv may be given as a string of bytes or a byte buffer.\nThe cipher is initialized to use 128 effective key bits.\n\n@param key the symmetric key to use.\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n\n@return the cipher." + }, + "createDecryptionCipher": { + "!type": "fn(key: string, bits: number) -> createCipher.!ret", + "!span": "11858[407:10]-11880[407:32]", + "!doc": "Creates an RC2 cipher object to decrypt data in ECB or CBC mode using the\ngiven symmetric key.\n\nThe key may be given as a string of bytes or a byte buffer.\n\nTo start decrypting call start() on the cipher with an iv and optional\noutput buffer.\n\n@param key the symmetric key to use.\n\n@return the cipher." + }, + "!span": "2660[63:23]-2663[63:26]", + "!doc": "RC2 API" + }, + "rsa": { + "publicKeyValidator": { + "name": { + "!type": "string", + "!span": "6195[231:2]-6199[231:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6227[232:2]-6235[232:10]" + }, + "type": { + "!type": "number", + "!span": "6261[233:2]-6265[233:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6289[234:2]-6300[234:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6310[235:2]-6321[235:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6363[237:4]-6367[237:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6417[238:4]-6425[238:12]" + }, + "type": { + "!type": "number", + "!span": "6453[239:4]-6457[239:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6483[240:4]-6494[240:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6522[242:6]-6526[242:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6567[243:6]-6575[243:14]" + }, + "type": { + "!type": "number", + "!span": "6605[244:6]-6609[244:10]" + }, + "constructed": { + "!type": "bool", + "!span": "6632[245:6]-6643[245:17]" + }, + "capture": { + "!type": "string", + "!span": "6658[246:6]-6665[246:13]" + } + } + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6724[250:4]-6728[250:8]", + "!doc": "subjectPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6775[251:4]-6783[251:12]" + }, + "type": { + "!type": "number", + "!span": "6811[252:4]-6815[252:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6842[253:4]-6853[253:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6904[256:6]-6908[256:10]", + "!doc": "RSAPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6970[257:6]-6978[257:14]" + }, + "type": { + "!type": "number", + "!span": "7008[258:6]-7012[258:10]" + }, + "constructed": { + "!type": "bool", + "!span": "7040[259:6]-7051[259:17]" + }, + "optional": { + "!type": "bool", + "!span": "7065[260:6]-7073[260:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "7087[261:6]-7098[261:17]" + } + } + } + } + } + }, + "encrypt": { + "!type": "fn(m: string|+ByteBuffer, key: _publicKeyFromJwk.!ret|_modPow.!1, bt: bool|number) -> ?", + "!span": "14183[479:8]-14190[479:15]", + "!doc": "NOTE: THIS METHOD IS DEPRECATED, use 'sign' on a private key object or\n'encrypt' on a public key object instead.\n\nPerforms RSA encryption.\n\nThe parameter bt controls whether to put padding bytes before the\nmessage passed in. Set bt to either true or false to disable padding\ncompletely (in order to handle e.g. EMSA-PSS encoding seperately before),\nsignaling whether the encryption operation is a public key operation\n(i.e. encrypting data) or not, i.e. private key operation (data signing).\n\nFor PKCS#1 v1.5 padding pass in the block type to use, i.e. either 0x01\n(for signing) or 0x02 (for encryption). The key operation mode (private\nor public) is derived from this flag in that case).\n\n@param m the message to encrypt as a byte string.\n@param key the RSA key to use.\n@param bt for PKCS#1 v1.5 padding, the block type to use\n (0x01 for private key, 0x02 for public),\n to disable padding: true = public key, false = private key.\n\n@return the encrypted bytes as a string." + }, + "decrypt": { + "!type": "fn(ed: ?, key: _publicKeyFromJwk.!ret|_modPow.!1, pub: bool, ml: bool) -> ?", + "!span": "15898[534:8]-15905[534:15]", + "!doc": "NOTE: THIS METHOD IS DEPRECATED, use 'decrypt' on a private key object or\n'verify' on a public key object instead.\n\nPerforms RSA decryption.\n\nThe parameter ml controls whether to apply PKCS#1 v1.5 padding\nor not. Set ml = false to disable padding removal completely\n(in order to handle e.g. EMSA-PSS later on) and simply pass back\nthe RSA encryption block.\n\n@param ed the encrypted data to decrypt in as a byte string.\n@param key the RSA key to use.\n@param pub true for a public key operation, false for private.\n@param ml the message length, if known, false to disable padding.\n\n@return the decrypted message as a byte string." + }, + "createKeyPairGenerationState": { + "!type": "fn(bits: number, e: number, options: ?|number) -> _generateKeyPair.!0", + "!span": "17910[594:8]-17938[594:36]", + "!doc": "Creates an RSA key-pair generation state object. It is used to allow\nkey-generation to be performed in steps. It also allows for a UI to\ndisplay progress updates.\n\n@param bits the size for the private key in bits, defaults to 2048.\n@param e the public exponent to use, defaults to 65537 (0x10001).\n@param [options] the options to use.\n prng a custom crypto-secure pseudo-random number generator to use,\n that must define \"getBytesSync\".\n algorithm the algorithm to use (default: 'PRIMEINC').\n\n@return the state object to use to generate the key-pair." + }, + "stepKeyPairGenerationState": { + "!type": "fn(state: _generateKeyPair.!0, n: number) -> bool", + "!span": "20210[673:8]-20236[673:34]", + "!doc": "Attempts to runs the key-generation algorithm for at most n seconds\n(approximately) using the given state. When key-generation has completed,\nthe keys will be stored in state.keys.\n\nTo use this function to update a UI while generating a key or to prevent\ncausing browser lockups/warnings, set \"n\" to a value other than 0. A\nsimple pattern for generating a key and showing a progress indicator is:\n\nvar state = pki.rsa.createKeyPairGenerationState(2048);\nvar step = function() {\n // step key-generation, run algorithm for 100 ms, repeat\n if(!forge.pki.rsa.stepKeyPairGenerationState(state, 100)) {\n setTimeout(step, 1);\n } else {\n // key-generation complete\n // TODO: turn off progress indicator here\n // TODO: use the generated key-pair in \"state.keys\"\n }\n};\n// TODO: turn on progress indicator here\nsetTimeout(step, 0);\n\n@param state the state to use.\n@param n the maximum number of milliseconds to run the algorithm for, 0\n to run the algorithm to completion.\n\n@return true if the key-generation completed, false if not." + }, + "generateKeyPair": { + "!type": "fn(bits: number, e: number, options: ?|number, callback: ?|number) -> ?", + "!span": "26181[843:8]-26196[843:23]", + "!doc": "Generates an RSA public-private key pair in a single call.\n\nTo generate a key-pair in steps (to allow for progress updates and to\nprevent blocking or warnings in slow browsers) then use the key-pair\ngeneration state functions.\n\nTo generate a key-pair asynchronously (either through web-workers, if\navailable, or by breaking up the work on the main thread), pass a\ncallback function.\n\n@param [bits] the size for the private key in bits, defaults to 2048.\n@param [e] the public exponent to use, defaults to 65537.\n@param [options] options for key-pair generation, if given then 'bits'\n and 'e' must *not* be given:\n bits the size for the private key in bits, (default: 2048).\n e the public exponent to use, (default: 65537 (0x10001)).\n workerScript the worker script URL.\n workers the number of web workers (if supported) to use,\n (default: 2).\n workLoad the size of the work load, ie: number of possible prime\n numbers for each web worker to check per work assignment,\n (default: 100).\n prng a custom crypto-secure pseudo-random number generator to use,\n that must define \"getBytesSync\". Disables use of native APIs.\n algorithm the algorithm to use (default: 'PRIMEINC').\n@param [callback(err, keypair)] called once the operation completes.\n\n@return an object with privateKey and publicKey properties." + }, + "!span": "2386[88:39]-2389[88:42]", + "setPublicKey": "pki.setRsaPublicKey", + "setPrivateKey": "pki.setRsaPrivateKey" + }, + "sha512": { + "create": { + "!type": "fn(algorithm: string) -> _createKDF.!1", + "!span": "1357[54:7]-1363[54:13]" + }, + "!span": "415[16:36]-421[16:42]", + "!doc": "SHA-512", + "sha384": "sha384", + "sha256": "forge.md.sha512/256", + "sha224": "forge.md.sha512/224" + }, + "util": { + "isNodejs": { + "!type": "bool", + "!span": "3331[109:5]-3339[109:13]", + "!doc": "check if running under Node.js" + }, + "parseFragment": {}, + "makeRequest": {}, + "cores": { + "!type": "number", + "!span": "73990[2815:9]-73995[2815:14]", + "!doc": "can't estimate, default to 2" + }, + "setImmediate": "util.nextTick", + "ByteStringBuffer": "ByteBuffer", + "binary": { + "hex": { + "encode": "util.bytesToHex", + "decode": "util.binary.hex.decode" + }, + "raw": { + "encode": "util.binary.raw.encode", + "decode": "util.binary.raw.decode" + }, + "base64": { + "encode": "util.binary.base64.encode", + "decode": "util.binary.base64.decode" + }, + "base58": { + "encode": "util.binary.base58.encode", + "decode": "util.binary.base58.decode" + }, + "baseN": "util.binary.baseN" + }, + "setItem": {}, + "parseUrl": "http.parseUrl", + "deflate": {}, + "ByteBuffer": { + "prototype": { + "_optimizeConstructedString": "ByteBuffer.prototype._optimizeConstructedString", + "length": "ByteBuffer.prototype.length", + "isEmpty": "ByteBuffer.prototype.isEmpty", + "putByte": "ByteBuffer.prototype.putByte", + "fillWithByte": "ByteBuffer.prototype.fillWithByte", + "putBytes": "ByteBuffer.prototype.putBytes", + "putString": "ByteBuffer.prototype.putString", + "putInt16": "ByteBuffer.prototype.putInt16", + "putInt24": "ByteBuffer.prototype.putInt24", + "putInt32": "ByteBuffer.prototype.putInt32", + "putInt16Le": "ByteBuffer.prototype.putInt16Le", + "putInt24Le": "ByteBuffer.prototype.putInt24Le", + "putInt32Le": "ByteBuffer.prototype.putInt32Le", + "putInt": "ByteBuffer.prototype.putInt", + "putSignedInt": "ByteBuffer.prototype.putSignedInt", + "putBuffer": "ByteBuffer.prototype.putBuffer", + "getByte": "ByteBuffer.prototype.getByte", + "getInt16": "ByteBuffer.prototype.getInt16", + "getInt24": "ByteBuffer.prototype.getInt24", + "getInt32": "ByteBuffer.prototype.getInt32", + "getInt16Le": "ByteBuffer.prototype.getInt16Le", + "getInt24Le": "ByteBuffer.prototype.getInt24Le", + "getInt32Le": "ByteBuffer.prototype.getInt32Le", + "getInt": "ByteBuffer.prototype.getInt", + "getSignedInt": "ByteBuffer.prototype.getSignedInt", + "getBytes": "ByteBuffer.prototype.getBytes", + "bytes": "ByteBuffer.prototype.bytes", + "at": "ByteBuffer.prototype.at", + "setAt": "ByteBuffer.prototype.setAt", + "last": "ByteBuffer.prototype.last", + "copy": "ByteBuffer.prototype.copy", + "compact": "ByteBuffer.prototype.compact", + "clear": "ByteBuffer.prototype.clear", + "truncate": "ByteBuffer.prototype.truncate", + "toHex": "ByteBuffer.prototype.toHex", + "toString": "ByteBuffer.prototype.toString" + } + }, + "nextTick": "util.nextTick", + "isArray": "util.isArray", + "isArrayBuffer": "util.isArrayBuffer", + "isArrayBufferView": "util.isArrayBufferView", + "DataBuffer": { + "prototype": { + "length": "DataBuffer.prototype.length", + "isEmpty": "DataBuffer.prototype.isEmpty", + "accommodate": "DataBuffer.prototype.accommodate", + "putByte": "DataBuffer.prototype.putByte", + "fillWithByte": "DataBuffer.prototype.fillWithByte", + "putBytes": "DataBuffer.prototype.putBytes", + "putBuffer": "DataBuffer.prototype.putBuffer", + "putString": "DataBuffer.prototype.putString", + "putInt16": "DataBuffer.prototype.putInt16", + "putInt24": "DataBuffer.prototype.putInt24", + "putInt32": "DataBuffer.prototype.putInt32", + "putInt16Le": "DataBuffer.prototype.putInt16Le", + "putInt24Le": "DataBuffer.prototype.putInt24Le", + "putInt32Le": "DataBuffer.prototype.putInt32Le", + "putInt": "DataBuffer.prototype.putInt", + "putSignedInt": "DataBuffer.prototype.putSignedInt", + "getByte": "DataBuffer.prototype.getByte", + "getInt16": "DataBuffer.prototype.getInt16", + "getInt24": "DataBuffer.prototype.getInt24", + "getInt32": "DataBuffer.prototype.getInt32", + "getInt16Le": "DataBuffer.prototype.getInt16Le", + "getInt24Le": "DataBuffer.prototype.getInt24Le", + "getInt32Le": "DataBuffer.prototype.getInt32Le", + "getInt": "DataBuffer.prototype.getInt", + "getSignedInt": "DataBuffer.prototype.getSignedInt", + "getBytes": "DataBuffer.prototype.getBytes", + "bytes": "DataBuffer.prototype.bytes", + "at": "DataBuffer.prototype.at", + "setAt": "DataBuffer.prototype.setAt", + "last": "DataBuffer.prototype.last", + "copy": "DataBuffer.prototype.copy", + "compact": "DataBuffer.prototype.compact", + "clear": "DataBuffer.prototype.clear", + "truncate": "DataBuffer.prototype.truncate", + "toHex": "DataBuffer.prototype.toHex", + "toString": "DataBuffer.prototype.toString" + } + }, + "createBuffer": "util.createBuffer", + "fillString": "util.fillString", + "xorBytes": "util.xorBytes", + "hexToBytes": "util.hexToBytes", + "bytesToHex": "util.bytesToHex", + "int32ToBytes": "util.int32ToBytes", + "encode64": "util.encode64", + "decode64": "util.decode64", + "encodeUtf8": "util.encodeUtf8", + "decodeUtf8": "util.decodeUtf8", + "text": { + "utf8": { + "encode": "util.text.utf8.encode", + "decode": "util.text.utf8.decode" + }, + "utf16": { + "encode": "util.text.utf16.encode", + "decode": "util.text.utf16.decode" + } + }, + "inflate": "util.inflate", + "getItem": "util.getItem", + "removeItem": "util.removeItem", + "clearItems": "util.clearItems", + "getQueryVariables": "util.getQueryVariables", + "makeLink": "util.makeLink", + "isEmpty": "util.isEmpty", + "format": "util.format", + "formatNumber": "util.formatNumber", + "formatSize": "util.formatSize", + "bytesFromIP": "util.bytesFromIP", + "bytesFromIPv4": "util.bytesFromIPv4", + "bytesFromIPv6": "util.bytesFromIPv6", + "bytesToIP": "util.bytesToIP", + "bytesToIPv4": "util.bytesToIPv4", + "bytesToIPv6": "util.bytesToIPv6", + "estimateCores": "util.estimateCores" + }, + "hmac": { + "create": {} + }, + "pkcs5": { + "pbkdf2": "forge.pbkdf2" + }, + "mgf1": { + "create": {} + }, + "pkcs1": { + "encode_rsa_oaep": "pkcs1.encode_rsa_oaep", + "decode_rsa_oaep": "pkcs1.decode_rsa_oaep" + }, + "pss": { + "create": {} + }, + "sha1": { + "create": "sha1.create" + }, + "sha256": { + "create": "sha256.create" + }, + "sha384": { + "create": "sha384.create" + }, + "ssh": { + "privateKeyToPutty": "ssh.privateKeyToPutty", + "publicKeyToOpenSSH": "ssh.publicKeyToOpenSSH", + "privateKeyToOpenSSH": "ssh.privateKeyToOpenSSH", + "getPublicKeyFingerprint": "ssh.getPublicKeyFingerprint" + } + } +} diff --git a/app/client/src/utils/DynamicBindingUtils.ts b/app/client/src/utils/DynamicBindingUtils.ts index ea39ea6b32..e09e3ea5b3 100644 --- a/app/client/src/utils/DynamicBindingUtils.ts +++ b/app/client/src/utils/DynamicBindingUtils.ts @@ -9,6 +9,7 @@ import { WidgetProps } from "widgets/BaseWidget"; import parser from "fast-xml-parser"; import { Severity } from "entities/AppsmithConsole"; import { getEntityNameAndPropertyPath } from "workers/evaluationUtils"; +import forge from "node-forge"; export type DependencyMap = Record>; @@ -140,6 +141,15 @@ export const extraLibraries: ExtraLibrary[] = [ docsURL: "https://github.com/NaturalIntelligence/fast-xml-parser", displayName: "xmlParser", }, + { + accessor: "forge", + // We are removing some functionalities of node-forge because they wont + // work in the worker thread + lib: _.omit(forge, ["tls", "http", "xhr", "socket", "task"]), + version: "0.10.0", + docsURL: "https://github.com/digitalbazaar/forge", + displayName: "forge", + }, ]; export interface DynamicPath { diff --git a/app/client/src/utils/autocomplete/TernServer.ts b/app/client/src/utils/autocomplete/TernServer.ts index 1cbddcd3b8..2d97d851ed 100644 --- a/app/client/src/utils/autocomplete/TernServer.ts +++ b/app/client/src/utils/autocomplete/TernServer.ts @@ -7,6 +7,7 @@ import lodash from "constants/defs/lodash.json"; import base64 from "constants/defs/base64-js.json"; import moment from "constants/defs/moment.json"; import xmlJs from "constants/defs/xmlParser.json"; +import forge from "constants/defs/forge.json"; import { dataTreeTypeDefCreator } from "utils/autocomplete/dataTreeTypeDefCreator"; import { customTreeTypeDefCreator } from "utils/autocomplete/customTreeTypeDefCreator"; import CodeMirror, { Hint, Pos, cmpPos } from "codemirror"; @@ -15,7 +16,7 @@ import { isDynamicValue, } from "utils/DynamicBindingUtils"; -const DEFS = [ecma, lodash, base64, moment, xmlJs]; +const DEFS = [ecma, lodash, base64, moment, xmlJs, forge]; const bigDoc = 250; const cls = "CodeMirror-Tern-"; const hintDelay = 1700; diff --git a/app/client/yarn.lock b/app/client/yarn.lock index f5a9523428..aaf61e4e07 100644 --- a/app/client/yarn.lock +++ b/app/client/yarn.lock @@ -3748,6 +3748,13 @@ dependencies: "@types/node" "*" +"@types/node-forge@^0.10.0": + version "0.10.0" + resolved "https://registry.yarnpkg.com/@types/node-forge/-/node-forge-0.10.0.tgz#14888032a0e873a746b3a7f2b320b44d19ccb104" + integrity sha512-qxCPxN/6s/kY4Xud/1T6gIQtJjRz09UWSA8fTEfUXu4rC9EkFt4KA3s8bYLvkNJmIEWlVeuhZ1CFl7F5rp3FCA== + dependencies: + "@types/node" "*" + "@types/node@*": version "14.11.8" resolved "https://registry.yarnpkg.com/@types/node/-/node-14.11.8.tgz#fe2012f2355e4ce08bca44aeb3abbb21cf88d33f" @@ -12296,6 +12303,7 @@ node-fetch@^1.0.1: node-forge@^0.10.0: version "0.10.0" resolved "https://registry.yarnpkg.com/node-forge/-/node-forge-0.10.0.tgz#32dea2afb3e9926f02ee5ce8794902691a676bf3" + integrity sha512-PPmu8eEeG9saEUvI97fm4OYxXVB6bFvyNTyiUOBichBpFG8A1Ljw3bY62+5oOjDEMHRnd0Y7HQ+x7uzxOzC6JA== node-gyp@^3.8.0: version "3.8.0"