Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
projectdiscovery
GitHub Repository: projectdiscovery/nuclei
Path: blob/dev/pkg/js/generated/ts/rsync.ts
2850 views
1
2
3
/**
4
* IsRsync checks if a host is running a Rsync server.
5
* @example
6
* ```javascript
7
* const rsync = require('nuclei/rsync');
8
* const isRsync = rsync.IsRsync('acme.com', 873);
9
* log(toJSON(isRsync));
10
* ```
11
*/
12
export function IsRsync(host: string, port: number): IsRsyncResponse | null {
13
return null;
14
}
15
16
/**
17
* RsyncClient is a client for RSYNC servers.
18
* Internally client uses https://github.com/gokrazy/rsync driver.
19
* @example
20
* ```javascript
21
* const rsync = require('nuclei/rsync');
22
* const client = new rsync.RsyncClient();
23
* ```
24
*/
25
export class RsyncClient {
26
27
// Constructor of RsyncClient
28
constructor() {}
29
30
/**
31
* Connect establishes a connection to the rsync server with authentication.
32
* @example
33
* ```javascript
34
* const rsync = require('nuclei/rsync');
35
* const client = new rsync.RsyncClient();
36
* const connected = client.Connect('acme.com', 873, 'username', 'password', 'backup');
37
* ```
38
*/
39
public Connect(host: string, port: number, username: string, password: string, module: string): boolean | null {
40
return null;
41
}
42
43
/**
44
* ListModules lists available modules on the rsync server.
45
* @example
46
* ```javascript
47
* const rsync = require('nuclei/rsync');
48
* const client = new rsync.RsyncClient();
49
* const modules = client.ListModules('acme.com', 873, 'username', 'password');
50
* log(toJSON(modules));
51
* ```
52
*/
53
public ListModules(host: string, port: number, username: string, password: string): string[] | null {
54
return null;
55
}
56
57
/**
58
* ListFilesInModule lists files in a specific module on the rsync server.
59
* @example
60
* ```javascript
61
* const rsync = require('nuclei/rsync');
62
* const client = new rsync.RsyncClient();
63
* const files = client.ListFilesInModule('acme.com', 873, 'username', 'password', 'backup');
64
* log(toJSON(files));
65
* ```
66
*/
67
public ListFilesInModule(host: string, port: number, username: string, password: string, module: string): string[] | null {
68
return null;
69
}
70
}
71
72
/**
73
* IsRsyncResponse is the response from the IsRsync function.
74
* this is returned by IsRsync function.
75
* @example
76
* ```javascript
77
* const rsync = require('nuclei/rsync');
78
* const isRsync = rsync.IsRsync('acme.com', 873);
79
* log(toJSON(isRsync));
80
* ```
81
*/
82
export interface IsRsyncResponse {
83
84
IsRsync?: boolean,
85
86
Banner?: string,
87
}
88
89
90