@famir/reverse-app 0.0.4 → 0.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +29 -6
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/loader.d.ts +3 -0
- package/dist/loader.d.ts.map +1 -0
- package/dist/loader.js +29 -0
- package/dist/loader.js.map +1 -0
- package/dist/modules/authorize/authorize.controller.d.ts +4 -2
- package/dist/modules/authorize/authorize.controller.d.ts.map +1 -0
- package/dist/modules/authorize/authorize.controller.js +12 -9
- package/dist/modules/authorize/authorize.controller.js.map +1 -1
- package/dist/modules/authorize/authorize.service.d.ts +27 -7
- package/dist/modules/authorize/authorize.service.d.ts.map +1 -0
- package/dist/modules/authorize/authorize.service.js +14 -41
- package/dist/modules/authorize/authorize.service.js.map +1 -1
- package/dist/modules/authorize/index.d.ts +1 -2
- package/dist/modules/authorize/index.d.ts.map +1 -0
- package/dist/modules/authorize/index.js +0 -2
- package/dist/modules/authorize/index.js.map +1 -1
- package/dist/modules/base/base.controller.d.ts +19 -8
- package/dist/modules/base/base.controller.d.ts.map +1 -0
- package/dist/modules/base/base.controller.js +17 -26
- package/dist/modules/base/base.controller.js.map +1 -1
- package/dist/modules/base/index.d.ts +1 -1
- package/dist/modules/base/index.d.ts.map +1 -0
- package/dist/modules/base/index.js +0 -1
- package/dist/modules/base/index.js.map +1 -1
- package/dist/modules/complete/complete.controller.d.ts +4 -2
- package/dist/modules/complete/complete.controller.d.ts.map +1 -0
- package/dist/modules/complete/complete.controller.js +38 -27
- package/dist/modules/complete/complete.controller.js.map +1 -1
- package/dist/modules/complete/complete.service.d.ts +32 -3
- package/dist/modules/complete/complete.service.d.ts.map +1 -0
- package/dist/modules/complete/complete.service.js +19 -13
- package/dist/modules/complete/complete.service.js.map +1 -1
- package/dist/modules/complete/index.d.ts +1 -1
- package/dist/modules/complete/index.d.ts.map +1 -0
- package/dist/modules/complete/index.js +0 -1
- package/dist/modules/complete/index.js.map +1 -1
- package/dist/modules/forward/forward.controller.d.ts +4 -2
- package/dist/modules/forward/forward.controller.d.ts.map +1 -0
- package/dist/modules/forward/forward.controller.js +17 -20
- package/dist/modules/forward/forward.controller.js.map +1 -1
- package/dist/modules/forward/forward.service.d.ts +37 -5
- package/dist/modules/forward/forward.service.d.ts.map +1 -0
- package/dist/modules/forward/forward.service.js +20 -4
- package/dist/modules/forward/forward.service.js.map +1 -1
- package/dist/modules/forward/index.d.ts +1 -1
- package/dist/modules/forward/index.d.ts.map +1 -0
- package/dist/modules/forward/index.js +0 -1
- package/dist/modules/forward/index.js.map +1 -1
- package/dist/modules/index.d.ts +1 -0
- package/dist/modules/index.d.ts.map +1 -0
- package/dist/modules/setup-mirror/index.d.ts +1 -1
- package/dist/modules/setup-mirror/index.d.ts.map +1 -0
- package/dist/modules/setup-mirror/index.js +0 -1
- package/dist/modules/setup-mirror/index.js.map +1 -1
- package/dist/modules/setup-mirror/setup-mirror.controller.d.ts +4 -2
- package/dist/modules/setup-mirror/setup-mirror.controller.d.ts.map +1 -0
- package/dist/modules/setup-mirror/setup-mirror.controller.js +7 -10
- package/dist/modules/setup-mirror/setup-mirror.controller.js.map +1 -1
- package/dist/modules/setup-mirror/setup-mirror.service.d.ts +11 -4
- package/dist/modules/setup-mirror/setup-mirror.service.d.ts.map +1 -0
- package/dist/modules/setup-mirror/setup-mirror.service.js +4 -22
- package/dist/modules/setup-mirror/setup-mirror.service.js.map +1 -1
- package/dist/modules/transform/index.d.ts +1 -1
- package/dist/modules/transform/index.d.ts.map +1 -0
- package/dist/modules/transform/index.js +0 -1
- package/dist/modules/transform/index.js.map +1 -1
- package/dist/modules/transform/transform.controller.d.ts +2 -5
- package/dist/modules/transform/transform.controller.d.ts.map +1 -0
- package/dist/modules/transform/transform.controller.js +3 -7
- package/dist/modules/transform/transform.controller.js.map +1 -1
- package/dist/modules/well-known-urls/index.d.ts +1 -1
- package/dist/modules/well-known-urls/index.d.ts.map +1 -0
- package/dist/modules/well-known-urls/index.js +0 -1
- package/dist/modules/well-known-urls/index.js.map +1 -1
- package/dist/modules/well-known-urls/well-known-urls.controller.d.ts +2 -5
- package/dist/modules/well-known-urls/well-known-urls.controller.d.ts.map +1 -0
- package/dist/modules/well-known-urls/well-known-urls.controller.js +3 -7
- package/dist/modules/well-known-urls/well-known-urls.controller.js.map +1 -1
- package/dist/reverse-app.d.ts +4 -3
- package/dist/reverse-app.d.ts.map +1 -0
- package/dist/reverse-app.js +12 -13
- package/dist/reverse-app.js.map +1 -1
- package/package.json +4 -7
- package/dist/modules/authorize/authorize.d.ts +0 -32
- package/dist/modules/authorize/authorize.js +0 -3
- package/dist/modules/authorize/authorize.js.map +0 -1
- package/dist/modules/authorize/authorize.schemas.d.ts +0 -2
- package/dist/modules/authorize/authorize.schemas.js +0 -8
- package/dist/modules/authorize/authorize.schemas.js.map +0 -1
- package/dist/modules/base/base.d.ts +0 -11
- package/dist/modules/base/base.js +0 -2
- package/dist/modules/base/base.js.map +0 -1
- package/dist/modules/complete/complete.d.ts +0 -24
- package/dist/modules/complete/complete.js +0 -3
- package/dist/modules/complete/complete.js.map +0 -1
- package/dist/modules/forward/forward.d.ts +0 -41
- package/dist/modules/forward/forward.js +0 -3
- package/dist/modules/forward/forward.js.map +0 -1
- package/dist/modules/setup-mirror/setup-mirror.d.ts +0 -16
- package/dist/modules/setup-mirror/setup-mirror.js +0 -3
- package/dist/modules/setup-mirror/setup-mirror.js.map +0 -1
- package/dist/modules/transform/transform.d.ts +0 -1
- package/dist/modules/transform/transform.js +0 -2
- package/dist/modules/transform/transform.js.map +0 -1
- package/dist/modules/well-known-urls/well-known-urls.d.ts +0 -5
- package/dist/modules/well-known-urls/well-known-urls.js +0 -2
- package/dist/modules/well-known-urls/well-known-urls.js.map +0 -1
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { EnabledFullTargetModel, EnabledProxyModel, FullCampaignModel, SessionModel, TargetModel } from '@famir/database';
|
|
2
|
-
import { HttpServerContextState } from '@famir/http-server';
|
|
3
|
-
import { HttpMessage } from '@famir/http-tools';
|
|
4
|
-
export interface ReverseContextState extends HttpServerContextState {
|
|
5
|
-
campaign?: FullCampaignModel;
|
|
6
|
-
proxy?: EnabledProxyModel;
|
|
7
|
-
target?: EnabledFullTargetModel;
|
|
8
|
-
targets?: TargetModel[];
|
|
9
|
-
session?: SessionModel;
|
|
10
|
-
message?: HttpMessage;
|
|
11
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"base.js","sourceRoot":"","sources":["../../../src/modules/base/base.ts"],"names":[],"mappings":""}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { HttpBody, HttpConnection, HttpError, HttpHeaders, HttpMethod, HttpPayload, HttpType } from '@famir/http-proto';
|
|
2
|
-
export declare const COMPLETE_CONTROLLER: unique symbol;
|
|
3
|
-
export declare const COMPLETE_SERVICE: unique symbol;
|
|
4
|
-
export interface CreateMessageData {
|
|
5
|
-
campaignId: string;
|
|
6
|
-
messageId: string;
|
|
7
|
-
proxyId: string;
|
|
8
|
-
targetId: string;
|
|
9
|
-
sessionId: string;
|
|
10
|
-
type: HttpType;
|
|
11
|
-
method: HttpMethod;
|
|
12
|
-
url: string;
|
|
13
|
-
requestHeaders: HttpHeaders;
|
|
14
|
-
requestBody: HttpBody;
|
|
15
|
-
status: number;
|
|
16
|
-
responseHeaders: HttpHeaders;
|
|
17
|
-
responseBody: HttpBody;
|
|
18
|
-
connection: HttpConnection;
|
|
19
|
-
payload: HttpPayload;
|
|
20
|
-
errors: HttpError[];
|
|
21
|
-
analyze: string | null;
|
|
22
|
-
startTime: number;
|
|
23
|
-
finishTime: number;
|
|
24
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"complete.js","sourceRoot":"","sources":["../../../src/modules/complete/complete.ts"],"names":[],"mappings":"AAcA,MAAM,CAAC,MAAM,mBAAmB,GAAG,MAAM,CAAC,oBAAoB,CAAC,CAAA;AAM/D,MAAM,CAAC,MAAM,gBAAgB,GAAG,MAAM,CAAC,iBAAiB,CAAC,CAAA"}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { EnabledFullTargetModel, EnabledProxyModel } from '@famir/database';
|
|
2
|
-
import { HttpBody, HttpHeaders, HttpMethod, HttpType } from '@famir/http-proto';
|
|
3
|
-
import { HttpServerContext, HttpServerNextFunction } from '@famir/http-server';
|
|
4
|
-
import { type HttpMessage } from '@famir/http-tools';
|
|
5
|
-
import type { Readable } from 'node:stream';
|
|
6
|
-
export declare const FORWARD_CONTROLLER: unique symbol;
|
|
7
|
-
export declare const FORWARD_SERVICE: unique symbol;
|
|
8
|
-
export type ForwardHandler = (ctx: HttpServerContext, proxy: EnabledProxyModel, target: EnabledFullTargetModel, message: HttpMessage, next: HttpServerNextFunction) => Promise<void>;
|
|
9
|
-
export type ForwardDispatchHttpType = Record<HttpType, ForwardHandler>;
|
|
10
|
-
export interface ForwardSimpleData {
|
|
11
|
-
proxy: string;
|
|
12
|
-
method: HttpMethod;
|
|
13
|
-
url: string;
|
|
14
|
-
requestHeaders: HttpHeaders;
|
|
15
|
-
requestBody: HttpBody;
|
|
16
|
-
connectTimeout: number;
|
|
17
|
-
timeout: number;
|
|
18
|
-
headersSizeLimit: number;
|
|
19
|
-
bodySizeLimit: number;
|
|
20
|
-
}
|
|
21
|
-
export interface ForwardStreamRequestData {
|
|
22
|
-
proxy: string;
|
|
23
|
-
method: HttpMethod;
|
|
24
|
-
url: string;
|
|
25
|
-
requestHeaders: HttpHeaders;
|
|
26
|
-
requestStream: Readable;
|
|
27
|
-
connectTimeout: number;
|
|
28
|
-
timeout: number;
|
|
29
|
-
headersSizeLimit: number;
|
|
30
|
-
bodySizeLimit: number;
|
|
31
|
-
}
|
|
32
|
-
export interface ForwardStreamResponseData {
|
|
33
|
-
proxy: string;
|
|
34
|
-
method: HttpMethod;
|
|
35
|
-
url: string;
|
|
36
|
-
requestHeaders: HttpHeaders;
|
|
37
|
-
requestBody: HttpBody;
|
|
38
|
-
connectTimeout: number;
|
|
39
|
-
timeout: number;
|
|
40
|
-
headersSizeLimit: number;
|
|
41
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"forward.js","sourceRoot":"","sources":["../../../src/modules/forward/forward.ts"],"names":[],"mappings":"AAUA,MAAM,CAAC,MAAM,kBAAkB,GAAG,MAAM,CAAC,mBAAmB,CAAC,CAAA;AAM7D,MAAM,CAAC,MAAM,eAAe,GAAG,MAAM,CAAC,gBAAgB,CAAC,CAAA"}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { type EnabledFullTargetModel, type FullCampaignModel } from '@famir/database';
|
|
2
|
-
import { HttpServerContext, HttpServerContextType, HttpServerNextFunction } from '@famir/http-server';
|
|
3
|
-
import { type HttpMessage } from '@famir/http-tools';
|
|
4
|
-
export declare const SETUP_MIRROR_CONTROLLER: unique symbol;
|
|
5
|
-
export declare const SETUP_MIRROR_SERVICE: unique symbol;
|
|
6
|
-
export type SetupMirrorHandler = (ctx: HttpServerContext, campaign: FullCampaignModel, target: EnabledFullTargetModel, message: HttpMessage, next: HttpServerNextFunction) => Promise<void>;
|
|
7
|
-
export type SetupMirrorDispatchContextType = Record<HttpServerContextType, SetupMirrorHandler>;
|
|
8
|
-
export interface ReadCampaignData {
|
|
9
|
-
campaignId: string;
|
|
10
|
-
}
|
|
11
|
-
export interface FindTargetData {
|
|
12
|
-
mirrorHost: string;
|
|
13
|
-
}
|
|
14
|
-
export interface ListTargetsData {
|
|
15
|
-
campaignId: string;
|
|
16
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"setup-mirror.js","sourceRoot":"","sources":["../../../src/modules/setup-mirror/setup-mirror.ts"],"names":[],"mappings":"AAYA,MAAM,CAAC,MAAM,uBAAuB,GAAG,MAAM,CAAC,uBAAuB,CAAC,CAAA;AAMtE,MAAM,CAAC,MAAM,oBAAoB,GAAG,MAAM,CAAC,oBAAoB,CAAC,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const TRANSFORM_CONTROLLER: unique symbol;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"transform.js","sourceRoot":"","sources":["../../../src/modules/transform/transform.ts"],"names":[],"mappings":"AAIA,MAAM,CAAC,MAAM,oBAAoB,GAAG,MAAM,CAAC,qBAAqB,CAAC,CAAA"}
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { type EnabledFullTargetModel } from '@famir/database';
|
|
2
|
-
import { HttpServerContext, HttpServerContextType, HttpServerNextFunction } from '@famir/http-server';
|
|
3
|
-
export declare const WELL_KNOWN_URLS_CONTROLLER: unique symbol;
|
|
4
|
-
export type WellKnownUrlsHandler = (ctx: HttpServerContext, target: EnabledFullTargetModel, next: HttpServerNextFunction) => Promise<void>;
|
|
5
|
-
export type WellKnownUrlsDispatchContextType = Record<HttpServerContextType, WellKnownUrlsHandler>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"well-known-urls.js","sourceRoot":"","sources":["../../../src/modules/well-known-urls/well-known-urls.ts"],"names":[],"mappings":"AAWA,MAAM,CAAC,MAAM,0BAA0B,GAAG,MAAM,CAAC,yBAAyB,CAAC,CAAA"}
|