KPAR archive validation#
This page lists the requirements Sysand Index enforces on uploaded .kpar
archives.
Project metadata#
publisheris set in.project.jsonand conforms to the publisher field rules.publisherin.project.jsonmatches a username or organization in Sysand Index.nameis set in.project.jsonand conforms to the project name field rules.The normalized
publisherandnamematch the publisher and name IDs in the upload metadata sent by the client.The upload version is a SemVer version string without build metadata, and
versionin.project.jsonis present, is a non-empty string, and equals it.licenseis set in.project.jsonand is a valid SPDX license expression of at most 255 characters. CustomLicenseRef-*identifiers are accepted even though they are not on the SPDX license list.website, when present in.project.json, is anhttporhttpsURL.description, when present, is a string;maintainerandtopic, when present, are lists of strings.usageentries are objects whoseresourceis an IRI accepted by the index, with an optional stringversionConstraint. The accepted IRIs are apkg:sysand/...PURL for a project on this index or an OMG standard library.kparURL (see usage identifiers).
Archive layout#
.project.jsonand.meta.jsonare present in the root of the ZIP file..meta.jsoncontains ametamodelfield matchinghttps://www.omg.org/spec/KerML/YYYYMMXXorhttps://www.omg.org/spec/SysML/YYYYMMXX. TheYYYYMMportion must be a valid year/month; the final two digits (XX) are an incrementing release number within that month, not a calendar day.
Note
The accepted metamodel values will grow over time. Sysand Index currently
recognizes the OMG-published KerML and SysML metamodels listed above, but it
is designed so additional metamodels (including community-built ones beyond
the OMG specifications) can be added as the ecosystem evolves. Check this
page for the current list before publishing a package that targets a
non-OMG metamodel.
To request support for a community-defined metamodel, reach out at sysand@sensmetry.com.
LICENSES/is present and contains a.txtfile for each mentioned license.LICENSES/contains no additional.txtfiles other than those for the mentioned licenses.Each
LICENSES/*.txtfile is UTF-8 encoded.The KPAR contains no additional unknown files other than:
LICENSES/*.txtfiles,README.md,CHANGELOG.md(see Markdown support for howREADME.mdandCHANGELOG.mdare rendered),.sysmland.kermlfiles mentioned in.meta.json.
Size limits#
The uploaded
.kparfile is at most 1 MiB.The archive contains at most 500 entries.
The total uncompressed size is at most 10 MiB.
Each file is at most 2 MiB uncompressed.
Each entry’s compression ratio (uncompressed to compressed) is at most 100.
Paths and ZIP structure#
The ZIP uses the DEFLATE compression method.
The ZIP contains no nested ZIP archives.
The ZIP contains no symlinks.
ZIP entry paths contain no relative path components such as
.or.., no absolute paths, no backslashes, no drive-letter components, and no duplicate entry names.
File integrity#
Hashes of all source files are included in
.meta.json.Hashes use SHA256.
Hashes match the referenced file contents.
The
indexfield in.meta.jsondoes not mention files that are absent from the checksum field in.meta.json.All files referenced in
checksumandindexin.meta.jsonare present in the archive.Files referenced in
indexuse the extension that matches themetamodelkind:.sysmlfor SysML and.kermlfor KerML.Each symbol listed in the
.meta.jsonindexfield appears as text in the file it references. The index does not parse or validate the models themselves.
File safety#
Files in the KPAR do not have extra permissions, such as executable bits.
No file may begin with an executable signature (Windows, macOS, or Linux binary formats), a ZIP signature, or a
#!script line, regardless of its extension.