@@ -349,6 +349,78 @@ public enum Components {
349349 case other = " other "
350350 case swift = " swift "
351351 }
352+ /// A vulnerability describing the product and its affected versions within a GitHub Security Advisory.
353+ ///
354+ /// - Remark: Generated from `#/components/schemas/vulnerability`.
355+ public struct vulnerability : Codable , Hashable , Sendable {
356+ /// The name of the package affected by the vulnerability.
357+ ///
358+ /// - Remark: Generated from `#/components/schemas/vulnerability/package`.
359+ public struct packagePayload : Codable , Hashable , Sendable {
360+ /// - Remark: Generated from `#/components/schemas/vulnerability/package/ecosystem`.
361+ public var ecosystem : Components . Schemas . security_hyphen_advisory_hyphen_ecosystems
362+ /// The unique package name within its ecosystem.
363+ ///
364+ /// - Remark: Generated from `#/components/schemas/vulnerability/package/name`.
365+ public var name : Swift . String ?
366+ /// Creates a new `packagePayload`.
367+ ///
368+ /// - Parameters:
369+ /// - ecosystem:
370+ /// - name: The unique package name within its ecosystem.
371+ public init (
372+ ecosystem: Components . Schemas . security_hyphen_advisory_hyphen_ecosystems ,
373+ name: Swift . String ? = nil
374+ ) {
375+ self . ecosystem = ecosystem
376+ self . name = name
377+ }
378+ public enum CodingKeys : String , CodingKey {
379+ case ecosystem
380+ case name
381+ }
382+ }
383+ /// The name of the package affected by the vulnerability.
384+ ///
385+ /// - Remark: Generated from `#/components/schemas/vulnerability/package`.
386+ public var package : Components . Schemas . vulnerability . packagePayload ?
387+ /// The range of the package versions affected by the vulnerability.
388+ ///
389+ /// - Remark: Generated from `#/components/schemas/vulnerability/vulnerable_version_range`.
390+ public var vulnerable_version_range : Swift . String ?
391+ /// The package version that resolves the vulnerability.
392+ ///
393+ /// - Remark: Generated from `#/components/schemas/vulnerability/first_patched_version`.
394+ public var first_patched_version : Swift . String ?
395+ /// The functions in the package that are affected by the vulnerability.
396+ ///
397+ /// - Remark: Generated from `#/components/schemas/vulnerability/vulnerable_functions`.
398+ public var vulnerable_functions : [ Swift . String ] ?
399+ /// Creates a new `vulnerability`.
400+ ///
401+ /// - Parameters:
402+ /// - package: The name of the package affected by the vulnerability.
403+ /// - vulnerable_version_range: The range of the package versions affected by the vulnerability.
404+ /// - first_patched_version: The package version that resolves the vulnerability.
405+ /// - vulnerable_functions: The functions in the package that are affected by the vulnerability.
406+ public init (
407+ package : Components . Schemas . vulnerability . packagePayload ? = nil ,
408+ vulnerable_version_range: Swift . String ? = nil ,
409+ first_patched_version: Swift . String ? = nil ,
410+ vulnerable_functions: [ Swift . String ] ? = nil
411+ ) {
412+ self . package = package
413+ self . vulnerable_version_range = vulnerable_version_range
414+ self . first_patched_version = first_patched_version
415+ self . vulnerable_functions = vulnerable_functions
416+ }
417+ public enum CodingKeys : String , CodingKey {
418+ case package
419+ case vulnerable_version_range
420+ case first_patched_version
421+ case vulnerable_functions
422+ }
423+ }
352424 /// A GitHub user.
353425 ///
354426 /// - Remark: Generated from `#/components/schemas/simple-user`.
@@ -626,84 +698,10 @@ public enum Components {
626698 ///
627699 /// - Remark: Generated from `#/components/schemas/global-advisory/withdrawn_at`.
628700 public var withdrawn_at : Foundation . Date ?
629- /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilitiesPayload`.
630- public struct vulnerabilitiesPayloadPayload : Codable , Hashable , Sendable {
631- /// The name of the package affected by the vulnerability.
632- ///
633- /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilitiesPayload/package`.
634- public struct packagePayload : Codable , Hashable , Sendable {
635- /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilitiesPayload/package/ecosystem`.
636- public var ecosystem : Components . Schemas . security_hyphen_advisory_hyphen_ecosystems
637- /// The unique package name within its ecosystem.
638- ///
639- /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilitiesPayload/package/name`.
640- public var name : Swift . String ?
641- /// Creates a new `packagePayload`.
642- ///
643- /// - Parameters:
644- /// - ecosystem:
645- /// - name: The unique package name within its ecosystem.
646- public init (
647- ecosystem: Components . Schemas . security_hyphen_advisory_hyphen_ecosystems ,
648- name: Swift . String ? = nil
649- ) {
650- self . ecosystem = ecosystem
651- self . name = name
652- }
653- public enum CodingKeys : String , CodingKey {
654- case ecosystem
655- case name
656- }
657- }
658- /// The name of the package affected by the vulnerability.
659- ///
660- /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilitiesPayload/package`.
661- public var package : Components . Schemas . global_hyphen_advisory . vulnerabilitiesPayloadPayload . packagePayload ?
662- /// The range of the package versions affected by the vulnerability.
663- ///
664- /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilitiesPayload/vulnerable_version_range`.
665- public var vulnerable_version_range : Swift . String ?
666- /// The package version that resolve the vulnerability.
667- ///
668- /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilitiesPayload/first_patched_version`.
669- public var first_patched_version : Swift . String ?
670- /// The functions in the package that are affected by the vulnerability.
671- ///
672- /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilitiesPayload/vulnerable_functions`.
673- public var vulnerable_functions : [ Swift . String ] ?
674- /// Creates a new `vulnerabilitiesPayloadPayload`.
675- ///
676- /// - Parameters:
677- /// - package: The name of the package affected by the vulnerability.
678- /// - vulnerable_version_range: The range of the package versions affected by the vulnerability.
679- /// - first_patched_version: The package version that resolve the vulnerability.
680- /// - vulnerable_functions: The functions in the package that are affected by the vulnerability.
681- public init (
682- package : Components . Schemas . global_hyphen_advisory . vulnerabilitiesPayloadPayload . packagePayload ? = nil ,
683- vulnerable_version_range: Swift . String ? = nil ,
684- first_patched_version: Swift . String ? = nil ,
685- vulnerable_functions: [ Swift . String ] ? = nil
686- ) {
687- self . package = package
688- self . vulnerable_version_range = vulnerable_version_range
689- self . first_patched_version = first_patched_version
690- self . vulnerable_functions = vulnerable_functions
691- }
692- public enum CodingKeys : String , CodingKey {
693- case package
694- case vulnerable_version_range
695- case first_patched_version
696- case vulnerable_functions
697- }
698- }
699- /// The products and respective version ranges affected by the advisory.
700- ///
701- /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilities`.
702- public typealias vulnerabilitiesPayload = [ Components . Schemas . global_hyphen_advisory . vulnerabilitiesPayloadPayload ]
703701 /// The products and respective version ranges affected by the advisory.
704702 ///
705703 /// - Remark: Generated from `#/components/schemas/global-advisory/vulnerabilities`.
706- public var vulnerabilities : Components . Schemas . global_hyphen_advisory . vulnerabilitiesPayload ?
704+ public var vulnerabilities : [ Components . Schemas . vulnerability ] ?
707705 /// - Remark: Generated from `#/components/schemas/global-advisory/cvss`.
708706 public struct cvssPayload : Codable , Hashable , Sendable {
709707 /// The CVSS vector.
@@ -837,7 +835,7 @@ public enum Components {
837835 github_reviewed_at: Foundation . Date ? = nil ,
838836 nvd_published_at: Foundation . Date ? = nil ,
839837 withdrawn_at: Foundation . Date ? = nil ,
840- vulnerabilities: Components . Schemas . global_hyphen_advisory . vulnerabilitiesPayload ? = nil ,
838+ vulnerabilities: [ Components . Schemas . vulnerability ] ? = nil ,
841839 cvss: Components . Schemas . global_hyphen_advisory . cvssPayload ? = nil ,
842840 cwes: Components . Schemas . global_hyphen_advisory . cwesPayload ? = nil ,
843841 credits: Components . Schemas . global_hyphen_advisory . creditsPayload ? = nil
@@ -958,7 +956,7 @@ public enum Components {
958956 forKey: . withdrawn_at
959957 )
960958 vulnerabilities = try container. decodeIfPresent (
961- Components . Schemas. global_hyphen_advisory . vulnerabilitiesPayload . self,
959+ [ Components . Schemas . vulnerability ] . self,
962960 forKey: . vulnerabilities
963961 )
964962 cvss = try container. decodeIfPresent (
0 commit comments