pmcf 1.11.0 → 1.12.0
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/package.json +1 -1
- package/src/model.mjs +20 -10
- package/types/model.d.mts +2 -1
package/package.json
CHANGED
package/src/model.mjs
CHANGED
|
@@ -863,15 +863,15 @@ export class Subnet extends Base {
|
|
|
863
863
|
}
|
|
864
864
|
|
|
865
865
|
const ServiceTypes = {
|
|
866
|
-
dns: {
|
|
867
|
-
ldap: {
|
|
868
|
-
http: {
|
|
869
|
-
https: {
|
|
870
|
-
rtsp: {
|
|
871
|
-
smtp: {
|
|
872
|
-
ssh: {
|
|
873
|
-
imap: {
|
|
874
|
-
imaps: {
|
|
866
|
+
dns: { protocol: "udp", port: 53 },
|
|
867
|
+
ldap: { protocol: "tcp", port: 389 },
|
|
868
|
+
http: { protocol: "tcp", port: 80 },
|
|
869
|
+
https: { protocol: "tcp", port: 443 },
|
|
870
|
+
rtsp: { protocol: "tcp", port: 554 },
|
|
871
|
+
smtp: { protocol: "tcp", port: 25 },
|
|
872
|
+
ssh: { protocol: "tcp", port: 22 },
|
|
873
|
+
imap: { protocol: "tcp", port: 143 },
|
|
874
|
+
imaps: { protocol: "tcp", port: 993 },
|
|
875
875
|
dhcp: {}
|
|
876
876
|
};
|
|
877
877
|
|
|
@@ -941,8 +941,16 @@ export class Service extends Base {
|
|
|
941
941
|
return this;
|
|
942
942
|
}
|
|
943
943
|
|
|
944
|
+
get protocol()
|
|
945
|
+
{
|
|
946
|
+
return ServiceTypes[this.type]?.protocol;
|
|
947
|
+
}
|
|
948
|
+
|
|
944
949
|
get srvPrefix() {
|
|
945
|
-
|
|
950
|
+
const st = ServiceTypes[this.type];
|
|
951
|
+
if(st) {
|
|
952
|
+
return `_${this.type}._${st.protocol}`;
|
|
953
|
+
}
|
|
946
954
|
}
|
|
947
955
|
|
|
948
956
|
get ipAddress() {
|
|
@@ -973,6 +981,8 @@ export class Service extends Base {
|
|
|
973
981
|
return [
|
|
974
982
|
...super.propertyNames,
|
|
975
983
|
"ipAddress",
|
|
984
|
+
"port",
|
|
985
|
+
"protocol",
|
|
976
986
|
"alias",
|
|
977
987
|
"type",
|
|
978
988
|
"master",
|
package/types/model.d.mts
CHANGED