attribute.js 933 B

1234567891011121314151617181920212223242526272829303132
  1. var PKCS12AttrSet_1;
  2. import { __decorate } from "tslib";
  3. import { AsnProp, AsnPropTypes, AsnArray, AsnType, AsnTypeTypes } from "@peculiar/asn1-schema";
  4. export class PKCS12Attribute {
  5. attrId = "";
  6. attrValues = [];
  7. constructor(params = {}) {
  8. Object.assign(params);
  9. }
  10. }
  11. __decorate([
  12. AsnProp({ type: AsnPropTypes.ObjectIdentifier })
  13. ], PKCS12Attribute.prototype, "attrId", void 0);
  14. __decorate([
  15. AsnProp({
  16. type: AsnPropTypes.Any,
  17. repeated: "set",
  18. })
  19. ], PKCS12Attribute.prototype, "attrValues", void 0);
  20. let PKCS12AttrSet = PKCS12AttrSet_1 = class PKCS12AttrSet extends AsnArray {
  21. constructor(items) {
  22. super(items);
  23. Object.setPrototypeOf(this, PKCS12AttrSet_1.prototype);
  24. }
  25. };
  26. PKCS12AttrSet = PKCS12AttrSet_1 = __decorate([
  27. AsnType({
  28. type: AsnTypeTypes.Sequence,
  29. itemType: PKCS12Attribute,
  30. })
  31. ], PKCS12AttrSet);
  32. export { PKCS12AttrSet };