added api server and changed docker files
This commit is contained in:
1
panel-mgmt_backend/node_modules/node/node_modules/.bin/node
generated
vendored
Symbolic link
1
panel-mgmt_backend/node_modules/node/node_modules/.bin/node
generated
vendored
Symbolic link
@@ -0,0 +1 @@
|
||||
../node-bin-darwin-arm64/bin/node
|
||||
4071
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/CHANGELOG.md
generated
vendored
Normal file
4071
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/CHANGELOG.md
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
2641
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/LICENSE
generated
vendored
Normal file
2641
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/LICENSE
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
907
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/README.md
generated
vendored
Normal file
907
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/README.md
generated
vendored
Normal file
@@ -0,0 +1,907 @@
|
||||
# Node.js
|
||||
|
||||
Node.js is an open-source, cross-platform JavaScript runtime environment.
|
||||
|
||||
For information on using Node.js, see the [Node.js website][].
|
||||
|
||||
The Node.js project uses an [open governance model](./GOVERNANCE.md). The
|
||||
[OpenJS Foundation][] provides support for the project.
|
||||
|
||||
Contributors are expected to act in a collaborative manner to move
|
||||
the project forward. We encourage the constructive exchange of contrary
|
||||
opinions and compromise. The [TSC](./GOVERNANCE.md#technical-steering-committee)
|
||||
reserves the right to limit or block contributors who repeatedly act in ways
|
||||
that discourage, exhaust, or otherwise negatively affect other participants.
|
||||
|
||||
**This project has a [Code of Conduct][].**
|
||||
|
||||
## Table of contents
|
||||
|
||||
* [Support](#support)
|
||||
* [Release types](#release-types)
|
||||
* [Download](#download)
|
||||
* [Current and LTS releases](#current-and-lts-releases)
|
||||
* [Nightly releases](#nightly-releases)
|
||||
* [API documentation](#api-documentation)
|
||||
* [Verifying binaries](#verifying-binaries)
|
||||
* [Building Node.js](#building-nodejs)
|
||||
* [Security](#security)
|
||||
* [Contributing to Node.js](#contributing-to-nodejs)
|
||||
* [Current project team members](#current-project-team-members)
|
||||
* [TSC (Technical Steering Committee)](#tsc-technical-steering-committee)
|
||||
* [Collaborators](#collaborators)
|
||||
* [Triagers](#triagers)
|
||||
* [Release keys](#release-keys)
|
||||
* [License](#license)
|
||||
|
||||
## Support
|
||||
|
||||
Looking for help? Check out the
|
||||
[instructions for getting support](.github/SUPPORT.md).
|
||||
|
||||
## Release types
|
||||
|
||||
* **Current**: Under active development. Code for the Current release is in the
|
||||
branch for its major version number (for example,
|
||||
[v22.x](https://github.com/nodejs/node/tree/v22.x)). Node.js releases a new
|
||||
major version every 6 months, allowing for breaking changes. This happens in
|
||||
April and October every year. Releases appearing each October have a support
|
||||
life of 8 months. Releases appearing each April convert to LTS (see below)
|
||||
each October.
|
||||
* **LTS**: Releases that receive Long Term Support, with a focus on stability
|
||||
and security. Every even-numbered major version will become an LTS release.
|
||||
LTS releases receive 12 months of _Active LTS_ support and a further 18 months
|
||||
of _Maintenance_. LTS release lines have alphabetically-ordered code names,
|
||||
beginning with v4 Argon. There are no breaking changes or feature additions,
|
||||
except in some special circumstances.
|
||||
* **Nightly**: Code from the Current branch built every 24-hours when there are
|
||||
changes. Use with caution.
|
||||
|
||||
Current and LTS releases follow [semantic versioning](https://semver.org). A
|
||||
member of the Release Team [signs](#release-keys) each Current and LTS release.
|
||||
For more information, see the
|
||||
[Release README](https://github.com/nodejs/Release#readme).
|
||||
|
||||
### Download
|
||||
|
||||
Binaries, installers, and source tarballs are available at
|
||||
<https://nodejs.org/en/download/>.
|
||||
|
||||
#### Current and LTS releases
|
||||
|
||||
<https://nodejs.org/download/release/>
|
||||
|
||||
The [latest](https://nodejs.org/download/release/latest/) directory is an
|
||||
alias for the latest Current release. The latest-_codename_ directory is an
|
||||
alias for the latest release from an LTS line. For example, the
|
||||
[latest-hydrogen](https://nodejs.org/download/release/latest-hydrogen/)
|
||||
directory contains the latest Hydrogen (Node.js 18) release.
|
||||
|
||||
#### Nightly releases
|
||||
|
||||
<https://nodejs.org/download/nightly/>
|
||||
|
||||
Each directory and filename includes the version (e.g., `v22.0.0`),
|
||||
followed by the UTC date (e.g., `20240424` for April 24, 2024),
|
||||
and the short commit SHA of the HEAD of the release (e.g., `ddd0a9e494`).
|
||||
For instance, a full directory name might look like `v22.0.0-nightly20240424ddd0a9e494`.
|
||||
|
||||
#### API documentation
|
||||
|
||||
Documentation for the latest Current release is at <https://nodejs.org/api/>.
|
||||
Version-specific documentation is available in each release directory in the
|
||||
_docs_ subdirectory. Version-specific documentation is also at
|
||||
<https://nodejs.org/download/docs/>.
|
||||
|
||||
### Verifying binaries
|
||||
|
||||
Download directories contain a `SHASUMS256.txt` file with SHA checksums for the
|
||||
files.
|
||||
|
||||
To download `SHASUMS256.txt` using `curl`:
|
||||
|
||||
```bash
|
||||
curl -O https://nodejs.org/dist/vx.y.z/SHASUMS256.txt
|
||||
```
|
||||
|
||||
To check that downloaded files match the checksum, use `sha256sum`:
|
||||
|
||||
```bash
|
||||
sha256sum -c SHASUMS256.txt --ignore-missing
|
||||
```
|
||||
|
||||
For Current and LTS, the GPG detached signature of `SHASUMS256.txt` is in
|
||||
`SHASUMS256.txt.sig`. You can use it with `gpg` to verify the integrity of
|
||||
`SHASUMS256.txt`. You will first need to import
|
||||
[the GPG keys of individuals authorized to create releases](#release-keys).
|
||||
|
||||
See [Release keys](#release-keys) for commands to import active release keys.
|
||||
|
||||
Next, download the `SHASUMS256.txt.sig` for the release:
|
||||
|
||||
```bash
|
||||
curl -O https://nodejs.org/dist/vx.y.z/SHASUMS256.txt.sig
|
||||
```
|
||||
|
||||
Then use `gpg --verify SHASUMS256.txt.sig SHASUMS256.txt` to verify
|
||||
the file's signature.
|
||||
|
||||
## Building Node.js
|
||||
|
||||
See [BUILDING.md](BUILDING.md) for instructions on how to build Node.js from
|
||||
source and a list of supported platforms.
|
||||
|
||||
## Security
|
||||
|
||||
For information on reporting security vulnerabilities in Node.js, see
|
||||
[SECURITY.md](./SECURITY.md).
|
||||
|
||||
## Contributing to Node.js
|
||||
|
||||
* [Contributing to the project][]
|
||||
* [Working Groups][]
|
||||
* [Strategic initiatives][]
|
||||
* [Technical values and prioritization][]
|
||||
|
||||
## Current project team members
|
||||
|
||||
For information about the governance of the Node.js project, see
|
||||
[GOVERNANCE.md](./GOVERNANCE.md).
|
||||
|
||||
<!-- node-core-utils and find-inactive-tsc.mjs depend on the format of the TSC
|
||||
list. If the format changes, those utilities need to be tested and
|
||||
updated. -->
|
||||
|
||||
### TSC (Technical Steering Committee)
|
||||
|
||||
#### TSC voting members
|
||||
|
||||
<!--lint disable prohibited-strings-->
|
||||
|
||||
* [aduh95](https://github.com/aduh95) -
|
||||
**Antoine du Hamel** <<duhamelantoine1995@gmail.com>> (he/him)
|
||||
* [anonrig](https://github.com/anonrig) -
|
||||
**Yagiz Nizipli** <<yagiz@nizipli.com>> (he/him)
|
||||
* [benjamingr](https://github.com/benjamingr) -
|
||||
**Benjamin Gruenbaum** <<benjamingr@gmail.com>>
|
||||
* [BridgeAR](https://github.com/BridgeAR) -
|
||||
**Ruben Bridgewater** <<ruben@bridgewater.de>> (he/him)
|
||||
* [gireeshpunathil](https://github.com/gireeshpunathil) -
|
||||
**Gireesh Punathil** <<gpunathi@in.ibm.com>> (he/him)
|
||||
* [jasnell](https://github.com/jasnell) -
|
||||
**James M Snell** <<jasnell@gmail.com>> (he/him)
|
||||
* [joyeecheung](https://github.com/joyeecheung) -
|
||||
**Joyee Cheung** <<joyeec9h3@gmail.com>> (she/her)
|
||||
* [legendecas](https://github.com/legendecas) -
|
||||
**Chengzhong Wu** <<legendecas@gmail.com>> (he/him)
|
||||
* [marco-ippolito](https://github.com/marco-ippolito) -
|
||||
**Marco Ippolito** <<marcoippolito54@gmail.com>> (he/him)
|
||||
* [mcollina](https://github.com/mcollina) -
|
||||
**Matteo Collina** <<matteo.collina@gmail.com>> (he/him)
|
||||
* [mhdawson](https://github.com/mhdawson) -
|
||||
**Michael Dawson** <<midawson@redhat.com>> (he/him)
|
||||
* [panva](https://github.com/panva) -
|
||||
**Filip Skokan** <<panva.ip@gmail.com>> (he/him)
|
||||
* [RafaelGSS](https://github.com/RafaelGSS) -
|
||||
**Rafael Gonzaga** <<rafael.nunu@hotmail.com>> (he/him)
|
||||
* [RaisinTen](https://github.com/RaisinTen) -
|
||||
**Darshan Sen** <<raisinten@gmail.com>> (he/him)
|
||||
* [richardlau](https://github.com/richardlau) -
|
||||
**Richard Lau** <<rlau@redhat.com>>
|
||||
* [ronag](https://github.com/ronag) -
|
||||
**Robert Nagy** <<ronagy@icloud.com>>
|
||||
* [ruyadorno](https://github.com/ruyadorno) -
|
||||
**Ruy Adorno** <<ruy@vlt.sh>> (he/him)
|
||||
* [ShogunPanda](https://github.com/ShogunPanda) -
|
||||
**Paolo Insogna** <<paolo@cowtech.it>> (he/him)
|
||||
* [targos](https://github.com/targos) -
|
||||
**Michaël Zasso** <<targos@protonmail.com>> (he/him)
|
||||
* [tniessen](https://github.com/tniessen) -
|
||||
**Tobias Nießen** <<tniessen@tnie.de>> (he/him)
|
||||
|
||||
#### TSC regular members
|
||||
|
||||
* [BethGriggs](https://github.com/BethGriggs) -
|
||||
**Beth Griggs** <<bethanyngriggs@gmail.com>> (she/her)
|
||||
* [bnoordhuis](https://github.com/bnoordhuis) -
|
||||
**Ben Noordhuis** <<info@bnoordhuis.nl>>
|
||||
* [cjihrig](https://github.com/cjihrig) -
|
||||
**Colin Ihrig** <<cjihrig@gmail.com>> (he/him)
|
||||
* [codebytere](https://github.com/codebytere) -
|
||||
**Shelley Vohr** <<shelley.vohr@gmail.com>> (she/her)
|
||||
* [GeoffreyBooth](https://github.com/GeoffreyBooth) -
|
||||
**Geoffrey Booth** <<webadmin@geoffreybooth.com>> (he/him)
|
||||
* [MoLow](https://github.com/MoLow) -
|
||||
**Moshe Atlow** <<moshe@atlow.co.il>> (he/him)
|
||||
* [Trott](https://github.com/Trott) -
|
||||
**Rich Trott** <<rtrott@gmail.com>> (he/him)
|
||||
|
||||
<details>
|
||||
|
||||
<summary>TSC emeriti members</summary>
|
||||
|
||||
#### TSC emeriti members
|
||||
|
||||
* [addaleax](https://github.com/addaleax) -
|
||||
**Anna Henningsen** <<anna@addaleax.net>> (she/her)
|
||||
* [apapirovski](https://github.com/apapirovski) -
|
||||
**Anatoli Papirovski** <<apapirovski@mac.com>> (he/him)
|
||||
* [ChALkeR](https://github.com/ChALkeR) -
|
||||
**Сковорода Никита Андреевич** <<chalkerx@gmail.com>> (he/him)
|
||||
* [chrisdickinson](https://github.com/chrisdickinson) -
|
||||
**Chris Dickinson** <<christopher.s.dickinson@gmail.com>>
|
||||
* [danbev](https://github.com/danbev) -
|
||||
**Daniel Bevenius** <<daniel.bevenius@gmail.com>> (he/him)
|
||||
* [danielleadams](https://github.com/danielleadams) -
|
||||
**Danielle Adams** <<adamzdanielle@gmail.com>> (she/her)
|
||||
* [evanlucas](https://github.com/evanlucas) -
|
||||
**Evan Lucas** <<evanlucas@me.com>> (he/him)
|
||||
* [fhinkel](https://github.com/fhinkel) -
|
||||
**Franziska Hinkelmann** <<franziska.hinkelmann@gmail.com>> (she/her)
|
||||
* [Fishrock123](https://github.com/Fishrock123) -
|
||||
**Jeremiah Senkpiel** <<fishrock123@rocketmail.com>> (he/they)
|
||||
* [gabrielschulhof](https://github.com/gabrielschulhof) -
|
||||
**Gabriel Schulhof** <<gabrielschulhof@gmail.com>>
|
||||
* [gibfahn](https://github.com/gibfahn) -
|
||||
**Gibson Fahnestock** <<gibfahn@gmail.com>> (he/him)
|
||||
* [indutny](https://github.com/indutny) -
|
||||
**Fedor Indutny** <<fedor@indutny.com>>
|
||||
* [isaacs](https://github.com/isaacs) -
|
||||
**Isaac Z. Schlueter** <<i@izs.me>>
|
||||
* [joshgav](https://github.com/joshgav) -
|
||||
**Josh Gavant** <<josh.gavant@outlook.com>>
|
||||
* [mmarchini](https://github.com/mmarchini) -
|
||||
**Mary Marchini** <<oss@mmarchini.me>> (she/her)
|
||||
* [mscdex](https://github.com/mscdex) -
|
||||
**Brian White** <<mscdex@mscdex.net>>
|
||||
* [MylesBorins](https://github.com/MylesBorins) -
|
||||
**Myles Borins** <<myles.borins@gmail.com>> (he/him)
|
||||
* [nebrius](https://github.com/nebrius) -
|
||||
**Bryan Hughes** <<bryan@nebri.us>>
|
||||
* [ofrobots](https://github.com/ofrobots) -
|
||||
**Ali Ijaz Sheikh** <<ofrobots@google.com>> (he/him)
|
||||
* [orangemocha](https://github.com/orangemocha) -
|
||||
**Alexis Campailla** <<orangemocha@nodejs.org>>
|
||||
* [piscisaureus](https://github.com/piscisaureus) -
|
||||
**Bert Belder** <<bertbelder@gmail.com>>
|
||||
* [rvagg](https://github.com/rvagg) -
|
||||
**Rod Vagg** <<r@va.gg>>
|
||||
* [sam-github](https://github.com/sam-github) -
|
||||
**Sam Roberts** <<vieuxtech@gmail.com>>
|
||||
* [shigeki](https://github.com/shigeki) -
|
||||
**Shigeki Ohtsu** <<ohtsu@ohtsu.org>> (he/him)
|
||||
* [thefourtheye](https://github.com/thefourtheye) -
|
||||
**Sakthipriyan Vairamani** <<thechargingvolcano@gmail.com>> (he/him)
|
||||
* [TimothyGu](https://github.com/TimothyGu) -
|
||||
**Tiancheng "Timothy" Gu** <<timothygu99@gmail.com>> (he/him)
|
||||
* [trevnorris](https://github.com/trevnorris) -
|
||||
**Trevor Norris** <<trev.norris@gmail.com>>
|
||||
|
||||
</details>
|
||||
|
||||
<!-- node-core-utils and find-inactive-collaborators.mjs depend on the format
|
||||
of the collaborator list. If the format changes, those utilities need to be
|
||||
tested and updated. -->
|
||||
|
||||
### Collaborators
|
||||
|
||||
* [abmusse](https://github.com/abmusse) -
|
||||
**Abdirahim Musse** <<abdirahim.musse@ibm.com>>
|
||||
* [addaleax](https://github.com/addaleax) -
|
||||
**Anna Henningsen** <<anna@addaleax.net>> (she/her)
|
||||
* [aduh95](https://github.com/aduh95) -
|
||||
**Antoine du Hamel** <<duhamelantoine1995@gmail.com>> (he/him) - [Support me](https://github.com/sponsors/aduh95)
|
||||
* [anonrig](https://github.com/anonrig) -
|
||||
**Yagiz Nizipli** <<yagiz@nizipli.com>> (he/him) - [Support me](https://github.com/sponsors/anonrig)
|
||||
* [atlowChemi](https://github.com/atlowChemi) -
|
||||
**Chemi Atlow** <<chemi@atlow.co.il>> (he/him)
|
||||
* [Ayase-252](https://github.com/Ayase-252) -
|
||||
**Qingyu Deng** <<i@ayase-lab.com>>
|
||||
* [bengl](https://github.com/bengl) -
|
||||
**Bryan English** <<bryan@bryanenglish.com>> (he/him)
|
||||
* [benjamingr](https://github.com/benjamingr) -
|
||||
**Benjamin Gruenbaum** <<benjamingr@gmail.com>>
|
||||
* [BethGriggs](https://github.com/BethGriggs) -
|
||||
**Beth Griggs** <<bethanyngriggs@gmail.com>> (she/her)
|
||||
* [bnb](https://github.com/bnb) -
|
||||
**Tierney Cyren** <<hello@bnb.im>> (they/them)
|
||||
* [bnoordhuis](https://github.com/bnoordhuis) -
|
||||
**Ben Noordhuis** <<info@bnoordhuis.nl>>
|
||||
* [BridgeAR](https://github.com/BridgeAR) -
|
||||
**Ruben Bridgewater** <<ruben@bridgewater.de>> (he/him)
|
||||
* [cclauss](https://github.com/cclauss) -
|
||||
**Christian Clauss** <<cclauss@me.com>> (he/him)
|
||||
* [cjihrig](https://github.com/cjihrig) -
|
||||
**Colin Ihrig** <<cjihrig@gmail.com>> (he/him)
|
||||
* [codebytere](https://github.com/codebytere) -
|
||||
**Shelley Vohr** <<shelley.vohr@gmail.com>> (she/her)
|
||||
* [cola119](https://github.com/cola119) -
|
||||
**Kohei Ueno** <<kohei.ueno119@gmail.com>> (he/him)
|
||||
* [daeyeon](https://github.com/daeyeon) -
|
||||
**Daeyeon Jeong** <<daeyeon.dev@gmail.com>> (he/him)
|
||||
* [dario-piotrowicz](https://github.com/dario-piotrowicz) -
|
||||
**Dario Piotrowicz** <<dario.piotrowicz@gmail.com>> (he/him)
|
||||
* [debadree25](https://github.com/debadree25) -
|
||||
**Debadree Chatterjee** <<debadree333@gmail.com>> (he/him)
|
||||
* [deokjinkim](https://github.com/deokjinkim) -
|
||||
**Deokjin Kim** <<deokjin81.kim@gmail.com>> (he/him)
|
||||
* [edsadr](https://github.com/edsadr) -
|
||||
**Adrian Estrada** <<edsadr@gmail.com>> (he/him)
|
||||
* [ErickWendel](https://github.com/ErickWendel) -
|
||||
**Erick Wendel** <<erick.workspace@gmail.com>> (he/him)
|
||||
* [Ethan-Arrowood](https://github.com/Ethan-Arrowood) -
|
||||
**Ethan Arrowood** <<ethan@arrowood.dev>> (he/him)
|
||||
* [F3n67u](https://github.com/F3n67u) -
|
||||
**Feng Yu** <<F3n67u@outlook.com>> (he/him)
|
||||
* [fhinkel](https://github.com/fhinkel) -
|
||||
**Franziska Hinkelmann** <<franziska.hinkelmann@gmail.com>> (she/her)
|
||||
* [Flarna](https://github.com/Flarna) -
|
||||
**Gerhard Stöbich** <<deb2001-github@yahoo.de>> (he/they)
|
||||
* [gabrielschulhof](https://github.com/gabrielschulhof) -
|
||||
**Gabriel Schulhof** <<gabrielschulhof@gmail.com>>
|
||||
* [geeksilva97](https://github.com/geeksilva97) -
|
||||
**Edy Silva** <<edigleyssonsilva@gmail.com>> (he/him)
|
||||
* [gengjiawen](https://github.com/gengjiawen) -
|
||||
**Jiawen Geng** <<technicalcute@gmail.com>>
|
||||
* [GeoffreyBooth](https://github.com/GeoffreyBooth) -
|
||||
**Geoffrey Booth** <<webadmin@geoffreybooth.com>> (he/him)
|
||||
* [gireeshpunathil](https://github.com/gireeshpunathil) -
|
||||
**Gireesh Punathil** <<gpunathi@in.ibm.com>> (he/him)
|
||||
* [guybedford](https://github.com/guybedford) -
|
||||
**Guy Bedford** <<guybedford@gmail.com>> (he/him)
|
||||
* [H4ad](https://github.com/H4ad) -
|
||||
**Vinícius Lourenço Claro Cardoso** <<contact@viniciusl.com.br>> (he/him)
|
||||
* [HarshithaKP](https://github.com/HarshithaKP) -
|
||||
**Harshitha K P** <<harshitha014@gmail.com>> (she/her)
|
||||
* [himself65](https://github.com/himself65) -
|
||||
**Zeyu "Alex" Yang** <<himself65@outlook.com>> (he/him)
|
||||
* [jakecastelli](https://github.com/jakecastelli) -
|
||||
**Jake Yuesong Li** <<jake.yuesong@gmail.com>> (he/him)
|
||||
* [JakobJingleheimer](https://github.com/JakobJingleheimer) -
|
||||
**Jacob Smith** <<jacob@frende.me>> (he/him)
|
||||
* [jasnell](https://github.com/jasnell) -
|
||||
**James M Snell** <<jasnell@gmail.com>> (he/him)
|
||||
* [jazelly](https://github.com/jazelly) -
|
||||
**Jason Zhang** <<xzha4350@gmail.com>> (he/him)
|
||||
* [jkrems](https://github.com/jkrems) -
|
||||
**Jan Martin** <<jan.krems@gmail.com>> (he/him)
|
||||
* [JonasBa](https://github.com/JonasBa) -
|
||||
**Jonas Badalic** <<jonas.badalic@gmail.com>> (he/him)
|
||||
* [joyeecheung](https://github.com/joyeecheung) -
|
||||
**Joyee Cheung** <<joyeec9h3@gmail.com>> (she/her)
|
||||
* [juanarbol](https://github.com/juanarbol) -
|
||||
**Juan José Arboleda** <<soyjuanarbol@gmail.com>> (he/him)
|
||||
* [JungMinu](https://github.com/JungMinu) -
|
||||
**Minwoo Jung** <<nodecorelab@gmail.com>> (he/him)
|
||||
* [KhafraDev](https://github.com/KhafraDev) -
|
||||
**Matthew Aitken** <<maitken033380023@gmail.com>> (he/him)
|
||||
* [legendecas](https://github.com/legendecas) -
|
||||
**Chengzhong Wu** <<legendecas@gmail.com>> (he/him)
|
||||
* [lemire](https://github.com/lemire) -
|
||||
**Daniel Lemire** <<daniel@lemire.me>>
|
||||
* [Linkgoron](https://github.com/Linkgoron) -
|
||||
**Nitzan Uziely** <<linkgoron@gmail.com>>
|
||||
* [LiviaMedeiros](https://github.com/LiviaMedeiros) -
|
||||
**LiviaMedeiros** <<livia@cirno.name>>
|
||||
* [ljharb](https://github.com/ljharb) -
|
||||
**Jordan Harband** <<ljharb@gmail.com>>
|
||||
* [lpinca](https://github.com/lpinca) -
|
||||
**Luigi Pinca** <<luigipinca@gmail.com>> (he/him)
|
||||
* [lukekarrys](https://github.com/lukekarrys) -
|
||||
**Luke Karrys** <<luke@lukekarrys.com>> (he/him)
|
||||
* [Lxxyx](https://github.com/Lxxyx) -
|
||||
**Zijian Liu** <<lxxyxzj@gmail.com>> (he/him)
|
||||
* [marco-ippolito](https://github.com/marco-ippolito) -
|
||||
**Marco Ippolito** <<marcoippolito54@gmail.com>> (he/him) - [Support me](https://github.com/sponsors/marco-ippolito)
|
||||
* [marsonya](https://github.com/marsonya) -
|
||||
**Akhil Marsonya** <<akhil.marsonya27@gmail.com>> (he/him)
|
||||
* [MattiasBuelens](https://github.com/MattiasBuelens) -
|
||||
**Mattias Buelens** <<mattias@buelens.com>> (he/him)
|
||||
* [mcollina](https://github.com/mcollina) -
|
||||
**Matteo Collina** <<matteo.collina@gmail.com>> (he/him) - [Support me](https://github.com/sponsors/mcollina)
|
||||
* [meixg](https://github.com/meixg) -
|
||||
**Xuguang Mei** <<meixuguang@gmail.com>> (he/him)
|
||||
* [mhdawson](https://github.com/mhdawson) -
|
||||
**Michael Dawson** <<midawson@redhat.com>> (he/him)
|
||||
* [MoLow](https://github.com/MoLow) -
|
||||
**Moshe Atlow** <<moshe@atlow.co.il>> (he/him)
|
||||
* [MrJithil](https://github.com/MrJithil) -
|
||||
**Jithil P Ponnan** <<jithil@outlook.com>> (he/him)
|
||||
* [panva](https://github.com/panva) -
|
||||
**Filip Skokan** <<panva.ip@gmail.com>> (he/him) - [Support me](https://github.com/sponsors/panva)
|
||||
* [pimterry](https://github.com/pimterry) -
|
||||
**Tim Perry** <<pimterry@gmail.com>> (he/him)
|
||||
* [pmarchini](https://github.com/pmarchini) -
|
||||
**Pietro Marchini** <<pietro.marchini94@gmail.com>> (he/him)
|
||||
* [puskin](https://github.com/puskin) -
|
||||
**Giovanni Bucci** <<github@puskin.it>> (he/him)
|
||||
* [Qard](https://github.com/Qard) -
|
||||
**Stephen Belanger** <<admin@stephenbelanger.com>> (he/him)
|
||||
* [RafaelGSS](https://github.com/RafaelGSS) -
|
||||
**Rafael Gonzaga** <<rafael.nunu@hotmail.com>> (he/him)
|
||||
* [RaisinTen](https://github.com/RaisinTen) -
|
||||
**Darshan Sen** <<raisinten@gmail.com>> (he/him) - [Support me](https://github.com/sponsors/RaisinTen)
|
||||
* [richardlau](https://github.com/richardlau) -
|
||||
**Richard Lau** <<rlau@redhat.com>>
|
||||
* [rluvaton](https://github.com/rluvaton) -
|
||||
**Raz Luvaton** <<rluvaton@gmail.com>> (he/him)
|
||||
* [ronag](https://github.com/ronag) -
|
||||
**Robert Nagy** <<ronagy@icloud.com>>
|
||||
* [ruyadorno](https://github.com/ruyadorno) -
|
||||
**Ruy Adorno** <<ruy@vlt.sh>> (he/him)
|
||||
* [santigimeno](https://github.com/santigimeno) -
|
||||
**Santiago Gimeno** <<santiago.gimeno@gmail.com>>
|
||||
* [ShogunPanda](https://github.com/ShogunPanda) -
|
||||
**Paolo Insogna** <<paolo@cowtech.it>> (he/him)
|
||||
* [srl295](https://github.com/srl295) -
|
||||
**Steven R Loomis** <<srl295@gmail.com>>
|
||||
* [StefanStojanovic](https://github.com/StefanStojanovic) -
|
||||
**Stefan Stojanovic** <<stefan.stojanovic@janeasystems.com>> (he/him)
|
||||
* [sxa](https://github.com/sxa) -
|
||||
**Stewart X Addison** <<sxa@redhat.com>> (he/him)
|
||||
* [targos](https://github.com/targos) -
|
||||
**Michaël Zasso** <<targos@protonmail.com>> (he/him)
|
||||
* [theanarkh](https://github.com/theanarkh) -
|
||||
**theanarkh** <<theratliter@gmail.com>> (he/him)
|
||||
* [tniessen](https://github.com/tniessen) -
|
||||
**Tobias Nießen** <<tniessen@tnie.de>> (he/him)
|
||||
* [trivikr](https://github.com/trivikr) -
|
||||
**Trivikram Kamat** <<trivikr.dev@gmail.com>>
|
||||
* [Trott](https://github.com/Trott) -
|
||||
**Rich Trott** <<rtrott@gmail.com>> (he/him)
|
||||
* [UlisesGascon](https://github.com/UlisesGascon) -
|
||||
**Ulises Gascón** <<ulisesgascongonzalez@gmail.com>> (he/him)
|
||||
* [vmoroz](https://github.com/vmoroz) -
|
||||
**Vladimir Morozov** <<vmorozov@microsoft.com>> (he/him)
|
||||
* [VoltrexKeyva](https://github.com/VoltrexKeyva) -
|
||||
**Mohammed Keyvanzadeh** <<mohammadkeyvanzade94@gmail.com>> (he/him)
|
||||
* [zcbenz](https://github.com/zcbenz) -
|
||||
**Cheng Zhao** <<zcbenz@gmail.com>> (he/him)
|
||||
* [ZYSzys](https://github.com/ZYSzys) -
|
||||
**Yongsheng Zhang** <<zyszys98@gmail.com>> (he/him)
|
||||
|
||||
<details>
|
||||
|
||||
<summary>Emeriti</summary>
|
||||
|
||||
<!-- find-inactive-collaborators.mjs depends on the format of the emeriti list.
|
||||
If the format changes, those utilities need to be tested and updated. -->
|
||||
|
||||
### Collaborator emeriti
|
||||
|
||||
* [ak239](https://github.com/ak239) -
|
||||
**Aleksei Koziatinskii** <<ak239spb@gmail.com>>
|
||||
* [andrasq](https://github.com/andrasq) -
|
||||
**Andras** <<andras@kinvey.com>>
|
||||
* [AndreasMadsen](https://github.com/AndreasMadsen) -
|
||||
**Andreas Madsen** <<amwebdk@gmail.com>> (he/him)
|
||||
* [AnnaMag](https://github.com/AnnaMag) -
|
||||
**Anna M. Kedzierska** <<anna.m.kedzierska@gmail.com>>
|
||||
* [antsmartian](https://github.com/antsmartian) -
|
||||
**Anto Aravinth** <<anto.aravinth.cse@gmail.com>> (he/him)
|
||||
* [apapirovski](https://github.com/apapirovski) -
|
||||
**Anatoli Papirovski** <<apapirovski@mac.com>> (he/him)
|
||||
* [aqrln](https://github.com/aqrln) -
|
||||
**Alexey Orlenko** <<eaglexrlnk@gmail.com>> (he/him)
|
||||
* [AshCripps](https://github.com/AshCripps) -
|
||||
**Ash Cripps** <<email@ashleycripps.co.uk>>
|
||||
* [bcoe](https://github.com/bcoe) -
|
||||
**Ben Coe** <<bencoe@gmail.com>> (he/him)
|
||||
* [bmeck](https://github.com/bmeck) -
|
||||
**Bradley Farias** <<bradley.meck@gmail.com>>
|
||||
* [bmeurer](https://github.com/bmeurer) -
|
||||
**Benedikt Meurer** <<benedikt.meurer@gmail.com>>
|
||||
* [boneskull](https://github.com/boneskull) -
|
||||
**Christopher Hiller** <<boneskull@boneskull.com>> (he/him)
|
||||
* [brendanashworth](https://github.com/brendanashworth) -
|
||||
**Brendan Ashworth** <<brendan.ashworth@me.com>>
|
||||
* [bzoz](https://github.com/bzoz) -
|
||||
**Bartosz Sosnowski** <<bartosz@janeasystems.com>>
|
||||
* [calvinmetcalf](https://github.com/calvinmetcalf) -
|
||||
**Calvin Metcalf** <<calvin.metcalf@gmail.com>>
|
||||
* [ChALkeR](https://github.com/ChALkeR) -
|
||||
**Сковорода Никита Андреевич** <<chalkerx@gmail.com>> (he/him)
|
||||
* [chrisdickinson](https://github.com/chrisdickinson) -
|
||||
**Chris Dickinson** <<christopher.s.dickinson@gmail.com>>
|
||||
* [claudiorodriguez](https://github.com/claudiorodriguez) -
|
||||
**Claudio Rodriguez** <<cjrodr@yahoo.com>>
|
||||
* [danbev](https://github.com/danbev) -
|
||||
**Daniel Bevenius** <<daniel.bevenius@gmail.com>> (he/him)
|
||||
* [danielleadams](https://github.com/danielleadams) -
|
||||
**Danielle Adams** <<adamzdanielle@gmail.com>> (she/her)
|
||||
* [DavidCai1993](https://github.com/DavidCai1993) -
|
||||
**David Cai** <<davidcai1993@yahoo.com>> (he/him)
|
||||
* [davisjam](https://github.com/davisjam) -
|
||||
**Jamie Davis** <<davisjam@vt.edu>> (he/him)
|
||||
* [devnexen](https://github.com/devnexen) -
|
||||
**David Carlier** <<devnexen@gmail.com>>
|
||||
* [devsnek](https://github.com/devsnek) -
|
||||
**Gus Caplan** <<me@gus.host>> (they/them)
|
||||
* [digitalinfinity](https://github.com/digitalinfinity) -
|
||||
**Hitesh Kanwathirtha** <<digitalinfinity@gmail.com>> (he/him)
|
||||
* [dmabupt](https://github.com/dmabupt) -
|
||||
**Xu Meng** <<dmabupt@gmail.com>> (he/him)
|
||||
* [dnlup](https://github.com/dnlup) -
|
||||
**dnlup** <<dnlup.dev@gmail.com>>
|
||||
* [eljefedelrodeodeljefe](https://github.com/eljefedelrodeodeljefe) -
|
||||
**Robert Jefe Lindstaedt** <<robert.lindstaedt@gmail.com>>
|
||||
* [estliberitas](https://github.com/estliberitas) -
|
||||
**Alexander Makarenko** <<estliberitas@gmail.com>>
|
||||
* [eugeneo](https://github.com/eugeneo) -
|
||||
**Eugene Ostroukhov** <<eostroukhov@google.com>>
|
||||
* [evanlucas](https://github.com/evanlucas) -
|
||||
**Evan Lucas** <<evanlucas@me.com>> (he/him)
|
||||
* [firedfox](https://github.com/firedfox) -
|
||||
**Daniel Wang** <<wangyang0123@gmail.com>>
|
||||
* [Fishrock123](https://github.com/Fishrock123) -
|
||||
**Jeremiah Senkpiel** <<fishrock123@rocketmail.com>> (he/they)
|
||||
* [gdams](https://github.com/gdams) -
|
||||
**George Adams** <<gadams@microsoft.com>> (he/him)
|
||||
* [geek](https://github.com/geek) -
|
||||
**Wyatt Preul** <<wpreul@gmail.com>>
|
||||
* [gibfahn](https://github.com/gibfahn) -
|
||||
**Gibson Fahnestock** <<gibfahn@gmail.com>> (he/him)
|
||||
* [glentiki](https://github.com/glentiki) -
|
||||
**Glen Keane** <<glenkeane.94@gmail.com>> (he/him)
|
||||
* [hashseed](https://github.com/hashseed) -
|
||||
**Yang Guo** <<yangguo@chromium.org>> (he/him)
|
||||
* [hiroppy](https://github.com/hiroppy) -
|
||||
**Yuta Hiroto** <<hello@hiroppy.me>> (he/him)
|
||||
* [iansu](https://github.com/iansu) -
|
||||
**Ian Sutherland** <<ian@iansutherland.ca>>
|
||||
* [iarna](https://github.com/iarna) -
|
||||
**Rebecca Turner** <<me@re-becca.org>>
|
||||
* [imran-iq](https://github.com/imran-iq) -
|
||||
**Imran Iqbal** <<imran@imraniqbal.org>>
|
||||
* [imyller](https://github.com/imyller) -
|
||||
**Ilkka Myller** <<ilkka.myller@nodefield.com>>
|
||||
* [indutny](https://github.com/indutny) -
|
||||
**Fedor Indutny** <<fedor@indutny.com>>
|
||||
* [isaacs](https://github.com/isaacs) -
|
||||
**Isaac Z. Schlueter** <<i@izs.me>>
|
||||
* [italoacasas](https://github.com/italoacasas) -
|
||||
**Italo A. Casas** <<me@italoacasas.com>> (he/him)
|
||||
* [JacksonTian](https://github.com/JacksonTian) -
|
||||
**Jackson Tian** <<shyvo1987@gmail.com>>
|
||||
* [jasongin](https://github.com/jasongin) -
|
||||
**Jason Ginchereau** <<jasongin@microsoft.com>>
|
||||
* [jbergstroem](https://github.com/jbergstroem) -
|
||||
**Johan Bergström** <<bugs@bergstroem.nu>>
|
||||
* [jdalton](https://github.com/jdalton) -
|
||||
**John-David Dalton** <<john.david.dalton@gmail.com>>
|
||||
* [jhamhader](https://github.com/jhamhader) -
|
||||
**Yuval Brik** <<yuval@brik.org.il>>
|
||||
* [joaocgreis](https://github.com/joaocgreis) -
|
||||
**João Reis** <<reis@janeasystems.com>>
|
||||
* [joesepi](https://github.com/joesepi) -
|
||||
**Joe Sepi** <<sepi@joesepi.com>> (he/him)
|
||||
* [joshgav](https://github.com/joshgav) -
|
||||
**Josh Gavant** <<josh.gavant@outlook.com>>
|
||||
* [julianduque](https://github.com/julianduque) -
|
||||
**Julian Duque** <<julianduquej@gmail.com>> (he/him)
|
||||
* [kfarnung](https://github.com/kfarnung) -
|
||||
**Kyle Farnung** <<kfarnung@microsoft.com>> (he/him)
|
||||
* [kunalspathak](https://github.com/kunalspathak) -
|
||||
**Kunal Pathak** <<kunal.pathak@microsoft.com>>
|
||||
* [kuriyosh](https://github.com/kuriyosh) -
|
||||
**Yoshiki Kurihara** <<yosyos0306@gmail.com>> (he/him)
|
||||
* [kvakil](https://github.com/kvakil) -
|
||||
**Keyhan Vakil** <<kvakil@sylph.kvakil.me>>
|
||||
* [lance](https://github.com/lance) -
|
||||
**Lance Ball** <<lball@redhat.com>> (he/him)
|
||||
* [Leko](https://github.com/Leko) -
|
||||
**Shingo Inoue** <<leko.noor@gmail.com>> (he/him)
|
||||
* [lucamaraschi](https://github.com/lucamaraschi) -
|
||||
**Luca Maraschi** <<luca.maraschi@gmail.com>> (he/him)
|
||||
* [lundibundi](https://github.com/lundibundi) -
|
||||
**Denys Otrishko** <<shishugi@gmail.com>> (he/him)
|
||||
* [lxe](https://github.com/lxe) -
|
||||
**Aleksey Smolenchuk** <<lxe@lxe.co>>
|
||||
* [maclover7](https://github.com/maclover7) -
|
||||
**Jon Moss** <<me@jonathanmoss.me>> (he/him)
|
||||
* [mafintosh](https://github.com/mafintosh) -
|
||||
**Mathias Buus** <<mathiasbuus@gmail.com>> (he/him)
|
||||
* [matthewloring](https://github.com/matthewloring) -
|
||||
**Matthew Loring** <<mattloring@google.com>>
|
||||
* [Mesteery](https://github.com/Mesteery) -
|
||||
**Mestery** <<mestery@protonmail.com>> (he/him)
|
||||
* [micnic](https://github.com/micnic) -
|
||||
**Nicu Micleușanu** <<micnic90@gmail.com>> (he/him)
|
||||
* [mikeal](https://github.com/mikeal) -
|
||||
**Mikeal Rogers** <<mikeal.rogers@gmail.com>>
|
||||
* [miladfarca](https://github.com/miladfarca) -
|
||||
**Milad Fa** <<mfarazma@redhat.com>> (he/him)
|
||||
* [mildsunrise](https://github.com/mildsunrise) -
|
||||
**Alba Mendez** <<me@alba.sh>> (she/her)
|
||||
* [misterdjules](https://github.com/misterdjules) -
|
||||
**Julien Gilli** <<jgilli@netflix.com>>
|
||||
* [mmarchini](https://github.com/mmarchini) -
|
||||
**Mary Marchini** <<oss@mmarchini.me>> (she/her)
|
||||
* [monsanto](https://github.com/monsanto) -
|
||||
**Christopher Monsanto** <<chris@monsan.to>>
|
||||
* [MoonBall](https://github.com/MoonBall) -
|
||||
**Chen Gang** <<gangc.cxy@foxmail.com>>
|
||||
* [mscdex](https://github.com/mscdex) -
|
||||
**Brian White** <<mscdex@mscdex.net>>
|
||||
* [MylesBorins](https://github.com/MylesBorins) -
|
||||
**Myles Borins** <<myles.borins@gmail.com>> (he/him)
|
||||
* [not-an-aardvark](https://github.com/not-an-aardvark) -
|
||||
**Teddy Katz** <<teddy.katz@gmail.com>> (he/him)
|
||||
* [ofrobots](https://github.com/ofrobots) -
|
||||
**Ali Ijaz Sheikh** <<ofrobots@google.com>> (he/him)
|
||||
* [Olegas](https://github.com/Olegas) -
|
||||
**Oleg Elifantiev** <<oleg@elifantiev.ru>>
|
||||
* [orangemocha](https://github.com/orangemocha) -
|
||||
**Alexis Campailla** <<orangemocha@nodejs.org>>
|
||||
* [othiym23](https://github.com/othiym23) -
|
||||
**Forrest L Norvell** <<ogd@aoaioxxysz.net>> (they/them/themself)
|
||||
* [ovflowd](https://github.com/ovflowd) -
|
||||
**Claudio Wunder** <<cwunder@gnome.org>> (he/they)
|
||||
* [oyyd](https://github.com/oyyd) -
|
||||
**Ouyang Yadong** <<oyydoibh@gmail.com>> (he/him)
|
||||
* [petkaantonov](https://github.com/petkaantonov) -
|
||||
**Petka Antonov** <<petka_antonov@hotmail.com>>
|
||||
* [phillipj](https://github.com/phillipj) -
|
||||
**Phillip Johnsen** <<johphi@gmail.com>>
|
||||
* [piscisaureus](https://github.com/piscisaureus) -
|
||||
**Bert Belder** <<bertbelder@gmail.com>>
|
||||
* [pmq20](https://github.com/pmq20) -
|
||||
**Minqi Pan** <<pmq2001@gmail.com>>
|
||||
* [PoojaDurgad](https://github.com/PoojaDurgad) -
|
||||
**Pooja D P** <<Pooja.D.P@ibm.com>> (she/her)
|
||||
* [princejwesley](https://github.com/princejwesley) -
|
||||
**Prince John Wesley** <<princejohnwesley@gmail.com>>
|
||||
* [psmarshall](https://github.com/psmarshall) -
|
||||
**Peter Marshall** <<petermarshall@chromium.org>> (he/him)
|
||||
* [puzpuzpuz](https://github.com/puzpuzpuz) -
|
||||
**Andrey Pechkurov** <<apechkurov@gmail.com>> (he/him)
|
||||
* [refack](https://github.com/refack) -
|
||||
**Refael Ackermann (רפאל פלחי)** <<refack@gmail.com>> (he/him/הוא/אתה)
|
||||
* [rexagod](https://github.com/rexagod) -
|
||||
**Pranshu Srivastava** <<rexagod@gmail.com>> (he/him)
|
||||
* [rickyes](https://github.com/rickyes) -
|
||||
**Ricky Zhou** <<0x19951125@gmail.com>> (he/him)
|
||||
* [rlidwka](https://github.com/rlidwka) -
|
||||
**Alex Kocharin** <<alex@kocharin.ru>>
|
||||
* [rmg](https://github.com/rmg) -
|
||||
**Ryan Graham** <<r.m.graham@gmail.com>>
|
||||
* [robertkowalski](https://github.com/robertkowalski) -
|
||||
**Robert Kowalski** <<rok@kowalski.gd>>
|
||||
* [romankl](https://github.com/romankl) -
|
||||
**Roman Klauke** <<romaaan.git@gmail.com>>
|
||||
* [ronkorving](https://github.com/ronkorving) -
|
||||
**Ron Korving** <<ron@ronkorving.nl>>
|
||||
* [RReverser](https://github.com/RReverser) -
|
||||
**Ingvar Stepanyan** <<me@rreverser.com>>
|
||||
* [rubys](https://github.com/rubys) -
|
||||
**Sam Ruby** <<rubys@intertwingly.net>>
|
||||
* [rvagg](https://github.com/rvagg) -
|
||||
**Rod Vagg** <<rod@vagg.org>>
|
||||
* [ryzokuken](https://github.com/ryzokuken) -
|
||||
**Ujjwal Sharma** <<ryzokuken@disroot.org>> (he/him)
|
||||
* [saghul](https://github.com/saghul) -
|
||||
**Saúl Ibarra Corretgé** <<s@saghul.net>>
|
||||
* [sam-github](https://github.com/sam-github) -
|
||||
**Sam Roberts** <<vieuxtech@gmail.com>>
|
||||
* [sebdeckers](https://github.com/sebdeckers) -
|
||||
**Sebastiaan Deckers** <<sebdeckers83@gmail.com>>
|
||||
* [seishun](https://github.com/seishun) -
|
||||
**Nikolai Vavilov** <<vvnicholas@gmail.com>>
|
||||
* [shigeki](https://github.com/shigeki) -
|
||||
**Shigeki Ohtsu** <<ohtsu@ohtsu.org>> (he/him)
|
||||
* [shisama](https://github.com/shisama) -
|
||||
**Masashi Hirano** <<shisama07@gmail.com>> (he/him)
|
||||
* [silverwind](https://github.com/silverwind) -
|
||||
**Roman Reiss** <<me@silverwind.io>>
|
||||
* [starkwang](https://github.com/starkwang) -
|
||||
**Weijia Wang** <<starkwang@126.com>>
|
||||
* [stefanmb](https://github.com/stefanmb) -
|
||||
**Stefan Budeanu** <<stefan@budeanu.com>>
|
||||
* [tellnes](https://github.com/tellnes) -
|
||||
**Christian Tellnes** <<christian@tellnes.no>>
|
||||
* [thefourtheye](https://github.com/thefourtheye) -
|
||||
**Sakthipriyan Vairamani** <<thechargingvolcano@gmail.com>> (he/him)
|
||||
* [thlorenz](https://github.com/thlorenz) -
|
||||
**Thorsten Lorenz** <<thlorenz@gmx.de>>
|
||||
* [TimothyGu](https://github.com/TimothyGu) -
|
||||
**Tiancheng "Timothy" Gu** <<timothygu99@gmail.com>> (he/him)
|
||||
* [trevnorris](https://github.com/trevnorris) -
|
||||
**Trevor Norris** <<trev.norris@gmail.com>>
|
||||
* [tunniclm](https://github.com/tunniclm) -
|
||||
**Mike Tunnicliffe** <<m.j.tunnicliffe@gmail.com>>
|
||||
* [vdeturckheim](https://github.com/vdeturckheim) -
|
||||
**Vladimir de Turckheim** <<vlad2t@hotmail.com>> (he/him)
|
||||
* [vkurchatkin](https://github.com/vkurchatkin) -
|
||||
**Vladimir Kurchatkin** <<vladimir.kurchatkin@gmail.com>>
|
||||
* [vsemozhetbyt](https://github.com/vsemozhetbyt) -
|
||||
**Vse Mozhet Byt** <<vsemozhetbyt@gmail.com>> (he/him)
|
||||
* [watilde](https://github.com/watilde) -
|
||||
**Daijiro Wachi** <<daijiro.wachi@gmail.com>> (he/him)
|
||||
* [watson](https://github.com/watson) -
|
||||
**Thomas Watson** <<w@tson.dk>>
|
||||
* [whitlockjc](https://github.com/whitlockjc) -
|
||||
**Jeremy Whitlock** <<jwhitlock@apache.org>>
|
||||
* [XadillaX](https://github.com/XadillaX) -
|
||||
**Khaidi Chu** <<i@2333.moe>> (he/him)
|
||||
* [yashLadha](https://github.com/yashLadha) -
|
||||
**Yash Ladha** <<yash@yashladha.in>> (he/him)
|
||||
* [yhwang](https://github.com/yhwang) -
|
||||
**Yihong Wang** <<yh.wang@ibm.com>>
|
||||
* [yorkie](https://github.com/yorkie) -
|
||||
**Yorkie Liu** <<yorkiefixer@gmail.com>>
|
||||
* [yosuke-furukawa](https://github.com/yosuke-furukawa) -
|
||||
**Yosuke Furukawa** <<yosuke.furukawa@gmail.com>>
|
||||
|
||||
</details>
|
||||
|
||||
<!--lint enable prohibited-strings-->
|
||||
|
||||
Collaborators follow the [Collaborator Guide](./doc/contributing/collaborator-guide.md) in
|
||||
maintaining the Node.js project.
|
||||
|
||||
### Triagers
|
||||
|
||||
* [1ilsang](https://github.com/1ilsang) -
|
||||
**Sangchul Lee** <<1ilsang.dev@gmail.com>> (he/him)
|
||||
* [atlowChemi](https://github.com/atlowChemi) -
|
||||
**Chemi Atlow** <<chemi@atlow.co.il>> (he/him)
|
||||
* [Ayase-252](https://github.com/Ayase-252) -
|
||||
**Qingyu Deng** <<i@ayase-lab.com>>
|
||||
* [bjohansebas](https://github.com/bjohansebas) -
|
||||
**Sebastian Beltran** <<bjohansebas@gmail.com>>
|
||||
* [bmuenzenmeyer](https://github.com/bmuenzenmeyer) -
|
||||
**Brian Muenzenmeyer** <<brian.muenzenmeyer@gmail.com>> (he/him)
|
||||
* [CanadaHonk](https://github.com/CanadaHonk) -
|
||||
**Oliver Medhurst** <<honk@goose.icu>> (they/them)
|
||||
* [daeyeon](https://github.com/daeyeon) -
|
||||
**Daeyeon Jeong** <<daeyeon.dev@gmail.com>> (he/him)
|
||||
* [F3n67u](https://github.com/F3n67u) -
|
||||
**Feng Yu** <<F3n67u@outlook.com>> (he/him)
|
||||
* [gireeshpunathil](https://github.com/gireeshpunathil) -
|
||||
**Gireesh Punathil** <<gpunathi@in.ibm.com>> (he/him)
|
||||
* [gurgunday](https://github.com/gurgunday) -
|
||||
**Gürgün Dayıoğlu** <<hey@gurgun.day>>
|
||||
* [HBSPS](https://github.com/HBSPS) -
|
||||
**Wiyeong Seo** <<hbsps.dev@gmail.com>>
|
||||
* [iam-frankqiu](https://github.com/iam-frankqiu) -
|
||||
**Frank Qiu** <<iam.frankqiu@gmail.com>> (he/him)
|
||||
* [KevinEady](https://github.com/KevinEady) -
|
||||
**Kevin Eady** <<kevin.c.eady@gmail.com>> (he/him)
|
||||
* [marsonya](https://github.com/marsonya) -
|
||||
**Akhil Marsonya** <<akhil.marsonya27@gmail.com>> (he/him)
|
||||
* [meixg](https://github.com/meixg) -
|
||||
**Xuguang Mei** <<meixuguang@gmail.com>> (he/him)
|
||||
* [preveen-stack](https://github.com/preveen-stack) -
|
||||
**Preveen Padmanabhan** <<wide4head@gmail.com>> (he/him)
|
||||
* [RaisinTen](https://github.com/RaisinTen) -
|
||||
**Darshan Sen** <<raisinten@gmail.com>> (he/him)
|
||||
* [VoltrexKeyva](https://github.com/VoltrexKeyva) -
|
||||
**Mohammed Keyvanzadeh** <<mohammadkeyvanzade94@gmail.com>> (he/him)
|
||||
|
||||
Triagers follow the [Triage Guide](./doc/contributing/issues.md#triaging-a-bug-report) when
|
||||
responding to new issues.
|
||||
|
||||
### Release keys
|
||||
|
||||
Primary GPG keys for Node.js Releasers (some Releasers sign with subkeys):
|
||||
|
||||
* **Antoine du Hamel** <<duhamelantoine1995@gmail.com>>
|
||||
`C0D6248439F1D5604AAFFB4021D900FFDB233756`
|
||||
* **Juan José Arboleda** <<soyjuanarbol@gmail.com>>
|
||||
`DD792F5973C6DE52C432CBDAC77ABFA00DDBF2B7`
|
||||
* **Marco Ippolito** <<marcoippolito54@gmail.com>>
|
||||
`CC68F5A3106FF448322E48ED27F5E38D5B0A215F`
|
||||
* **Michaël Zasso** <<targos@protonmail.com>>
|
||||
`8FCCA13FEF1D0C2E91008E09770F7A9A5AE15600`
|
||||
* **Rafael Gonzaga** <<rafael.nunu@hotmail.com>>
|
||||
`890C08DB8579162FEE0DF9DB8BEAB4DFCF555EF4`
|
||||
* **Richard Lau** <<rlau@redhat.com>>
|
||||
`C82FA3AE1CBEDC6BE46B9360C43CEC45C17AB93C`
|
||||
* **Ruy Adorno** <<ruyadorno@hotmail.com>>
|
||||
`108F52B48DB57BB0CC439B2997B01419BD92F80A`
|
||||
* **Ulises Gascón** <<ulisesgascongonzalez@gmail.com>>
|
||||
`A363A499291CBBC940DD62E41F10027AF002F8B0`
|
||||
|
||||
To import the full set of trusted release keys (including subkeys possibly used
|
||||
to sign releases):
|
||||
|
||||
```bash
|
||||
gpg --keyserver hkps://keys.openpgp.org --recv-keys C0D6248439F1D5604AAFFB4021D900FFDB233756 # Antoine du Hamel
|
||||
gpg --keyserver hkps://keys.openpgp.org --recv-keys DD792F5973C6DE52C432CBDAC77ABFA00DDBF2B7 # Juan José Arboleda
|
||||
gpg --keyserver hkps://keys.openpgp.org --recv-keys CC68F5A3106FF448322E48ED27F5E38D5B0A215F # Marco Ippolito
|
||||
gpg --keyserver hkps://keys.openpgp.org --recv-keys 8FCCA13FEF1D0C2E91008E09770F7A9A5AE15600 # Michaël Zasso
|
||||
gpg --keyserver hkps://keys.openpgp.org --recv-keys 890C08DB8579162FEE0DF9DB8BEAB4DFCF555EF4 # Rafael Gonzaga
|
||||
gpg --keyserver hkps://keys.openpgp.org --recv-keys C82FA3AE1CBEDC6BE46B9360C43CEC45C17AB93C # Richard Lau
|
||||
gpg --keyserver hkps://keys.openpgp.org --recv-keys 108F52B48DB57BB0CC439B2997B01419BD92F80A # Ruy Adorno
|
||||
gpg --keyserver hkps://keys.openpgp.org --recv-keys A363A499291CBBC940DD62E41F10027AF002F8B0 # Ulises Gascón
|
||||
```
|
||||
|
||||
See [Verifying binaries](#verifying-binaries) for how to use these keys to
|
||||
verify a downloaded file.
|
||||
|
||||
<details>
|
||||
|
||||
<summary>Other keys used to sign some previous releases</summary>
|
||||
|
||||
* **Beth Griggs** <<bethanyngriggs@gmail.com>>
|
||||
`4ED778F539E3634C779C87C6D7062848A1AB005C`
|
||||
* **Bryan English** <<bryan@bryanenglish.com>>
|
||||
`141F07595B7B3FFE74309A937405533BE57C7D57`
|
||||
* **Chris Dickinson** <<christopher.s.dickinson@gmail.com>>
|
||||
`9554F04D7259F04124DE6B476D5A82AC7E37093B`
|
||||
* **Colin Ihrig** <<cjihrig@gmail.com>>
|
||||
`94AE36675C464D64BAFA68DD7434390BDBE9B9C5`
|
||||
* **Danielle Adams** <<adamzdanielle@gmail.com>>
|
||||
`1C050899334244A8AF75E53792EF661D867B9DFA`
|
||||
`74F12602B6F1C4E913FAA37AD3A89613643B6201`
|
||||
* **Evan Lucas** <<evanlucas@me.com>>
|
||||
`B9AE9905FFD7803F25714661B63B535A4C206CA9`
|
||||
* **Gibson Fahnestock** <<gibfahn@gmail.com>>
|
||||
`77984A986EBC2AA786BC0F66B01FBB92821C587A`
|
||||
* **Isaac Z. Schlueter** <<i@izs.me>>
|
||||
`93C7E9E91B49E432C2F75674B0A78B0A6C481CF6`
|
||||
* **Italo A. Casas** <<me@italoacasas.com>>
|
||||
`56730D5401028683275BD23C23EFEFE93C4CFFFE`
|
||||
* **James M Snell** <<jasnell@keybase.io>>
|
||||
`71DCFD284A79C3B38668286BC97EC7A07EDE3FC1`
|
||||
* **Jeremiah Senkpiel** <<fishrock@keybase.io>>
|
||||
`FD3A5288F042B6850C66B31F09FE44734EB7990E`
|
||||
* **Juan José Arboleda** <<soyjuanarbol@gmail.com>>
|
||||
`61FC681DFB92A079F1685E77973F295594EC4689`
|
||||
* **Julien Gilli** <<jgilli@fastmail.fm>>
|
||||
`114F43EE0176B71C7BC219DD50A3051F888C628D`
|
||||
* **Myles Borins** <<myles.borins@gmail.com>>
|
||||
`C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8`
|
||||
* **Rod Vagg** <<rod@vagg.org>>
|
||||
`DD8F2338BAE7501E3DD5AC78C273792F7D83545D`
|
||||
* **Ruben Bridgewater** <<ruben@bridgewater.de>>
|
||||
`A48C2BEE680E841632CD4E44F07496B3EB3C1762`
|
||||
* **Shelley Vohr** <<shelley.vohr@gmail.com>>
|
||||
`B9E2F5981AA6E0CD28160D9FF13993A75599653C`
|
||||
* **Timothy J Fontaine** <<tjfontaine@gmail.com>>
|
||||
`7937DFD2AB06298B2293C3187D33FF9D0246406D`
|
||||
|
||||
</details>
|
||||
|
||||
### Security release stewards
|
||||
|
||||
When possible, the commitment to take slots in the
|
||||
security release steward rotation is made by companies in order
|
||||
to ensure individuals who act as security stewards have the
|
||||
support and recognition from their employer to be able to
|
||||
prioritize security releases. Security release stewards manage security
|
||||
releases on a rotation basis as outlined in the
|
||||
[security release process](./doc/contributing/security-release-process.md).
|
||||
|
||||
* [Datadog](https://www.datadoghq.com/)
|
||||
* [bengl](https://github.com/bengl) -
|
||||
**Bryan English** <<bryan@bryanenglish.com>> (he/him)
|
||||
* [NodeSource](https://nodesource.com/)
|
||||
* [juanarbol](https://github.com/juanarbol) -
|
||||
**Juan José Arboleda** <<soyjuanarbol@gmail.com>> (he/him)
|
||||
* [RafaelGSS](https://github.com/RafaelGSS) -
|
||||
**Rafael Gonzaga** <<rafael.nunu@hotmail.com>> (he/him)
|
||||
* [Platformatic](https://platformatic.dev/)
|
||||
* [mcollina](https://github.com/mcollina) -
|
||||
**Matteo Collina** <<matteo.collina@gmail.com>> (he/him)
|
||||
* [Red Hat](https://redhat.com) / [IBM](https://ibm.com)
|
||||
* [joesepi](https://github.com/joesepi) -
|
||||
**Joe Sepi** <<joesepi@ibm.com>> (he/him)
|
||||
* [mhdawson](https://github.com/mhdawson) -
|
||||
**Michael Dawson** <<midawson@redhat.com>> (he/him)
|
||||
|
||||
## License
|
||||
|
||||
Node.js is available under the
|
||||
[MIT License](https://opensource.org/licenses/MIT). Node.js also includes
|
||||
external libraries that are available under a variety of licenses. See
|
||||
[LICENSE](https://github.com/nodejs/node/blob/HEAD/LICENSE) for the full
|
||||
license text.
|
||||
|
||||
[Code of Conduct]: https://github.com/nodejs/admin/blob/HEAD/CODE_OF_CONDUCT.md
|
||||
[Contributing to the project]: CONTRIBUTING.md
|
||||
[Node.js website]: https://nodejs.org/
|
||||
[OpenJS Foundation]: https://openjsf.org/
|
||||
[Strategic initiatives]: doc/contributing/strategic-initiatives.md
|
||||
[Technical values and prioritization]: doc/contributing/technical-values.md
|
||||
[Working Groups]: https://github.com/nodejs/TSC/blob/HEAD/WORKING_GROUPS.md
|
||||
BIN
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/bin/node
generated
vendored
Executable file
BIN
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/bin/node
generated
vendored
Executable file
Binary file not shown.
766
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/common.gypi
generated
vendored
Normal file
766
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/common.gypi
generated
vendored
Normal file
@@ -0,0 +1,766 @@
|
||||
{
|
||||
'variables': {
|
||||
'configuring_node%': 0,
|
||||
'asan%': 0,
|
||||
'ubsan%': 0,
|
||||
'visibility%': 'hidden', # V8's visibility setting
|
||||
'target_arch%': 'ia32', # set v8's target architecture
|
||||
'host_arch%': 'ia32', # set v8's host architecture
|
||||
'want_separate_host_toolset%': 0, # V8 should not build target and host
|
||||
'library%': 'static_library', # allow override to 'shared_library' for DLL/.so builds
|
||||
'component%': 'static_library', # NB. these names match with what V8 expects
|
||||
'msvs_multi_core_compile': '0', # we do enable multicore compiles, but not using the V8 way
|
||||
'enable_pgo_generate%': '0',
|
||||
'enable_pgo_use%': '0',
|
||||
'python%': 'python',
|
||||
|
||||
'node_shared%': 'false',
|
||||
'force_dynamic_crt%': 0,
|
||||
'node_use_v8_platform%': 'true',
|
||||
'node_use_bundled_v8%': 'true',
|
||||
'node_module_version%': '',
|
||||
'node_with_ltcg%': '',
|
||||
'node_shared_openssl%': 'false',
|
||||
|
||||
'node_tag%': '',
|
||||
'uv_library%': 'static_library',
|
||||
|
||||
'clang%': 0,
|
||||
'error_on_warn%': 'false',
|
||||
'suppress_all_error_on_warn%': 'false',
|
||||
'control_flow_guard%': 'false',
|
||||
|
||||
'openssl_product': '<(STATIC_LIB_PREFIX)openssl<(STATIC_LIB_SUFFIX)',
|
||||
'openssl_no_asm%': 0,
|
||||
|
||||
# Don't use ICU data file (icudtl.dat) from V8, we use our own.
|
||||
'icu_use_data_file_flag%': 0,
|
||||
|
||||
# Reset this number to 0 on major V8 upgrades.
|
||||
# Increment by one for each non-official patch applied to deps/v8.
|
||||
'v8_embedder_string': '-node.26',
|
||||
|
||||
##### V8 defaults for Node.js #####
|
||||
|
||||
# Turn on SipHash for hash seed generation, addresses HashWick
|
||||
'v8_use_siphash': 'true',
|
||||
|
||||
# These are more relevant for V8 internal development.
|
||||
# Refs: https://github.com/nodejs/node/issues/23122
|
||||
# Refs: https://github.com/nodejs/node/issues/23167
|
||||
# Enable compiler warnings when using V8_DEPRECATED apis from V8 code.
|
||||
'v8_deprecation_warnings': 0,
|
||||
# Enable compiler warnings when using V8_DEPRECATE_SOON apis from V8 code.
|
||||
'v8_imminent_deprecation_warnings': 0,
|
||||
|
||||
# Enable disassembler for `--print-code` v8 options
|
||||
'v8_enable_disassembler': 1,
|
||||
|
||||
# Sets -dOBJECT_PRINT.
|
||||
'v8_enable_object_print%': 1,
|
||||
|
||||
# https://github.com/nodejs/node/pull/22920/files#r222779926
|
||||
'v8_enable_handle_zapping': 0,
|
||||
|
||||
# Disable pointer compression. Can be enabled at build time via configure
|
||||
# options but default values are required here as this file is also used by
|
||||
# node-gyp to build addons.
|
||||
'v8_enable_pointer_compression%': 0,
|
||||
'v8_enable_31bit_smis_on_64bit_arch%': 0,
|
||||
|
||||
# Disable v8 hugepage by default.
|
||||
'v8_enable_hugepage%': 0,
|
||||
|
||||
# This is more of a V8 dev setting
|
||||
# https://github.com/nodejs/node/pull/22920/files#r222779926
|
||||
'v8_enable_fast_mksnapshot': 0,
|
||||
|
||||
'v8_win64_unwinding_info': 1,
|
||||
|
||||
# Variables controlling external defines exposed in public headers.
|
||||
'v8_enable_conservative_stack_scanning%': 0,
|
||||
'v8_enable_direct_local%': 0,
|
||||
'v8_enable_map_packing%': 0,
|
||||
'v8_enable_pointer_compression_shared_cage%': 0,
|
||||
'v8_enable_external_code_space%': 0,
|
||||
'v8_enable_sandbox%': 0,
|
||||
'v8_enable_v8_checks%': 0,
|
||||
'v8_enable_zone_compression%': 0,
|
||||
'v8_use_perfetto': 0,
|
||||
'tsan%': 0,
|
||||
|
||||
##### end V8 defaults #####
|
||||
|
||||
'conditions': [
|
||||
['OS == "win"', {
|
||||
'os_posix': 0,
|
||||
'v8_postmortem_support%': 0,
|
||||
'obj_dir': '<(PRODUCT_DIR)/obj',
|
||||
'v8_base': '<(PRODUCT_DIR)/lib/libv8_snapshot.a',
|
||||
}, {
|
||||
'os_posix': 1,
|
||||
'v8_postmortem_support%': 1,
|
||||
}],
|
||||
['GENERATOR == "ninja"', {
|
||||
'obj_dir': '<(PRODUCT_DIR)/obj',
|
||||
'v8_base': '<(PRODUCT_DIR)/obj/tools/v8_gypfiles/libv8_snapshot.a',
|
||||
}, {
|
||||
'obj_dir%': '<(PRODUCT_DIR)/obj.target',
|
||||
'v8_base': '<(PRODUCT_DIR)/obj.target/tools/v8_gypfiles/libv8_snapshot.a',
|
||||
}],
|
||||
['OS=="mac"', {
|
||||
'obj_dir%': '<(PRODUCT_DIR)/obj.target',
|
||||
'v8_base': '<(PRODUCT_DIR)/libv8_snapshot.a',
|
||||
}],
|
||||
# V8 pointer compression only supports 64bit architectures.
|
||||
['target_arch in "arm ia32 mips mipsel ppc"', {
|
||||
'v8_enable_pointer_compression': 0,
|
||||
'v8_enable_31bit_smis_on_64bit_arch': 0,
|
||||
'v8_enable_external_code_space': 0,
|
||||
'v8_enable_sandbox': 0
|
||||
}],
|
||||
['target_arch in "ppc64 s390x"', {
|
||||
'v8_enable_backtrace': 1,
|
||||
}],
|
||||
['OS=="linux" or OS=="openharmony"', {
|
||||
'node_section_ordering_info%': ''
|
||||
}],
|
||||
['OS == "zos"', {
|
||||
# use ICU data file on z/OS
|
||||
'icu_use_data_file_flag%': 1
|
||||
}]
|
||||
],
|
||||
},
|
||||
|
||||
'target_defaults': {
|
||||
'default_configuration': 'Release',
|
||||
'configurations': {
|
||||
'Debug': {
|
||||
'variables': {
|
||||
'v8_enable_handle_zapping': 1,
|
||||
'conditions': [
|
||||
['node_shared != "true"', {
|
||||
'MSVC_runtimeType': 1, # MultiThreadedDebug (/MTd)
|
||||
}, {
|
||||
'MSVC_runtimeType': 3, # MultiThreadedDebugDLL (/MDd)
|
||||
}],
|
||||
],
|
||||
},
|
||||
'defines': [ 'DEBUG', '_DEBUG' ],
|
||||
'cflags': [ '-g', '-O0' ],
|
||||
'conditions': [
|
||||
['OS in "aix os400"', {
|
||||
'cflags': [ '-gxcoff' ],
|
||||
'ldflags': [ '-Wl,-bbigtoc' ],
|
||||
}],
|
||||
['OS == "android"', {
|
||||
'cflags': [ '-fPIC' ],
|
||||
'ldflags': [ '-fPIC' ]
|
||||
}],
|
||||
['clang==1', {
|
||||
'msbuild_toolset': 'ClangCL',
|
||||
}],
|
||||
],
|
||||
'msvs_settings': {
|
||||
'VCCLCompilerTool': {
|
||||
'BasicRuntimeChecks': 3, # /RTC1
|
||||
'MinimalRebuild': 'false',
|
||||
'OmitFramePointers': 'false',
|
||||
'Optimization': 0, # /Od, no optimization
|
||||
'RuntimeLibrary': '<(MSVC_runtimeType)',
|
||||
},
|
||||
'VCLinkerTool': {
|
||||
'LinkIncremental': 2, # enable incremental linking
|
||||
},
|
||||
},
|
||||
'xcode_settings': {
|
||||
'GCC_OPTIMIZATION_LEVEL': '0', # stop gyp from defaulting to -Os
|
||||
},
|
||||
},
|
||||
'Release': {
|
||||
'variables': {
|
||||
'v8_enable_handle_zapping': 0,
|
||||
'pgo_generate': ' -fprofile-generate ',
|
||||
'pgo_use': ' -fprofile-use -fprofile-correction ',
|
||||
'conditions': [
|
||||
['node_shared != "true"', {
|
||||
'MSVC_runtimeType': 0 # MultiThreaded (/MT)
|
||||
}, {
|
||||
'MSVC_runtimeType': 2 # MultiThreadedDLL (/MD)
|
||||
}],
|
||||
['clang==1', {
|
||||
'lto': ' -flto ', # Clang
|
||||
}, {
|
||||
'lto': ' -flto=4 -fuse-linker-plugin -ffat-lto-objects ', # GCC
|
||||
}],
|
||||
],
|
||||
},
|
||||
'cflags': [ '-O3' ],
|
||||
'conditions': [
|
||||
['enable_lto=="true"', {
|
||||
'cflags': ['<(lto)'],
|
||||
'ldflags': ['<(lto)'],
|
||||
'xcode_settings': {
|
||||
'LLVM_LTO': 'YES',
|
||||
},
|
||||
}],
|
||||
['OS=="linux" or OS=="openharmony"', {
|
||||
'conditions': [
|
||||
['node_section_ordering_info!=""', {
|
||||
'cflags': [
|
||||
'-fuse-ld=gold',
|
||||
'-ffunction-sections',
|
||||
],
|
||||
'ldflags': [
|
||||
'-fuse-ld=gold',
|
||||
'-Wl,--section-ordering-file=<(node_section_ordering_info)',
|
||||
],
|
||||
}],
|
||||
],
|
||||
}],
|
||||
['OS=="solaris"', {
|
||||
# pull in V8's postmortem metadata
|
||||
'ldflags': [ '-Wl,-z,allextract' ]
|
||||
}],
|
||||
['OS=="zos"', {
|
||||
# increase performance, number from experimentation
|
||||
'cflags': [ '-qINLINE=::150:100000' ]
|
||||
}],
|
||||
['OS!="mac" and OS!="win" and OS!="zos"', {
|
||||
# -fno-omit-frame-pointer is necessary for the --perf_basic_prof
|
||||
# flag to work correctly. perf(1) gets confused about JS stack
|
||||
# frames otherwise, even with --call-graph dwarf.
|
||||
'cflags': [ '-fno-omit-frame-pointer' ],
|
||||
}],
|
||||
['OS=="linux" or OS=="openharmony"', {
|
||||
'conditions': [
|
||||
['enable_pgo_generate=="true"', {
|
||||
'cflags': ['<(pgo_generate)'],
|
||||
'ldflags': ['<(pgo_generate)'],
|
||||
},],
|
||||
['enable_pgo_use=="true"', {
|
||||
'cflags': ['<(pgo_use)'],
|
||||
'ldflags': ['<(pgo_use)'],
|
||||
},],
|
||||
],
|
||||
},],
|
||||
['OS == "android"', {
|
||||
'cflags': [ '-fPIC', '-I<(android_ndk_path)/sources/android/cpufeatures' ],
|
||||
'ldflags': [ '-fPIC' ]
|
||||
}],
|
||||
['clang==1', {
|
||||
'msbuild_toolset': 'ClangCL',
|
||||
}],
|
||||
],
|
||||
'msvs_settings': {
|
||||
'VCCLCompilerTool': {
|
||||
'conditions': [
|
||||
['target_arch=="arm64"', {
|
||||
'FloatingPointModel': 1 # /fp:strict
|
||||
}]
|
||||
],
|
||||
'EnableFunctionLevelLinking': 'true',
|
||||
'EnableIntrinsicFunctions': 'true',
|
||||
'FavorSizeOrSpeed': 1, # /Ot, favor speed over size
|
||||
'InlineFunctionExpansion': 2, # /Ob2, inline anything eligible
|
||||
'OmitFramePointers': 'true',
|
||||
'Optimization': 3, # /Ox, full optimization
|
||||
'RuntimeLibrary': '<(MSVC_runtimeType)',
|
||||
'RuntimeTypeInfo': 'false',
|
||||
}
|
||||
},
|
||||
'xcode_settings': {
|
||||
'GCC_OPTIMIZATION_LEVEL': '3', # stop gyp from defaulting to -Os
|
||||
},
|
||||
}
|
||||
},
|
||||
|
||||
# Defines these mostly for node-gyp to pickup.
|
||||
'defines': [
|
||||
'_GLIBCXX_USE_CXX11_ABI=1',
|
||||
# This help forks when building Node.js on a 32-bit arch as
|
||||
# libuv is always compiled with _FILE_OFFSET_BITS=64
|
||||
'_FILE_OFFSET_BITS=64'
|
||||
],
|
||||
|
||||
# Forcibly disable -Werror. We support a wide range of compilers, it's
|
||||
# simply not feasible to squelch all warnings, never mind that the
|
||||
# libraries in deps/ are not under our control.
|
||||
'conditions': [
|
||||
[ 'error_on_warn=="false"', {
|
||||
'cflags!': ['-Werror'],
|
||||
}, '(_target_name!="<(node_lib_target_name)" or '
|
||||
'_target_name!="<(node_core_target_name)")', {
|
||||
'cflags!': ['-Werror'],
|
||||
}],
|
||||
],
|
||||
'msvs_settings': {
|
||||
'VCCLCompilerTool': {
|
||||
# TODO(targos): Remove condition and always use LanguageStandard options
|
||||
# once node-gyp supports them.
|
||||
'conditions': [
|
||||
['clang==1', {
|
||||
'LanguageStandard': 'stdcpp20',
|
||||
'LanguageStandard_C': 'stdc11',
|
||||
'AdditionalOptions': [
|
||||
'/Zc:__cplusplus',
|
||||
# The following option reduces the "error C1060: compiler is out of heap space"
|
||||
'/Zm2000',
|
||||
],
|
||||
}, {
|
||||
'AdditionalOptions': [
|
||||
'/Zc:__cplusplus',
|
||||
# The following option enables c++20 on Windows. This is needed for V8 v12.4+
|
||||
'-std:c++20',
|
||||
# The following option reduces the "error C1060: compiler is out of heap space"
|
||||
'/Zm2000',
|
||||
],
|
||||
}],
|
||||
['control_flow_guard=="true"', {
|
||||
'AdditionalOptions': [
|
||||
'/guard:cf', # Control Flow Guard
|
||||
],
|
||||
}],
|
||||
],
|
||||
'BufferSecurityCheck': 'true',
|
||||
'DebugInformationFormat': 1, # /Z7 embed info in .obj files
|
||||
'ExceptionHandling': 0, # /EHsc
|
||||
'MultiProcessorCompilation': 'true',
|
||||
'StringPooling': 'true', # pool string literals
|
||||
'SuppressStartupBanner': 'true',
|
||||
'WarnAsError': 'false',
|
||||
'WarningLevel': 3, # /W3
|
||||
},
|
||||
'VCLinkerTool': {
|
||||
'target_conditions': [
|
||||
['_type=="executable"', {
|
||||
'SubSystem': 1, # /SUBSYSTEM:CONSOLE
|
||||
}],
|
||||
],
|
||||
'conditions': [
|
||||
['target_arch=="ia32"', {
|
||||
'TargetMachine' : 1, # /MACHINE:X86
|
||||
}],
|
||||
['target_arch=="x64"', {
|
||||
'TargetMachine' : 17, # /MACHINE:X64
|
||||
}],
|
||||
['target_arch=="arm64"', {
|
||||
'TargetMachine' : 0, # NotSet. MACHINE:ARM64 is inferred from the input files.
|
||||
}],
|
||||
['control_flow_guard=="true"', {
|
||||
'AdditionalOptions': [
|
||||
'/guard:cf', # Control Flow Guard
|
||||
],
|
||||
}],
|
||||
],
|
||||
'GenerateDebugInformation': 'true',
|
||||
'SuppressStartupBanner': 'true',
|
||||
},
|
||||
},
|
||||
# Disable warnings:
|
||||
# - "C4251: class needs to have dll-interface"
|
||||
# - "C4275: non-DLL-interface used as base for DLL-interface"
|
||||
# Over 10k of these warnings are generated when compiling node,
|
||||
# originating from v8.h. Most of them are false positives.
|
||||
# See also: https://github.com/nodejs/node/pull/15570
|
||||
# TODO: re-enable when Visual Studio fixes these upstream.
|
||||
#
|
||||
# - "C4267: conversion from 'size_t' to 'int'"
|
||||
# Many any originate from our dependencies, and their sheer number
|
||||
# drowns out other, more legitimate warnings.
|
||||
# - "C4244: conversion from 'type1' to 'type2', possible loss of data"
|
||||
# Ususaly safe. Disable for `dep`, enable for `src`
|
||||
'msvs_disabled_warnings': [4351, 4355, 4800, 4251, 4275, 4244, 4267],
|
||||
'msvs_cygwin_shell': 0, # prevent actions from trying to use cygwin
|
||||
|
||||
'conditions': [
|
||||
[ 'configuring_node', {
|
||||
'msvs_configuration_attributes': {
|
||||
'OutputDirectory': '<(DEPTH)/out/$(Configuration)/',
|
||||
'IntermediateDirectory': '$(OutDir)obj/$(ProjectName)/'
|
||||
},
|
||||
}],
|
||||
[ 'target_arch=="x64"', {
|
||||
'msvs_configuration_platform': 'x64',
|
||||
}],
|
||||
[ 'target_arch=="arm64"', {
|
||||
'msvs_configuration_platform': 'arm64',
|
||||
}],
|
||||
['asan == 1 and OS != "mac" and OS != "zos"', {
|
||||
'cflags+': [
|
||||
'-fno-omit-frame-pointer',
|
||||
'-fsanitize=address',
|
||||
'-fsanitize-address-use-after-scope',
|
||||
],
|
||||
'defines': [ 'LEAK_SANITIZER', 'V8_USE_ADDRESS_SANITIZER' ],
|
||||
'cflags!': [ '-fomit-frame-pointer' ],
|
||||
'ldflags': [ '-fsanitize=address' ],
|
||||
}],
|
||||
['asan == 1 and OS == "mac"', {
|
||||
'xcode_settings': {
|
||||
'OTHER_CFLAGS+': [
|
||||
'-fno-omit-frame-pointer',
|
||||
'-gline-tables-only',
|
||||
'-fsanitize=address',
|
||||
'-DLEAK_SANITIZER'
|
||||
],
|
||||
'OTHER_CFLAGS!': [
|
||||
'-fomit-frame-pointer',
|
||||
],
|
||||
},
|
||||
'target_conditions': [
|
||||
['_type!="static_library"', {
|
||||
'xcode_settings': {'OTHER_LDFLAGS': ['-fsanitize=address']},
|
||||
}],
|
||||
],
|
||||
}],
|
||||
['ubsan == 1 and OS != "mac" and OS != "zos"', {
|
||||
'cflags+': [
|
||||
'-fno-omit-frame-pointer',
|
||||
'-fsanitize=undefined',
|
||||
],
|
||||
'defines': [ 'UNDEFINED_SANITIZER'],
|
||||
'cflags!': [ '-fno-omit-frame-pointer' ],
|
||||
'ldflags': [ '-fsanitize=undefined' ],
|
||||
}],
|
||||
['ubsan == 1 and OS == "mac"', {
|
||||
'xcode_settings': {
|
||||
'OTHER_CFLAGS+': [
|
||||
'-fno-omit-frame-pointer',
|
||||
'-fsanitize=undefined',
|
||||
'-DUNDEFINED_SANITIZER'
|
||||
],
|
||||
},
|
||||
'target_conditions': [
|
||||
['_type!="static_library"', {
|
||||
'xcode_settings': {'OTHER_LDFLAGS': ['-fsanitize=undefined']},
|
||||
}],
|
||||
],
|
||||
}],
|
||||
# The defines bellow must include all things from the external_v8_defines
|
||||
# list in v8/BUILD.gn.
|
||||
['v8_enable_v8_checks == 1', {
|
||||
'defines': ['V8_ENABLE_CHECKS'],
|
||||
}],
|
||||
['v8_enable_pointer_compression == 1', {
|
||||
'defines': ['V8_COMPRESS_POINTERS'],
|
||||
}],
|
||||
['v8_enable_pointer_compression_shared_cage == 1', {
|
||||
'defines': ['V8_COMPRESS_POINTERS_IN_SHARED_CAGE'],
|
||||
}],
|
||||
['v8_enable_pointer_compression == 1 and v8_enable_pointer_compression_shared_cage != 1', {
|
||||
'defines': ['V8_COMPRESS_POINTERS_IN_ISOLATE_CAGE'],
|
||||
}],
|
||||
['v8_enable_pointer_compression == 1 or v8_enable_31bit_smis_on_64bit_arch == 1', {
|
||||
'defines': ['V8_31BIT_SMIS_ON_64BIT_ARCH'],
|
||||
}],
|
||||
['v8_enable_zone_compression == 1', {
|
||||
'defines': ['V8_COMPRESS_ZONES',],
|
||||
}],
|
||||
['v8_enable_sandbox == 1', {
|
||||
'defines': ['V8_ENABLE_SANDBOX',],
|
||||
}],
|
||||
['v8_enable_external_code_space == 1', {
|
||||
'defines': ['V8_EXTERNAL_CODE_SPACE',],
|
||||
}],
|
||||
['v8_deprecation_warnings == 1', {
|
||||
'defines': ['V8_DEPRECATION_WARNINGS',],
|
||||
}],
|
||||
['v8_imminent_deprecation_warnings == 1', {
|
||||
'defines': ['V8_IMMINENT_DEPRECATION_WARNINGS',],
|
||||
}],
|
||||
['v8_use_perfetto == 1', {
|
||||
'defines': ['V8_USE_PERFETTO',],
|
||||
}],
|
||||
['v8_enable_map_packing == 1', {
|
||||
'defines': ['V8_MAP_PACKING',],
|
||||
}],
|
||||
['tsan == 1', {
|
||||
'defines': ['V8_IS_TSAN',],
|
||||
}],
|
||||
['v8_enable_conservative_stack_scanning == 1', {
|
||||
'defines': ['V8_ENABLE_CONSERVATIVE_STACK_SCANNING',],
|
||||
}],
|
||||
['v8_enable_direct_local == 1', {
|
||||
'defines': ['V8_ENABLE_DIRECT_LOCAL',],
|
||||
}],
|
||||
['OS == "win"', {
|
||||
'defines': [
|
||||
'WIN32',
|
||||
# we don't really want VC++ warning us about
|
||||
# how dangerous C functions are...
|
||||
'_CRT_SECURE_NO_DEPRECATE',
|
||||
# ... or that C implementations shouldn't use
|
||||
# POSIX names
|
||||
'_CRT_NONSTDC_NO_DEPRECATE',
|
||||
# Make sure the STL doesn't try to use exceptions
|
||||
'_HAS_EXCEPTIONS=0',
|
||||
'BUILDING_V8_SHARED=1',
|
||||
'BUILDING_UV_SHARED=1',
|
||||
# Stop <windows.h> from defining macros that conflict with
|
||||
# std::min() and std::max(). We don't use <windows.h> (much)
|
||||
# but we still inherit it from uv.h.
|
||||
'NOMINMAX',
|
||||
],
|
||||
}],
|
||||
[ 'OS in "linux freebsd openbsd solaris aix os400 openharmony"', {
|
||||
'cflags': [ '-pthread' ],
|
||||
'ldflags': [ '-pthread' ],
|
||||
}],
|
||||
[ 'OS in "linux freebsd openbsd solaris android aix os400 cloudabi openharmony"', {
|
||||
'cflags': [ '-Wall', '-Wextra', '-Wno-unused-parameter', ],
|
||||
'cflags_cc': [
|
||||
'-fno-rtti',
|
||||
'-fno-exceptions',
|
||||
'-fno-strict-aliasing',
|
||||
'-std=gnu++17',
|
||||
],
|
||||
'defines': [ '__STDC_FORMAT_MACROS' ],
|
||||
'ldflags': [ '-rdynamic' ],
|
||||
'target_conditions': [
|
||||
# The 1990s toolchain on SmartOS can't handle thin archives.
|
||||
['_type=="static_library" and OS=="solaris"', {
|
||||
'standalone_static_library': 1,
|
||||
}],
|
||||
['OS=="openbsd"', {
|
||||
'cflags': [ '-I/usr/local/include' ],
|
||||
'ldflags': [ '-Wl,-z,wxneeded' ],
|
||||
}],
|
||||
['_toolset=="host"', {
|
||||
'conditions': [
|
||||
[ 'host_arch=="ia32"', {
|
||||
'cflags': [ '-m32' ],
|
||||
'ldflags': [ '-m32' ],
|
||||
}],
|
||||
[ 'host_arch=="x64"', {
|
||||
'cflags': [ '-m64' ],
|
||||
'ldflags': [ '-m64' ],
|
||||
}],
|
||||
[ 'host_arch=="ppc" and OS not in "aix os400"', {
|
||||
'cflags': [ '-m32' ],
|
||||
'ldflags': [ '-m32' ],
|
||||
}],
|
||||
[ 'host_arch=="ppc64" and OS not in "aix os400"', {
|
||||
'cflags': [ '-m64', '-mminimal-toc' ],
|
||||
'ldflags': [ '-m64' ],
|
||||
}],
|
||||
[ 'host_arch=="s390x" and OS=="linux"', {
|
||||
'cflags': [ '-m64', '-march=z196' ],
|
||||
'ldflags': [ '-m64', '-march=z196' ],
|
||||
}],
|
||||
],
|
||||
}],
|
||||
['_toolset=="target"', {
|
||||
'conditions': [
|
||||
[ 'target_arch=="ia32"', {
|
||||
'cflags': [ '-m32' ],
|
||||
'ldflags': [ '-m32' ],
|
||||
}],
|
||||
[ 'target_arch=="x64"', {
|
||||
'cflags': [ '-m64' ],
|
||||
'ldflags': [ '-m64' ],
|
||||
}],
|
||||
[ 'target_arch=="ppc" and OS not in "aix os400"', {
|
||||
'cflags': [ '-m32' ],
|
||||
'ldflags': [ '-m32' ],
|
||||
}],
|
||||
[ 'target_arch=="ppc64" and OS not in "aix os400"', {
|
||||
'cflags': [ '-m64', '-mminimal-toc' ],
|
||||
'ldflags': [ '-m64' ],
|
||||
}],
|
||||
[ 'target_arch=="s390x" and OS=="linux"', {
|
||||
'cflags': [ '-m64', '-march=z196' ],
|
||||
'ldflags': [ '-m64', '-march=z196' ],
|
||||
}],
|
||||
],
|
||||
}],
|
||||
],
|
||||
'conditions': [
|
||||
[ 'OS=="solaris"', {
|
||||
'cflags': [ '-pthreads' ],
|
||||
'ldflags': [ '-pthreads' ],
|
||||
'cflags!': [ '-pthread' ],
|
||||
'ldflags!': [ '-pthread' ],
|
||||
}],
|
||||
[ 'node_shared=="true"', {
|
||||
'cflags': [ '-fPIC' ],
|
||||
}],
|
||||
],
|
||||
}],
|
||||
[ 'OS in "aix os400"', {
|
||||
'variables': {
|
||||
# Used to differentiate `AIX` and `OS400`(IBM i).
|
||||
'aix_variant_name': '<!(uname -s)',
|
||||
},
|
||||
'cflags': [ '-maix64', ],
|
||||
'ldflags!': [ '-rdynamic', ],
|
||||
'ldflags': [
|
||||
'-Wl,-bbigtoc',
|
||||
'-maix64',
|
||||
],
|
||||
'conditions': [
|
||||
[ '"<(aix_variant_name)"=="OS400"', { # a.k.a. `IBM i`
|
||||
'ldflags': [
|
||||
'-Wl,-blibpath:/QOpenSys/pkgs/lib:/QOpenSys/usr/lib',
|
||||
'-Wl,-brtl',
|
||||
],
|
||||
}, { # else it's `AIX`
|
||||
'variables': {
|
||||
'gcc_major': '<!(<(python) -c "import os; import subprocess; CXX=os.environ.get(\'CXX\', \'g++\'); subprocess.run([CXX, \'-dumpversion\'])")'
|
||||
},
|
||||
# Disable the following compiler warning:
|
||||
#
|
||||
# warning: visibility attribute not supported in this
|
||||
# configuration; ignored [-Wattributes]
|
||||
#
|
||||
# This is gcc complaining about __attribute((visibility("default"))
|
||||
# in static library builds. Legitimate but harmless and it drowns
|
||||
# out more relevant warnings.
|
||||
'cflags': [ '-Wno-attributes' ],
|
||||
'ldflags': [
|
||||
'-Wl,-blibpath:/usr/lib:/lib:/opt/freeware/lib/gcc/powerpc-ibm-aix7.3.0.0/>(gcc_major)/pthread/ppc64:/opt/freeware/lib/gcc/powerpc-ibm-aix7.2.0.0/>(gcc_major)/pthread/ppc64:/opt/freeware/lib/pthread/ppc64',
|
||||
],
|
||||
}],
|
||||
],
|
||||
}],
|
||||
['OS=="android"', {
|
||||
'target_conditions': [
|
||||
['_toolset=="target"', {
|
||||
'defines': [ '_GLIBCXX_USE_C99_MATH' ],
|
||||
'libraries': [ '-llog' ],
|
||||
}],
|
||||
['_toolset=="host"', {
|
||||
'cflags': [ '-pthread' ],
|
||||
'ldflags': [ '-pthread' ],
|
||||
}],
|
||||
],
|
||||
}],
|
||||
['OS=="mac"', {
|
||||
'defines': ['_DARWIN_USE_64_BIT_INODE=1'],
|
||||
'xcode_settings': {
|
||||
'ALWAYS_SEARCH_USER_PATHS': 'NO',
|
||||
'GCC_CW_ASM_SYNTAX': 'NO', # No -fasm-blocks
|
||||
'GCC_DYNAMIC_NO_PIC': 'NO', # No -mdynamic-no-pic
|
||||
# (Equivalent to -fPIC)
|
||||
'GCC_ENABLE_CPP_EXCEPTIONS': 'NO', # -fno-exceptions
|
||||
'GCC_ENABLE_CPP_RTTI': 'NO', # -fno-rtti
|
||||
'GCC_ENABLE_PASCAL_STRINGS': 'NO', # No -mpascal-strings
|
||||
'GCC_STRICT_ALIASING': 'NO', # -fno-strict-aliasing
|
||||
'PREBINDING': 'NO', # No -Wl,-prebind
|
||||
'MACOSX_DEPLOYMENT_TARGET': '11.0', # -mmacosx-version-min=11.0
|
||||
'USE_HEADERMAP': 'NO',
|
||||
'WARNING_CFLAGS': [
|
||||
'-Wall',
|
||||
'-Wendif-labels',
|
||||
'-W',
|
||||
'-Wno-unused-parameter',
|
||||
],
|
||||
},
|
||||
'target_conditions': [
|
||||
['_type!="static_library"', {
|
||||
'xcode_settings': {
|
||||
'OTHER_LDFLAGS': [
|
||||
'-Wl,-search_paths_first'
|
||||
],
|
||||
},
|
||||
}],
|
||||
],
|
||||
'conditions': [
|
||||
['target_arch=="ia32"', {
|
||||
'xcode_settings': {'ARCHS': ['i386']},
|
||||
}],
|
||||
['target_arch=="x64"', {
|
||||
'xcode_settings': {'ARCHS': ['x86_64']},
|
||||
}],
|
||||
['target_arch=="arm64"', {
|
||||
'xcode_settings': {
|
||||
'ARCHS': ['arm64'],
|
||||
'OTHER_LDFLAGS!': [
|
||||
'-Wl,-no_pie',
|
||||
],
|
||||
},
|
||||
}],
|
||||
['clang==1', {
|
||||
'xcode_settings': {
|
||||
'GCC_VERSION': 'com.apple.compilers.llvm.clang.1_0',
|
||||
'CLANG_CXX_LANGUAGE_STANDARD': 'gnu++17', # -std=gnu++17
|
||||
'CLANG_CXX_LIBRARY': 'libc++',
|
||||
},
|
||||
}],
|
||||
],
|
||||
}],
|
||||
['OS=="freebsd"', {
|
||||
'ldflags': [
|
||||
'-Wl,--export-dynamic',
|
||||
],
|
||||
}],
|
||||
# if node is built as an executable,
|
||||
# the openssl mechanism for keeping itself "dload"-ed to ensure proper
|
||||
# atexit cleanup does not apply
|
||||
['node_shared_openssl!="true" and node_shared!="true"', {
|
||||
'defines': [
|
||||
# `OPENSSL_NO_PINSHARED` prevents openssl from dload
|
||||
# current node executable,
|
||||
# see https://github.com/nodejs/node/pull/21848
|
||||
# or https://github.com/nodejs/node/issues/27925
|
||||
'OPENSSL_NO_PINSHARED'
|
||||
],
|
||||
}],
|
||||
['node_shared_openssl!="true"', {
|
||||
# `OPENSSL_THREADS` is defined via GYP for openSSL for all architectures.
|
||||
'defines': [
|
||||
'OPENSSL_THREADS',
|
||||
],
|
||||
}],
|
||||
['node_shared_openssl!="true" and openssl_no_asm==1', {
|
||||
'defines': [
|
||||
'OPENSSL_NO_ASM',
|
||||
],
|
||||
}],
|
||||
['OS == "zos"', {
|
||||
'defines': [
|
||||
'_XOPEN_SOURCE_EXTENDED',
|
||||
'_XOPEN_SOURCE=600',
|
||||
'_UNIX03_THREADS',
|
||||
'_UNIX03_WITHDRAWN',
|
||||
'_UNIX03_SOURCE',
|
||||
'_OPEN_SYS_SOCK_IPV6',
|
||||
'_OPEN_SYS_FILE_EXT=1',
|
||||
'_POSIX_SOURCE',
|
||||
'_OPEN_SYS',
|
||||
'_OPEN_SYS_IF_EXT',
|
||||
'_OPEN_SYS_SOCK_IPV6',
|
||||
'_OPEN_MSGQ_EXT',
|
||||
'_LARGE_TIME_API',
|
||||
'_ALL_SOURCE',
|
||||
'_AE_BIMODAL=1',
|
||||
'__IBMCPP_TR1__',
|
||||
'NODE_PLATFORM="os390"',
|
||||
'PATH_MAX=1024',
|
||||
'_ENHANCED_ASCII_EXT=0xFFFFFFFF',
|
||||
'_Export=extern',
|
||||
'__static_assert=static_assert',
|
||||
],
|
||||
'cflags': [
|
||||
'-q64',
|
||||
'-Wc,DLL',
|
||||
'-Wa,GOFF',
|
||||
'-qARCH=10',
|
||||
'-qASCII',
|
||||
'-qTUNE=12',
|
||||
'-qENUM=INT',
|
||||
'-qEXPORTALL',
|
||||
'-qASM',
|
||||
],
|
||||
'cflags_cc': [
|
||||
'-qxclang=-std=c++14',
|
||||
],
|
||||
'ldflags': [
|
||||
'-q64',
|
||||
],
|
||||
# for addons due to v8config.h include of "zos-base.h":
|
||||
'include_dirs': ['<(zoslib_include_dir)'],
|
||||
}],
|
||||
],
|
||||
}
|
||||
}
|
||||
471
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/config.gypi
generated
vendored
Normal file
471
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/config.gypi
generated
vendored
Normal file
@@ -0,0 +1,471 @@
|
||||
# Do not edit. Generated by the configure script.
|
||||
{ 'target_defaults': { 'cflags': [],
|
||||
'configurations': { 'Debug': {'v8_enable_v8_checks': 0, 'variables': {}},
|
||||
'Release': {'v8_enable_v8_checks': 1, 'variables': {}}},
|
||||
'default_configuration': 'Release',
|
||||
'defines': ['NODE_OPENSSL_CONF_NAME=nodejs_conf', 'ICU_NO_USER_DATA_OVERRIDE'],
|
||||
'include_dirs': [],
|
||||
'libraries': []},
|
||||
'variables': { 'arm_fpu': 'neon',
|
||||
'asan': 0,
|
||||
'clang': 1,
|
||||
'control_flow_guard': 'false',
|
||||
'coverage': 'false',
|
||||
'dcheck_always_on': 0,
|
||||
'debug_nghttp2': 'false',
|
||||
'debug_node': 'false',
|
||||
'enable_lto': 'false',
|
||||
'enable_pgo_generate': 'false',
|
||||
'enable_pgo_use': 'false',
|
||||
'error_on_warn': 'false',
|
||||
'force_dynamic_crt': 0,
|
||||
'host_arch': 'arm64',
|
||||
'icu_data_in': '../../deps/icu-tmp/icudt77l.dat',
|
||||
'icu_endianness': 'l',
|
||||
'icu_gyp_path': 'tools/icu/icu-generic.gyp',
|
||||
'icu_path': 'deps/icu-small',
|
||||
'icu_small': 'false',
|
||||
'icu_ver_major': '77',
|
||||
'libdir': 'lib',
|
||||
'llvm_version': '16.0',
|
||||
'napi_build_version': '10',
|
||||
'node_builtin_shareable_builtins': [ 'deps/cjs-module-lexer/lexer.js',
|
||||
'deps/cjs-module-lexer/dist/lexer.js',
|
||||
'deps/undici/undici.js',
|
||||
'deps/amaro/dist/index.js'],
|
||||
'node_byteorder': 'little',
|
||||
'node_cctest_sources': [ 'src/node_snapshot_stub.cc',
|
||||
'test/cctest/inspector/test_node_protocol.cc',
|
||||
'test/cctest/node_test_fixture.cc',
|
||||
'test/cctest/test_aliased_buffer.cc',
|
||||
'test/cctest/test_base64.cc',
|
||||
'test/cctest/test_base_object_ptr.cc',
|
||||
'test/cctest/test_cppgc.cc',
|
||||
'test/cctest/test_crypto_clienthello.cc',
|
||||
'test/cctest/test_dataqueue.cc',
|
||||
'test/cctest/test_environment.cc',
|
||||
'test/cctest/test_inspector_socket.cc',
|
||||
'test/cctest/test_inspector_socket_server.cc',
|
||||
'test/cctest/test_json_utils.cc',
|
||||
'test/cctest/test_linked_binding.cc',
|
||||
'test/cctest/test_node_api.cc',
|
||||
'test/cctest/test_node_crypto.cc',
|
||||
'test/cctest/test_node_crypto_env.cc',
|
||||
'test/cctest/test_node_postmortem_metadata.cc',
|
||||
'test/cctest/test_node_task_runner.cc',
|
||||
'test/cctest/test_path.cc',
|
||||
'test/cctest/test_per_process.cc',
|
||||
'test/cctest/test_platform.cc',
|
||||
'test/cctest/test_quic_cid.cc',
|
||||
'test/cctest/test_quic_error.cc',
|
||||
'test/cctest/test_quic_tokens.cc',
|
||||
'test/cctest/test_report.cc',
|
||||
'test/cctest/test_sockaddr.cc',
|
||||
'test/cctest/test_traced_value.cc',
|
||||
'test/cctest/test_util.cc',
|
||||
'test/cctest/node_test_fixture.h'],
|
||||
'node_debug_lib': 'false',
|
||||
'node_enable_d8': 'false',
|
||||
'node_enable_v8_vtunejit': 'false',
|
||||
'node_fipsinstall': 'false',
|
||||
'node_install_corepack': 'true',
|
||||
'node_install_npm': 'true',
|
||||
'node_library_files': [ 'lib/_http_agent.js',
|
||||
'lib/_http_client.js',
|
||||
'lib/_http_common.js',
|
||||
'lib/_http_incoming.js',
|
||||
'lib/_http_outgoing.js',
|
||||
'lib/_http_server.js',
|
||||
'lib/_stream_duplex.js',
|
||||
'lib/_stream_passthrough.js',
|
||||
'lib/_stream_readable.js',
|
||||
'lib/_stream_transform.js',
|
||||
'lib/_stream_wrap.js',
|
||||
'lib/_stream_writable.js',
|
||||
'lib/_tls_common.js',
|
||||
'lib/_tls_wrap.js',
|
||||
'lib/assert.js',
|
||||
'lib/assert/strict.js',
|
||||
'lib/async_hooks.js',
|
||||
'lib/buffer.js',
|
||||
'lib/child_process.js',
|
||||
'lib/cluster.js',
|
||||
'lib/console.js',
|
||||
'lib/constants.js',
|
||||
'lib/crypto.js',
|
||||
'lib/dgram.js',
|
||||
'lib/diagnostics_channel.js',
|
||||
'lib/dns.js',
|
||||
'lib/dns/promises.js',
|
||||
'lib/domain.js',
|
||||
'lib/events.js',
|
||||
'lib/fs.js',
|
||||
'lib/fs/promises.js',
|
||||
'lib/http.js',
|
||||
'lib/http2.js',
|
||||
'lib/https.js',
|
||||
'lib/inspector.js',
|
||||
'lib/inspector/promises.js',
|
||||
'lib/internal/abort_controller.js',
|
||||
'lib/internal/assert.js',
|
||||
'lib/internal/assert/assertion_error.js',
|
||||
'lib/internal/assert/calltracker.js',
|
||||
'lib/internal/assert/myers_diff.js',
|
||||
'lib/internal/assert/utils.js',
|
||||
'lib/internal/async_context_frame.js',
|
||||
'lib/internal/async_hooks.js',
|
||||
'lib/internal/async_local_storage/async_context_frame.js',
|
||||
'lib/internal/async_local_storage/async_hooks.js',
|
||||
'lib/internal/blob.js',
|
||||
'lib/internal/blocklist.js',
|
||||
'lib/internal/bootstrap/node.js',
|
||||
'lib/internal/bootstrap/realm.js',
|
||||
'lib/internal/bootstrap/shadow_realm.js',
|
||||
'lib/internal/bootstrap/switches/does_not_own_process_state.js',
|
||||
'lib/internal/bootstrap/switches/does_own_process_state.js',
|
||||
'lib/internal/bootstrap/switches/is_main_thread.js',
|
||||
'lib/internal/bootstrap/switches/is_not_main_thread.js',
|
||||
'lib/internal/bootstrap/web/exposed-wildcard.js',
|
||||
'lib/internal/bootstrap/web/exposed-window-or-worker.js',
|
||||
'lib/internal/buffer.js',
|
||||
'lib/internal/child_process.js',
|
||||
'lib/internal/child_process/serialization.js',
|
||||
'lib/internal/cli_table.js',
|
||||
'lib/internal/cluster/child.js',
|
||||
'lib/internal/cluster/primary.js',
|
||||
'lib/internal/cluster/round_robin_handle.js',
|
||||
'lib/internal/cluster/shared_handle.js',
|
||||
'lib/internal/cluster/utils.js',
|
||||
'lib/internal/cluster/worker.js',
|
||||
'lib/internal/console/constructor.js',
|
||||
'lib/internal/console/global.js',
|
||||
'lib/internal/constants.js',
|
||||
'lib/internal/crypto/aes.js',
|
||||
'lib/internal/crypto/certificate.js',
|
||||
'lib/internal/crypto/cfrg.js',
|
||||
'lib/internal/crypto/cipher.js',
|
||||
'lib/internal/crypto/diffiehellman.js',
|
||||
'lib/internal/crypto/ec.js',
|
||||
'lib/internal/crypto/hash.js',
|
||||
'lib/internal/crypto/hashnames.js',
|
||||
'lib/internal/crypto/hkdf.js',
|
||||
'lib/internal/crypto/keygen.js',
|
||||
'lib/internal/crypto/keys.js',
|
||||
'lib/internal/crypto/mac.js',
|
||||
'lib/internal/crypto/pbkdf2.js',
|
||||
'lib/internal/crypto/random.js',
|
||||
'lib/internal/crypto/rsa.js',
|
||||
'lib/internal/crypto/scrypt.js',
|
||||
'lib/internal/crypto/sig.js',
|
||||
'lib/internal/crypto/util.js',
|
||||
'lib/internal/crypto/webcrypto.js',
|
||||
'lib/internal/crypto/webidl.js',
|
||||
'lib/internal/crypto/x509.js',
|
||||
'lib/internal/data_url.js',
|
||||
'lib/internal/debugger/inspect.js',
|
||||
'lib/internal/debugger/inspect_client.js',
|
||||
'lib/internal/debugger/inspect_repl.js',
|
||||
'lib/internal/dgram.js',
|
||||
'lib/internal/dns/callback_resolver.js',
|
||||
'lib/internal/dns/promises.js',
|
||||
'lib/internal/dns/utils.js',
|
||||
'lib/internal/encoding.js',
|
||||
'lib/internal/error_serdes.js',
|
||||
'lib/internal/errors.js',
|
||||
'lib/internal/event_target.js',
|
||||
'lib/internal/events/abort_listener.js',
|
||||
'lib/internal/events/symbols.js',
|
||||
'lib/internal/file.js',
|
||||
'lib/internal/fixed_queue.js',
|
||||
'lib/internal/freelist.js',
|
||||
'lib/internal/freeze_intrinsics.js',
|
||||
'lib/internal/fs/cp/cp-sync.js',
|
||||
'lib/internal/fs/cp/cp.js',
|
||||
'lib/internal/fs/dir.js',
|
||||
'lib/internal/fs/glob.js',
|
||||
'lib/internal/fs/promises.js',
|
||||
'lib/internal/fs/read/context.js',
|
||||
'lib/internal/fs/recursive_watch.js',
|
||||
'lib/internal/fs/rimraf.js',
|
||||
'lib/internal/fs/streams.js',
|
||||
'lib/internal/fs/sync_write_stream.js',
|
||||
'lib/internal/fs/utils.js',
|
||||
'lib/internal/fs/watchers.js',
|
||||
'lib/internal/heap_utils.js',
|
||||
'lib/internal/histogram.js',
|
||||
'lib/internal/http.js',
|
||||
'lib/internal/http2/compat.js',
|
||||
'lib/internal/http2/core.js',
|
||||
'lib/internal/http2/util.js',
|
||||
'lib/internal/inspector/network.js',
|
||||
'lib/internal/inspector/network_http.js',
|
||||
'lib/internal/inspector/network_undici.js',
|
||||
'lib/internal/inspector_async_hook.js',
|
||||
'lib/internal/inspector_network_tracking.js',
|
||||
'lib/internal/js_stream_socket.js',
|
||||
'lib/internal/legacy/processbinding.js',
|
||||
'lib/internal/linkedlist.js',
|
||||
'lib/internal/main/check_syntax.js',
|
||||
'lib/internal/main/embedding.js',
|
||||
'lib/internal/main/eval_stdin.js',
|
||||
'lib/internal/main/eval_string.js',
|
||||
'lib/internal/main/inspect.js',
|
||||
'lib/internal/main/mksnapshot.js',
|
||||
'lib/internal/main/print_help.js',
|
||||
'lib/internal/main/prof_process.js',
|
||||
'lib/internal/main/repl.js',
|
||||
'lib/internal/main/run_main_module.js',
|
||||
'lib/internal/main/test_runner.js',
|
||||
'lib/internal/main/watch_mode.js',
|
||||
'lib/internal/main/worker_thread.js',
|
||||
'lib/internal/mime.js',
|
||||
'lib/internal/modules/cjs/loader.js',
|
||||
'lib/internal/modules/customization_hooks.js',
|
||||
'lib/internal/modules/esm/assert.js',
|
||||
'lib/internal/modules/esm/create_dynamic_module.js',
|
||||
'lib/internal/modules/esm/formats.js',
|
||||
'lib/internal/modules/esm/get_format.js',
|
||||
'lib/internal/modules/esm/hooks.js',
|
||||
'lib/internal/modules/esm/initialize_import_meta.js',
|
||||
'lib/internal/modules/esm/load.js',
|
||||
'lib/internal/modules/esm/loader.js',
|
||||
'lib/internal/modules/esm/module_job.js',
|
||||
'lib/internal/modules/esm/module_map.js',
|
||||
'lib/internal/modules/esm/resolve.js',
|
||||
'lib/internal/modules/esm/shared_constants.js',
|
||||
'lib/internal/modules/esm/translators.js',
|
||||
'lib/internal/modules/esm/utils.js',
|
||||
'lib/internal/modules/esm/worker.js',
|
||||
'lib/internal/modules/helpers.js',
|
||||
'lib/internal/modules/package_json_reader.js',
|
||||
'lib/internal/modules/run_main.js',
|
||||
'lib/internal/modules/typescript.js',
|
||||
'lib/internal/navigator.js',
|
||||
'lib/internal/net.js',
|
||||
'lib/internal/options.js',
|
||||
'lib/internal/per_context/domexception.js',
|
||||
'lib/internal/per_context/messageport.js',
|
||||
'lib/internal/per_context/primordials.js',
|
||||
'lib/internal/perf/event_loop_delay.js',
|
||||
'lib/internal/perf/event_loop_utilization.js',
|
||||
'lib/internal/perf/nodetiming.js',
|
||||
'lib/internal/perf/observe.js',
|
||||
'lib/internal/perf/performance.js',
|
||||
'lib/internal/perf/performance_entry.js',
|
||||
'lib/internal/perf/resource_timing.js',
|
||||
'lib/internal/perf/timerify.js',
|
||||
'lib/internal/perf/usertiming.js',
|
||||
'lib/internal/perf/utils.js',
|
||||
'lib/internal/priority_queue.js',
|
||||
'lib/internal/process/execution.js',
|
||||
'lib/internal/process/finalization.js',
|
||||
'lib/internal/process/per_thread.js',
|
||||
'lib/internal/process/permission.js',
|
||||
'lib/internal/process/pre_execution.js',
|
||||
'lib/internal/process/promises.js',
|
||||
'lib/internal/process/report.js',
|
||||
'lib/internal/process/signal.js',
|
||||
'lib/internal/process/task_queues.js',
|
||||
'lib/internal/process/warning.js',
|
||||
'lib/internal/process/worker_thread_only.js',
|
||||
'lib/internal/promise_hooks.js',
|
||||
'lib/internal/querystring.js',
|
||||
'lib/internal/quic/quic.js',
|
||||
'lib/internal/quic/state.js',
|
||||
'lib/internal/quic/stats.js',
|
||||
'lib/internal/quic/symbols.js',
|
||||
'lib/internal/readline/callbacks.js',
|
||||
'lib/internal/readline/emitKeypressEvents.js',
|
||||
'lib/internal/readline/interface.js',
|
||||
'lib/internal/readline/promises.js',
|
||||
'lib/internal/readline/utils.js',
|
||||
'lib/internal/repl.js',
|
||||
'lib/internal/repl/await.js',
|
||||
'lib/internal/repl/history.js',
|
||||
'lib/internal/repl/utils.js',
|
||||
'lib/internal/socket_list.js',
|
||||
'lib/internal/socketaddress.js',
|
||||
'lib/internal/source_map/prepare_stack_trace.js',
|
||||
'lib/internal/source_map/source_map.js',
|
||||
'lib/internal/source_map/source_map_cache.js',
|
||||
'lib/internal/source_map/source_map_cache_map.js',
|
||||
'lib/internal/stream_base_commons.js',
|
||||
'lib/internal/streams/add-abort-signal.js',
|
||||
'lib/internal/streams/compose.js',
|
||||
'lib/internal/streams/destroy.js',
|
||||
'lib/internal/streams/duplex.js',
|
||||
'lib/internal/streams/duplexify.js',
|
||||
'lib/internal/streams/duplexpair.js',
|
||||
'lib/internal/streams/end-of-stream.js',
|
||||
'lib/internal/streams/from.js',
|
||||
'lib/internal/streams/lazy_transform.js',
|
||||
'lib/internal/streams/legacy.js',
|
||||
'lib/internal/streams/operators.js',
|
||||
'lib/internal/streams/passthrough.js',
|
||||
'lib/internal/streams/pipeline.js',
|
||||
'lib/internal/streams/readable.js',
|
||||
'lib/internal/streams/state.js',
|
||||
'lib/internal/streams/transform.js',
|
||||
'lib/internal/streams/utils.js',
|
||||
'lib/internal/streams/writable.js',
|
||||
'lib/internal/test/binding.js',
|
||||
'lib/internal/test/transfer.js',
|
||||
'lib/internal/test_runner/assert.js',
|
||||
'lib/internal/test_runner/coverage.js',
|
||||
'lib/internal/test_runner/harness.js',
|
||||
'lib/internal/test_runner/mock/loader.js',
|
||||
'lib/internal/test_runner/mock/mock.js',
|
||||
'lib/internal/test_runner/mock/mock_timers.js',
|
||||
'lib/internal/test_runner/reporter/dot.js',
|
||||
'lib/internal/test_runner/reporter/junit.js',
|
||||
'lib/internal/test_runner/reporter/lcov.js',
|
||||
'lib/internal/test_runner/reporter/spec.js',
|
||||
'lib/internal/test_runner/reporter/tap.js',
|
||||
'lib/internal/test_runner/reporter/utils.js',
|
||||
'lib/internal/test_runner/reporter/v8-serializer.js',
|
||||
'lib/internal/test_runner/runner.js',
|
||||
'lib/internal/test_runner/snapshot.js',
|
||||
'lib/internal/test_runner/test.js',
|
||||
'lib/internal/test_runner/tests_stream.js',
|
||||
'lib/internal/test_runner/utils.js',
|
||||
'lib/internal/timers.js',
|
||||
'lib/internal/tls/secure-context.js',
|
||||
'lib/internal/tls/secure-pair.js',
|
||||
'lib/internal/trace_events_async_hooks.js',
|
||||
'lib/internal/tty.js',
|
||||
'lib/internal/url.js',
|
||||
'lib/internal/util.js',
|
||||
'lib/internal/util/colors.js',
|
||||
'lib/internal/util/comparisons.js',
|
||||
'lib/internal/util/debuglog.js',
|
||||
'lib/internal/util/diff.js',
|
||||
'lib/internal/util/inspect.js',
|
||||
'lib/internal/util/inspector.js',
|
||||
'lib/internal/util/parse_args/parse_args.js',
|
||||
'lib/internal/util/parse_args/utils.js',
|
||||
'lib/internal/util/types.js',
|
||||
'lib/internal/v8/startup_snapshot.js',
|
||||
'lib/internal/v8_prof_polyfill.js',
|
||||
'lib/internal/v8_prof_processor.js',
|
||||
'lib/internal/validators.js',
|
||||
'lib/internal/vm.js',
|
||||
'lib/internal/vm/module.js',
|
||||
'lib/internal/wasm_web_api.js',
|
||||
'lib/internal/watch_mode/files_watcher.js',
|
||||
'lib/internal/watchdog.js',
|
||||
'lib/internal/webidl.js',
|
||||
'lib/internal/webstorage.js',
|
||||
'lib/internal/webstreams/adapters.js',
|
||||
'lib/internal/webstreams/compression.js',
|
||||
'lib/internal/webstreams/encoding.js',
|
||||
'lib/internal/webstreams/queuingstrategies.js',
|
||||
'lib/internal/webstreams/readablestream.js',
|
||||
'lib/internal/webstreams/transfer.js',
|
||||
'lib/internal/webstreams/transformstream.js',
|
||||
'lib/internal/webstreams/util.js',
|
||||
'lib/internal/webstreams/writablestream.js',
|
||||
'lib/internal/worker.js',
|
||||
'lib/internal/worker/io.js',
|
||||
'lib/internal/worker/js_transferable.js',
|
||||
'lib/internal/worker/messaging.js',
|
||||
'lib/module.js',
|
||||
'lib/net.js',
|
||||
'lib/os.js',
|
||||
'lib/path.js',
|
||||
'lib/path/posix.js',
|
||||
'lib/path/win32.js',
|
||||
'lib/perf_hooks.js',
|
||||
'lib/process.js',
|
||||
'lib/punycode.js',
|
||||
'lib/querystring.js',
|
||||
'lib/readline.js',
|
||||
'lib/readline/promises.js',
|
||||
'lib/repl.js',
|
||||
'lib/sea.js',
|
||||
'lib/sqlite.js',
|
||||
'lib/stream.js',
|
||||
'lib/stream/consumers.js',
|
||||
'lib/stream/promises.js',
|
||||
'lib/stream/web.js',
|
||||
'lib/string_decoder.js',
|
||||
'lib/sys.js',
|
||||
'lib/test.js',
|
||||
'lib/test/reporters.js',
|
||||
'lib/timers.js',
|
||||
'lib/timers/promises.js',
|
||||
'lib/tls.js',
|
||||
'lib/trace_events.js',
|
||||
'lib/tty.js',
|
||||
'lib/url.js',
|
||||
'lib/util.js',
|
||||
'lib/util/types.js',
|
||||
'lib/v8.js',
|
||||
'lib/vm.js',
|
||||
'lib/wasi.js',
|
||||
'lib/worker_threads.js',
|
||||
'lib/zlib.js'],
|
||||
'node_module_version': 127,
|
||||
'node_no_browser_globals': 'false',
|
||||
'node_prefix': '/',
|
||||
'node_release_urlbase': 'https://nodejs.org/download/release/',
|
||||
'node_shared': 'false',
|
||||
'node_shared_ada': 'false',
|
||||
'node_shared_brotli': 'false',
|
||||
'node_shared_cares': 'false',
|
||||
'node_shared_http_parser': 'false',
|
||||
'node_shared_libuv': 'false',
|
||||
'node_shared_nghttp2': 'false',
|
||||
'node_shared_nghttp3': 'false',
|
||||
'node_shared_ngtcp2': 'false',
|
||||
'node_shared_openssl': 'false',
|
||||
'node_shared_simdjson': 'false',
|
||||
'node_shared_simdutf': 'false',
|
||||
'node_shared_sqlite': 'false',
|
||||
'node_shared_uvwasi': 'false',
|
||||
'node_shared_zlib': 'false',
|
||||
'node_shared_zstd': 'false',
|
||||
'node_tag': '',
|
||||
'node_target_type': 'executable',
|
||||
'node_use_amaro': 'true',
|
||||
'node_use_bundled_v8': 'true',
|
||||
'node_use_node_code_cache': 'true',
|
||||
'node_use_node_snapshot': 'true',
|
||||
'node_use_openssl': 'true',
|
||||
'node_use_sqlite': 'true',
|
||||
'node_use_v8_platform': 'true',
|
||||
'node_with_ltcg': 'false',
|
||||
'node_without_node_options': 'false',
|
||||
'node_write_snapshot_as_array_literals': 'false',
|
||||
'openssl_is_fips': 'false',
|
||||
'openssl_quic': 'false',
|
||||
'ossfuzz': 'false',
|
||||
'shlib_suffix': '127.dylib',
|
||||
'single_executable_application': 'true',
|
||||
'suppress_all_error_on_warn': 'false',
|
||||
'target_arch': 'arm64',
|
||||
'ubsan': 0,
|
||||
'use_ccache_win': 0,
|
||||
'use_prefix_to_find_headers': 'false',
|
||||
'v8_enable_31bit_smis_on_64bit_arch': 0,
|
||||
'v8_enable_extensible_ro_snapshot': 0,
|
||||
'v8_enable_external_code_space': 0,
|
||||
'v8_enable_gdbjit': 0,
|
||||
'v8_enable_hugepage': 0,
|
||||
'v8_enable_i18n_support': 1,
|
||||
'v8_enable_inspector': 1,
|
||||
'v8_enable_javascript_promise_hooks': 1,
|
||||
'v8_enable_lite_mode': 0,
|
||||
'v8_enable_maglev': 0,
|
||||
'v8_enable_object_print': 1,
|
||||
'v8_enable_pointer_compression': 0,
|
||||
'v8_enable_pointer_compression_shared_cage': 0,
|
||||
'v8_enable_sandbox': 0,
|
||||
'v8_enable_shared_ro_heap': 1,
|
||||
'v8_enable_webassembly': 1,
|
||||
'v8_optimized_debug': 1,
|
||||
'v8_promise_internal_field_count': 1,
|
||||
'v8_random_seed': 0,
|
||||
'v8_trace_maps': 0,
|
||||
'v8_use_siphash': 1,
|
||||
'want_separate_host_toolset': 0,
|
||||
'xcode_version': '16.0'}}
|
||||
310
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/allocation.h
generated
vendored
Normal file
310
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/allocation.h
generated
vendored
Normal file
@@ -0,0 +1,310 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_ALLOCATION_H_
|
||||
#define INCLUDE_CPPGC_ALLOCATION_H_
|
||||
|
||||
#include <atomic>
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
#include <new>
|
||||
#include <type_traits>
|
||||
#include <utility>
|
||||
|
||||
#include "cppgc/custom-space.h"
|
||||
#include "cppgc/internal/api-constants.h"
|
||||
#include "cppgc/internal/gc-info.h"
|
||||
#include "cppgc/type-traits.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
#if defined(__has_attribute)
|
||||
#if __has_attribute(assume_aligned)
|
||||
#define CPPGC_DEFAULT_ALIGNED \
|
||||
__attribute__((assume_aligned(api_constants::kDefaultAlignment)))
|
||||
#define CPPGC_DOUBLE_WORD_ALIGNED \
|
||||
__attribute__((assume_aligned(2 * api_constants::kDefaultAlignment)))
|
||||
#endif // __has_attribute(assume_aligned)
|
||||
#endif // defined(__has_attribute)
|
||||
|
||||
#if !defined(CPPGC_DEFAULT_ALIGNED)
|
||||
#define CPPGC_DEFAULT_ALIGNED
|
||||
#endif
|
||||
|
||||
#if !defined(CPPGC_DOUBLE_WORD_ALIGNED)
|
||||
#define CPPGC_DOUBLE_WORD_ALIGNED
|
||||
#endif
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
/**
|
||||
* AllocationHandle is used to allocate garbage-collected objects.
|
||||
*/
|
||||
class AllocationHandle;
|
||||
|
||||
namespace internal {
|
||||
|
||||
// Similar to C++17 std::align_val_t;
|
||||
enum class AlignVal : size_t {};
|
||||
|
||||
class V8_EXPORT MakeGarbageCollectedTraitInternal {
|
||||
protected:
|
||||
static inline void MarkObjectAsFullyConstructed(const void* payload) {
|
||||
// See api_constants for an explanation of the constants.
|
||||
std::atomic<uint16_t>* atomic_mutable_bitfield =
|
||||
reinterpret_cast<std::atomic<uint16_t>*>(
|
||||
const_cast<uint16_t*>(reinterpret_cast<const uint16_t*>(
|
||||
reinterpret_cast<const uint8_t*>(payload) -
|
||||
api_constants::kFullyConstructedBitFieldOffsetFromPayload)));
|
||||
// It's safe to split use load+store here (instead of a read-modify-write
|
||||
// operation), since it's guaranteed that this 16-bit bitfield is only
|
||||
// modified by a single thread. This is cheaper in terms of code bloat (on
|
||||
// ARM) and performance.
|
||||
uint16_t value = atomic_mutable_bitfield->load(std::memory_order_relaxed);
|
||||
value |= api_constants::kFullyConstructedBitMask;
|
||||
atomic_mutable_bitfield->store(value, std::memory_order_release);
|
||||
}
|
||||
|
||||
// Dispatch based on compile-time information.
|
||||
//
|
||||
// Default implementation is for a custom space with >`kDefaultAlignment` byte
|
||||
// alignment.
|
||||
template <typename GCInfoType, typename CustomSpace, size_t alignment>
|
||||
struct AllocationDispatcher final {
|
||||
static void* Invoke(AllocationHandle& handle, size_t size) {
|
||||
static_assert(std::is_base_of<CustomSpaceBase, CustomSpace>::value,
|
||||
"Custom space must inherit from CustomSpaceBase.");
|
||||
static_assert(
|
||||
!CustomSpace::kSupportsCompaction,
|
||||
"Custom spaces that support compaction do not support allocating "
|
||||
"objects with non-default (i.e. word-sized) alignment.");
|
||||
return MakeGarbageCollectedTraitInternal::Allocate(
|
||||
handle, size, static_cast<AlignVal>(alignment),
|
||||
internal::GCInfoTrait<GCInfoType>::Index(), CustomSpace::kSpaceIndex);
|
||||
}
|
||||
};
|
||||
|
||||
// Fast path for regular allocations for the default space with
|
||||
// `kDefaultAlignment` byte alignment.
|
||||
template <typename GCInfoType>
|
||||
struct AllocationDispatcher<GCInfoType, void,
|
||||
api_constants::kDefaultAlignment>
|
||||
final {
|
||||
static void* Invoke(AllocationHandle& handle, size_t size) {
|
||||
return MakeGarbageCollectedTraitInternal::Allocate(
|
||||
handle, size, internal::GCInfoTrait<GCInfoType>::Index());
|
||||
}
|
||||
};
|
||||
|
||||
// Default space with >`kDefaultAlignment` byte alignment.
|
||||
template <typename GCInfoType, size_t alignment>
|
||||
struct AllocationDispatcher<GCInfoType, void, alignment> final {
|
||||
static void* Invoke(AllocationHandle& handle, size_t size) {
|
||||
return MakeGarbageCollectedTraitInternal::Allocate(
|
||||
handle, size, static_cast<AlignVal>(alignment),
|
||||
internal::GCInfoTrait<GCInfoType>::Index());
|
||||
}
|
||||
};
|
||||
|
||||
// Custom space with `kDefaultAlignment` byte alignment.
|
||||
template <typename GCInfoType, typename CustomSpace>
|
||||
struct AllocationDispatcher<GCInfoType, CustomSpace,
|
||||
api_constants::kDefaultAlignment>
|
||||
final {
|
||||
static void* Invoke(AllocationHandle& handle, size_t size) {
|
||||
static_assert(std::is_base_of<CustomSpaceBase, CustomSpace>::value,
|
||||
"Custom space must inherit from CustomSpaceBase.");
|
||||
return MakeGarbageCollectedTraitInternal::Allocate(
|
||||
handle, size, internal::GCInfoTrait<GCInfoType>::Index(),
|
||||
CustomSpace::kSpaceIndex);
|
||||
}
|
||||
};
|
||||
|
||||
private:
|
||||
static void* CPPGC_DEFAULT_ALIGNED Allocate(cppgc::AllocationHandle&, size_t,
|
||||
GCInfoIndex);
|
||||
static void* CPPGC_DOUBLE_WORD_ALIGNED Allocate(cppgc::AllocationHandle&,
|
||||
size_t, AlignVal,
|
||||
GCInfoIndex);
|
||||
static void* CPPGC_DEFAULT_ALIGNED Allocate(cppgc::AllocationHandle&, size_t,
|
||||
GCInfoIndex, CustomSpaceIndex);
|
||||
static void* CPPGC_DOUBLE_WORD_ALIGNED Allocate(cppgc::AllocationHandle&,
|
||||
size_t, AlignVal, GCInfoIndex,
|
||||
CustomSpaceIndex);
|
||||
|
||||
friend class HeapObjectHeader;
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
/**
|
||||
* Base trait that provides utilities for advancers users that have custom
|
||||
* allocation needs (e.g., overriding size). It's expected that users override
|
||||
* MakeGarbageCollectedTrait (see below) and inherit from
|
||||
* MakeGarbageCollectedTraitBase and make use of the low-level primitives
|
||||
* offered to allocate and construct an object.
|
||||
*/
|
||||
template <typename T>
|
||||
class MakeGarbageCollectedTraitBase
|
||||
: private internal::MakeGarbageCollectedTraitInternal {
|
||||
private:
|
||||
static_assert(internal::IsGarbageCollectedType<T>::value,
|
||||
"T needs to be a garbage collected object");
|
||||
static_assert(!IsGarbageCollectedWithMixinTypeV<T> ||
|
||||
sizeof(T) <=
|
||||
internal::api_constants::kLargeObjectSizeThreshold,
|
||||
"GarbageCollectedMixin may not be a large object");
|
||||
|
||||
protected:
|
||||
/**
|
||||
* Allocates memory for an object of type T.
|
||||
*
|
||||
* \param handle AllocationHandle identifying the heap to allocate the object
|
||||
* on.
|
||||
* \param size The size that should be reserved for the object.
|
||||
* \returns the memory to construct an object of type T on.
|
||||
*/
|
||||
V8_INLINE static void* Allocate(AllocationHandle& handle, size_t size) {
|
||||
static_assert(
|
||||
std::is_base_of<typename T::ParentMostGarbageCollectedType, T>::value,
|
||||
"U of GarbageCollected<U> must be a base of T. Check "
|
||||
"GarbageCollected<T> base class inheritance.");
|
||||
static constexpr size_t kWantedAlignment =
|
||||
alignof(T) < internal::api_constants::kDefaultAlignment
|
||||
? internal::api_constants::kDefaultAlignment
|
||||
: alignof(T);
|
||||
static_assert(
|
||||
kWantedAlignment <= internal::api_constants::kMaxSupportedAlignment,
|
||||
"Requested alignment larger than alignof(std::max_align_t) bytes. "
|
||||
"Please file a bug to possibly get this restriction lifted.");
|
||||
return AllocationDispatcher<
|
||||
typename internal::GCInfoFolding<
|
||||
T, typename T::ParentMostGarbageCollectedType>::ResultType,
|
||||
typename SpaceTrait<T>::Space, kWantedAlignment>::Invoke(handle, size);
|
||||
}
|
||||
|
||||
/**
|
||||
* Marks an object as fully constructed, resulting in precise handling by the
|
||||
* garbage collector.
|
||||
*
|
||||
* \param payload The base pointer the object is allocated at.
|
||||
*/
|
||||
V8_INLINE static void MarkObjectAsFullyConstructed(const void* payload) {
|
||||
internal::MakeGarbageCollectedTraitInternal::MarkObjectAsFullyConstructed(
|
||||
payload);
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* Passed to MakeGarbageCollected to specify how many bytes should be appended
|
||||
* to the allocated object.
|
||||
*
|
||||
* Example:
|
||||
* \code
|
||||
* class InlinedArray final : public GarbageCollected<InlinedArray> {
|
||||
* public:
|
||||
* explicit InlinedArray(size_t bytes) : size(bytes), byte_array(this + 1) {}
|
||||
* void Trace(Visitor*) const {}
|
||||
|
||||
* size_t size;
|
||||
* char* byte_array;
|
||||
* };
|
||||
*
|
||||
* auto* inlined_array = MakeGarbageCollected<InlinedArray(
|
||||
* GetAllocationHandle(), AdditionalBytes(4), 4);
|
||||
* for (size_t i = 0; i < 4; i++) {
|
||||
* Process(inlined_array->byte_array[i]);
|
||||
* }
|
||||
* \endcode
|
||||
*/
|
||||
struct AdditionalBytes {
|
||||
constexpr explicit AdditionalBytes(size_t bytes) : value(bytes) {}
|
||||
const size_t value;
|
||||
};
|
||||
|
||||
/**
|
||||
* Default trait class that specifies how to construct an object of type T.
|
||||
* Advanced users may override how an object is constructed using the utilities
|
||||
* that are provided through MakeGarbageCollectedTraitBase.
|
||||
*
|
||||
* Any trait overriding construction must
|
||||
* - allocate through `MakeGarbageCollectedTraitBase<T>::Allocate`;
|
||||
* - mark the object as fully constructed using
|
||||
* `MakeGarbageCollectedTraitBase<T>::MarkObjectAsFullyConstructed`;
|
||||
*/
|
||||
template <typename T>
|
||||
class MakeGarbageCollectedTrait : public MakeGarbageCollectedTraitBase<T> {
|
||||
public:
|
||||
template <typename... Args>
|
||||
static T* Call(AllocationHandle& handle, Args&&... args) {
|
||||
void* memory =
|
||||
MakeGarbageCollectedTraitBase<T>::Allocate(handle, sizeof(T));
|
||||
T* object = ::new (memory) T(std::forward<Args>(args)...);
|
||||
MakeGarbageCollectedTraitBase<T>::MarkObjectAsFullyConstructed(object);
|
||||
return object;
|
||||
}
|
||||
|
||||
template <typename... Args>
|
||||
static T* Call(AllocationHandle& handle, AdditionalBytes additional_bytes,
|
||||
Args&&... args) {
|
||||
void* memory = MakeGarbageCollectedTraitBase<T>::Allocate(
|
||||
handle, sizeof(T) + additional_bytes.value);
|
||||
T* object = ::new (memory) T(std::forward<Args>(args)...);
|
||||
MakeGarbageCollectedTraitBase<T>::MarkObjectAsFullyConstructed(object);
|
||||
return object;
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* Allows users to specify a post-construction callback for specific types. The
|
||||
* callback is invoked on the instance of type T right after it has been
|
||||
* constructed. This can be useful when the callback requires a
|
||||
* fully-constructed object to be able to dispatch to virtual methods.
|
||||
*/
|
||||
template <typename T, typename = void>
|
||||
struct PostConstructionCallbackTrait {
|
||||
static void Call(T*) {}
|
||||
};
|
||||
|
||||
/**
|
||||
* Constructs a managed object of type T where T transitively inherits from
|
||||
* GarbageCollected.
|
||||
*
|
||||
* \param args List of arguments with which an instance of T will be
|
||||
* constructed.
|
||||
* \returns an instance of type T.
|
||||
*/
|
||||
template <typename T, typename... Args>
|
||||
V8_INLINE T* MakeGarbageCollected(AllocationHandle& handle, Args&&... args) {
|
||||
T* object =
|
||||
MakeGarbageCollectedTrait<T>::Call(handle, std::forward<Args>(args)...);
|
||||
PostConstructionCallbackTrait<T>::Call(object);
|
||||
return object;
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a managed object of type T where T transitively inherits from
|
||||
* GarbageCollected. Created objects will have additional bytes appended to
|
||||
* it. Allocated memory would suffice for `sizeof(T) + additional_bytes`.
|
||||
*
|
||||
* \param additional_bytes Denotes how many bytes to append to T.
|
||||
* \param args List of arguments with which an instance of T will be
|
||||
* constructed.
|
||||
* \returns an instance of type T.
|
||||
*/
|
||||
template <typename T, typename... Args>
|
||||
V8_INLINE T* MakeGarbageCollected(AllocationHandle& handle,
|
||||
AdditionalBytes additional_bytes,
|
||||
Args&&... args) {
|
||||
T* object = MakeGarbageCollectedTrait<T>::Call(handle, additional_bytes,
|
||||
std::forward<Args>(args)...);
|
||||
PostConstructionCallbackTrait<T>::Call(object);
|
||||
return object;
|
||||
}
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#undef CPPGC_DEFAULT_ALIGNED
|
||||
#undef CPPGC_DOUBLE_WORD_ALIGNED
|
||||
|
||||
#endif // INCLUDE_CPPGC_ALLOCATION_H_
|
||||
28
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/common.h
generated
vendored
Normal file
28
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/common.h
generated
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_COMMON_H_
|
||||
#define INCLUDE_CPPGC_COMMON_H_
|
||||
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
/**
|
||||
* Indicator for the stack state of the embedder.
|
||||
*/
|
||||
enum class EmbedderStackState {
|
||||
/**
|
||||
* Stack may contain interesting heap pointers.
|
||||
*/
|
||||
kMayContainHeapPointers,
|
||||
/**
|
||||
* Stack does not contain any interesting heap pointers.
|
||||
*/
|
||||
kNoHeapPointers,
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_COMMON_H_
|
||||
466
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/cross-thread-persistent.h
generated
vendored
Normal file
466
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/cross-thread-persistent.h
generated
vendored
Normal file
@@ -0,0 +1,466 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_CROSS_THREAD_PERSISTENT_H_
|
||||
#define INCLUDE_CPPGC_CROSS_THREAD_PERSISTENT_H_
|
||||
|
||||
#include <atomic>
|
||||
|
||||
#include "cppgc/internal/persistent-node.h"
|
||||
#include "cppgc/internal/pointer-policies.h"
|
||||
#include "cppgc/persistent.h"
|
||||
#include "cppgc/visitor.h"
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
// Wrapper around PersistentBase that allows accessing poisoned memory when
|
||||
// using ASAN. This is needed as the GC of the heap that owns the value
|
||||
// of a CTP, may clear it (heap termination, weakness) while the object
|
||||
// holding the CTP may be poisoned as itself may be deemed dead.
|
||||
class CrossThreadPersistentBase : public PersistentBase {
|
||||
public:
|
||||
CrossThreadPersistentBase() = default;
|
||||
explicit CrossThreadPersistentBase(const void* raw) : PersistentBase(raw) {}
|
||||
|
||||
V8_CLANG_NO_SANITIZE("address") const void* GetValueFromGC() const {
|
||||
return raw_;
|
||||
}
|
||||
|
||||
V8_CLANG_NO_SANITIZE("address")
|
||||
PersistentNode* GetNodeFromGC() const { return node_; }
|
||||
|
||||
V8_CLANG_NO_SANITIZE("address")
|
||||
void ClearFromGC() const {
|
||||
raw_ = nullptr;
|
||||
SetNodeSafe(nullptr);
|
||||
}
|
||||
|
||||
// GetNodeSafe() can be used for a thread-safe IsValid() check in a
|
||||
// double-checked locking pattern. See ~BasicCrossThreadPersistent.
|
||||
PersistentNode* GetNodeSafe() const {
|
||||
return reinterpret_cast<std::atomic<PersistentNode*>*>(&node_)->load(
|
||||
std::memory_order_acquire);
|
||||
}
|
||||
|
||||
// The GC writes using SetNodeSafe() while holding the lock.
|
||||
V8_CLANG_NO_SANITIZE("address")
|
||||
void SetNodeSafe(PersistentNode* value) const {
|
||||
#if defined(__has_feature)
|
||||
#if __has_feature(address_sanitizer)
|
||||
#define V8_IS_ASAN 1
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef V8_IS_ASAN
|
||||
__atomic_store(&node_, &value, __ATOMIC_RELEASE);
|
||||
#else // !V8_IS_ASAN
|
||||
// Non-ASAN builds can use atomics. This also covers MSVC which does not
|
||||
// have the __atomic_store intrinsic.
|
||||
reinterpret_cast<std::atomic<PersistentNode*>*>(&node_)->store(
|
||||
value, std::memory_order_release);
|
||||
#endif // !V8_IS_ASAN
|
||||
|
||||
#undef V8_IS_ASAN
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T, typename WeaknessPolicy, typename LocationPolicy,
|
||||
typename CheckingPolicy>
|
||||
class BasicCrossThreadPersistent final : public CrossThreadPersistentBase,
|
||||
public LocationPolicy,
|
||||
private WeaknessPolicy,
|
||||
private CheckingPolicy {
|
||||
public:
|
||||
using typename WeaknessPolicy::IsStrongPersistent;
|
||||
using PointeeType = T;
|
||||
|
||||
~BasicCrossThreadPersistent() {
|
||||
// This implements fast path for destroying empty/sentinel.
|
||||
//
|
||||
// Simplified version of `AssignUnsafe()` to allow calling without a
|
||||
// complete type `T`. Uses double-checked locking with a simple thread-safe
|
||||
// check for a valid handle based on a node.
|
||||
if (GetNodeSafe()) {
|
||||
PersistentRegionLock guard;
|
||||
const void* old_value = GetValue();
|
||||
// The fast path check (GetNodeSafe()) does not acquire the lock. Recheck
|
||||
// validity while holding the lock to ensure the reference has not been
|
||||
// cleared.
|
||||
if (IsValid(old_value)) {
|
||||
CrossThreadPersistentRegion& region =
|
||||
this->GetPersistentRegion(old_value);
|
||||
region.FreeNode(GetNode());
|
||||
SetNode(nullptr);
|
||||
} else {
|
||||
CPPGC_DCHECK(!GetNode());
|
||||
}
|
||||
}
|
||||
// No need to call SetValue() as the handle is not used anymore. This can
|
||||
// leave behind stale sentinel values but will always destroy the underlying
|
||||
// node.
|
||||
}
|
||||
|
||||
BasicCrossThreadPersistent(
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: LocationPolicy(loc) {}
|
||||
|
||||
BasicCrossThreadPersistent(
|
||||
std::nullptr_t, const SourceLocation& loc = SourceLocation::Current())
|
||||
: LocationPolicy(loc) {}
|
||||
|
||||
BasicCrossThreadPersistent(
|
||||
SentinelPointer s, const SourceLocation& loc = SourceLocation::Current())
|
||||
: CrossThreadPersistentBase(s), LocationPolicy(loc) {}
|
||||
|
||||
BasicCrossThreadPersistent(
|
||||
T* raw, const SourceLocation& loc = SourceLocation::Current())
|
||||
: CrossThreadPersistentBase(raw), LocationPolicy(loc) {
|
||||
if (!IsValid(raw)) return;
|
||||
PersistentRegionLock guard;
|
||||
CrossThreadPersistentRegion& region = this->GetPersistentRegion(raw);
|
||||
SetNode(region.AllocateNode(this, &TraceAsRoot));
|
||||
this->CheckPointer(raw);
|
||||
}
|
||||
|
||||
class UnsafeCtorTag {
|
||||
private:
|
||||
UnsafeCtorTag() = default;
|
||||
template <typename U, typename OtherWeaknessPolicy,
|
||||
typename OtherLocationPolicy, typename OtherCheckingPolicy>
|
||||
friend class BasicCrossThreadPersistent;
|
||||
};
|
||||
|
||||
BasicCrossThreadPersistent(
|
||||
UnsafeCtorTag, T* raw,
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: CrossThreadPersistentBase(raw), LocationPolicy(loc) {
|
||||
if (!IsValid(raw)) return;
|
||||
CrossThreadPersistentRegion& region = this->GetPersistentRegion(raw);
|
||||
SetNode(region.AllocateNode(this, &TraceAsRoot));
|
||||
this->CheckPointer(raw);
|
||||
}
|
||||
|
||||
BasicCrossThreadPersistent(
|
||||
T& raw, const SourceLocation& loc = SourceLocation::Current())
|
||||
: BasicCrossThreadPersistent(&raw, loc) {}
|
||||
|
||||
template <typename U, typename MemberBarrierPolicy,
|
||||
typename MemberWeaknessTag, typename MemberCheckingPolicy,
|
||||
typename MemberStorageType,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
BasicCrossThreadPersistent(
|
||||
internal::BasicMember<U, MemberBarrierPolicy, MemberWeaknessTag,
|
||||
MemberCheckingPolicy, MemberStorageType>
|
||||
member,
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: BasicCrossThreadPersistent(member.Get(), loc) {}
|
||||
|
||||
BasicCrossThreadPersistent(
|
||||
const BasicCrossThreadPersistent& other,
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: BasicCrossThreadPersistent(loc) {
|
||||
// Invoke operator=.
|
||||
*this = other;
|
||||
}
|
||||
|
||||
// Heterogeneous ctor.
|
||||
template <typename U, typename OtherWeaknessPolicy,
|
||||
typename OtherLocationPolicy, typename OtherCheckingPolicy,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
BasicCrossThreadPersistent(
|
||||
const BasicCrossThreadPersistent<U, OtherWeaknessPolicy,
|
||||
OtherLocationPolicy,
|
||||
OtherCheckingPolicy>& other,
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: BasicCrossThreadPersistent(loc) {
|
||||
*this = other;
|
||||
}
|
||||
|
||||
BasicCrossThreadPersistent(
|
||||
BasicCrossThreadPersistent&& other,
|
||||
const SourceLocation& loc = SourceLocation::Current()) noexcept {
|
||||
// Invoke operator=.
|
||||
*this = std::move(other);
|
||||
}
|
||||
|
||||
BasicCrossThreadPersistent& operator=(
|
||||
const BasicCrossThreadPersistent& other) {
|
||||
PersistentRegionLock guard;
|
||||
AssignSafe(guard, other.Get());
|
||||
return *this;
|
||||
}
|
||||
|
||||
template <typename U, typename OtherWeaknessPolicy,
|
||||
typename OtherLocationPolicy, typename OtherCheckingPolicy,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
BasicCrossThreadPersistent& operator=(
|
||||
const BasicCrossThreadPersistent<U, OtherWeaknessPolicy,
|
||||
OtherLocationPolicy,
|
||||
OtherCheckingPolicy>& other) {
|
||||
PersistentRegionLock guard;
|
||||
AssignSafe(guard, other.Get());
|
||||
return *this;
|
||||
}
|
||||
|
||||
BasicCrossThreadPersistent& operator=(BasicCrossThreadPersistent&& other) {
|
||||
if (this == &other) return *this;
|
||||
Clear();
|
||||
PersistentRegionLock guard;
|
||||
PersistentBase::operator=(std::move(other));
|
||||
LocationPolicy::operator=(std::move(other));
|
||||
if (!IsValid(GetValue())) return *this;
|
||||
GetNode()->UpdateOwner(this);
|
||||
other.SetValue(nullptr);
|
||||
other.SetNode(nullptr);
|
||||
this->CheckPointer(Get());
|
||||
return *this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Assigns a raw pointer.
|
||||
*
|
||||
* Note: **Not thread-safe.**
|
||||
*/
|
||||
BasicCrossThreadPersistent& operator=(T* other) {
|
||||
AssignUnsafe(other);
|
||||
return *this;
|
||||
}
|
||||
|
||||
// Assignment from member.
|
||||
template <typename U, typename MemberBarrierPolicy,
|
||||
typename MemberWeaknessTag, typename MemberCheckingPolicy,
|
||||
typename MemberStorageType,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
BasicCrossThreadPersistent& operator=(
|
||||
internal::BasicMember<U, MemberBarrierPolicy, MemberWeaknessTag,
|
||||
MemberCheckingPolicy, MemberStorageType>
|
||||
member) {
|
||||
return operator=(member.Get());
|
||||
}
|
||||
|
||||
/**
|
||||
* Assigns a nullptr.
|
||||
*
|
||||
* \returns the handle.
|
||||
*/
|
||||
BasicCrossThreadPersistent& operator=(std::nullptr_t) {
|
||||
Clear();
|
||||
return *this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Assigns the sentinel pointer.
|
||||
*
|
||||
* \returns the handle.
|
||||
*/
|
||||
BasicCrossThreadPersistent& operator=(SentinelPointer s) {
|
||||
PersistentRegionLock guard;
|
||||
AssignSafe(guard, s);
|
||||
return *this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a pointer to the stored object.
|
||||
*
|
||||
* Note: **Not thread-safe.**
|
||||
*
|
||||
* \returns a pointer to the stored object.
|
||||
*/
|
||||
// CFI cast exemption to allow passing SentinelPointer through T* and support
|
||||
// heterogeneous assignments between different Member and Persistent handles
|
||||
// based on their actual types.
|
||||
V8_CLANG_NO_SANITIZE("cfi-unrelated-cast") T* Get() const {
|
||||
return static_cast<T*>(const_cast<void*>(GetValue()));
|
||||
}
|
||||
|
||||
/**
|
||||
* Clears the stored object.
|
||||
*/
|
||||
void Clear() {
|
||||
PersistentRegionLock guard;
|
||||
AssignSafe(guard, nullptr);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a pointer to the stored object and releases it.
|
||||
*
|
||||
* Note: **Not thread-safe.**
|
||||
*
|
||||
* \returns a pointer to the stored object.
|
||||
*/
|
||||
T* Release() {
|
||||
T* result = Get();
|
||||
Clear();
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Conversio to boolean.
|
||||
*
|
||||
* Note: **Not thread-safe.**
|
||||
*
|
||||
* \returns true if an actual object has been stored and false otherwise.
|
||||
*/
|
||||
explicit operator bool() const { return Get(); }
|
||||
|
||||
/**
|
||||
* Conversion to object of type T.
|
||||
*
|
||||
* Note: **Not thread-safe.**
|
||||
*
|
||||
* \returns the object.
|
||||
*/
|
||||
operator T*() const { return Get(); }
|
||||
|
||||
/**
|
||||
* Dereferences the stored object.
|
||||
*
|
||||
* Note: **Not thread-safe.**
|
||||
*/
|
||||
T* operator->() const { return Get(); }
|
||||
T& operator*() const { return *Get(); }
|
||||
|
||||
template <typename U, typename OtherWeaknessPolicy = WeaknessPolicy,
|
||||
typename OtherLocationPolicy = LocationPolicy,
|
||||
typename OtherCheckingPolicy = CheckingPolicy>
|
||||
BasicCrossThreadPersistent<U, OtherWeaknessPolicy, OtherLocationPolicy,
|
||||
OtherCheckingPolicy>
|
||||
To() const {
|
||||
using OtherBasicCrossThreadPersistent =
|
||||
BasicCrossThreadPersistent<U, OtherWeaknessPolicy, OtherLocationPolicy,
|
||||
OtherCheckingPolicy>;
|
||||
PersistentRegionLock guard;
|
||||
return OtherBasicCrossThreadPersistent(
|
||||
typename OtherBasicCrossThreadPersistent::UnsafeCtorTag(),
|
||||
static_cast<U*>(Get()));
|
||||
}
|
||||
|
||||
template <typename U = T,
|
||||
typename = typename std::enable_if<!BasicCrossThreadPersistent<
|
||||
U, WeaknessPolicy>::IsStrongPersistent::value>::type>
|
||||
BasicCrossThreadPersistent<U, internal::StrongCrossThreadPersistentPolicy>
|
||||
Lock() const {
|
||||
return BasicCrossThreadPersistent<
|
||||
U, internal::StrongCrossThreadPersistentPolicy>(*this);
|
||||
}
|
||||
|
||||
private:
|
||||
static bool IsValid(const void* ptr) {
|
||||
return ptr && ptr != kSentinelPointer;
|
||||
}
|
||||
|
||||
static void TraceAsRoot(RootVisitor& root_visitor, const void* ptr) {
|
||||
root_visitor.Trace(*static_cast<const BasicCrossThreadPersistent*>(ptr));
|
||||
}
|
||||
|
||||
void AssignUnsafe(T* ptr) {
|
||||
const void* old_value = GetValue();
|
||||
if (IsValid(old_value)) {
|
||||
PersistentRegionLock guard;
|
||||
old_value = GetValue();
|
||||
// The fast path check (IsValid()) does not acquire the lock. Reload
|
||||
// the value to ensure the reference has not been cleared.
|
||||
if (IsValid(old_value)) {
|
||||
CrossThreadPersistentRegion& region =
|
||||
this->GetPersistentRegion(old_value);
|
||||
if (IsValid(ptr) && (®ion == &this->GetPersistentRegion(ptr))) {
|
||||
SetValue(ptr);
|
||||
this->CheckPointer(ptr);
|
||||
return;
|
||||
}
|
||||
region.FreeNode(GetNode());
|
||||
SetNode(nullptr);
|
||||
} else {
|
||||
CPPGC_DCHECK(!GetNode());
|
||||
}
|
||||
}
|
||||
SetValue(ptr);
|
||||
if (!IsValid(ptr)) return;
|
||||
PersistentRegionLock guard;
|
||||
SetNode(this->GetPersistentRegion(ptr).AllocateNode(this, &TraceAsRoot));
|
||||
this->CheckPointer(ptr);
|
||||
}
|
||||
|
||||
void AssignSafe(PersistentRegionLock&, T* ptr) {
|
||||
PersistentRegionLock::AssertLocked();
|
||||
const void* old_value = GetValue();
|
||||
if (IsValid(old_value)) {
|
||||
CrossThreadPersistentRegion& region =
|
||||
this->GetPersistentRegion(old_value);
|
||||
if (IsValid(ptr) && (®ion == &this->GetPersistentRegion(ptr))) {
|
||||
SetValue(ptr);
|
||||
this->CheckPointer(ptr);
|
||||
return;
|
||||
}
|
||||
region.FreeNode(GetNode());
|
||||
SetNode(nullptr);
|
||||
}
|
||||
SetValue(ptr);
|
||||
if (!IsValid(ptr)) return;
|
||||
SetNode(this->GetPersistentRegion(ptr).AllocateNode(this, &TraceAsRoot));
|
||||
this->CheckPointer(ptr);
|
||||
}
|
||||
|
||||
void ClearFromGC() const {
|
||||
if (IsValid(GetValueFromGC())) {
|
||||
WeaknessPolicy::GetPersistentRegion(GetValueFromGC())
|
||||
.FreeNode(GetNodeFromGC());
|
||||
CrossThreadPersistentBase::ClearFromGC();
|
||||
}
|
||||
}
|
||||
|
||||
// See Get() for details.
|
||||
V8_CLANG_NO_SANITIZE("cfi-unrelated-cast")
|
||||
T* GetFromGC() const {
|
||||
return static_cast<T*>(const_cast<void*>(GetValueFromGC()));
|
||||
}
|
||||
|
||||
friend class internal::RootVisitor;
|
||||
};
|
||||
|
||||
template <typename T, typename LocationPolicy, typename CheckingPolicy>
|
||||
struct IsWeak<
|
||||
BasicCrossThreadPersistent<T, internal::WeakCrossThreadPersistentPolicy,
|
||||
LocationPolicy, CheckingPolicy>>
|
||||
: std::true_type {};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
namespace subtle {
|
||||
|
||||
/**
|
||||
* **DO NOT USE: Has known caveats, see below.**
|
||||
*
|
||||
* CrossThreadPersistent allows retaining objects from threads other than the
|
||||
* thread the owning heap is operating on.
|
||||
*
|
||||
* Known caveats:
|
||||
* - Does not protect the heap owning an object from terminating.
|
||||
* - Reaching transitively through the graph is unsupported as objects may be
|
||||
* moved concurrently on the thread owning the object.
|
||||
*/
|
||||
template <typename T>
|
||||
using CrossThreadPersistent = internal::BasicCrossThreadPersistent<
|
||||
T, internal::StrongCrossThreadPersistentPolicy>;
|
||||
|
||||
/**
|
||||
* **DO NOT USE: Has known caveats, see below.**
|
||||
*
|
||||
* CrossThreadPersistent allows weakly retaining objects from threads other than
|
||||
* the thread the owning heap is operating on.
|
||||
*
|
||||
* Known caveats:
|
||||
* - Does not protect the heap owning an object from terminating.
|
||||
* - Reaching transitively through the graph is unsupported as objects may be
|
||||
* moved concurrently on the thread owning the object.
|
||||
*/
|
||||
template <typename T>
|
||||
using WeakCrossThreadPersistent = internal::BasicCrossThreadPersistent<
|
||||
T, internal::WeakCrossThreadPersistentPolicy>;
|
||||
|
||||
} // namespace subtle
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_CROSS_THREAD_PERSISTENT_H_
|
||||
97
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/custom-space.h
generated
vendored
Normal file
97
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/custom-space.h
generated
vendored
Normal file
@@ -0,0 +1,97 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_CUSTOM_SPACE_H_
|
||||
#define INCLUDE_CPPGC_CUSTOM_SPACE_H_
|
||||
|
||||
#include <stddef.h>
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
/**
|
||||
* Index identifying a custom space.
|
||||
*/
|
||||
struct CustomSpaceIndex {
|
||||
constexpr CustomSpaceIndex(size_t value) : value(value) {} // NOLINT
|
||||
size_t value;
|
||||
};
|
||||
|
||||
/**
|
||||
* Top-level base class for custom spaces. Users must inherit from CustomSpace
|
||||
* below.
|
||||
*/
|
||||
class CustomSpaceBase {
|
||||
public:
|
||||
virtual ~CustomSpaceBase() = default;
|
||||
virtual CustomSpaceIndex GetCustomSpaceIndex() const = 0;
|
||||
virtual bool IsCompactable() const = 0;
|
||||
};
|
||||
|
||||
/**
|
||||
* Base class custom spaces should directly inherit from. The class inheriting
|
||||
* from `CustomSpace` must define `kSpaceIndex` as unique space index. These
|
||||
* indices need for form a sequence starting at 0.
|
||||
*
|
||||
* Example:
|
||||
* \code
|
||||
* class CustomSpace1 : public CustomSpace<CustomSpace1> {
|
||||
* public:
|
||||
* static constexpr CustomSpaceIndex kSpaceIndex = 0;
|
||||
* };
|
||||
* class CustomSpace2 : public CustomSpace<CustomSpace2> {
|
||||
* public:
|
||||
* static constexpr CustomSpaceIndex kSpaceIndex = 1;
|
||||
* };
|
||||
* \endcode
|
||||
*/
|
||||
template <typename ConcreteCustomSpace>
|
||||
class CustomSpace : public CustomSpaceBase {
|
||||
public:
|
||||
/**
|
||||
* Compaction is only supported on spaces that manually manage slots
|
||||
* recording.
|
||||
*/
|
||||
static constexpr bool kSupportsCompaction = false;
|
||||
|
||||
CustomSpaceIndex GetCustomSpaceIndex() const final {
|
||||
return ConcreteCustomSpace::kSpaceIndex;
|
||||
}
|
||||
bool IsCompactable() const final {
|
||||
return ConcreteCustomSpace::kSupportsCompaction;
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* User-overridable trait that allows pinning types to custom spaces.
|
||||
*/
|
||||
template <typename T, typename = void>
|
||||
struct SpaceTrait {
|
||||
using Space = void;
|
||||
};
|
||||
|
||||
namespace internal {
|
||||
|
||||
template <typename CustomSpace>
|
||||
struct IsAllocatedOnCompactableSpaceImpl {
|
||||
static constexpr bool value = CustomSpace::kSupportsCompaction;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct IsAllocatedOnCompactableSpaceImpl<void> {
|
||||
// Non-custom spaces are by default not compactable.
|
||||
static constexpr bool value = false;
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct IsAllocatedOnCompactableSpace {
|
||||
public:
|
||||
static constexpr bool value =
|
||||
IsAllocatedOnCompactableSpaceImpl<typename SpaceTrait<T>::Space>::value;
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_CUSTOM_SPACE_H_
|
||||
67
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/default-platform.h
generated
vendored
Normal file
67
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/default-platform.h
generated
vendored
Normal file
@@ -0,0 +1,67 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_DEFAULT_PLATFORM_H_
|
||||
#define INCLUDE_CPPGC_DEFAULT_PLATFORM_H_
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "cppgc/platform.h"
|
||||
#include "libplatform/libplatform.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
/**
|
||||
* Platform provided by cppgc. Uses V8's DefaultPlatform provided by
|
||||
* libplatform internally. Exception: `GetForegroundTaskRunner()`, see below.
|
||||
*/
|
||||
class V8_EXPORT DefaultPlatform : public Platform {
|
||||
public:
|
||||
using IdleTaskSupport = v8::platform::IdleTaskSupport;
|
||||
explicit DefaultPlatform(
|
||||
int thread_pool_size = 0,
|
||||
IdleTaskSupport idle_task_support = IdleTaskSupport::kDisabled,
|
||||
std::unique_ptr<TracingController> tracing_controller = {})
|
||||
: v8_platform_(v8::platform::NewDefaultPlatform(
|
||||
thread_pool_size, idle_task_support,
|
||||
v8::platform::InProcessStackDumping::kDisabled,
|
||||
std::move(tracing_controller))) {}
|
||||
|
||||
cppgc::PageAllocator* GetPageAllocator() override {
|
||||
return v8_platform_->GetPageAllocator();
|
||||
}
|
||||
|
||||
double MonotonicallyIncreasingTime() override {
|
||||
return v8_platform_->MonotonicallyIncreasingTime();
|
||||
}
|
||||
|
||||
std::shared_ptr<cppgc::TaskRunner> GetForegroundTaskRunner() override {
|
||||
// V8's default platform creates a new task runner when passed the
|
||||
// `v8::Isolate` pointer the first time. For non-default platforms this will
|
||||
// require getting the appropriate task runner.
|
||||
return v8_platform_->GetForegroundTaskRunner(kNoIsolate);
|
||||
}
|
||||
|
||||
std::unique_ptr<cppgc::JobHandle> PostJob(
|
||||
cppgc::TaskPriority priority,
|
||||
std::unique_ptr<cppgc::JobTask> job_task) override {
|
||||
return v8_platform_->PostJob(priority, std::move(job_task));
|
||||
}
|
||||
|
||||
TracingController* GetTracingController() override {
|
||||
return v8_platform_->GetTracingController();
|
||||
}
|
||||
|
||||
v8::Platform* GetV8Platform() const { return v8_platform_.get(); }
|
||||
|
||||
protected:
|
||||
static constexpr v8::Isolate* kNoIsolate = nullptr;
|
||||
|
||||
std::unique_ptr<v8::Platform> v8_platform_;
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_DEFAULT_PLATFORM_H_
|
||||
30
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/ephemeron-pair.h
generated
vendored
Normal file
30
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/ephemeron-pair.h
generated
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_EPHEMERON_PAIR_H_
|
||||
#define INCLUDE_CPPGC_EPHEMERON_PAIR_H_
|
||||
|
||||
#include "cppgc/liveness-broker.h"
|
||||
#include "cppgc/member.h"
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
/**
|
||||
* An ephemeron pair is used to conditionally retain an object.
|
||||
* The `value` will be kept alive only if the `key` is alive.
|
||||
*/
|
||||
template <typename K, typename V>
|
||||
struct EphemeronPair {
|
||||
EphemeronPair(K* k, V* v) : key(k), value(v) {}
|
||||
WeakMember<K> key;
|
||||
Member<V> value;
|
||||
|
||||
void ClearValueIfKeyIsDead(const LivenessBroker& broker) {
|
||||
if (!broker.IsHeapObjectAlive(key)) value = nullptr;
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_EPHEMERON_PAIR_H_
|
||||
100
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/explicit-management.h
generated
vendored
Normal file
100
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/explicit-management.h
generated
vendored
Normal file
@@ -0,0 +1,100 @@
|
||||
// Copyright 2021 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_EXPLICIT_MANAGEMENT_H_
|
||||
#define INCLUDE_CPPGC_EXPLICIT_MANAGEMENT_H_
|
||||
|
||||
#include <cstddef>
|
||||
|
||||
#include "cppgc/allocation.h"
|
||||
#include "cppgc/internal/logging.h"
|
||||
#include "cppgc/type-traits.h"
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
class HeapHandle;
|
||||
|
||||
namespace subtle {
|
||||
|
||||
template <typename T>
|
||||
void FreeUnreferencedObject(HeapHandle& heap_handle, T& object);
|
||||
template <typename T>
|
||||
bool Resize(T& object, AdditionalBytes additional_bytes);
|
||||
|
||||
} // namespace subtle
|
||||
|
||||
namespace internal {
|
||||
|
||||
class ExplicitManagementImpl final {
|
||||
private:
|
||||
V8_EXPORT static void FreeUnreferencedObject(HeapHandle&, void*);
|
||||
V8_EXPORT static bool Resize(void*, size_t);
|
||||
|
||||
template <typename T>
|
||||
friend void subtle::FreeUnreferencedObject(HeapHandle&, T&);
|
||||
template <typename T>
|
||||
friend bool subtle::Resize(T&, AdditionalBytes);
|
||||
};
|
||||
} // namespace internal
|
||||
|
||||
namespace subtle {
|
||||
|
||||
/**
|
||||
* Informs the garbage collector that `object` can be immediately reclaimed. The
|
||||
* destructor may not be invoked immediately but only on next garbage
|
||||
* collection.
|
||||
*
|
||||
* It is up to the embedder to guarantee that no other object holds a reference
|
||||
* to `object` after calling `FreeUnreferencedObject()`. In case such a
|
||||
* reference exists, it's use results in a use-after-free.
|
||||
*
|
||||
* To aid in using the API, `FreeUnreferencedObject()` may be called from
|
||||
* destructors on objects that would be reclaimed in the same garbage collection
|
||||
* cycle.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
* \param object Reference to an object that is of type `GarbageCollected` and
|
||||
* should be immediately reclaimed.
|
||||
*/
|
||||
template <typename T>
|
||||
void FreeUnreferencedObject(HeapHandle& heap_handle, T& object) {
|
||||
static_assert(IsGarbageCollectedTypeV<T>,
|
||||
"Object must be of type GarbageCollected.");
|
||||
internal::ExplicitManagementImpl::FreeUnreferencedObject(heap_handle,
|
||||
&object);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tries to resize `object` of type `T` with additional bytes on top of
|
||||
* sizeof(T). Resizing is only useful with trailing inlined storage, see e.g.
|
||||
* `MakeGarbageCollected(AllocationHandle&, AdditionalBytes)`.
|
||||
*
|
||||
* `Resize()` performs growing or shrinking as needed and may skip the operation
|
||||
* for internal reasons, see return value.
|
||||
*
|
||||
* It is up to the embedder to guarantee that in case of shrinking a larger
|
||||
* object down, the reclaimed area is not used anymore. Any subsequent use
|
||||
* results in a use-after-free.
|
||||
*
|
||||
* The `object` must be live when calling `Resize()`.
|
||||
*
|
||||
* \param object Reference to an object that is of type `GarbageCollected` and
|
||||
* should be resized.
|
||||
* \param additional_bytes Bytes in addition to sizeof(T) that the object should
|
||||
* provide.
|
||||
* \returns true when the operation was successful and the result can be relied
|
||||
* on, and false otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
bool Resize(T& object, AdditionalBytes additional_bytes) {
|
||||
static_assert(IsGarbageCollectedTypeV<T>,
|
||||
"Object must be of type GarbageCollected.");
|
||||
return internal::ExplicitManagementImpl::Resize(
|
||||
&object, sizeof(T) + additional_bytes.value);
|
||||
}
|
||||
|
||||
} // namespace subtle
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_EXPLICIT_MANAGEMENT_H_
|
||||
106
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/garbage-collected.h
generated
vendored
Normal file
106
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/garbage-collected.h
generated
vendored
Normal file
@@ -0,0 +1,106 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_GARBAGE_COLLECTED_H_
|
||||
#define INCLUDE_CPPGC_GARBAGE_COLLECTED_H_
|
||||
|
||||
#include "cppgc/internal/api-constants.h"
|
||||
#include "cppgc/platform.h"
|
||||
#include "cppgc/trace-trait.h"
|
||||
#include "cppgc/type-traits.h"
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
class Visitor;
|
||||
|
||||
/**
|
||||
* Base class for managed objects. Only descendent types of `GarbageCollected`
|
||||
* can be constructed using `MakeGarbageCollected()`. Must be inherited from as
|
||||
* left-most base class.
|
||||
*
|
||||
* Types inheriting from GarbageCollected must provide a method of
|
||||
* signature `void Trace(cppgc::Visitor*) const` that dispatchs all managed
|
||||
* pointers to the visitor and delegates to garbage-collected base classes.
|
||||
* The method must be virtual if the type is not directly a child of
|
||||
* GarbageCollected and marked as final.
|
||||
*
|
||||
* \code
|
||||
* // Example using final class.
|
||||
* class FinalType final : public GarbageCollected<FinalType> {
|
||||
* public:
|
||||
* void Trace(cppgc::Visitor* visitor) const {
|
||||
* // Dispatch using visitor->Trace(...);
|
||||
* }
|
||||
* };
|
||||
*
|
||||
* // Example using non-final base class.
|
||||
* class NonFinalBase : public GarbageCollected<NonFinalBase> {
|
||||
* public:
|
||||
* virtual void Trace(cppgc::Visitor*) const {}
|
||||
* };
|
||||
*
|
||||
* class FinalChild final : public NonFinalBase {
|
||||
* public:
|
||||
* void Trace(cppgc::Visitor* visitor) const final {
|
||||
* // Dispatch using visitor->Trace(...);
|
||||
* NonFinalBase::Trace(visitor);
|
||||
* }
|
||||
* };
|
||||
* \endcode
|
||||
*/
|
||||
template <typename T>
|
||||
class GarbageCollected {
|
||||
public:
|
||||
using IsGarbageCollectedTypeMarker = void;
|
||||
using ParentMostGarbageCollectedType = T;
|
||||
|
||||
// Must use MakeGarbageCollected.
|
||||
void* operator new(size_t) = delete;
|
||||
void* operator new[](size_t) = delete;
|
||||
// The garbage collector is taking care of reclaiming the object. Also,
|
||||
// virtual destructor requires an unambiguous, accessible 'operator delete'.
|
||||
void operator delete(void*) {
|
||||
#ifdef V8_ENABLE_CHECKS
|
||||
internal::Fatal(
|
||||
"Manually deleting a garbage collected object is not allowed");
|
||||
#endif // V8_ENABLE_CHECKS
|
||||
}
|
||||
void operator delete[](void*) = delete;
|
||||
|
||||
protected:
|
||||
GarbageCollected() = default;
|
||||
};
|
||||
|
||||
/**
|
||||
* Base class for managed mixin objects. Such objects cannot be constructed
|
||||
* directly but must be mixed into the inheritance hierarchy of a
|
||||
* GarbageCollected object.
|
||||
*
|
||||
* Types inheriting from GarbageCollectedMixin must override a virtual method
|
||||
* of signature `void Trace(cppgc::Visitor*) const` that dispatchs all managed
|
||||
* pointers to the visitor and delegates to base classes.
|
||||
*
|
||||
* \code
|
||||
* class Mixin : public GarbageCollectedMixin {
|
||||
* public:
|
||||
* void Trace(cppgc::Visitor* visitor) const override {
|
||||
* // Dispatch using visitor->Trace(...);
|
||||
* }
|
||||
* };
|
||||
* \endcode
|
||||
*/
|
||||
class GarbageCollectedMixin {
|
||||
public:
|
||||
using IsGarbageCollectedMixinTypeMarker = void;
|
||||
|
||||
/**
|
||||
* This Trace method must be overriden by objects inheriting from
|
||||
* GarbageCollectedMixin.
|
||||
*/
|
||||
virtual void Trace(cppgc::Visitor*) const {}
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_GARBAGE_COLLECTED_H_
|
||||
309
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap-consistency.h
generated
vendored
Normal file
309
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap-consistency.h
generated
vendored
Normal file
@@ -0,0 +1,309 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_HEAP_CONSISTENCY_H_
|
||||
#define INCLUDE_CPPGC_HEAP_CONSISTENCY_H_
|
||||
|
||||
#include <cstddef>
|
||||
|
||||
#include "cppgc/internal/write-barrier.h"
|
||||
#include "cppgc/macros.h"
|
||||
#include "cppgc/member.h"
|
||||
#include "cppgc/trace-trait.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
class HeapHandle;
|
||||
|
||||
namespace subtle {
|
||||
|
||||
/**
|
||||
* **DO NOT USE: Use the appropriate managed types.**
|
||||
*
|
||||
* Consistency helpers that aid in maintaining a consistent internal state of
|
||||
* the garbage collector.
|
||||
*/
|
||||
class HeapConsistency final {
|
||||
public:
|
||||
using WriteBarrierParams = internal::WriteBarrier::Params;
|
||||
using WriteBarrierType = internal::WriteBarrier::Type;
|
||||
|
||||
/**
|
||||
* Gets the required write barrier type for a specific write.
|
||||
*
|
||||
* \param slot Slot containing the pointer to the object. The slot itself
|
||||
* must reside in an object that has been allocated using
|
||||
* `MakeGarbageCollected()`.
|
||||
* \param value The pointer to the object. May be an interior pointer to an
|
||||
* interface of the actual object.
|
||||
* \param params Parameters that may be used for actual write barrier calls.
|
||||
* Only filled if return value indicates that a write barrier is needed. The
|
||||
* contents of the `params` are an implementation detail.
|
||||
* \returns whether a write barrier is needed and which barrier to invoke.
|
||||
*/
|
||||
static V8_INLINE WriteBarrierType GetWriteBarrierType(
|
||||
const void* slot, const void* value, WriteBarrierParams& params) {
|
||||
return internal::WriteBarrier::GetWriteBarrierType(slot, value, params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the required write barrier type for a specific write. This override is
|
||||
* only used for all the BasicMember types.
|
||||
*
|
||||
* \param slot Slot containing the pointer to the object. The slot itself
|
||||
* must reside in an object that has been allocated using
|
||||
* `MakeGarbageCollected()`.
|
||||
* \param value The pointer to the object held via `BasicMember`.
|
||||
* \param params Parameters that may be used for actual write barrier calls.
|
||||
* Only filled if return value indicates that a write barrier is needed. The
|
||||
* contents of the `params` are an implementation detail.
|
||||
* \returns whether a write barrier is needed and which barrier to invoke.
|
||||
*/
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
static V8_INLINE WriteBarrierType GetWriteBarrierType(
|
||||
const internal::BasicMember<T, WeaknessTag, WriteBarrierPolicy,
|
||||
CheckingPolicy, StorageType>& value,
|
||||
WriteBarrierParams& params) {
|
||||
return internal::WriteBarrier::GetWriteBarrierType(
|
||||
value.GetRawSlot(), value.GetRawStorage(), params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the required write barrier type for a specific write.
|
||||
*
|
||||
* \param slot Slot to some part of an object. The object must not necessarily
|
||||
have been allocated using `MakeGarbageCollected()` but can also live
|
||||
off-heap or on stack.
|
||||
* \param params Parameters that may be used for actual write barrier calls.
|
||||
* Only filled if return value indicates that a write barrier is needed. The
|
||||
* contents of the `params` are an implementation detail.
|
||||
* \param callback Callback returning the corresponding heap handle. The
|
||||
* callback is only invoked if the heap cannot otherwise be figured out. The
|
||||
* callback must not allocate.
|
||||
* \returns whether a write barrier is needed and which barrier to invoke.
|
||||
*/
|
||||
template <typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrierType
|
||||
GetWriteBarrierType(const void* slot, WriteBarrierParams& params,
|
||||
HeapHandleCallback callback) {
|
||||
return internal::WriteBarrier::GetWriteBarrierType(slot, params, callback);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the required write barrier type for a specific write.
|
||||
* This version is meant to be used in conjunction with with a marking write
|
||||
* barrier barrier which doesn't consider the slot.
|
||||
*
|
||||
* \param value The pointer to the object. May be an interior pointer to an
|
||||
* interface of the actual object.
|
||||
* \param params Parameters that may be used for actual write barrier calls.
|
||||
* Only filled if return value indicates that a write barrier is needed. The
|
||||
* contents of the `params` are an implementation detail.
|
||||
* \returns whether a write barrier is needed and which barrier to invoke.
|
||||
*/
|
||||
static V8_INLINE WriteBarrierType
|
||||
GetWriteBarrierType(const void* value, WriteBarrierParams& params) {
|
||||
return internal::WriteBarrier::GetWriteBarrierType(value, params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Conservative Dijkstra-style write barrier that processes an object if it
|
||||
* has not yet been processed.
|
||||
*
|
||||
* \param params The parameters retrieved from `GetWriteBarrierType()`.
|
||||
* \param object The pointer to the object. May be an interior pointer to a
|
||||
* an interface of the actual object.
|
||||
*/
|
||||
static V8_INLINE void DijkstraWriteBarrier(const WriteBarrierParams& params,
|
||||
const void* object) {
|
||||
internal::WriteBarrier::DijkstraMarkingBarrier(params, object);
|
||||
}
|
||||
|
||||
/**
|
||||
* Conservative Dijkstra-style write barrier that processes a range of
|
||||
* elements if they have not yet been processed.
|
||||
*
|
||||
* \param params The parameters retrieved from `GetWriteBarrierType()`.
|
||||
* \param first_element Pointer to the first element that should be processed.
|
||||
* The slot itself must reside in an object that has been allocated using
|
||||
* `MakeGarbageCollected()`.
|
||||
* \param element_size Size of the element in bytes.
|
||||
* \param number_of_elements Number of elements that should be processed,
|
||||
* starting with `first_element`.
|
||||
* \param trace_callback The trace callback that should be invoked for each
|
||||
* element if necessary.
|
||||
*/
|
||||
static V8_INLINE void DijkstraWriteBarrierRange(
|
||||
const WriteBarrierParams& params, const void* first_element,
|
||||
size_t element_size, size_t number_of_elements,
|
||||
TraceCallback trace_callback) {
|
||||
internal::WriteBarrier::DijkstraMarkingBarrierRange(
|
||||
params, first_element, element_size, number_of_elements,
|
||||
trace_callback);
|
||||
}
|
||||
|
||||
/**
|
||||
* Steele-style write barrier that re-processes an object if it has already
|
||||
* been processed.
|
||||
*
|
||||
* \param params The parameters retrieved from `GetWriteBarrierType()`.
|
||||
* \param object The pointer to the object which must point to an object that
|
||||
* has been allocated using `MakeGarbageCollected()`. Interior pointers are
|
||||
* not supported.
|
||||
*/
|
||||
static V8_INLINE void SteeleWriteBarrier(const WriteBarrierParams& params,
|
||||
const void* object) {
|
||||
internal::WriteBarrier::SteeleMarkingBarrier(params, object);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generational barrier for maintaining consistency when running with multiple
|
||||
* generations.
|
||||
*
|
||||
* \param params The parameters retrieved from `GetWriteBarrierType()`.
|
||||
* \param slot Slot containing the pointer to the object. The slot itself
|
||||
* must reside in an object that has been allocated using
|
||||
* `MakeGarbageCollected()`.
|
||||
*/
|
||||
static V8_INLINE void GenerationalBarrier(const WriteBarrierParams& params,
|
||||
const void* slot) {
|
||||
internal::WriteBarrier::GenerationalBarrier<
|
||||
internal::WriteBarrier::GenerationalBarrierType::kPreciseSlot>(params,
|
||||
slot);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generational barrier for maintaining consistency when running with multiple
|
||||
* generations. This version is used when slot contains uncompressed pointer.
|
||||
*
|
||||
* \param params The parameters retrieved from `GetWriteBarrierType()`.
|
||||
* \param slot Uncompressed slot containing the direct pointer to the object.
|
||||
* The slot itself must reside in an object that has been allocated using
|
||||
* `MakeGarbageCollected()`.
|
||||
*/
|
||||
static V8_INLINE void GenerationalBarrierForUncompressedSlot(
|
||||
const WriteBarrierParams& params, const void* uncompressed_slot) {
|
||||
internal::WriteBarrier::GenerationalBarrier<
|
||||
internal::WriteBarrier::GenerationalBarrierType::
|
||||
kPreciseUncompressedSlot>(params, uncompressed_slot);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generational barrier for source object that may contain outgoing pointers
|
||||
* to objects in young generation.
|
||||
*
|
||||
* \param params The parameters retrieved from `GetWriteBarrierType()`.
|
||||
* \param inner_pointer Pointer to the source object.
|
||||
*/
|
||||
static V8_INLINE void GenerationalBarrierForSourceObject(
|
||||
const WriteBarrierParams& params, const void* inner_pointer) {
|
||||
internal::WriteBarrier::GenerationalBarrier<
|
||||
internal::WriteBarrier::GenerationalBarrierType::kImpreciseSlot>(
|
||||
params, inner_pointer);
|
||||
}
|
||||
|
||||
private:
|
||||
HeapConsistency() = delete;
|
||||
};
|
||||
|
||||
/**
|
||||
* Disallows garbage collection finalizations. Any garbage collection triggers
|
||||
* result in a crash when in this scope.
|
||||
*
|
||||
* Note that the garbage collector already covers paths that can lead to garbage
|
||||
* collections, so user code does not require checking
|
||||
* `IsGarbageCollectionAllowed()` before allocations.
|
||||
*/
|
||||
class V8_EXPORT V8_NODISCARD DisallowGarbageCollectionScope final {
|
||||
CPPGC_STACK_ALLOCATED();
|
||||
|
||||
public:
|
||||
/**
|
||||
* \returns whether garbage collections are currently allowed.
|
||||
*/
|
||||
static bool IsGarbageCollectionAllowed(HeapHandle& heap_handle);
|
||||
|
||||
/**
|
||||
* Enters a disallow garbage collection scope. Must be paired with `Leave()`.
|
||||
* Prefer a scope instance of `DisallowGarbageCollectionScope`.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
*/
|
||||
static void Enter(HeapHandle& heap_handle);
|
||||
|
||||
/**
|
||||
* Leaves a disallow garbage collection scope. Must be paired with `Enter()`.
|
||||
* Prefer a scope instance of `DisallowGarbageCollectionScope`.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
*/
|
||||
static void Leave(HeapHandle& heap_handle);
|
||||
|
||||
/**
|
||||
* Constructs a scoped object that automatically enters and leaves a disallow
|
||||
* garbage collection scope based on its lifetime.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
*/
|
||||
explicit DisallowGarbageCollectionScope(HeapHandle& heap_handle);
|
||||
~DisallowGarbageCollectionScope();
|
||||
|
||||
DisallowGarbageCollectionScope(const DisallowGarbageCollectionScope&) =
|
||||
delete;
|
||||
DisallowGarbageCollectionScope& operator=(
|
||||
const DisallowGarbageCollectionScope&) = delete;
|
||||
|
||||
private:
|
||||
HeapHandle& heap_handle_;
|
||||
};
|
||||
|
||||
/**
|
||||
* Avoids invoking garbage collection finalizations. Already running garbage
|
||||
* collection phase are unaffected by this scope.
|
||||
*
|
||||
* Should only be used temporarily as the scope has an impact on memory usage
|
||||
* and follow up garbage collections.
|
||||
*/
|
||||
class V8_EXPORT V8_NODISCARD NoGarbageCollectionScope final {
|
||||
CPPGC_STACK_ALLOCATED();
|
||||
|
||||
public:
|
||||
/**
|
||||
* Enters a no garbage collection scope. Must be paired with `Leave()`. Prefer
|
||||
* a scope instance of `NoGarbageCollectionScope`.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
*/
|
||||
static void Enter(HeapHandle& heap_handle);
|
||||
|
||||
/**
|
||||
* Leaves a no garbage collection scope. Must be paired with `Enter()`. Prefer
|
||||
* a scope instance of `NoGarbageCollectionScope`.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
*/
|
||||
static void Leave(HeapHandle& heap_handle);
|
||||
|
||||
/**
|
||||
* Constructs a scoped object that automatically enters and leaves a no
|
||||
* garbage collection scope based on its lifetime.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
*/
|
||||
explicit NoGarbageCollectionScope(HeapHandle& heap_handle);
|
||||
~NoGarbageCollectionScope();
|
||||
|
||||
NoGarbageCollectionScope(const NoGarbageCollectionScope&) = delete;
|
||||
NoGarbageCollectionScope& operator=(const NoGarbageCollectionScope&) = delete;
|
||||
|
||||
private:
|
||||
HeapHandle& heap_handle_;
|
||||
};
|
||||
|
||||
} // namespace subtle
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_HEAP_CONSISTENCY_H_
|
||||
48
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap-handle.h
generated
vendored
Normal file
48
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap-handle.h
generated
vendored
Normal file
@@ -0,0 +1,48 @@
|
||||
// Copyright 2022 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_HEAP_HANDLE_H_
|
||||
#define INCLUDE_CPPGC_HEAP_HANDLE_H_
|
||||
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
namespace internal {
|
||||
class HeapBase;
|
||||
class WriteBarrierTypeForCagedHeapPolicy;
|
||||
class WriteBarrierTypeForNonCagedHeapPolicy;
|
||||
} // namespace internal
|
||||
|
||||
/**
|
||||
* Opaque handle used for additional heap APIs.
|
||||
*/
|
||||
class HeapHandle {
|
||||
public:
|
||||
// Deleted copy ctor to avoid treating the type by value.
|
||||
HeapHandle(const HeapHandle&) = delete;
|
||||
HeapHandle& operator=(const HeapHandle&) = delete;
|
||||
|
||||
private:
|
||||
HeapHandle() = default;
|
||||
|
||||
V8_INLINE bool is_incremental_marking_in_progress() const {
|
||||
return is_incremental_marking_in_progress_;
|
||||
}
|
||||
|
||||
V8_INLINE bool is_young_generation_enabled() const {
|
||||
return is_young_generation_enabled_;
|
||||
}
|
||||
|
||||
bool is_incremental_marking_in_progress_ = false;
|
||||
bool is_young_generation_enabled_ = false;
|
||||
|
||||
friend class internal::HeapBase;
|
||||
friend class internal::WriteBarrierTypeForCagedHeapPolicy;
|
||||
friend class internal::WriteBarrierTypeForNonCagedHeapPolicy;
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_HEAP_HANDLE_H_
|
||||
82
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap-state.h
generated
vendored
Normal file
82
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap-state.h
generated
vendored
Normal file
@@ -0,0 +1,82 @@
|
||||
// Copyright 2021 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_HEAP_STATE_H_
|
||||
#define INCLUDE_CPPGC_HEAP_STATE_H_
|
||||
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
class HeapHandle;
|
||||
|
||||
namespace subtle {
|
||||
|
||||
/**
|
||||
* Helpers to peek into heap-internal state.
|
||||
*/
|
||||
class V8_EXPORT HeapState final {
|
||||
public:
|
||||
/**
|
||||
* Returns whether the garbage collector is marking. This API is experimental
|
||||
* and is expected to be removed in future.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
* \returns true if the garbage collector is currently marking, and false
|
||||
* otherwise.
|
||||
*/
|
||||
static bool IsMarking(const HeapHandle& heap_handle);
|
||||
|
||||
/*
|
||||
* Returns whether the garbage collector is sweeping. This API is experimental
|
||||
* and is expected to be removed in future.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
* \returns true if the garbage collector is currently sweeping, and false
|
||||
* otherwise.
|
||||
*/
|
||||
static bool IsSweeping(const HeapHandle& heap_handle);
|
||||
|
||||
/*
|
||||
* Returns whether the garbage collector is currently sweeping on the thread
|
||||
* owning this heap. This API allows the caller to determine whether it has
|
||||
* been called from a destructor of a managed object. This API is experimental
|
||||
* and may be removed in future.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
* \returns true if the garbage collector is currently sweeping on this
|
||||
* thread, and false otherwise.
|
||||
*/
|
||||
static bool IsSweepingOnOwningThread(const HeapHandle& heap_handle);
|
||||
|
||||
/**
|
||||
* Returns whether the garbage collector is in the atomic pause, i.e., the
|
||||
* mutator is stopped from running. This API is experimental and is expected
|
||||
* to be removed in future.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
* \returns true if the garbage collector is currently in the atomic pause,
|
||||
* and false otherwise.
|
||||
*/
|
||||
static bool IsInAtomicPause(const HeapHandle& heap_handle);
|
||||
|
||||
/**
|
||||
* Returns whether the last garbage collection was finalized conservatively
|
||||
* (i.e., with a non-empty stack). This API is experimental and is expected to
|
||||
* be removed in future.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
* \returns true if the last garbage collection was finalized conservatively,
|
||||
* and false otherwise.
|
||||
*/
|
||||
static bool PreviousGCWasConservative(const HeapHandle& heap_handle);
|
||||
|
||||
private:
|
||||
HeapState() = delete;
|
||||
};
|
||||
|
||||
} // namespace subtle
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_HEAP_STATE_H_
|
||||
120
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap-statistics.h
generated
vendored
Normal file
120
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap-statistics.h
generated
vendored
Normal file
@@ -0,0 +1,120 @@
|
||||
// Copyright 2021 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_HEAP_STATISTICS_H_
|
||||
#define INCLUDE_CPPGC_HEAP_STATISTICS_H_
|
||||
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
/**
|
||||
* `HeapStatistics` contains memory consumption and utilization statistics for a
|
||||
* cppgc heap.
|
||||
*/
|
||||
struct HeapStatistics final {
|
||||
/**
|
||||
* Specifies the detail level of the heap statistics. Brief statistics contain
|
||||
* only the top-level allocated and used memory statistics for the entire
|
||||
* heap. Detailed statistics also contain a break down per space and page, as
|
||||
* well as freelist statistics and object type histograms. Note that used
|
||||
* memory reported by brief statistics and detailed statistics might differ
|
||||
* slightly.
|
||||
*/
|
||||
enum DetailLevel : uint8_t {
|
||||
kBrief,
|
||||
kDetailed,
|
||||
};
|
||||
|
||||
/**
|
||||
* Object statistics for a single type.
|
||||
*/
|
||||
struct ObjectStatsEntry {
|
||||
/**
|
||||
* Number of allocated bytes.
|
||||
*/
|
||||
size_t allocated_bytes;
|
||||
/**
|
||||
* Number of allocated objects.
|
||||
*/
|
||||
size_t object_count;
|
||||
};
|
||||
|
||||
/**
|
||||
* Page granularity statistics. For each page the statistics record the
|
||||
* allocated memory size and overall used memory size for the page.
|
||||
*/
|
||||
struct PageStatistics {
|
||||
/** Overall committed amount of memory for the page. */
|
||||
size_t committed_size_bytes = 0;
|
||||
/** Resident amount of memory held by the page. */
|
||||
size_t resident_size_bytes = 0;
|
||||
/** Amount of memory actually used on the page. */
|
||||
size_t used_size_bytes = 0;
|
||||
/** Statistics for object allocated on the page. Filled only when
|
||||
* NameProvider::SupportsCppClassNamesAsObjectNames() is true. */
|
||||
std::vector<ObjectStatsEntry> object_statistics;
|
||||
};
|
||||
|
||||
/**
|
||||
* Statistics of the freelist (used only in non-large object spaces). For
|
||||
* each bucket in the freelist the statistics record the bucket size, the
|
||||
* number of freelist entries in the bucket, and the overall allocated memory
|
||||
* consumed by these freelist entries.
|
||||
*/
|
||||
struct FreeListStatistics {
|
||||
/** bucket sizes in the freelist. */
|
||||
std::vector<size_t> bucket_size;
|
||||
/** number of freelist entries per bucket. */
|
||||
std::vector<size_t> free_count;
|
||||
/** memory size consumed by freelist entries per size. */
|
||||
std::vector<size_t> free_size;
|
||||
};
|
||||
|
||||
/**
|
||||
* Space granularity statistics. For each space the statistics record the
|
||||
* space name, the amount of allocated memory and overall used memory for the
|
||||
* space. The statistics also contain statistics for each of the space's
|
||||
* pages, its freelist and the objects allocated on the space.
|
||||
*/
|
||||
struct SpaceStatistics {
|
||||
/** The space name */
|
||||
std::string name;
|
||||
/** Overall committed amount of memory for the heap. */
|
||||
size_t committed_size_bytes = 0;
|
||||
/** Resident amount of memory held by the heap. */
|
||||
size_t resident_size_bytes = 0;
|
||||
/** Amount of memory actually used on the space. */
|
||||
size_t used_size_bytes = 0;
|
||||
/** Statistics for each of the pages in the space. */
|
||||
std::vector<PageStatistics> page_stats;
|
||||
/** Statistics for the freelist of the space. */
|
||||
FreeListStatistics free_list_stats;
|
||||
};
|
||||
|
||||
/** Overall committed amount of memory for the heap. */
|
||||
size_t committed_size_bytes = 0;
|
||||
/** Resident amount of memory held by the heap. */
|
||||
size_t resident_size_bytes = 0;
|
||||
/** Amount of memory actually used on the heap. */
|
||||
size_t used_size_bytes = 0;
|
||||
/** Detail level of this HeapStatistics. */
|
||||
DetailLevel detail_level;
|
||||
|
||||
/** Statistics for each of the spaces in the heap. Filled only when
|
||||
* `detail_level` is `DetailLevel::kDetailed`. */
|
||||
std::vector<SpaceStatistics> space_stats;
|
||||
|
||||
/**
|
||||
* Vector of `cppgc::GarbageCollected` type names.
|
||||
*/
|
||||
std::vector<std::string> type_names;
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_HEAP_STATISTICS_H_
|
||||
202
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap.h
generated
vendored
Normal file
202
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/heap.h
generated
vendored
Normal file
@@ -0,0 +1,202 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_HEAP_H_
|
||||
#define INCLUDE_CPPGC_HEAP_H_
|
||||
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
|
||||
#include "cppgc/common.h"
|
||||
#include "cppgc/custom-space.h"
|
||||
#include "cppgc/platform.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
/**
|
||||
* cppgc - A C++ garbage collection library.
|
||||
*/
|
||||
namespace cppgc {
|
||||
|
||||
class AllocationHandle;
|
||||
class HeapHandle;
|
||||
|
||||
/**
|
||||
* Implementation details of cppgc. Those details are considered internal and
|
||||
* may change at any point in time without notice. Users should never rely on
|
||||
* the contents of this namespace.
|
||||
*/
|
||||
namespace internal {
|
||||
class Heap;
|
||||
} // namespace internal
|
||||
|
||||
class V8_EXPORT Heap {
|
||||
public:
|
||||
/**
|
||||
* Specifies the stack state the embedder is in.
|
||||
*/
|
||||
using StackState = EmbedderStackState;
|
||||
|
||||
/**
|
||||
* Specifies whether conservative stack scanning is supported.
|
||||
*/
|
||||
enum class StackSupport : uint8_t {
|
||||
/**
|
||||
* Conservative stack scan is supported.
|
||||
*/
|
||||
kSupportsConservativeStackScan,
|
||||
/**
|
||||
* Conservative stack scan is not supported. Embedders may use this option
|
||||
* when using custom infrastructure that is unsupported by the library.
|
||||
*/
|
||||
kNoConservativeStackScan,
|
||||
};
|
||||
|
||||
/**
|
||||
* Specifies supported marking types.
|
||||
*/
|
||||
enum class MarkingType : uint8_t {
|
||||
/**
|
||||
* Atomic stop-the-world marking. This option does not require any write
|
||||
* barriers but is the most intrusive in terms of jank.
|
||||
*/
|
||||
kAtomic,
|
||||
/**
|
||||
* Incremental marking interleaves marking with the rest of the application
|
||||
* workload on the same thread.
|
||||
*/
|
||||
kIncremental,
|
||||
/**
|
||||
* Incremental and concurrent marking.
|
||||
*/
|
||||
kIncrementalAndConcurrent
|
||||
};
|
||||
|
||||
/**
|
||||
* Specifies supported sweeping types.
|
||||
*/
|
||||
enum class SweepingType : uint8_t {
|
||||
/**
|
||||
* Atomic stop-the-world sweeping. All of sweeping is performed at once.
|
||||
*/
|
||||
kAtomic,
|
||||
/**
|
||||
* Incremental sweeping interleaves sweeping with the rest of the
|
||||
* application workload on the same thread.
|
||||
*/
|
||||
kIncremental,
|
||||
/**
|
||||
* Incremental and concurrent sweeping. Sweeping is split and interleaved
|
||||
* with the rest of the application.
|
||||
*/
|
||||
kIncrementalAndConcurrent
|
||||
};
|
||||
|
||||
/**
|
||||
* Constraints for a Heap setup.
|
||||
*/
|
||||
struct ResourceConstraints {
|
||||
/**
|
||||
* Allows the heap to grow to some initial size in bytes before triggering
|
||||
* garbage collections. This is useful when it is known that applications
|
||||
* need a certain minimum heap to run to avoid repeatedly invoking the
|
||||
* garbage collector when growing the heap.
|
||||
*/
|
||||
size_t initial_heap_size_bytes = 0;
|
||||
};
|
||||
|
||||
/**
|
||||
* Options specifying Heap properties (e.g. custom spaces) when initializing a
|
||||
* heap through `Heap::Create()`.
|
||||
*/
|
||||
struct HeapOptions {
|
||||
/**
|
||||
* Creates reasonable defaults for instantiating a Heap.
|
||||
*
|
||||
* \returns the HeapOptions that can be passed to `Heap::Create()`.
|
||||
*/
|
||||
static HeapOptions Default() { return {}; }
|
||||
|
||||
/**
|
||||
* Custom spaces added to heap are required to have indices forming a
|
||||
* numbered sequence starting at 0, i.e., their `kSpaceIndex` must
|
||||
* correspond to the index they reside in the vector.
|
||||
*/
|
||||
std::vector<std::unique_ptr<CustomSpaceBase>> custom_spaces;
|
||||
|
||||
/**
|
||||
* Specifies whether conservative stack scan is supported. When conservative
|
||||
* stack scan is not supported, the collector may try to invoke
|
||||
* garbage collections using non-nestable task, which are guaranteed to have
|
||||
* no interesting stack, through the provided Platform. If such tasks are
|
||||
* not supported by the Platform, the embedder must take care of invoking
|
||||
* the GC through `ForceGarbageCollectionSlow()`.
|
||||
*/
|
||||
StackSupport stack_support = StackSupport::kSupportsConservativeStackScan;
|
||||
|
||||
/**
|
||||
* Specifies which types of marking are supported by the heap.
|
||||
*/
|
||||
MarkingType marking_support = MarkingType::kIncrementalAndConcurrent;
|
||||
|
||||
/**
|
||||
* Specifies which types of sweeping are supported by the heap.
|
||||
*/
|
||||
SweepingType sweeping_support = SweepingType::kIncrementalAndConcurrent;
|
||||
|
||||
/**
|
||||
* Resource constraints specifying various properties that the internal
|
||||
* GC scheduler follows.
|
||||
*/
|
||||
ResourceConstraints resource_constraints;
|
||||
};
|
||||
|
||||
/**
|
||||
* Creates a new heap that can be used for object allocation.
|
||||
*
|
||||
* \param platform implemented and provided by the embedder.
|
||||
* \param options HeapOptions specifying various properties for the Heap.
|
||||
* \returns a new Heap instance.
|
||||
*/
|
||||
static std::unique_ptr<Heap> Create(
|
||||
std::shared_ptr<Platform> platform,
|
||||
HeapOptions options = HeapOptions::Default());
|
||||
|
||||
virtual ~Heap() = default;
|
||||
|
||||
/**
|
||||
* Forces garbage collection.
|
||||
*
|
||||
* \param source String specifying the source (or caller) triggering a
|
||||
* forced garbage collection.
|
||||
* \param reason String specifying the reason for the forced garbage
|
||||
* collection.
|
||||
* \param stack_state The embedder stack state, see StackState.
|
||||
*/
|
||||
void ForceGarbageCollectionSlow(
|
||||
const char* source, const char* reason,
|
||||
StackState stack_state = StackState::kMayContainHeapPointers);
|
||||
|
||||
/**
|
||||
* \returns the opaque handle for allocating objects using
|
||||
* `MakeGarbageCollected()`.
|
||||
*/
|
||||
AllocationHandle& GetAllocationHandle();
|
||||
|
||||
/**
|
||||
* \returns the opaque heap handle which may be used to refer to this heap in
|
||||
* other APIs. Valid as long as the underlying `Heap` is alive.
|
||||
*/
|
||||
HeapHandle& GetHeapHandle();
|
||||
|
||||
private:
|
||||
Heap() = default;
|
||||
|
||||
friend class internal::Heap;
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_HEAP_H_
|
||||
87
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/api-constants.h
generated
vendored
Normal file
87
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/api-constants.h
generated
vendored
Normal file
@@ -0,0 +1,87 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_API_CONSTANTS_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_API_CONSTANTS_H_
|
||||
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
// Embedders should not rely on this code!
|
||||
|
||||
// Internal constants to avoid exposing internal types on the API surface.
|
||||
namespace api_constants {
|
||||
|
||||
constexpr size_t kKB = 1024;
|
||||
constexpr size_t kMB = kKB * 1024;
|
||||
constexpr size_t kGB = kMB * 1024;
|
||||
|
||||
// Offset of the uint16_t bitfield from the payload contaning the
|
||||
// in-construction bit. This is subtracted from the payload pointer to get
|
||||
// to the right bitfield.
|
||||
static constexpr size_t kFullyConstructedBitFieldOffsetFromPayload =
|
||||
2 * sizeof(uint16_t);
|
||||
// Mask for in-construction bit.
|
||||
static constexpr uint16_t kFullyConstructedBitMask = uint16_t{1};
|
||||
|
||||
static constexpr size_t kPageSize = size_t{1} << 17;
|
||||
|
||||
#if defined(V8_HOST_ARCH_ARM64) && defined(V8_OS_DARWIN)
|
||||
constexpr size_t kGuardPageSize = 0;
|
||||
#else
|
||||
constexpr size_t kGuardPageSize = 4096;
|
||||
#endif
|
||||
|
||||
static constexpr size_t kLargeObjectSizeThreshold = kPageSize / 2;
|
||||
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
#if defined(CPPGC_ENABLE_LARGER_CAGE)
|
||||
constexpr unsigned kPointerCompressionShift = 3;
|
||||
#else // !defined(CPPGC_ENABLE_LARGER_CAGE)
|
||||
constexpr unsigned kPointerCompressionShift = 1;
|
||||
#endif // !defined(CPPGC_ENABLE_LARGER_CAGE)
|
||||
#endif // !defined(CPPGC_POINTER_COMPRESSION)
|
||||
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
#if defined(CPPGC_2GB_CAGE)
|
||||
constexpr size_t kCagedHeapDefaultReservationSize =
|
||||
static_cast<size_t>(2) * kGB;
|
||||
constexpr size_t kCagedHeapMaxReservationSize =
|
||||
kCagedHeapDefaultReservationSize;
|
||||
#else // !defined(CPPGC_2GB_CAGE)
|
||||
constexpr size_t kCagedHeapDefaultReservationSize =
|
||||
static_cast<size_t>(4) * kGB;
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
constexpr size_t kCagedHeapMaxReservationSize =
|
||||
size_t{1} << (31 + kPointerCompressionShift);
|
||||
#else // !defined(CPPGC_POINTER_COMPRESSION)
|
||||
constexpr size_t kCagedHeapMaxReservationSize =
|
||||
kCagedHeapDefaultReservationSize;
|
||||
#endif // !defined(CPPGC_POINTER_COMPRESSION)
|
||||
#endif // !defined(CPPGC_2GB_CAGE)
|
||||
constexpr size_t kCagedHeapReservationAlignment = kCagedHeapMaxReservationSize;
|
||||
#endif // defined(CPPGC_CAGED_HEAP)
|
||||
|
||||
static constexpr size_t kDefaultAlignment = sizeof(void*);
|
||||
|
||||
// Maximum support alignment for a type as in `alignof(T)`.
|
||||
static constexpr size_t kMaxSupportedAlignment = 2 * kDefaultAlignment;
|
||||
|
||||
// Granularity of heap allocations.
|
||||
constexpr size_t kAllocationGranularity = sizeof(void*);
|
||||
|
||||
// Default cacheline size.
|
||||
constexpr size_t kCachelineSize = 64;
|
||||
|
||||
} // namespace api_constants
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_API_CONSTANTS_H_
|
||||
48
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/atomic-entry-flag.h
generated
vendored
Normal file
48
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/atomic-entry-flag.h
generated
vendored
Normal file
@@ -0,0 +1,48 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_ATOMIC_ENTRY_FLAG_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_ATOMIC_ENTRY_FLAG_H_
|
||||
|
||||
#include <atomic>
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
// A flag which provides a fast check whether a scope may be entered on the
|
||||
// current thread, without needing to access thread-local storage or mutex. Can
|
||||
// have false positives (i.e., spuriously report that it might be entered), so
|
||||
// it is expected that this will be used in tandem with a precise check that the
|
||||
// scope is in fact entered on that thread.
|
||||
//
|
||||
// Example:
|
||||
// g_frobnicating_flag.MightBeEntered() &&
|
||||
// ThreadLocalFrobnicator().IsFrobnicating()
|
||||
//
|
||||
// Relaxed atomic operations are sufficient, since:
|
||||
// - all accesses remain atomic
|
||||
// - each thread must observe its own operations in order
|
||||
// - no thread ever exits the flag more times than it enters (if used correctly)
|
||||
// And so if a thread observes zero, it must be because it has observed an equal
|
||||
// number of exits as entries.
|
||||
class AtomicEntryFlag final {
|
||||
public:
|
||||
void Enter() { entries_.fetch_add(1, std::memory_order_relaxed); }
|
||||
void Exit() { entries_.fetch_sub(1, std::memory_order_relaxed); }
|
||||
|
||||
// Returns false only if the current thread is not between a call to Enter
|
||||
// and a call to Exit. Returns true if this thread or another thread may
|
||||
// currently be in the scope guarded by this flag.
|
||||
bool MightBeEntered() const {
|
||||
return entries_.load(std::memory_order_relaxed) != 0;
|
||||
}
|
||||
|
||||
private:
|
||||
std::atomic_int entries_{0};
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_ATOMIC_ENTRY_FLAG_H_
|
||||
45
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/base-page-handle.h
generated
vendored
Normal file
45
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/base-page-handle.h
generated
vendored
Normal file
@@ -0,0 +1,45 @@
|
||||
// Copyright 2022 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_BASE_PAGE_HANDLE_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_BASE_PAGE_HANDLE_H_
|
||||
|
||||
#include "cppgc/heap-handle.h"
|
||||
#include "cppgc/internal/api-constants.h"
|
||||
#include "cppgc/internal/logging.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
// The class is needed in the header to allow for fast access to HeapHandle in
|
||||
// the write barrier.
|
||||
class BasePageHandle {
|
||||
public:
|
||||
static V8_INLINE BasePageHandle* FromPayload(void* payload) {
|
||||
return reinterpret_cast<BasePageHandle*>(
|
||||
(reinterpret_cast<uintptr_t>(payload) &
|
||||
~(api_constants::kPageSize - 1)) +
|
||||
api_constants::kGuardPageSize);
|
||||
}
|
||||
static V8_INLINE const BasePageHandle* FromPayload(const void* payload) {
|
||||
return FromPayload(const_cast<void*>(payload));
|
||||
}
|
||||
|
||||
HeapHandle& heap_handle() { return heap_handle_; }
|
||||
const HeapHandle& heap_handle() const { return heap_handle_; }
|
||||
|
||||
protected:
|
||||
explicit BasePageHandle(HeapHandle& heap_handle) : heap_handle_(heap_handle) {
|
||||
CPPGC_DCHECK(reinterpret_cast<uintptr_t>(this) % api_constants::kPageSize ==
|
||||
api_constants::kGuardPageSize);
|
||||
}
|
||||
|
||||
HeapHandle& heap_handle_;
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_BASE_PAGE_HANDLE_H_
|
||||
121
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/caged-heap-local-data.h
generated
vendored
Normal file
121
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/caged-heap-local-data.h
generated
vendored
Normal file
@@ -0,0 +1,121 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_CAGED_HEAP_LOCAL_DATA_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_CAGED_HEAP_LOCAL_DATA_H_
|
||||
|
||||
#include <array>
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
|
||||
#include "cppgc/internal/api-constants.h"
|
||||
#include "cppgc/internal/caged-heap.h"
|
||||
#include "cppgc/internal/logging.h"
|
||||
#include "cppgc/platform.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
#if __cpp_lib_bitopts
|
||||
#include <bit>
|
||||
#endif // __cpp_lib_bitopts
|
||||
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
class HeapBase;
|
||||
class HeapBaseHandle;
|
||||
|
||||
#if defined(CPPGC_YOUNG_GENERATION)
|
||||
|
||||
// AgeTable is the bytemap needed for the fast generation check in the write
|
||||
// barrier. AgeTable contains entries that correspond to 4096 bytes memory
|
||||
// regions (cards). Each entry in the table represents generation of the objects
|
||||
// that reside on the corresponding card (young, old or mixed).
|
||||
class V8_EXPORT AgeTable final {
|
||||
static constexpr size_t kRequiredSize = 1 * api_constants::kMB;
|
||||
static constexpr size_t kAllocationGranularity =
|
||||
api_constants::kAllocationGranularity;
|
||||
|
||||
public:
|
||||
// Represents age of the objects living on a single card.
|
||||
enum class Age : uint8_t { kOld, kYoung, kMixed };
|
||||
// When setting age for a range, consider or ignore ages of the adjacent
|
||||
// cards.
|
||||
enum class AdjacentCardsPolicy : uint8_t { kConsider, kIgnore };
|
||||
|
||||
static constexpr size_t kCardSizeInBytes =
|
||||
api_constants::kCagedHeapDefaultReservationSize / kRequiredSize;
|
||||
|
||||
static constexpr size_t CalculateAgeTableSizeForHeapSize(size_t heap_size) {
|
||||
return heap_size / kCardSizeInBytes;
|
||||
}
|
||||
|
||||
void SetAge(uintptr_t cage_offset, Age age) {
|
||||
table_[card(cage_offset)] = age;
|
||||
}
|
||||
|
||||
V8_INLINE Age GetAge(uintptr_t cage_offset) const {
|
||||
return table_[card(cage_offset)];
|
||||
}
|
||||
|
||||
void SetAgeForRange(uintptr_t cage_offset_begin, uintptr_t cage_offset_end,
|
||||
Age age, AdjacentCardsPolicy adjacent_cards_policy);
|
||||
|
||||
Age GetAgeForRange(uintptr_t cage_offset_begin,
|
||||
uintptr_t cage_offset_end) const;
|
||||
|
||||
void ResetForTesting();
|
||||
|
||||
private:
|
||||
V8_INLINE size_t card(uintptr_t offset) const {
|
||||
constexpr size_t kGranularityBits =
|
||||
#if __cpp_lib_bitopts
|
||||
std::countr_zero(static_cast<uint32_t>(kCardSizeInBytes));
|
||||
#elif V8_HAS_BUILTIN_CTZ
|
||||
__builtin_ctz(static_cast<uint32_t>(kCardSizeInBytes));
|
||||
#else //! V8_HAS_BUILTIN_CTZ
|
||||
// Hardcode and check with assert.
|
||||
#if defined(CPPGC_2GB_CAGE)
|
||||
11;
|
||||
#else // !defined(CPPGC_2GB_CAGE)
|
||||
12;
|
||||
#endif // !defined(CPPGC_2GB_CAGE)
|
||||
#endif // !V8_HAS_BUILTIN_CTZ
|
||||
static_assert((1 << kGranularityBits) == kCardSizeInBytes);
|
||||
const size_t entry = offset >> kGranularityBits;
|
||||
CPPGC_DCHECK(CagedHeapBase::GetAgeTableSize() > entry);
|
||||
return entry;
|
||||
}
|
||||
|
||||
#if defined(V8_CC_GNU)
|
||||
// gcc disallows flexible arrays in otherwise empty classes.
|
||||
Age table_[0];
|
||||
#else // !defined(V8_CC_GNU)
|
||||
Age table_[];
|
||||
#endif // !defined(V8_CC_GNU)
|
||||
};
|
||||
|
||||
#endif // CPPGC_YOUNG_GENERATION
|
||||
|
||||
struct CagedHeapLocalData final {
|
||||
V8_INLINE static CagedHeapLocalData& Get() {
|
||||
return *reinterpret_cast<CagedHeapLocalData*>(CagedHeapBase::GetBase());
|
||||
}
|
||||
|
||||
static constexpr size_t CalculateLocalDataSizeForHeapSize(size_t heap_size) {
|
||||
return AgeTable::CalculateAgeTableSizeForHeapSize(heap_size);
|
||||
}
|
||||
|
||||
#if defined(CPPGC_YOUNG_GENERATION)
|
||||
AgeTable age_table;
|
||||
#endif
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // defined(CPPGC_CAGED_HEAP)
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_CAGED_HEAP_LOCAL_DATA_H_
|
||||
68
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/caged-heap.h
generated
vendored
Normal file
68
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/caged-heap.h
generated
vendored
Normal file
@@ -0,0 +1,68 @@
|
||||
// Copyright 2022 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_CAGED_HEAP_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_CAGED_HEAP_H_
|
||||
|
||||
#include <climits>
|
||||
#include <cstddef>
|
||||
|
||||
#include "cppgc/internal/api-constants.h"
|
||||
#include "cppgc/internal/base-page-handle.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
class V8_EXPORT CagedHeapBase {
|
||||
public:
|
||||
V8_INLINE static uintptr_t OffsetFromAddress(const void* address) {
|
||||
return reinterpret_cast<uintptr_t>(address) &
|
||||
(api_constants::kCagedHeapReservationAlignment - 1);
|
||||
}
|
||||
|
||||
V8_INLINE static bool IsWithinCage(const void* address) {
|
||||
CPPGC_DCHECK(g_heap_base_);
|
||||
return (reinterpret_cast<uintptr_t>(address) &
|
||||
~(api_constants::kCagedHeapReservationAlignment - 1)) ==
|
||||
g_heap_base_;
|
||||
}
|
||||
|
||||
V8_INLINE static bool AreWithinCage(const void* addr1, const void* addr2) {
|
||||
#if defined(CPPGC_2GB_CAGE)
|
||||
static constexpr size_t kHeapBaseShift = sizeof(uint32_t) * CHAR_BIT - 1;
|
||||
#else //! defined(CPPGC_2GB_CAGE)
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
static constexpr size_t kHeapBaseShift =
|
||||
31 + api_constants::kPointerCompressionShift;
|
||||
#else // !defined(CPPGC_POINTER_COMPRESSION)
|
||||
static constexpr size_t kHeapBaseShift = sizeof(uint32_t) * CHAR_BIT;
|
||||
#endif // !defined(CPPGC_POINTER_COMPRESSION)
|
||||
#endif //! defined(CPPGC_2GB_CAGE)
|
||||
static_assert((static_cast<size_t>(1) << kHeapBaseShift) ==
|
||||
api_constants::kCagedHeapMaxReservationSize);
|
||||
CPPGC_DCHECK(g_heap_base_);
|
||||
return !(((reinterpret_cast<uintptr_t>(addr1) ^ g_heap_base_) |
|
||||
(reinterpret_cast<uintptr_t>(addr2) ^ g_heap_base_)) >>
|
||||
kHeapBaseShift);
|
||||
}
|
||||
|
||||
V8_INLINE static uintptr_t GetBase() { return g_heap_base_; }
|
||||
V8_INLINE static size_t GetAgeTableSize() { return g_age_table_size_; }
|
||||
|
||||
private:
|
||||
friend class CagedHeap;
|
||||
|
||||
static uintptr_t g_heap_base_;
|
||||
static size_t g_age_table_size_;
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // defined(CPPGC_CAGED_HEAP)
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_CAGED_HEAP_H_
|
||||
38
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/compiler-specific.h
generated
vendored
Normal file
38
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/compiler-specific.h
generated
vendored
Normal file
@@ -0,0 +1,38 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_COMPILER_SPECIFIC_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_COMPILER_SPECIFIC_H_
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
#if defined(__has_attribute)
|
||||
#define CPPGC_HAS_ATTRIBUTE(FEATURE) __has_attribute(FEATURE)
|
||||
#else
|
||||
#define CPPGC_HAS_ATTRIBUTE(FEATURE) 0
|
||||
#endif
|
||||
|
||||
#if defined(__has_cpp_attribute)
|
||||
#define CPPGC_HAS_CPP_ATTRIBUTE(FEATURE) __has_cpp_attribute(FEATURE)
|
||||
#else
|
||||
#define CPPGC_HAS_CPP_ATTRIBUTE(FEATURE) 0
|
||||
#endif
|
||||
|
||||
// [[no_unique_address]] comes in C++20 but supported in clang with -std >=
|
||||
// c++11.
|
||||
#if CPPGC_HAS_CPP_ATTRIBUTE(no_unique_address)
|
||||
#define CPPGC_NO_UNIQUE_ADDRESS [[no_unique_address]]
|
||||
#else
|
||||
#define CPPGC_NO_UNIQUE_ADDRESS
|
||||
#endif
|
||||
|
||||
#if CPPGC_HAS_ATTRIBUTE(unused)
|
||||
#define CPPGC_UNUSED __attribute__((unused))
|
||||
#else
|
||||
#define CPPGC_UNUSED
|
||||
#endif
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_COMPILER_SPECIFIC_H_
|
||||
93
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/finalizer-trait.h
generated
vendored
Normal file
93
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/finalizer-trait.h
generated
vendored
Normal file
@@ -0,0 +1,93 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_FINALIZER_TRAIT_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_FINALIZER_TRAIT_H_
|
||||
|
||||
#include <type_traits>
|
||||
|
||||
#include "cppgc/type-traits.h"
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
using FinalizationCallback = void (*)(void*);
|
||||
|
||||
template <typename T, typename = void>
|
||||
struct HasFinalizeGarbageCollectedObject : std::false_type {};
|
||||
|
||||
template <typename T>
|
||||
struct HasFinalizeGarbageCollectedObject<
|
||||
T,
|
||||
std::void_t<decltype(std::declval<T>().FinalizeGarbageCollectedObject())>>
|
||||
: std::true_type {};
|
||||
|
||||
// The FinalizerTraitImpl specifies how to finalize objects.
|
||||
template <typename T, bool isFinalized>
|
||||
struct FinalizerTraitImpl;
|
||||
|
||||
template <typename T>
|
||||
struct FinalizerTraitImpl<T, true> {
|
||||
private:
|
||||
// Dispatch to custom FinalizeGarbageCollectedObject().
|
||||
struct Custom {
|
||||
static void Call(void* obj) {
|
||||
static_cast<T*>(obj)->FinalizeGarbageCollectedObject();
|
||||
}
|
||||
};
|
||||
|
||||
// Dispatch to regular destructor.
|
||||
struct Destructor {
|
||||
static void Call(void* obj) { static_cast<T*>(obj)->~T(); }
|
||||
};
|
||||
|
||||
using FinalizeImpl =
|
||||
std::conditional_t<HasFinalizeGarbageCollectedObject<T>::value, Custom,
|
||||
Destructor>;
|
||||
|
||||
public:
|
||||
static void Finalize(void* obj) {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
FinalizeImpl::Call(obj);
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct FinalizerTraitImpl<T, false> {
|
||||
static void Finalize(void* obj) {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
}
|
||||
};
|
||||
|
||||
// The FinalizerTrait is used to determine if a type requires finalization and
|
||||
// what finalization means.
|
||||
template <typename T>
|
||||
struct FinalizerTrait {
|
||||
private:
|
||||
// Object has a finalizer if it has
|
||||
// - a custom FinalizeGarbageCollectedObject method, or
|
||||
// - a destructor.
|
||||
static constexpr bool kNonTrivialFinalizer =
|
||||
internal::HasFinalizeGarbageCollectedObject<T>::value ||
|
||||
!std::is_trivially_destructible<typename std::remove_cv<T>::type>::value;
|
||||
|
||||
static void Finalize(void* obj) {
|
||||
internal::FinalizerTraitImpl<T, kNonTrivialFinalizer>::Finalize(obj);
|
||||
}
|
||||
|
||||
public:
|
||||
static constexpr bool HasFinalizer() { return kNonTrivialFinalizer; }
|
||||
|
||||
// The callback used to finalize an object of type T.
|
||||
static constexpr FinalizationCallback kCallback =
|
||||
kNonTrivialFinalizer ? Finalize : nullptr;
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
constexpr FinalizationCallback FinalizerTrait<T>::kCallback;
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_FINALIZER_TRAIT_H_
|
||||
148
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/gc-info.h
generated
vendored
Normal file
148
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/gc-info.h
generated
vendored
Normal file
@@ -0,0 +1,148 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_GC_INFO_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_GC_INFO_H_
|
||||
|
||||
#include <atomic>
|
||||
#include <cstdint>
|
||||
#include <type_traits>
|
||||
|
||||
#include "cppgc/internal/finalizer-trait.h"
|
||||
#include "cppgc/internal/logging.h"
|
||||
#include "cppgc/internal/name-trait.h"
|
||||
#include "cppgc/trace-trait.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
using GCInfoIndex = uint16_t;
|
||||
|
||||
struct V8_EXPORT EnsureGCInfoIndexTrait final {
|
||||
// Acquires a new GC info object and updates `registered_index` with the index
|
||||
// that identifies that new info accordingly.
|
||||
template <typename T>
|
||||
V8_INLINE static GCInfoIndex EnsureIndex(
|
||||
std::atomic<GCInfoIndex>& registered_index) {
|
||||
return EnsureGCInfoIndexTraitDispatch<T>{}(registered_index);
|
||||
}
|
||||
|
||||
private:
|
||||
template <typename T, bool = FinalizerTrait<T>::HasFinalizer(),
|
||||
bool = NameTrait<T>::HasNonHiddenName()>
|
||||
struct EnsureGCInfoIndexTraitDispatch;
|
||||
|
||||
static GCInfoIndex V8_PRESERVE_MOST
|
||||
EnsureGCInfoIndex(std::atomic<GCInfoIndex>&, TraceCallback,
|
||||
FinalizationCallback, NameCallback);
|
||||
static GCInfoIndex V8_PRESERVE_MOST EnsureGCInfoIndex(
|
||||
std::atomic<GCInfoIndex>&, TraceCallback, FinalizationCallback);
|
||||
static GCInfoIndex V8_PRESERVE_MOST
|
||||
EnsureGCInfoIndex(std::atomic<GCInfoIndex>&, TraceCallback, NameCallback);
|
||||
static GCInfoIndex V8_PRESERVE_MOST
|
||||
EnsureGCInfoIndex(std::atomic<GCInfoIndex>&, TraceCallback);
|
||||
};
|
||||
|
||||
#define DISPATCH(has_finalizer, has_non_hidden_name, function) \
|
||||
template <typename T> \
|
||||
struct EnsureGCInfoIndexTrait::EnsureGCInfoIndexTraitDispatch< \
|
||||
T, has_finalizer, has_non_hidden_name> { \
|
||||
V8_INLINE GCInfoIndex \
|
||||
operator()(std::atomic<GCInfoIndex>& registered_index) { \
|
||||
return function; \
|
||||
} \
|
||||
};
|
||||
|
||||
// ------------------------------------------------------- //
|
||||
// DISPATCH(has_finalizer, has_non_hidden_name, function) //
|
||||
// ------------------------------------------------------- //
|
||||
DISPATCH(true, true, //
|
||||
EnsureGCInfoIndex(registered_index, //
|
||||
TraceTrait<T>::Trace, //
|
||||
FinalizerTrait<T>::kCallback, //
|
||||
NameTrait<T>::GetName)) //
|
||||
DISPATCH(true, false, //
|
||||
EnsureGCInfoIndex(registered_index, //
|
||||
TraceTrait<T>::Trace, //
|
||||
FinalizerTrait<T>::kCallback)) //
|
||||
DISPATCH(false, true, //
|
||||
EnsureGCInfoIndex(registered_index, //
|
||||
TraceTrait<T>::Trace, //
|
||||
NameTrait<T>::GetName)) //
|
||||
DISPATCH(false, false, //
|
||||
EnsureGCInfoIndex(registered_index, //
|
||||
TraceTrait<T>::Trace)) //
|
||||
|
||||
#undef DISPATCH
|
||||
|
||||
// Trait determines how the garbage collector treats objects wrt. to traversing,
|
||||
// finalization, and naming.
|
||||
template <typename T>
|
||||
struct GCInfoTrait final {
|
||||
V8_INLINE static GCInfoIndex Index() {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
static std::atomic<GCInfoIndex>
|
||||
registered_index; // Uses zero initialization.
|
||||
GCInfoIndex index = registered_index.load(std::memory_order_acquire);
|
||||
if (V8_UNLIKELY(!index)) {
|
||||
index = EnsureGCInfoIndexTrait::EnsureIndex<T>(registered_index);
|
||||
CPPGC_DCHECK(index != 0);
|
||||
CPPGC_DCHECK(index == registered_index.load(std::memory_order_acquire));
|
||||
}
|
||||
return index;
|
||||
}
|
||||
|
||||
static constexpr bool CheckCallbacksAreDefined() {
|
||||
// No USE() macro available.
|
||||
(void)static_cast<TraceCallback>(TraceTrait<T>::Trace);
|
||||
(void)static_cast<FinalizationCallback>(FinalizerTrait<T>::kCallback);
|
||||
(void)static_cast<NameCallback>(NameTrait<T>::GetName);
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
// Fold types based on finalizer behavior. Note that finalizer characteristics
|
||||
// align with trace behavior, i.e., destructors are virtual when trace methods
|
||||
// are and vice versa.
|
||||
template <typename T, typename ParentMostGarbageCollectedType>
|
||||
struct GCInfoFolding final {
|
||||
static constexpr bool kHasVirtualDestructorAtBase =
|
||||
std::has_virtual_destructor<ParentMostGarbageCollectedType>::value;
|
||||
static constexpr bool kBothTypesAreTriviallyDestructible =
|
||||
std::is_trivially_destructible<ParentMostGarbageCollectedType>::value &&
|
||||
std::is_trivially_destructible<T>::value;
|
||||
static constexpr bool kHasCustomFinalizerDispatchAtBase =
|
||||
internal::HasFinalizeGarbageCollectedObject<
|
||||
ParentMostGarbageCollectedType>::value;
|
||||
#ifdef CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
static constexpr bool kWantsDetailedObjectNames = true;
|
||||
#else // !CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
static constexpr bool kWantsDetailedObjectNames = false;
|
||||
#endif // !CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
|
||||
// Always true. Forces the compiler to resolve callbacks which ensures that
|
||||
// both modes don't break without requiring compiling a separate
|
||||
// configuration. Only a single GCInfo (for `ResultType` below) will actually
|
||||
// be instantiated but existence (and well-formedness) of all callbacks is
|
||||
// checked.
|
||||
static constexpr bool kCheckTypeGuardAlwaysTrue =
|
||||
GCInfoTrait<T>::CheckCallbacksAreDefined() &&
|
||||
GCInfoTrait<ParentMostGarbageCollectedType>::CheckCallbacksAreDefined();
|
||||
|
||||
// Folding would regress name resolution when deriving names from C++
|
||||
// class names as it would just folds a name to the base class name.
|
||||
using ResultType =
|
||||
std::conditional_t<kCheckTypeGuardAlwaysTrue &&
|
||||
(kHasVirtualDestructorAtBase ||
|
||||
kBothTypesAreTriviallyDestructible ||
|
||||
kHasCustomFinalizerDispatchAtBase) &&
|
||||
!kWantsDetailedObjectNames,
|
||||
ParentMostGarbageCollectedType, T>;
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_GC_INFO_H_
|
||||
50
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/logging.h
generated
vendored
Normal file
50
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/logging.h
generated
vendored
Normal file
@@ -0,0 +1,50 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_LOGGING_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_LOGGING_H_
|
||||
|
||||
#include "cppgc/source-location.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
void V8_EXPORT DCheckImpl(const char*,
|
||||
const SourceLocation& = SourceLocation::Current());
|
||||
[[noreturn]] void V8_EXPORT
|
||||
FatalImpl(const char*, const SourceLocation& = SourceLocation::Current());
|
||||
|
||||
// Used to ignore -Wunused-variable.
|
||||
template <typename>
|
||||
struct EatParams {};
|
||||
|
||||
#if defined(DEBUG)
|
||||
#define CPPGC_DCHECK_MSG(condition, message) \
|
||||
do { \
|
||||
if (V8_UNLIKELY(!(condition))) { \
|
||||
::cppgc::internal::DCheckImpl(message); \
|
||||
} \
|
||||
} while (false)
|
||||
#else // !defined(DEBUG)
|
||||
#define CPPGC_DCHECK_MSG(condition, message) \
|
||||
(static_cast<void>(::cppgc::internal::EatParams<decltype( \
|
||||
static_cast<void>(condition), message)>{}))
|
||||
#endif // !defined(DEBUG)
|
||||
|
||||
#define CPPGC_DCHECK(condition) CPPGC_DCHECK_MSG(condition, #condition)
|
||||
|
||||
#define CPPGC_CHECK_MSG(condition, message) \
|
||||
do { \
|
||||
if (V8_UNLIKELY(!(condition))) { \
|
||||
::cppgc::internal::FatalImpl(message); \
|
||||
} \
|
||||
} while (false)
|
||||
|
||||
#define CPPGC_CHECK(condition) CPPGC_CHECK_MSG(condition, #condition)
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_LOGGING_H_
|
||||
256
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/member-storage.h
generated
vendored
Normal file
256
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/member-storage.h
generated
vendored
Normal file
@@ -0,0 +1,256 @@
|
||||
// Copyright 2022 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_MEMBER_STORAGE_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_MEMBER_STORAGE_H_
|
||||
|
||||
#include <atomic>
|
||||
#include <cstddef>
|
||||
#include <type_traits>
|
||||
|
||||
#include "cppgc/internal/api-constants.h"
|
||||
#include "cppgc/internal/logging.h"
|
||||
#include "cppgc/sentinel-pointer.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
enum class WriteBarrierSlotType {
|
||||
kCompressed,
|
||||
kUncompressed,
|
||||
};
|
||||
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
|
||||
#if defined(__clang__)
|
||||
// Attribute const allows the compiler to assume that CageBaseGlobal::g_base_
|
||||
// doesn't change (e.g. across calls) and thereby avoid redundant loads.
|
||||
#define CPPGC_CONST __attribute__((const))
|
||||
#define CPPGC_REQUIRE_CONSTANT_INIT \
|
||||
__attribute__((require_constant_initialization))
|
||||
#else // defined(__clang__)
|
||||
#define CPPGC_CONST
|
||||
#define CPPGC_REQUIRE_CONSTANT_INIT
|
||||
#endif // defined(__clang__)
|
||||
|
||||
class V8_EXPORT CageBaseGlobal final {
|
||||
public:
|
||||
V8_INLINE CPPGC_CONST static uintptr_t Get() {
|
||||
CPPGC_DCHECK(IsBaseConsistent());
|
||||
return g_base_.base;
|
||||
}
|
||||
|
||||
V8_INLINE CPPGC_CONST static bool IsSet() {
|
||||
CPPGC_DCHECK(IsBaseConsistent());
|
||||
return (g_base_.base & ~kLowerHalfWordMask) != 0;
|
||||
}
|
||||
|
||||
private:
|
||||
// We keep the lower halfword as ones to speed up decompression.
|
||||
static constexpr uintptr_t kLowerHalfWordMask =
|
||||
(api_constants::kCagedHeapReservationAlignment - 1);
|
||||
|
||||
static union alignas(api_constants::kCachelineSize) Base {
|
||||
uintptr_t base;
|
||||
char cache_line[api_constants::kCachelineSize];
|
||||
} g_base_ CPPGC_REQUIRE_CONSTANT_INIT;
|
||||
|
||||
CageBaseGlobal() = delete;
|
||||
|
||||
V8_INLINE static bool IsBaseConsistent() {
|
||||
return kLowerHalfWordMask == (g_base_.base & kLowerHalfWordMask);
|
||||
}
|
||||
|
||||
friend class CageBaseGlobalUpdater;
|
||||
};
|
||||
|
||||
#undef CPPGC_REQUIRE_CONSTANT_INIT
|
||||
#undef CPPGC_CONST
|
||||
|
||||
class V8_TRIVIAL_ABI CompressedPointer final {
|
||||
public:
|
||||
using IntegralType = uint32_t;
|
||||
static constexpr auto kWriteBarrierSlotType =
|
||||
WriteBarrierSlotType::kCompressed;
|
||||
|
||||
V8_INLINE CompressedPointer() : value_(0u) {}
|
||||
V8_INLINE explicit CompressedPointer(const void* ptr)
|
||||
: value_(Compress(ptr)) {}
|
||||
V8_INLINE explicit CompressedPointer(std::nullptr_t) : value_(0u) {}
|
||||
V8_INLINE explicit CompressedPointer(SentinelPointer)
|
||||
: value_(kCompressedSentinel) {}
|
||||
|
||||
V8_INLINE const void* Load() const { return Decompress(value_); }
|
||||
V8_INLINE const void* LoadAtomic() const {
|
||||
return Decompress(
|
||||
reinterpret_cast<const std::atomic<IntegralType>&>(value_).load(
|
||||
std::memory_order_relaxed));
|
||||
}
|
||||
|
||||
V8_INLINE void Store(const void* ptr) { value_ = Compress(ptr); }
|
||||
V8_INLINE void StoreAtomic(const void* value) {
|
||||
reinterpret_cast<std::atomic<IntegralType>&>(value_).store(
|
||||
Compress(value), std::memory_order_relaxed);
|
||||
}
|
||||
|
||||
V8_INLINE void Clear() { value_ = 0u; }
|
||||
V8_INLINE bool IsCleared() const { return !value_; }
|
||||
|
||||
V8_INLINE bool IsSentinel() const { return value_ == kCompressedSentinel; }
|
||||
|
||||
V8_INLINE uint32_t GetAsInteger() const { return value_; }
|
||||
|
||||
V8_INLINE friend bool operator==(CompressedPointer a, CompressedPointer b) {
|
||||
return a.value_ == b.value_;
|
||||
}
|
||||
V8_INLINE friend bool operator!=(CompressedPointer a, CompressedPointer b) {
|
||||
return a.value_ != b.value_;
|
||||
}
|
||||
V8_INLINE friend bool operator<(CompressedPointer a, CompressedPointer b) {
|
||||
return a.value_ < b.value_;
|
||||
}
|
||||
V8_INLINE friend bool operator<=(CompressedPointer a, CompressedPointer b) {
|
||||
return a.value_ <= b.value_;
|
||||
}
|
||||
V8_INLINE friend bool operator>(CompressedPointer a, CompressedPointer b) {
|
||||
return a.value_ > b.value_;
|
||||
}
|
||||
V8_INLINE friend bool operator>=(CompressedPointer a, CompressedPointer b) {
|
||||
return a.value_ >= b.value_;
|
||||
}
|
||||
|
||||
static V8_INLINE IntegralType Compress(const void* ptr) {
|
||||
static_assert(SentinelPointer::kSentinelValue ==
|
||||
1 << api_constants::kPointerCompressionShift,
|
||||
"The compression scheme relies on the sentinel encoded as 1 "
|
||||
"<< kPointerCompressionShift");
|
||||
static constexpr size_t kGigaCageMask =
|
||||
~(api_constants::kCagedHeapReservationAlignment - 1);
|
||||
static constexpr size_t kPointerCompressionShiftMask =
|
||||
(1 << api_constants::kPointerCompressionShift) - 1;
|
||||
|
||||
CPPGC_DCHECK(CageBaseGlobal::IsSet());
|
||||
const uintptr_t base = CageBaseGlobal::Get();
|
||||
CPPGC_DCHECK(!ptr || ptr == kSentinelPointer ||
|
||||
(base & kGigaCageMask) ==
|
||||
(reinterpret_cast<uintptr_t>(ptr) & kGigaCageMask));
|
||||
CPPGC_DCHECK(
|
||||
(reinterpret_cast<uintptr_t>(ptr) & kPointerCompressionShiftMask) == 0);
|
||||
|
||||
#if defined(CPPGC_2GB_CAGE)
|
||||
// Truncate the pointer.
|
||||
auto compressed =
|
||||
static_cast<IntegralType>(reinterpret_cast<uintptr_t>(ptr));
|
||||
#else // !defined(CPPGC_2GB_CAGE)
|
||||
const auto uptr = reinterpret_cast<uintptr_t>(ptr);
|
||||
// Shift the pointer and truncate.
|
||||
auto compressed = static_cast<IntegralType>(
|
||||
uptr >> api_constants::kPointerCompressionShift);
|
||||
#endif // !defined(CPPGC_2GB_CAGE)
|
||||
// Normal compressed pointers must have the MSB set.
|
||||
CPPGC_DCHECK((!compressed || compressed == kCompressedSentinel) ||
|
||||
(compressed & (1 << 31)));
|
||||
return compressed;
|
||||
}
|
||||
|
||||
static V8_INLINE void* Decompress(IntegralType ptr) {
|
||||
CPPGC_DCHECK(CageBaseGlobal::IsSet());
|
||||
const uintptr_t base = CageBaseGlobal::Get();
|
||||
// Treat compressed pointer as signed and cast it to uint64_t, which will
|
||||
// sign-extend it.
|
||||
#if defined(CPPGC_2GB_CAGE)
|
||||
const uint64_t mask = static_cast<uint64_t>(static_cast<int32_t>(ptr));
|
||||
#else // !defined(CPPGC_2GB_CAGE)
|
||||
// Then, shift the result. It's important to shift the unsigned
|
||||
// value, as otherwise it would result in undefined behavior.
|
||||
const uint64_t mask = static_cast<uint64_t>(static_cast<int32_t>(ptr))
|
||||
<< api_constants::kPointerCompressionShift;
|
||||
#endif // !defined(CPPGC_2GB_CAGE)
|
||||
return reinterpret_cast<void*>(mask & base);
|
||||
}
|
||||
|
||||
private:
|
||||
#if defined(CPPGC_2GB_CAGE)
|
||||
static constexpr IntegralType kCompressedSentinel =
|
||||
SentinelPointer::kSentinelValue;
|
||||
#else // !defined(CPPGC_2GB_CAGE)
|
||||
static constexpr IntegralType kCompressedSentinel =
|
||||
SentinelPointer::kSentinelValue >>
|
||||
api_constants::kPointerCompressionShift;
|
||||
#endif // !defined(CPPGC_2GB_CAGE)
|
||||
// All constructors initialize `value_`. Do not add a default value here as it
|
||||
// results in a non-atomic write on some builds, even when the atomic version
|
||||
// of the constructor is used.
|
||||
IntegralType value_;
|
||||
};
|
||||
|
||||
#endif // defined(CPPGC_POINTER_COMPRESSION)
|
||||
|
||||
class V8_TRIVIAL_ABI RawPointer final {
|
||||
public:
|
||||
using IntegralType = uintptr_t;
|
||||
static constexpr auto kWriteBarrierSlotType =
|
||||
WriteBarrierSlotType::kUncompressed;
|
||||
|
||||
V8_INLINE RawPointer() : ptr_(nullptr) {}
|
||||
V8_INLINE explicit RawPointer(const void* ptr) : ptr_(ptr) {}
|
||||
|
||||
V8_INLINE const void* Load() const { return ptr_; }
|
||||
V8_INLINE const void* LoadAtomic() const {
|
||||
return reinterpret_cast<const std::atomic<const void*>&>(ptr_).load(
|
||||
std::memory_order_relaxed);
|
||||
}
|
||||
|
||||
V8_INLINE void Store(const void* ptr) { ptr_ = ptr; }
|
||||
V8_INLINE void StoreAtomic(const void* ptr) {
|
||||
reinterpret_cast<std::atomic<const void*>&>(ptr_).store(
|
||||
ptr, std::memory_order_relaxed);
|
||||
}
|
||||
|
||||
V8_INLINE void Clear() { ptr_ = nullptr; }
|
||||
V8_INLINE bool IsCleared() const { return !ptr_; }
|
||||
|
||||
V8_INLINE bool IsSentinel() const { return ptr_ == kSentinelPointer; }
|
||||
|
||||
V8_INLINE uintptr_t GetAsInteger() const {
|
||||
return reinterpret_cast<uintptr_t>(ptr_);
|
||||
}
|
||||
|
||||
V8_INLINE friend bool operator==(RawPointer a, RawPointer b) {
|
||||
return a.ptr_ == b.ptr_;
|
||||
}
|
||||
V8_INLINE friend bool operator!=(RawPointer a, RawPointer b) {
|
||||
return a.ptr_ != b.ptr_;
|
||||
}
|
||||
V8_INLINE friend bool operator<(RawPointer a, RawPointer b) {
|
||||
return a.ptr_ < b.ptr_;
|
||||
}
|
||||
V8_INLINE friend bool operator<=(RawPointer a, RawPointer b) {
|
||||
return a.ptr_ <= b.ptr_;
|
||||
}
|
||||
V8_INLINE friend bool operator>(RawPointer a, RawPointer b) {
|
||||
return a.ptr_ > b.ptr_;
|
||||
}
|
||||
V8_INLINE friend bool operator>=(RawPointer a, RawPointer b) {
|
||||
return a.ptr_ >= b.ptr_;
|
||||
}
|
||||
|
||||
private:
|
||||
// All constructors initialize `ptr_`. Do not add a default value here as it
|
||||
// results in a non-atomic write on some builds, even when the atomic version
|
||||
// of the constructor is used.
|
||||
const void* ptr_;
|
||||
};
|
||||
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
using DefaultMemberStorage = CompressedPointer;
|
||||
#else // !defined(CPPGC_POINTER_COMPRESSION)
|
||||
using DefaultMemberStorage = RawPointer;
|
||||
#endif // !defined(CPPGC_POINTER_COMPRESSION)
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_MEMBER_STORAGE_H_
|
||||
137
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/name-trait.h
generated
vendored
Normal file
137
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/name-trait.h
generated
vendored
Normal file
@@ -0,0 +1,137 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_NAME_TRAIT_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_NAME_TRAIT_H_
|
||||
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
#include <type_traits>
|
||||
|
||||
#include "cppgc/name-provider.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
#if CPPGC_SUPPORTS_OBJECT_NAMES && defined(__clang__)
|
||||
#define CPPGC_SUPPORTS_COMPILE_TIME_TYPENAME 1
|
||||
|
||||
// Provides constexpr c-string storage for a name of fixed |Size| characters.
|
||||
// Automatically appends terminating 0 byte.
|
||||
template <size_t Size>
|
||||
struct NameBuffer {
|
||||
char name[Size + 1]{};
|
||||
|
||||
static constexpr NameBuffer FromCString(const char* str) {
|
||||
NameBuffer result;
|
||||
for (size_t i = 0; i < Size; ++i) result.name[i] = str[i];
|
||||
result.name[Size] = 0;
|
||||
return result;
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
const char* GetTypename() {
|
||||
static constexpr char kSelfPrefix[] =
|
||||
"const char *cppgc::internal::GetTypename() [T =";
|
||||
static_assert(__builtin_strncmp(__PRETTY_FUNCTION__, kSelfPrefix,
|
||||
sizeof(kSelfPrefix) - 1) == 0,
|
||||
"The prefix must match");
|
||||
static constexpr const char* kTypenameStart =
|
||||
__PRETTY_FUNCTION__ + sizeof(kSelfPrefix);
|
||||
static constexpr size_t kTypenameSize =
|
||||
__builtin_strlen(__PRETTY_FUNCTION__) - sizeof(kSelfPrefix) - 1;
|
||||
// NameBuffer is an indirection that is needed to make sure that only a
|
||||
// substring of __PRETTY_FUNCTION__ gets materialized in the binary.
|
||||
static constexpr auto buffer =
|
||||
NameBuffer<kTypenameSize>::FromCString(kTypenameStart);
|
||||
return buffer.name;
|
||||
}
|
||||
|
||||
#else
|
||||
#define CPPGC_SUPPORTS_COMPILE_TIME_TYPENAME 0
|
||||
#endif
|
||||
|
||||
struct HeapObjectName {
|
||||
const char* value;
|
||||
bool name_was_hidden;
|
||||
};
|
||||
|
||||
enum class HeapObjectNameForUnnamedObject : uint8_t {
|
||||
kUseClassNameIfSupported,
|
||||
kUseHiddenName,
|
||||
};
|
||||
|
||||
class V8_EXPORT NameTraitBase {
|
||||
protected:
|
||||
static HeapObjectName GetNameFromTypeSignature(const char*);
|
||||
};
|
||||
|
||||
// Trait that specifies how the garbage collector retrieves the name for a
|
||||
// given object.
|
||||
template <typename T>
|
||||
class NameTrait final : public NameTraitBase {
|
||||
public:
|
||||
static constexpr bool HasNonHiddenName() {
|
||||
#if CPPGC_SUPPORTS_COMPILE_TIME_TYPENAME
|
||||
return true;
|
||||
#elif CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
return true;
|
||||
#else // !CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
return std::is_base_of<NameProvider, T>::value;
|
||||
#endif // !CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
}
|
||||
|
||||
static HeapObjectName GetName(
|
||||
const void* obj, HeapObjectNameForUnnamedObject name_retrieval_mode) {
|
||||
return GetNameFor(static_cast<const T*>(obj), name_retrieval_mode);
|
||||
}
|
||||
|
||||
private:
|
||||
static HeapObjectName GetNameFor(const NameProvider* name_provider,
|
||||
HeapObjectNameForUnnamedObject) {
|
||||
// Objects inheriting from `NameProvider` are not considered unnamed as
|
||||
// users already provided a name for them.
|
||||
return {name_provider->GetHumanReadableName(), false};
|
||||
}
|
||||
|
||||
static HeapObjectName GetNameFor(
|
||||
const void*, HeapObjectNameForUnnamedObject name_retrieval_mode) {
|
||||
if (name_retrieval_mode == HeapObjectNameForUnnamedObject::kUseHiddenName)
|
||||
return {NameProvider::kHiddenName, true};
|
||||
|
||||
#if CPPGC_SUPPORTS_COMPILE_TIME_TYPENAME
|
||||
return {GetTypename<T>(), false};
|
||||
#elif CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
|
||||
#if defined(V8_CC_GNU)
|
||||
#define PRETTY_FUNCTION_VALUE __PRETTY_FUNCTION__
|
||||
#elif defined(V8_CC_MSVC)
|
||||
#define PRETTY_FUNCTION_VALUE __FUNCSIG__
|
||||
#else
|
||||
#define PRETTY_FUNCTION_VALUE nullptr
|
||||
#endif
|
||||
|
||||
static const HeapObjectName leaky_name =
|
||||
GetNameFromTypeSignature(PRETTY_FUNCTION_VALUE);
|
||||
return leaky_name;
|
||||
|
||||
#undef PRETTY_FUNCTION_VALUE
|
||||
|
||||
#else // !CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
return {NameProvider::kHiddenName, true};
|
||||
#endif // !CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
}
|
||||
};
|
||||
|
||||
using NameCallback = HeapObjectName (*)(const void*,
|
||||
HeapObjectNameForUnnamedObject);
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#undef CPPGC_SUPPORTS_COMPILE_TIME_TYPENAME
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_NAME_TRAIT_H_
|
||||
214
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/persistent-node.h
generated
vendored
Normal file
214
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/persistent-node.h
generated
vendored
Normal file
@@ -0,0 +1,214 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_PERSISTENT_NODE_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_PERSISTENT_NODE_H_
|
||||
|
||||
#include <array>
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
|
||||
#include "cppgc/internal/logging.h"
|
||||
#include "cppgc/trace-trait.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
class CrossThreadPersistentRegion;
|
||||
class FatalOutOfMemoryHandler;
|
||||
class RootVisitor;
|
||||
|
||||
// PersistentNode represents a variant of two states:
|
||||
// 1) traceable node with a back pointer to the Persistent object;
|
||||
// 2) freelist entry.
|
||||
class PersistentNode final {
|
||||
public:
|
||||
PersistentNode() = default;
|
||||
|
||||
PersistentNode(const PersistentNode&) = delete;
|
||||
PersistentNode& operator=(const PersistentNode&) = delete;
|
||||
|
||||
void InitializeAsUsedNode(void* owner, TraceRootCallback trace) {
|
||||
CPPGC_DCHECK(trace);
|
||||
owner_ = owner;
|
||||
trace_ = trace;
|
||||
}
|
||||
|
||||
void InitializeAsFreeNode(PersistentNode* next) {
|
||||
next_ = next;
|
||||
trace_ = nullptr;
|
||||
}
|
||||
|
||||
void UpdateOwner(void* owner) {
|
||||
CPPGC_DCHECK(IsUsed());
|
||||
owner_ = owner;
|
||||
}
|
||||
|
||||
PersistentNode* FreeListNext() const {
|
||||
CPPGC_DCHECK(!IsUsed());
|
||||
return next_;
|
||||
}
|
||||
|
||||
void Trace(RootVisitor& root_visitor) const {
|
||||
CPPGC_DCHECK(IsUsed());
|
||||
trace_(root_visitor, owner_);
|
||||
}
|
||||
|
||||
bool IsUsed() const { return trace_; }
|
||||
|
||||
void* owner() const {
|
||||
CPPGC_DCHECK(IsUsed());
|
||||
return owner_;
|
||||
}
|
||||
|
||||
private:
|
||||
// PersistentNode acts as a designated union:
|
||||
// If trace_ != nullptr, owner_ points to the corresponding Persistent handle.
|
||||
// Otherwise, next_ points to the next freed PersistentNode.
|
||||
union {
|
||||
void* owner_ = nullptr;
|
||||
PersistentNode* next_;
|
||||
};
|
||||
TraceRootCallback trace_ = nullptr;
|
||||
};
|
||||
|
||||
class V8_EXPORT PersistentRegionBase {
|
||||
using PersistentNodeSlots = std::array<PersistentNode, 256u>;
|
||||
|
||||
public:
|
||||
// Clears Persistent fields to avoid stale pointers after heap teardown.
|
||||
~PersistentRegionBase();
|
||||
|
||||
PersistentRegionBase(const PersistentRegionBase&) = delete;
|
||||
PersistentRegionBase& operator=(const PersistentRegionBase&) = delete;
|
||||
|
||||
void Iterate(RootVisitor&);
|
||||
|
||||
size_t NodesInUse() const;
|
||||
|
||||
void ClearAllUsedNodes();
|
||||
|
||||
protected:
|
||||
explicit PersistentRegionBase(const FatalOutOfMemoryHandler& oom_handler);
|
||||
|
||||
PersistentNode* TryAllocateNodeFromFreeList(void* owner,
|
||||
TraceRootCallback trace) {
|
||||
PersistentNode* node = nullptr;
|
||||
if (V8_LIKELY(free_list_head_)) {
|
||||
node = free_list_head_;
|
||||
free_list_head_ = free_list_head_->FreeListNext();
|
||||
CPPGC_DCHECK(!node->IsUsed());
|
||||
node->InitializeAsUsedNode(owner, trace);
|
||||
nodes_in_use_++;
|
||||
}
|
||||
return node;
|
||||
}
|
||||
|
||||
void FreeNode(PersistentNode* node) {
|
||||
CPPGC_DCHECK(node);
|
||||
CPPGC_DCHECK(node->IsUsed());
|
||||
node->InitializeAsFreeNode(free_list_head_);
|
||||
free_list_head_ = node;
|
||||
CPPGC_DCHECK(nodes_in_use_ > 0);
|
||||
nodes_in_use_--;
|
||||
}
|
||||
|
||||
PersistentNode* RefillFreeListAndAllocateNode(void* owner,
|
||||
TraceRootCallback trace);
|
||||
|
||||
private:
|
||||
template <typename PersistentBaseClass>
|
||||
void ClearAllUsedNodes();
|
||||
|
||||
void RefillFreeList();
|
||||
|
||||
std::vector<std::unique_ptr<PersistentNodeSlots>> nodes_;
|
||||
PersistentNode* free_list_head_ = nullptr;
|
||||
size_t nodes_in_use_ = 0;
|
||||
const FatalOutOfMemoryHandler& oom_handler_;
|
||||
|
||||
friend class CrossThreadPersistentRegion;
|
||||
};
|
||||
|
||||
// Variant of PersistentRegionBase that checks whether the allocation and
|
||||
// freeing happens only on the thread that created the region.
|
||||
class V8_EXPORT PersistentRegion final : public PersistentRegionBase {
|
||||
public:
|
||||
explicit PersistentRegion(const FatalOutOfMemoryHandler&);
|
||||
// Clears Persistent fields to avoid stale pointers after heap teardown.
|
||||
~PersistentRegion() = default;
|
||||
|
||||
PersistentRegion(const PersistentRegion&) = delete;
|
||||
PersistentRegion& operator=(const PersistentRegion&) = delete;
|
||||
|
||||
V8_INLINE PersistentNode* AllocateNode(void* owner, TraceRootCallback trace) {
|
||||
CPPGC_DCHECK(IsCreationThread());
|
||||
auto* node = TryAllocateNodeFromFreeList(owner, trace);
|
||||
if (V8_LIKELY(node)) return node;
|
||||
|
||||
// Slow path allocation allows for checking thread correspondence.
|
||||
CPPGC_CHECK(IsCreationThread());
|
||||
return RefillFreeListAndAllocateNode(owner, trace);
|
||||
}
|
||||
|
||||
V8_INLINE void FreeNode(PersistentNode* node) {
|
||||
CPPGC_DCHECK(IsCreationThread());
|
||||
PersistentRegionBase::FreeNode(node);
|
||||
}
|
||||
|
||||
private:
|
||||
bool IsCreationThread();
|
||||
|
||||
int creation_thread_id_;
|
||||
};
|
||||
|
||||
// CrossThreadPersistent uses PersistentRegionBase but protects it using this
|
||||
// lock when needed.
|
||||
class V8_EXPORT PersistentRegionLock final {
|
||||
public:
|
||||
PersistentRegionLock();
|
||||
~PersistentRegionLock();
|
||||
|
||||
static void AssertLocked();
|
||||
};
|
||||
|
||||
// Variant of PersistentRegionBase that checks whether the PersistentRegionLock
|
||||
// is locked.
|
||||
class V8_EXPORT CrossThreadPersistentRegion final
|
||||
: protected PersistentRegionBase {
|
||||
public:
|
||||
explicit CrossThreadPersistentRegion(const FatalOutOfMemoryHandler&);
|
||||
// Clears Persistent fields to avoid stale pointers after heap teardown.
|
||||
~CrossThreadPersistentRegion();
|
||||
|
||||
CrossThreadPersistentRegion(const CrossThreadPersistentRegion&) = delete;
|
||||
CrossThreadPersistentRegion& operator=(const CrossThreadPersistentRegion&) =
|
||||
delete;
|
||||
|
||||
V8_INLINE PersistentNode* AllocateNode(void* owner, TraceRootCallback trace) {
|
||||
PersistentRegionLock::AssertLocked();
|
||||
auto* node = TryAllocateNodeFromFreeList(owner, trace);
|
||||
if (V8_LIKELY(node)) return node;
|
||||
|
||||
return RefillFreeListAndAllocateNode(owner, trace);
|
||||
}
|
||||
|
||||
V8_INLINE void FreeNode(PersistentNode* node) {
|
||||
PersistentRegionLock::AssertLocked();
|
||||
PersistentRegionBase::FreeNode(node);
|
||||
}
|
||||
|
||||
void Iterate(RootVisitor&);
|
||||
|
||||
size_t NodesInUse() const;
|
||||
|
||||
void ClearAllUsedNodes();
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_PERSISTENT_NODE_H_
|
||||
243
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/pointer-policies.h
generated
vendored
Normal file
243
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/pointer-policies.h
generated
vendored
Normal file
@@ -0,0 +1,243 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_POINTER_POLICIES_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_POINTER_POLICIES_H_
|
||||
|
||||
#include <cstdint>
|
||||
#include <type_traits>
|
||||
|
||||
#include "cppgc/internal/member-storage.h"
|
||||
#include "cppgc/internal/write-barrier.h"
|
||||
#include "cppgc/sentinel-pointer.h"
|
||||
#include "cppgc/source-location.h"
|
||||
#include "cppgc/type-traits.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
class HeapBase;
|
||||
class PersistentRegion;
|
||||
class CrossThreadPersistentRegion;
|
||||
|
||||
// Tags to distinguish between strong and weak member types.
|
||||
class StrongMemberTag;
|
||||
class WeakMemberTag;
|
||||
class UntracedMemberTag;
|
||||
|
||||
struct DijkstraWriteBarrierPolicy {
|
||||
V8_INLINE static void InitializingBarrier(const void*, const void*) {
|
||||
// Since in initializing writes the source object is always white, having no
|
||||
// barrier doesn't break the tri-color invariant.
|
||||
}
|
||||
|
||||
template <WriteBarrierSlotType SlotType>
|
||||
V8_INLINE static void AssigningBarrier(const void* slot, const void* value) {
|
||||
#ifdef CPPGC_SLIM_WRITE_BARRIER
|
||||
if (V8_UNLIKELY(WriteBarrier::IsEnabled()))
|
||||
WriteBarrier::CombinedWriteBarrierSlow<SlotType>(slot);
|
||||
#else // !CPPGC_SLIM_WRITE_BARRIER
|
||||
WriteBarrier::Params params;
|
||||
const WriteBarrier::Type type =
|
||||
WriteBarrier::GetWriteBarrierType(slot, value, params);
|
||||
WriteBarrier(type, params, slot, value);
|
||||
#endif // !CPPGC_SLIM_WRITE_BARRIER
|
||||
}
|
||||
|
||||
template <WriteBarrierSlotType SlotType>
|
||||
V8_INLINE static void AssigningBarrier(const void* slot, RawPointer storage) {
|
||||
static_assert(
|
||||
SlotType == WriteBarrierSlotType::kUncompressed,
|
||||
"Assigning storages of Member and UncompressedMember is not supported");
|
||||
#ifdef CPPGC_SLIM_WRITE_BARRIER
|
||||
if (V8_UNLIKELY(WriteBarrier::IsEnabled()))
|
||||
WriteBarrier::CombinedWriteBarrierSlow<SlotType>(slot);
|
||||
#else // !CPPGC_SLIM_WRITE_BARRIER
|
||||
WriteBarrier::Params params;
|
||||
const WriteBarrier::Type type =
|
||||
WriteBarrier::GetWriteBarrierType(slot, storage, params);
|
||||
WriteBarrier(type, params, slot, storage.Load());
|
||||
#endif // !CPPGC_SLIM_WRITE_BARRIER
|
||||
}
|
||||
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
template <WriteBarrierSlotType SlotType>
|
||||
V8_INLINE static void AssigningBarrier(const void* slot,
|
||||
CompressedPointer storage) {
|
||||
static_assert(
|
||||
SlotType == WriteBarrierSlotType::kCompressed,
|
||||
"Assigning storages of Member and UncompressedMember is not supported");
|
||||
#ifdef CPPGC_SLIM_WRITE_BARRIER
|
||||
if (V8_UNLIKELY(WriteBarrier::IsEnabled()))
|
||||
WriteBarrier::CombinedWriteBarrierSlow<SlotType>(slot);
|
||||
#else // !CPPGC_SLIM_WRITE_BARRIER
|
||||
WriteBarrier::Params params;
|
||||
const WriteBarrier::Type type =
|
||||
WriteBarrier::GetWriteBarrierType(slot, storage, params);
|
||||
WriteBarrier(type, params, slot, storage.Load());
|
||||
#endif // !CPPGC_SLIM_WRITE_BARRIER
|
||||
}
|
||||
#endif // defined(CPPGC_POINTER_COMPRESSION)
|
||||
|
||||
private:
|
||||
V8_INLINE static void WriteBarrier(WriteBarrier::Type type,
|
||||
const WriteBarrier::Params& params,
|
||||
const void* slot, const void* value) {
|
||||
switch (type) {
|
||||
case WriteBarrier::Type::kGenerational:
|
||||
WriteBarrier::GenerationalBarrier<
|
||||
WriteBarrier::GenerationalBarrierType::kPreciseSlot>(params, slot);
|
||||
break;
|
||||
case WriteBarrier::Type::kMarking:
|
||||
WriteBarrier::DijkstraMarkingBarrier(params, value);
|
||||
break;
|
||||
case WriteBarrier::Type::kNone:
|
||||
break;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
struct NoWriteBarrierPolicy {
|
||||
V8_INLINE static void InitializingBarrier(const void*, const void*) {}
|
||||
template <WriteBarrierSlotType>
|
||||
V8_INLINE static void AssigningBarrier(const void*, const void*) {}
|
||||
template <WriteBarrierSlotType, typename MemberStorage>
|
||||
V8_INLINE static void AssigningBarrier(const void*, MemberStorage) {}
|
||||
};
|
||||
|
||||
class V8_EXPORT SameThreadEnabledCheckingPolicyBase {
|
||||
protected:
|
||||
void CheckPointerImpl(const void* ptr, bool points_to_payload,
|
||||
bool check_off_heap_assignments);
|
||||
|
||||
const HeapBase* heap_ = nullptr;
|
||||
};
|
||||
|
||||
template <bool kCheckOffHeapAssignments>
|
||||
class V8_EXPORT SameThreadEnabledCheckingPolicy
|
||||
: private SameThreadEnabledCheckingPolicyBase {
|
||||
protected:
|
||||
template <typename T>
|
||||
void CheckPointer(const T* ptr) {
|
||||
if (!ptr || (kSentinelPointer == ptr)) return;
|
||||
|
||||
CheckPointersImplTrampoline<T>::Call(this, ptr);
|
||||
}
|
||||
|
||||
private:
|
||||
template <typename T, bool = IsCompleteV<T>>
|
||||
struct CheckPointersImplTrampoline {
|
||||
static void Call(SameThreadEnabledCheckingPolicy* policy, const T* ptr) {
|
||||
policy->CheckPointerImpl(ptr, false, kCheckOffHeapAssignments);
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct CheckPointersImplTrampoline<T, true> {
|
||||
static void Call(SameThreadEnabledCheckingPolicy* policy, const T* ptr) {
|
||||
policy->CheckPointerImpl(ptr, IsGarbageCollectedTypeV<T>,
|
||||
kCheckOffHeapAssignments);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
class DisabledCheckingPolicy {
|
||||
protected:
|
||||
V8_INLINE void CheckPointer(const void*) {}
|
||||
};
|
||||
|
||||
#ifdef DEBUG
|
||||
// Off heap members are not connected to object graph and thus cannot ressurect
|
||||
// dead objects.
|
||||
using DefaultMemberCheckingPolicy =
|
||||
SameThreadEnabledCheckingPolicy<false /* kCheckOffHeapAssignments*/>;
|
||||
using DefaultPersistentCheckingPolicy =
|
||||
SameThreadEnabledCheckingPolicy<true /* kCheckOffHeapAssignments*/>;
|
||||
#else // !DEBUG
|
||||
using DefaultMemberCheckingPolicy = DisabledCheckingPolicy;
|
||||
using DefaultPersistentCheckingPolicy = DisabledCheckingPolicy;
|
||||
#endif // !DEBUG
|
||||
// For CT(W)P neither marking information (for value), nor objectstart bitmap
|
||||
// (for slot) are guaranteed to be present because there's no synchronization
|
||||
// between heaps after marking.
|
||||
using DefaultCrossThreadPersistentCheckingPolicy = DisabledCheckingPolicy;
|
||||
|
||||
class KeepLocationPolicy {
|
||||
public:
|
||||
constexpr const SourceLocation& Location() const { return location_; }
|
||||
|
||||
protected:
|
||||
constexpr KeepLocationPolicy() = default;
|
||||
constexpr explicit KeepLocationPolicy(const SourceLocation& location)
|
||||
: location_(location) {}
|
||||
|
||||
// KeepLocationPolicy must not copy underlying source locations.
|
||||
KeepLocationPolicy(const KeepLocationPolicy&) = delete;
|
||||
KeepLocationPolicy& operator=(const KeepLocationPolicy&) = delete;
|
||||
|
||||
// Location of the original moved from object should be preserved.
|
||||
KeepLocationPolicy(KeepLocationPolicy&&) = default;
|
||||
KeepLocationPolicy& operator=(KeepLocationPolicy&&) = default;
|
||||
|
||||
private:
|
||||
SourceLocation location_;
|
||||
};
|
||||
|
||||
class IgnoreLocationPolicy {
|
||||
public:
|
||||
constexpr SourceLocation Location() const { return {}; }
|
||||
|
||||
protected:
|
||||
constexpr IgnoreLocationPolicy() = default;
|
||||
constexpr explicit IgnoreLocationPolicy(const SourceLocation&) {}
|
||||
};
|
||||
|
||||
#if CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
using DefaultLocationPolicy = KeepLocationPolicy;
|
||||
#else
|
||||
using DefaultLocationPolicy = IgnoreLocationPolicy;
|
||||
#endif
|
||||
|
||||
struct StrongPersistentPolicy {
|
||||
using IsStrongPersistent = std::true_type;
|
||||
static V8_EXPORT PersistentRegion& GetPersistentRegion(const void* object);
|
||||
};
|
||||
|
||||
struct WeakPersistentPolicy {
|
||||
using IsStrongPersistent = std::false_type;
|
||||
static V8_EXPORT PersistentRegion& GetPersistentRegion(const void* object);
|
||||
};
|
||||
|
||||
struct StrongCrossThreadPersistentPolicy {
|
||||
using IsStrongPersistent = std::true_type;
|
||||
static V8_EXPORT CrossThreadPersistentRegion& GetPersistentRegion(
|
||||
const void* object);
|
||||
};
|
||||
|
||||
struct WeakCrossThreadPersistentPolicy {
|
||||
using IsStrongPersistent = std::false_type;
|
||||
static V8_EXPORT CrossThreadPersistentRegion& GetPersistentRegion(
|
||||
const void* object);
|
||||
};
|
||||
|
||||
// Forward declarations setting up the default policies.
|
||||
template <typename T, typename WeaknessPolicy,
|
||||
typename LocationPolicy = DefaultLocationPolicy,
|
||||
typename CheckingPolicy = DefaultCrossThreadPersistentCheckingPolicy>
|
||||
class BasicCrossThreadPersistent;
|
||||
template <typename T, typename WeaknessPolicy,
|
||||
typename LocationPolicy = DefaultLocationPolicy,
|
||||
typename CheckingPolicy = DefaultPersistentCheckingPolicy>
|
||||
class BasicPersistent;
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy = DefaultMemberCheckingPolicy,
|
||||
typename StorageType = DefaultMemberStorage>
|
||||
class BasicMember;
|
||||
|
||||
} // namespace internal
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_POINTER_POLICIES_H_
|
||||
487
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/write-barrier.h
generated
vendored
Normal file
487
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/internal/write-barrier.h
generated
vendored
Normal file
@@ -0,0 +1,487 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_INTERNAL_WRITE_BARRIER_H_
|
||||
#define INCLUDE_CPPGC_INTERNAL_WRITE_BARRIER_H_
|
||||
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
|
||||
#include "cppgc/heap-handle.h"
|
||||
#include "cppgc/heap-state.h"
|
||||
#include "cppgc/internal/api-constants.h"
|
||||
#include "cppgc/internal/atomic-entry-flag.h"
|
||||
#include "cppgc/internal/base-page-handle.h"
|
||||
#include "cppgc/internal/member-storage.h"
|
||||
#include "cppgc/platform.h"
|
||||
#include "cppgc/sentinel-pointer.h"
|
||||
#include "cppgc/trace-trait.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
#include "cppgc/internal/caged-heap-local-data.h"
|
||||
#include "cppgc/internal/caged-heap.h"
|
||||
#endif
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
class HeapHandle;
|
||||
|
||||
namespace internal {
|
||||
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
class WriteBarrierTypeForCagedHeapPolicy;
|
||||
#else // !CPPGC_CAGED_HEAP
|
||||
class WriteBarrierTypeForNonCagedHeapPolicy;
|
||||
#endif // !CPPGC_CAGED_HEAP
|
||||
|
||||
class V8_EXPORT WriteBarrier final {
|
||||
public:
|
||||
enum class Type : uint8_t {
|
||||
kNone,
|
||||
kMarking,
|
||||
kGenerational,
|
||||
};
|
||||
|
||||
enum class GenerationalBarrierType : uint8_t {
|
||||
kPreciseSlot,
|
||||
kPreciseUncompressedSlot,
|
||||
kImpreciseSlot,
|
||||
};
|
||||
|
||||
struct Params {
|
||||
HeapHandle* heap = nullptr;
|
||||
#if V8_ENABLE_CHECKS
|
||||
Type type = Type::kNone;
|
||||
#endif // !V8_ENABLE_CHECKS
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
uintptr_t slot_offset = 0;
|
||||
uintptr_t value_offset = 0;
|
||||
#endif // CPPGC_CAGED_HEAP
|
||||
};
|
||||
|
||||
enum class ValueMode {
|
||||
kValuePresent,
|
||||
kNoValuePresent,
|
||||
};
|
||||
|
||||
// Returns the required write barrier for a given `slot` and `value`.
|
||||
static V8_INLINE Type GetWriteBarrierType(const void* slot, const void* value,
|
||||
Params& params);
|
||||
// Returns the required write barrier for a given `slot` and `value`.
|
||||
template <typename MemberStorage>
|
||||
static V8_INLINE Type GetWriteBarrierType(const void* slot, MemberStorage,
|
||||
Params& params);
|
||||
// Returns the required write barrier for a given `slot`.
|
||||
template <typename HeapHandleCallback>
|
||||
static V8_INLINE Type GetWriteBarrierType(const void* slot, Params& params,
|
||||
HeapHandleCallback callback);
|
||||
// Returns the required write barrier for a given `value`.
|
||||
static V8_INLINE Type GetWriteBarrierType(const void* value, Params& params);
|
||||
|
||||
#ifdef CPPGC_SLIM_WRITE_BARRIER
|
||||
// A write barrier that combines `GenerationalBarrier()` and
|
||||
// `DijkstraMarkingBarrier()`. We only pass a single parameter here to clobber
|
||||
// as few registers as possible.
|
||||
template <WriteBarrierSlotType>
|
||||
static V8_NOINLINE void V8_PRESERVE_MOST
|
||||
CombinedWriteBarrierSlow(const void* slot);
|
||||
#endif // CPPGC_SLIM_WRITE_BARRIER
|
||||
|
||||
static V8_INLINE void DijkstraMarkingBarrier(const Params& params,
|
||||
const void* object);
|
||||
static V8_INLINE void DijkstraMarkingBarrierRange(
|
||||
const Params& params, const void* first_element, size_t element_size,
|
||||
size_t number_of_elements, TraceCallback trace_callback);
|
||||
static V8_INLINE void SteeleMarkingBarrier(const Params& params,
|
||||
const void* object);
|
||||
#if defined(CPPGC_YOUNG_GENERATION)
|
||||
template <GenerationalBarrierType>
|
||||
static V8_INLINE void GenerationalBarrier(const Params& params,
|
||||
const void* slot);
|
||||
#else // !CPPGC_YOUNG_GENERATION
|
||||
template <GenerationalBarrierType>
|
||||
static V8_INLINE void GenerationalBarrier(const Params& params,
|
||||
const void* slot){}
|
||||
#endif // CPPGC_YOUNG_GENERATION
|
||||
|
||||
#if V8_ENABLE_CHECKS
|
||||
static void CheckParams(Type expected_type, const Params& params);
|
||||
#else // !V8_ENABLE_CHECKS
|
||||
static void CheckParams(Type expected_type, const Params& params) {}
|
||||
#endif // !V8_ENABLE_CHECKS
|
||||
|
||||
// The FlagUpdater class allows cppgc internal to update
|
||||
// |write_barrier_enabled_|.
|
||||
class FlagUpdater;
|
||||
static bool IsEnabled() { return write_barrier_enabled_.MightBeEntered(); }
|
||||
|
||||
private:
|
||||
WriteBarrier() = delete;
|
||||
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
using WriteBarrierTypePolicy = WriteBarrierTypeForCagedHeapPolicy;
|
||||
#else // !CPPGC_CAGED_HEAP
|
||||
using WriteBarrierTypePolicy = WriteBarrierTypeForNonCagedHeapPolicy;
|
||||
#endif // !CPPGC_CAGED_HEAP
|
||||
|
||||
static void DijkstraMarkingBarrierSlow(const void* value);
|
||||
static void DijkstraMarkingBarrierSlowWithSentinelCheck(const void* value);
|
||||
static void DijkstraMarkingBarrierRangeSlow(HeapHandle& heap_handle,
|
||||
const void* first_element,
|
||||
size_t element_size,
|
||||
size_t number_of_elements,
|
||||
TraceCallback trace_callback);
|
||||
static void SteeleMarkingBarrierSlow(const void* value);
|
||||
static void SteeleMarkingBarrierSlowWithSentinelCheck(const void* value);
|
||||
|
||||
#if defined(CPPGC_YOUNG_GENERATION)
|
||||
static CagedHeapLocalData& GetLocalData(HeapHandle&);
|
||||
static void GenerationalBarrierSlow(const CagedHeapLocalData& local_data,
|
||||
const AgeTable& age_table,
|
||||
const void* slot, uintptr_t value_offset,
|
||||
HeapHandle* heap_handle);
|
||||
static void GenerationalBarrierForUncompressedSlotSlow(
|
||||
const CagedHeapLocalData& local_data, const AgeTable& age_table,
|
||||
const void* slot, uintptr_t value_offset, HeapHandle* heap_handle);
|
||||
static void GenerationalBarrierForSourceObjectSlow(
|
||||
const CagedHeapLocalData& local_data, const void* object,
|
||||
HeapHandle* heap_handle);
|
||||
#endif // CPPGC_YOUNG_GENERATION
|
||||
|
||||
static AtomicEntryFlag write_barrier_enabled_;
|
||||
};
|
||||
|
||||
template <WriteBarrier::Type type>
|
||||
V8_INLINE WriteBarrier::Type SetAndReturnType(WriteBarrier::Params& params) {
|
||||
if constexpr (type == WriteBarrier::Type::kNone)
|
||||
return WriteBarrier::Type::kNone;
|
||||
#if V8_ENABLE_CHECKS
|
||||
params.type = type;
|
||||
#endif // !V8_ENABLE_CHECKS
|
||||
return type;
|
||||
}
|
||||
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
class V8_EXPORT WriteBarrierTypeForCagedHeapPolicy final {
|
||||
public:
|
||||
template <WriteBarrier::ValueMode value_mode, typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void* slot, const void* value,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
return ValueModeDispatch<value_mode>::Get(slot, value, params, callback);
|
||||
}
|
||||
|
||||
template <WriteBarrier::ValueMode value_mode, typename HeapHandleCallback,
|
||||
typename MemberStorage>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void* slot, MemberStorage value,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
return ValueModeDispatch<value_mode>::Get(slot, value, params, callback);
|
||||
}
|
||||
|
||||
template <WriteBarrier::ValueMode value_mode, typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void* value,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
return GetNoSlot(value, params, callback);
|
||||
}
|
||||
|
||||
private:
|
||||
WriteBarrierTypeForCagedHeapPolicy() = delete;
|
||||
|
||||
template <typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type GetNoSlot(const void* value,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback) {
|
||||
const bool within_cage = CagedHeapBase::IsWithinCage(value);
|
||||
if (!within_cage) return WriteBarrier::Type::kNone;
|
||||
|
||||
// We know that |value| points either within the normal page or to the
|
||||
// beginning of large-page, so extract the page header by bitmasking.
|
||||
BasePageHandle* page =
|
||||
BasePageHandle::FromPayload(const_cast<void*>(value));
|
||||
|
||||
HeapHandle& heap_handle = page->heap_handle();
|
||||
if (V8_UNLIKELY(heap_handle.is_incremental_marking_in_progress())) {
|
||||
return SetAndReturnType<WriteBarrier::Type::kMarking>(params);
|
||||
}
|
||||
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
}
|
||||
|
||||
template <WriteBarrier::ValueMode value_mode>
|
||||
struct ValueModeDispatch;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct WriteBarrierTypeForCagedHeapPolicy::ValueModeDispatch<
|
||||
WriteBarrier::ValueMode::kValuePresent> {
|
||||
template <typename HeapHandleCallback, typename MemberStorage>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void* slot,
|
||||
MemberStorage storage,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback) {
|
||||
if (V8_LIKELY(!WriteBarrier::IsEnabled()))
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
|
||||
return BarrierEnabledGet(slot, storage.Load(), params);
|
||||
}
|
||||
|
||||
template <typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void* slot, const void* value,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback) {
|
||||
if (V8_LIKELY(!WriteBarrier::IsEnabled()))
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
|
||||
return BarrierEnabledGet(slot, value, params);
|
||||
}
|
||||
|
||||
private:
|
||||
static V8_INLINE WriteBarrier::Type BarrierEnabledGet(
|
||||
const void* slot, const void* value, WriteBarrier::Params& params) {
|
||||
const bool within_cage = CagedHeapBase::AreWithinCage(slot, value);
|
||||
if (!within_cage) return WriteBarrier::Type::kNone;
|
||||
|
||||
// We know that |value| points either within the normal page or to the
|
||||
// beginning of large-page, so extract the page header by bitmasking.
|
||||
BasePageHandle* page =
|
||||
BasePageHandle::FromPayload(const_cast<void*>(value));
|
||||
|
||||
HeapHandle& heap_handle = page->heap_handle();
|
||||
if (V8_LIKELY(!heap_handle.is_incremental_marking_in_progress())) {
|
||||
#if defined(CPPGC_YOUNG_GENERATION)
|
||||
if (!heap_handle.is_young_generation_enabled())
|
||||
return WriteBarrier::Type::kNone;
|
||||
params.heap = &heap_handle;
|
||||
params.slot_offset = CagedHeapBase::OffsetFromAddress(slot);
|
||||
params.value_offset = CagedHeapBase::OffsetFromAddress(value);
|
||||
return SetAndReturnType<WriteBarrier::Type::kGenerational>(params);
|
||||
#else // !CPPGC_YOUNG_GENERATION
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
#endif // !CPPGC_YOUNG_GENERATION
|
||||
}
|
||||
|
||||
// Use marking barrier.
|
||||
params.heap = &heap_handle;
|
||||
return SetAndReturnType<WriteBarrier::Type::kMarking>(params);
|
||||
}
|
||||
};
|
||||
|
||||
template <>
|
||||
struct WriteBarrierTypeForCagedHeapPolicy::ValueModeDispatch<
|
||||
WriteBarrier::ValueMode::kNoValuePresent> {
|
||||
template <typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void* slot, const void*,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
if (V8_LIKELY(!WriteBarrier::IsEnabled()))
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
|
||||
HeapHandle& handle = callback();
|
||||
#if defined(CPPGC_YOUNG_GENERATION)
|
||||
if (V8_LIKELY(!handle.is_incremental_marking_in_progress())) {
|
||||
if (!handle.is_young_generation_enabled()) {
|
||||
return WriteBarrier::Type::kNone;
|
||||
}
|
||||
params.heap = &handle;
|
||||
// Check if slot is on stack.
|
||||
if (V8_UNLIKELY(!CagedHeapBase::IsWithinCage(slot))) {
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
}
|
||||
params.slot_offset = CagedHeapBase::OffsetFromAddress(slot);
|
||||
return SetAndReturnType<WriteBarrier::Type::kGenerational>(params);
|
||||
}
|
||||
#else // !defined(CPPGC_YOUNG_GENERATION)
|
||||
if (V8_UNLIKELY(!handle.is_incremental_marking_in_progress())) {
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
}
|
||||
#endif // !defined(CPPGC_YOUNG_GENERATION)
|
||||
params.heap = &handle;
|
||||
return SetAndReturnType<WriteBarrier::Type::kMarking>(params);
|
||||
}
|
||||
};
|
||||
|
||||
#endif // CPPGC_CAGED_HEAP
|
||||
|
||||
class V8_EXPORT WriteBarrierTypeForNonCagedHeapPolicy final {
|
||||
public:
|
||||
template <WriteBarrier::ValueMode value_mode, typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void* slot, const void* value,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
return ValueModeDispatch<value_mode>::Get(slot, value, params, callback);
|
||||
}
|
||||
|
||||
template <WriteBarrier::ValueMode value_mode, typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void* slot, RawPointer value,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
return ValueModeDispatch<value_mode>::Get(slot, value.Load(), params,
|
||||
callback);
|
||||
}
|
||||
|
||||
template <WriteBarrier::ValueMode value_mode, typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void* value,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
// The slot will never be used in `Get()` below.
|
||||
return Get<WriteBarrier::ValueMode::kValuePresent>(nullptr, value, params,
|
||||
callback);
|
||||
}
|
||||
|
||||
private:
|
||||
template <WriteBarrier::ValueMode value_mode>
|
||||
struct ValueModeDispatch;
|
||||
|
||||
WriteBarrierTypeForNonCagedHeapPolicy() = delete;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct WriteBarrierTypeForNonCagedHeapPolicy::ValueModeDispatch<
|
||||
WriteBarrier::ValueMode::kValuePresent> {
|
||||
template <typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void*, const void* object,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
// The following check covers nullptr as well as sentinel pointer.
|
||||
if (object <= static_cast<void*>(kSentinelPointer)) {
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
}
|
||||
if (V8_LIKELY(!WriteBarrier::IsEnabled())) {
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
}
|
||||
// We know that |object| is within the normal page or in the beginning of a
|
||||
// large page, so extract the page header by bitmasking.
|
||||
BasePageHandle* page =
|
||||
BasePageHandle::FromPayload(const_cast<void*>(object));
|
||||
|
||||
HeapHandle& heap_handle = page->heap_handle();
|
||||
if (V8_LIKELY(heap_handle.is_incremental_marking_in_progress())) {
|
||||
return SetAndReturnType<WriteBarrier::Type::kMarking>(params);
|
||||
}
|
||||
return SetAndReturnType<WriteBarrier::Type::kNone>(params);
|
||||
}
|
||||
};
|
||||
|
||||
template <>
|
||||
struct WriteBarrierTypeForNonCagedHeapPolicy::ValueModeDispatch<
|
||||
WriteBarrier::ValueMode::kNoValuePresent> {
|
||||
template <typename HeapHandleCallback>
|
||||
static V8_INLINE WriteBarrier::Type Get(const void*, const void*,
|
||||
WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
if (V8_UNLIKELY(WriteBarrier::IsEnabled())) {
|
||||
HeapHandle& handle = callback();
|
||||
if (V8_LIKELY(handle.is_incremental_marking_in_progress())) {
|
||||
params.heap = &handle;
|
||||
return SetAndReturnType<WriteBarrier::Type::kMarking>(params);
|
||||
}
|
||||
}
|
||||
return WriteBarrier::Type::kNone;
|
||||
}
|
||||
};
|
||||
|
||||
// static
|
||||
WriteBarrier::Type WriteBarrier::GetWriteBarrierType(
|
||||
const void* slot, const void* value, WriteBarrier::Params& params) {
|
||||
return WriteBarrierTypePolicy::Get<ValueMode::kValuePresent>(slot, value,
|
||||
params, []() {});
|
||||
}
|
||||
|
||||
// static
|
||||
template <typename MemberStorage>
|
||||
WriteBarrier::Type WriteBarrier::GetWriteBarrierType(
|
||||
const void* slot, MemberStorage value, WriteBarrier::Params& params) {
|
||||
return WriteBarrierTypePolicy::Get<ValueMode::kValuePresent>(slot, value,
|
||||
params, []() {});
|
||||
}
|
||||
|
||||
// static
|
||||
template <typename HeapHandleCallback>
|
||||
WriteBarrier::Type WriteBarrier::GetWriteBarrierType(
|
||||
const void* slot, WriteBarrier::Params& params,
|
||||
HeapHandleCallback callback) {
|
||||
return WriteBarrierTypePolicy::Get<ValueMode::kNoValuePresent>(
|
||||
slot, nullptr, params, callback);
|
||||
}
|
||||
|
||||
// static
|
||||
WriteBarrier::Type WriteBarrier::GetWriteBarrierType(
|
||||
const void* value, WriteBarrier::Params& params) {
|
||||
return WriteBarrierTypePolicy::Get<ValueMode::kValuePresent>(value, params,
|
||||
[]() {});
|
||||
}
|
||||
|
||||
// static
|
||||
void WriteBarrier::DijkstraMarkingBarrier(const Params& params,
|
||||
const void* object) {
|
||||
CheckParams(Type::kMarking, params);
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
// Caged heap already filters out sentinels.
|
||||
DijkstraMarkingBarrierSlow(object);
|
||||
#else // !CPPGC_CAGED_HEAP
|
||||
DijkstraMarkingBarrierSlowWithSentinelCheck(object);
|
||||
#endif // !CPPGC_CAGED_HEAP
|
||||
}
|
||||
|
||||
// static
|
||||
void WriteBarrier::DijkstraMarkingBarrierRange(const Params& params,
|
||||
const void* first_element,
|
||||
size_t element_size,
|
||||
size_t number_of_elements,
|
||||
TraceCallback trace_callback) {
|
||||
CheckParams(Type::kMarking, params);
|
||||
DijkstraMarkingBarrierRangeSlow(*params.heap, first_element, element_size,
|
||||
number_of_elements, trace_callback);
|
||||
}
|
||||
|
||||
// static
|
||||
void WriteBarrier::SteeleMarkingBarrier(const Params& params,
|
||||
const void* object) {
|
||||
CheckParams(Type::kMarking, params);
|
||||
#if defined(CPPGC_CAGED_HEAP)
|
||||
// Caged heap already filters out sentinels.
|
||||
SteeleMarkingBarrierSlow(object);
|
||||
#else // !CPPGC_CAGED_HEAP
|
||||
SteeleMarkingBarrierSlowWithSentinelCheck(object);
|
||||
#endif // !CPPGC_CAGED_HEAP
|
||||
}
|
||||
|
||||
#if defined(CPPGC_YOUNG_GENERATION)
|
||||
|
||||
// static
|
||||
template <WriteBarrier::GenerationalBarrierType type>
|
||||
void WriteBarrier::GenerationalBarrier(const Params& params, const void* slot) {
|
||||
CheckParams(Type::kGenerational, params);
|
||||
|
||||
const CagedHeapLocalData& local_data = CagedHeapLocalData::Get();
|
||||
const AgeTable& age_table = local_data.age_table;
|
||||
|
||||
// Bail out if the slot (precise or imprecise) is in young generation.
|
||||
if (V8_LIKELY(age_table.GetAge(params.slot_offset) == AgeTable::Age::kYoung))
|
||||
return;
|
||||
|
||||
// Dispatch between different types of barriers.
|
||||
// TODO(chromium:1029379): Consider reload local_data in the slow path to
|
||||
// reduce register pressure.
|
||||
if constexpr (type == GenerationalBarrierType::kPreciseSlot) {
|
||||
GenerationalBarrierSlow(local_data, age_table, slot, params.value_offset,
|
||||
params.heap);
|
||||
} else if constexpr (type ==
|
||||
GenerationalBarrierType::kPreciseUncompressedSlot) {
|
||||
GenerationalBarrierForUncompressedSlotSlow(
|
||||
local_data, age_table, slot, params.value_offset, params.heap);
|
||||
} else {
|
||||
GenerationalBarrierForSourceObjectSlow(local_data, slot, params.heap);
|
||||
}
|
||||
}
|
||||
|
||||
#endif // !CPPGC_YOUNG_GENERATION
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_INTERNAL_WRITE_BARRIER_H_
|
||||
78
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/liveness-broker.h
generated
vendored
Normal file
78
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/liveness-broker.h
generated
vendored
Normal file
@@ -0,0 +1,78 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_LIVENESS_BROKER_H_
|
||||
#define INCLUDE_CPPGC_LIVENESS_BROKER_H_
|
||||
|
||||
#include "cppgc/heap.h"
|
||||
#include "cppgc/member.h"
|
||||
#include "cppgc/sentinel-pointer.h"
|
||||
#include "cppgc/trace-trait.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
namespace internal {
|
||||
class LivenessBrokerFactory;
|
||||
} // namespace internal
|
||||
|
||||
/**
|
||||
* The broker is passed to weak callbacks to allow (temporarily) querying
|
||||
* the liveness state of an object. References to non-live objects must be
|
||||
* cleared when `IsHeapObjectAlive()` returns false.
|
||||
*
|
||||
* \code
|
||||
* class GCedWithCustomWeakCallback final
|
||||
* : public GarbageCollected<GCedWithCustomWeakCallback> {
|
||||
* public:
|
||||
* UntracedMember<Bar> bar;
|
||||
*
|
||||
* void CustomWeakCallbackMethod(const LivenessBroker& broker) {
|
||||
* if (!broker.IsHeapObjectAlive(bar))
|
||||
* bar = nullptr;
|
||||
* }
|
||||
*
|
||||
* void Trace(cppgc::Visitor* visitor) const {
|
||||
* visitor->RegisterWeakCallbackMethod<
|
||||
* GCedWithCustomWeakCallback,
|
||||
* &GCedWithCustomWeakCallback::CustomWeakCallbackMethod>(this);
|
||||
* }
|
||||
* };
|
||||
* \endcode
|
||||
*/
|
||||
class V8_EXPORT LivenessBroker final {
|
||||
public:
|
||||
template <typename T>
|
||||
bool IsHeapObjectAlive(const T* object) const {
|
||||
// - nullptr objects are considered alive to allow weakness to be used from
|
||||
// stack while running into a conservative GC. Treating nullptr as dead
|
||||
// would mean that e.g. custom collections could not be strongified on
|
||||
// stack.
|
||||
// - Sentinel pointers are also preserved in weakness and not cleared.
|
||||
return !object || object == kSentinelPointer ||
|
||||
IsHeapObjectAliveImpl(
|
||||
TraceTrait<T>::GetTraceDescriptor(object).base_object_payload);
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
bool IsHeapObjectAlive(const WeakMember<T>& weak_member) const {
|
||||
return IsHeapObjectAlive<T>(weak_member.Get());
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
bool IsHeapObjectAlive(const UntracedMember<T>& untraced_member) const {
|
||||
return IsHeapObjectAlive<T>(untraced_member.Get());
|
||||
}
|
||||
|
||||
private:
|
||||
LivenessBroker() = default;
|
||||
|
||||
bool IsHeapObjectAliveImpl(const void*) const;
|
||||
|
||||
friend class internal::LivenessBrokerFactory;
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_LIVENESS_BROKER_H_
|
||||
35
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/macros.h
generated
vendored
Normal file
35
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/macros.h
generated
vendored
Normal file
@@ -0,0 +1,35 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_MACROS_H_
|
||||
#define INCLUDE_CPPGC_MACROS_H_
|
||||
|
||||
#include <cstddef>
|
||||
|
||||
#include "cppgc/internal/compiler-specific.h"
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
// Use CPPGC_STACK_ALLOCATED if the object is only stack allocated.
|
||||
// Add the CPPGC_STACK_ALLOCATED_IGNORE annotation on a case-by-case basis when
|
||||
// enforcement of CPPGC_STACK_ALLOCATED should be suppressed.
|
||||
#if defined(__clang__)
|
||||
#define CPPGC_STACK_ALLOCATED() \
|
||||
public: \
|
||||
using IsStackAllocatedTypeMarker CPPGC_UNUSED = int; \
|
||||
\
|
||||
private: \
|
||||
void* operator new(size_t) = delete; \
|
||||
void* operator new(size_t, void*) = delete; \
|
||||
static_assert(true, "Force semicolon.")
|
||||
#define CPPGC_STACK_ALLOCATED_IGNORE(bug_or_reason) \
|
||||
__attribute__((annotate("stack_allocated_ignore")))
|
||||
#else // !defined(__clang__)
|
||||
#define CPPGC_STACK_ALLOCATED() static_assert(true, "Force semicolon.")
|
||||
#define CPPGC_STACK_ALLOCATED_IGNORE(bug_or_reason)
|
||||
#endif // !defined(__clang__)
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_MACROS_H_
|
||||
629
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/member.h
generated
vendored
Normal file
629
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/member.h
generated
vendored
Normal file
@@ -0,0 +1,629 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_MEMBER_H_
|
||||
#define INCLUDE_CPPGC_MEMBER_H_
|
||||
|
||||
#include <atomic>
|
||||
#include <cstddef>
|
||||
#include <type_traits>
|
||||
|
||||
#include "cppgc/internal/api-constants.h"
|
||||
#include "cppgc/internal/member-storage.h"
|
||||
#include "cppgc/internal/pointer-policies.h"
|
||||
#include "cppgc/sentinel-pointer.h"
|
||||
#include "cppgc/type-traits.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
namespace subtle {
|
||||
class HeapConsistency;
|
||||
} // namespace subtle
|
||||
|
||||
class Visitor;
|
||||
|
||||
namespace internal {
|
||||
|
||||
// MemberBase always refers to the object as const object and defers to
|
||||
// BasicMember on casting to the right type as needed.
|
||||
template <typename StorageType>
|
||||
class V8_TRIVIAL_ABI MemberBase {
|
||||
public:
|
||||
using RawStorage = StorageType;
|
||||
|
||||
protected:
|
||||
struct AtomicInitializerTag {};
|
||||
|
||||
V8_INLINE MemberBase() = default;
|
||||
V8_INLINE explicit MemberBase(const void* value) : raw_(value) {}
|
||||
V8_INLINE MemberBase(const void* value, AtomicInitializerTag) {
|
||||
SetRawAtomic(value);
|
||||
}
|
||||
|
||||
V8_INLINE explicit MemberBase(RawStorage raw) : raw_(raw) {}
|
||||
V8_INLINE explicit MemberBase(std::nullptr_t) : raw_(nullptr) {}
|
||||
V8_INLINE explicit MemberBase(SentinelPointer s) : raw_(s) {}
|
||||
|
||||
V8_INLINE const void** GetRawSlot() const {
|
||||
return reinterpret_cast<const void**>(const_cast<MemberBase*>(this));
|
||||
}
|
||||
V8_INLINE const void* GetRaw() const { return raw_.Load(); }
|
||||
V8_INLINE void SetRaw(void* value) { raw_.Store(value); }
|
||||
|
||||
V8_INLINE const void* GetRawAtomic() const { return raw_.LoadAtomic(); }
|
||||
V8_INLINE void SetRawAtomic(const void* value) { raw_.StoreAtomic(value); }
|
||||
|
||||
V8_INLINE RawStorage GetRawStorage() const { return raw_; }
|
||||
V8_INLINE void SetRawStorageAtomic(RawStorage other) {
|
||||
reinterpret_cast<std::atomic<RawStorage>&>(raw_).store(
|
||||
other, std::memory_order_relaxed);
|
||||
}
|
||||
|
||||
V8_INLINE bool IsCleared() const { return raw_.IsCleared(); }
|
||||
|
||||
V8_INLINE void ClearFromGC() const { raw_.Clear(); }
|
||||
|
||||
private:
|
||||
friend class MemberDebugHelper;
|
||||
|
||||
mutable RawStorage raw_;
|
||||
};
|
||||
|
||||
// The basic class from which all Member classes are 'generated'.
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
class V8_TRIVIAL_ABI BasicMember final : private MemberBase<StorageType>,
|
||||
private CheckingPolicy {
|
||||
using Base = MemberBase<StorageType>;
|
||||
|
||||
public:
|
||||
using PointeeType = T;
|
||||
using RawStorage = typename Base::RawStorage;
|
||||
|
||||
V8_INLINE constexpr BasicMember() = default;
|
||||
V8_INLINE constexpr BasicMember(std::nullptr_t) {} // NOLINT
|
||||
V8_INLINE BasicMember(SentinelPointer s) : Base(s) {} // NOLINT
|
||||
V8_INLINE BasicMember(T* raw) : Base(raw) { // NOLINT
|
||||
InitializingWriteBarrier(raw);
|
||||
this->CheckPointer(Get());
|
||||
}
|
||||
V8_INLINE BasicMember(T& raw) // NOLINT
|
||||
: BasicMember(&raw) {}
|
||||
|
||||
// Atomic ctor. Using the AtomicInitializerTag forces BasicMember to
|
||||
// initialize using atomic assignments. This is required for preventing
|
||||
// data races with concurrent marking.
|
||||
using AtomicInitializerTag = typename Base::AtomicInitializerTag;
|
||||
V8_INLINE BasicMember(std::nullptr_t, AtomicInitializerTag atomic)
|
||||
: Base(nullptr, atomic) {}
|
||||
V8_INLINE BasicMember(SentinelPointer s, AtomicInitializerTag atomic)
|
||||
: Base(s, atomic) {}
|
||||
V8_INLINE BasicMember(T* raw, AtomicInitializerTag atomic)
|
||||
: Base(raw, atomic) {
|
||||
InitializingWriteBarrier(raw);
|
||||
this->CheckPointer(Get());
|
||||
}
|
||||
V8_INLINE BasicMember(T& raw, AtomicInitializerTag atomic)
|
||||
: BasicMember(&raw, atomic) {}
|
||||
|
||||
// Copy ctor.
|
||||
V8_INLINE BasicMember(const BasicMember& other)
|
||||
: BasicMember(other.GetRawStorage()) {}
|
||||
|
||||
// Heterogeneous copy constructors. When the source pointer have a different
|
||||
// type, perform a compress-decompress round, because the source pointer may
|
||||
// need to be adjusted.
|
||||
template <typename U, typename OtherBarrierPolicy, typename OtherWeaknessTag,
|
||||
typename OtherCheckingPolicy,
|
||||
std::enable_if_t<internal::IsDecayedSameV<T, U>>* = nullptr>
|
||||
V8_INLINE BasicMember( // NOLINT
|
||||
const BasicMember<U, OtherWeaknessTag, OtherBarrierPolicy,
|
||||
OtherCheckingPolicy, StorageType>& other)
|
||||
: BasicMember(other.GetRawStorage()) {}
|
||||
|
||||
template <typename U, typename OtherBarrierPolicy, typename OtherWeaknessTag,
|
||||
typename OtherCheckingPolicy,
|
||||
std::enable_if_t<internal::IsStrictlyBaseOfV<T, U>>* = nullptr>
|
||||
V8_INLINE BasicMember( // NOLINT
|
||||
const BasicMember<U, OtherWeaknessTag, OtherBarrierPolicy,
|
||||
OtherCheckingPolicy, StorageType>& other)
|
||||
: BasicMember(other.Get()) {}
|
||||
|
||||
// Move ctor.
|
||||
V8_INLINE BasicMember(BasicMember&& other) noexcept
|
||||
: BasicMember(other.GetRawStorage()) {
|
||||
other.Clear();
|
||||
}
|
||||
|
||||
// Heterogeneous move constructors. When the source pointer have a different
|
||||
// type, perform a compress-decompress round, because the source pointer may
|
||||
// need to be adjusted.
|
||||
template <typename U, typename OtherBarrierPolicy, typename OtherWeaknessTag,
|
||||
typename OtherCheckingPolicy,
|
||||
std::enable_if_t<internal::IsDecayedSameV<T, U>>* = nullptr>
|
||||
V8_INLINE BasicMember(
|
||||
BasicMember<U, OtherWeaknessTag, OtherBarrierPolicy, OtherCheckingPolicy,
|
||||
StorageType>&& other) noexcept
|
||||
: BasicMember(other.GetRawStorage()) {
|
||||
other.Clear();
|
||||
}
|
||||
|
||||
template <typename U, typename OtherBarrierPolicy, typename OtherWeaknessTag,
|
||||
typename OtherCheckingPolicy,
|
||||
std::enable_if_t<internal::IsStrictlyBaseOfV<T, U>>* = nullptr>
|
||||
V8_INLINE BasicMember(
|
||||
BasicMember<U, OtherWeaknessTag, OtherBarrierPolicy, OtherCheckingPolicy,
|
||||
StorageType>&& other) noexcept
|
||||
: BasicMember(other.Get()) {
|
||||
other.Clear();
|
||||
}
|
||||
|
||||
// Construction from Persistent.
|
||||
template <typename U, typename PersistentWeaknessPolicy,
|
||||
typename PersistentLocationPolicy,
|
||||
typename PersistentCheckingPolicy,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
V8_INLINE BasicMember(const BasicPersistent<U, PersistentWeaknessPolicy,
|
||||
PersistentLocationPolicy,
|
||||
PersistentCheckingPolicy>& p)
|
||||
: BasicMember(p.Get()) {}
|
||||
|
||||
// Copy assignment.
|
||||
V8_INLINE BasicMember& operator=(const BasicMember& other) {
|
||||
return operator=(other.GetRawStorage());
|
||||
}
|
||||
|
||||
// Heterogeneous copy assignment. When the source pointer have a different
|
||||
// type, perform a compress-decompress round, because the source pointer may
|
||||
// need to be adjusted.
|
||||
template <typename U, typename OtherWeaknessTag, typename OtherBarrierPolicy,
|
||||
typename OtherCheckingPolicy>
|
||||
V8_INLINE BasicMember& operator=(
|
||||
const BasicMember<U, OtherWeaknessTag, OtherBarrierPolicy,
|
||||
OtherCheckingPolicy, StorageType>& other) {
|
||||
if constexpr (internal::IsDecayedSameV<T, U>) {
|
||||
return operator=(other.GetRawStorage());
|
||||
} else {
|
||||
static_assert(internal::IsStrictlyBaseOfV<T, U>);
|
||||
return operator=(other.Get());
|
||||
}
|
||||
}
|
||||
|
||||
// Move assignment.
|
||||
V8_INLINE BasicMember& operator=(BasicMember&& other) noexcept {
|
||||
operator=(other.GetRawStorage());
|
||||
other.Clear();
|
||||
return *this;
|
||||
}
|
||||
|
||||
// Heterogeneous move assignment. When the source pointer have a different
|
||||
// type, perform a compress-decompress round, because the source pointer may
|
||||
// need to be adjusted.
|
||||
template <typename U, typename OtherWeaknessTag, typename OtherBarrierPolicy,
|
||||
typename OtherCheckingPolicy>
|
||||
V8_INLINE BasicMember& operator=(
|
||||
BasicMember<U, OtherWeaknessTag, OtherBarrierPolicy, OtherCheckingPolicy,
|
||||
StorageType>&& other) noexcept {
|
||||
if constexpr (internal::IsDecayedSameV<T, U>) {
|
||||
operator=(other.GetRawStorage());
|
||||
} else {
|
||||
static_assert(internal::IsStrictlyBaseOfV<T, U>);
|
||||
operator=(other.Get());
|
||||
}
|
||||
other.Clear();
|
||||
return *this;
|
||||
}
|
||||
|
||||
// Assignment from Persistent.
|
||||
template <typename U, typename PersistentWeaknessPolicy,
|
||||
typename PersistentLocationPolicy,
|
||||
typename PersistentCheckingPolicy,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
V8_INLINE BasicMember& operator=(
|
||||
const BasicPersistent<U, PersistentWeaknessPolicy,
|
||||
PersistentLocationPolicy, PersistentCheckingPolicy>&
|
||||
other) {
|
||||
return operator=(other.Get());
|
||||
}
|
||||
|
||||
V8_INLINE BasicMember& operator=(T* other) {
|
||||
Base::SetRawAtomic(other);
|
||||
AssigningWriteBarrier(other);
|
||||
this->CheckPointer(Get());
|
||||
return *this;
|
||||
}
|
||||
|
||||
V8_INLINE BasicMember& operator=(std::nullptr_t) {
|
||||
Clear();
|
||||
return *this;
|
||||
}
|
||||
V8_INLINE BasicMember& operator=(SentinelPointer s) {
|
||||
Base::SetRawAtomic(s);
|
||||
return *this;
|
||||
}
|
||||
|
||||
template <typename OtherWeaknessTag, typename OtherBarrierPolicy,
|
||||
typename OtherCheckingPolicy>
|
||||
V8_INLINE void Swap(BasicMember<T, OtherWeaknessTag, OtherBarrierPolicy,
|
||||
OtherCheckingPolicy, StorageType>& other) {
|
||||
auto tmp = GetRawStorage();
|
||||
*this = other;
|
||||
other = tmp;
|
||||
}
|
||||
|
||||
V8_INLINE explicit operator bool() const { return !Base::IsCleared(); }
|
||||
V8_INLINE operator T*() const { return Get(); }
|
||||
V8_INLINE T* operator->() const { return Get(); }
|
||||
V8_INLINE T& operator*() const { return *Get(); }
|
||||
|
||||
// CFI cast exemption to allow passing SentinelPointer through T* and support
|
||||
// heterogeneous assignments between different Member and Persistent handles
|
||||
// based on their actual types.
|
||||
V8_INLINE V8_CLANG_NO_SANITIZE("cfi-unrelated-cast") T* Get() const {
|
||||
// Executed by the mutator, hence non atomic load.
|
||||
//
|
||||
// The const_cast below removes the constness from MemberBase storage. The
|
||||
// following static_cast re-adds any constness if specified through the
|
||||
// user-visible template parameter T.
|
||||
return static_cast<T*>(const_cast<void*>(Base::GetRaw()));
|
||||
}
|
||||
|
||||
V8_INLINE void Clear() {
|
||||
Base::SetRawStorageAtomic(RawStorage{});
|
||||
}
|
||||
|
||||
V8_INLINE T* Release() {
|
||||
T* result = Get();
|
||||
Clear();
|
||||
return result;
|
||||
}
|
||||
|
||||
V8_INLINE const T** GetSlotForTesting() const {
|
||||
return reinterpret_cast<const T**>(Base::GetRawSlot());
|
||||
}
|
||||
|
||||
V8_INLINE RawStorage GetRawStorage() const {
|
||||
return Base::GetRawStorage();
|
||||
}
|
||||
|
||||
private:
|
||||
V8_INLINE explicit BasicMember(RawStorage raw) : Base(raw) {
|
||||
InitializingWriteBarrier(Get());
|
||||
this->CheckPointer(Get());
|
||||
}
|
||||
|
||||
V8_INLINE BasicMember& operator=(RawStorage other) {
|
||||
Base::SetRawStorageAtomic(other);
|
||||
AssigningWriteBarrier();
|
||||
this->CheckPointer(Get());
|
||||
return *this;
|
||||
}
|
||||
|
||||
V8_INLINE const T* GetRawAtomic() const {
|
||||
return static_cast<const T*>(Base::GetRawAtomic());
|
||||
}
|
||||
|
||||
V8_INLINE void InitializingWriteBarrier(T* value) const {
|
||||
WriteBarrierPolicy::InitializingBarrier(Base::GetRawSlot(), value);
|
||||
}
|
||||
V8_INLINE void AssigningWriteBarrier(T* value) const {
|
||||
WriteBarrierPolicy::template AssigningBarrier<
|
||||
StorageType::kWriteBarrierSlotType>(Base::GetRawSlot(), value);
|
||||
}
|
||||
V8_INLINE void AssigningWriteBarrier() const {
|
||||
WriteBarrierPolicy::template AssigningBarrier<
|
||||
StorageType::kWriteBarrierSlotType>(Base::GetRawSlot(),
|
||||
Base::GetRawStorage());
|
||||
}
|
||||
|
||||
V8_INLINE void ClearFromGC() const { Base::ClearFromGC(); }
|
||||
|
||||
V8_INLINE T* GetFromGC() const { return Get(); }
|
||||
|
||||
friend class cppgc::subtle::HeapConsistency;
|
||||
friend class cppgc::Visitor;
|
||||
template <typename U>
|
||||
friend struct cppgc::TraceTrait;
|
||||
template <typename T1, typename WeaknessTag1, typename WriteBarrierPolicy1,
|
||||
typename CheckingPolicy1, typename StorageType1>
|
||||
friend class BasicMember;
|
||||
};
|
||||
|
||||
// Member equality operators.
|
||||
template <typename T1, typename WeaknessTag1, typename WriteBarrierPolicy1,
|
||||
typename CheckingPolicy1, typename T2, typename WeaknessTag2,
|
||||
typename WriteBarrierPolicy2, typename CheckingPolicy2,
|
||||
typename StorageType>
|
||||
V8_INLINE bool operator==(
|
||||
const BasicMember<T1, WeaknessTag1, WriteBarrierPolicy1, CheckingPolicy1,
|
||||
StorageType>& member1,
|
||||
const BasicMember<T2, WeaknessTag2, WriteBarrierPolicy2, CheckingPolicy2,
|
||||
StorageType>& member2) {
|
||||
if constexpr (internal::IsDecayedSameV<T1, T2>) {
|
||||
// Check compressed pointers if types are the same.
|
||||
return member1.GetRawStorage() == member2.GetRawStorage();
|
||||
} else {
|
||||
static_assert(internal::IsStrictlyBaseOfV<T1, T2> ||
|
||||
internal::IsStrictlyBaseOfV<T2, T1>);
|
||||
// Otherwise, check decompressed pointers.
|
||||
return member1.Get() == member2.Get();
|
||||
}
|
||||
}
|
||||
|
||||
template <typename T1, typename WeaknessTag1, typename WriteBarrierPolicy1,
|
||||
typename CheckingPolicy1, typename T2, typename WeaknessTag2,
|
||||
typename WriteBarrierPolicy2, typename CheckingPolicy2,
|
||||
typename StorageType>
|
||||
V8_INLINE bool operator!=(
|
||||
const BasicMember<T1, WeaknessTag1, WriteBarrierPolicy1, CheckingPolicy1,
|
||||
StorageType>& member1,
|
||||
const BasicMember<T2, WeaknessTag2, WriteBarrierPolicy2, CheckingPolicy2,
|
||||
StorageType>& member2) {
|
||||
return !(member1 == member2);
|
||||
}
|
||||
|
||||
// Equality with raw pointers.
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType, typename U>
|
||||
V8_INLINE bool operator==(
|
||||
const BasicMember<T, WeaknessTag, WriteBarrierPolicy, CheckingPolicy,
|
||||
StorageType>& member,
|
||||
U* raw) {
|
||||
// Never allow comparison with erased pointers.
|
||||
static_assert(!internal::IsDecayedSameV<void, U>);
|
||||
|
||||
if constexpr (internal::IsDecayedSameV<T, U>) {
|
||||
// Check compressed pointers if types are the same.
|
||||
return member.GetRawStorage() == StorageType(raw);
|
||||
} else if constexpr (internal::IsStrictlyBaseOfV<T, U>) {
|
||||
// Cast the raw pointer to T, which may adjust the pointer.
|
||||
return member.GetRawStorage() == StorageType(static_cast<T*>(raw));
|
||||
} else {
|
||||
// Otherwise, decompressed the member.
|
||||
return member.Get() == raw;
|
||||
}
|
||||
}
|
||||
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType, typename U>
|
||||
V8_INLINE bool operator!=(
|
||||
const BasicMember<T, WeaknessTag, WriteBarrierPolicy, CheckingPolicy,
|
||||
StorageType>& member,
|
||||
U* raw) {
|
||||
return !(member == raw);
|
||||
}
|
||||
|
||||
template <typename T, typename U, typename WeaknessTag,
|
||||
typename WriteBarrierPolicy, typename CheckingPolicy,
|
||||
typename StorageType>
|
||||
V8_INLINE bool operator==(
|
||||
T* raw, const BasicMember<U, WeaknessTag, WriteBarrierPolicy,
|
||||
CheckingPolicy, StorageType>& member) {
|
||||
return member == raw;
|
||||
}
|
||||
|
||||
template <typename T, typename U, typename WeaknessTag,
|
||||
typename WriteBarrierPolicy, typename CheckingPolicy,
|
||||
typename StorageType>
|
||||
V8_INLINE bool operator!=(
|
||||
T* raw, const BasicMember<U, WeaknessTag, WriteBarrierPolicy,
|
||||
CheckingPolicy, StorageType>& member) {
|
||||
return !(raw == member);
|
||||
}
|
||||
|
||||
// Equality with sentinel.
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
V8_INLINE bool operator==(
|
||||
const BasicMember<T, WeaknessTag, WriteBarrierPolicy, CheckingPolicy,
|
||||
StorageType>& member,
|
||||
SentinelPointer) {
|
||||
return member.GetRawStorage().IsSentinel();
|
||||
}
|
||||
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
V8_INLINE bool operator!=(
|
||||
const BasicMember<T, WeaknessTag, WriteBarrierPolicy, CheckingPolicy,
|
||||
StorageType>& member,
|
||||
SentinelPointer s) {
|
||||
return !(member == s);
|
||||
}
|
||||
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
V8_INLINE bool operator==(
|
||||
SentinelPointer s, const BasicMember<T, WeaknessTag, WriteBarrierPolicy,
|
||||
CheckingPolicy, StorageType>& member) {
|
||||
return member == s;
|
||||
}
|
||||
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
V8_INLINE bool operator!=(
|
||||
SentinelPointer s, const BasicMember<T, WeaknessTag, WriteBarrierPolicy,
|
||||
CheckingPolicy, StorageType>& member) {
|
||||
return !(s == member);
|
||||
}
|
||||
|
||||
// Equality with nullptr.
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
V8_INLINE bool operator==(
|
||||
const BasicMember<T, WeaknessTag, WriteBarrierPolicy, CheckingPolicy,
|
||||
StorageType>& member,
|
||||
std::nullptr_t) {
|
||||
return !static_cast<bool>(member);
|
||||
}
|
||||
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
V8_INLINE bool operator!=(
|
||||
const BasicMember<T, WeaknessTag, WriteBarrierPolicy, CheckingPolicy,
|
||||
StorageType>& member,
|
||||
std::nullptr_t n) {
|
||||
return !(member == n);
|
||||
}
|
||||
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
V8_INLINE bool operator==(
|
||||
std::nullptr_t n, const BasicMember<T, WeaknessTag, WriteBarrierPolicy,
|
||||
CheckingPolicy, StorageType>& member) {
|
||||
return member == n;
|
||||
}
|
||||
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
V8_INLINE bool operator!=(
|
||||
std::nullptr_t n, const BasicMember<T, WeaknessTag, WriteBarrierPolicy,
|
||||
CheckingPolicy, StorageType>& member) {
|
||||
return !(n == member);
|
||||
}
|
||||
|
||||
// Relational operators.
|
||||
template <typename T1, typename WeaknessTag1, typename WriteBarrierPolicy1,
|
||||
typename CheckingPolicy1, typename T2, typename WeaknessTag2,
|
||||
typename WriteBarrierPolicy2, typename CheckingPolicy2,
|
||||
typename StorageType>
|
||||
V8_INLINE bool operator<(
|
||||
const BasicMember<T1, WeaknessTag1, WriteBarrierPolicy1, CheckingPolicy1,
|
||||
StorageType>& member1,
|
||||
const BasicMember<T2, WeaknessTag2, WriteBarrierPolicy2, CheckingPolicy2,
|
||||
StorageType>& member2) {
|
||||
static_assert(
|
||||
internal::IsDecayedSameV<T1, T2>,
|
||||
"Comparison works only for same pointer type modulo cv-qualifiers");
|
||||
return member1.GetRawStorage() < member2.GetRawStorage();
|
||||
}
|
||||
|
||||
template <typename T1, typename WeaknessTag1, typename WriteBarrierPolicy1,
|
||||
typename CheckingPolicy1, typename T2, typename WeaknessTag2,
|
||||
typename WriteBarrierPolicy2, typename CheckingPolicy2,
|
||||
typename StorageType>
|
||||
V8_INLINE bool operator<=(
|
||||
const BasicMember<T1, WeaknessTag1, WriteBarrierPolicy1, CheckingPolicy1,
|
||||
StorageType>& member1,
|
||||
const BasicMember<T2, WeaknessTag2, WriteBarrierPolicy2, CheckingPolicy2,
|
||||
StorageType>& member2) {
|
||||
static_assert(
|
||||
internal::IsDecayedSameV<T1, T2>,
|
||||
"Comparison works only for same pointer type modulo cv-qualifiers");
|
||||
return member1.GetRawStorage() <= member2.GetRawStorage();
|
||||
}
|
||||
|
||||
template <typename T1, typename WeaknessTag1, typename WriteBarrierPolicy1,
|
||||
typename CheckingPolicy1, typename T2, typename WeaknessTag2,
|
||||
typename WriteBarrierPolicy2, typename CheckingPolicy2,
|
||||
typename StorageType>
|
||||
V8_INLINE bool operator>(
|
||||
const BasicMember<T1, WeaknessTag1, WriteBarrierPolicy1, CheckingPolicy1,
|
||||
StorageType>& member1,
|
||||
const BasicMember<T2, WeaknessTag2, WriteBarrierPolicy2, CheckingPolicy2,
|
||||
StorageType>& member2) {
|
||||
static_assert(
|
||||
internal::IsDecayedSameV<T1, T2>,
|
||||
"Comparison works only for same pointer type modulo cv-qualifiers");
|
||||
return member1.GetRawStorage() > member2.GetRawStorage();
|
||||
}
|
||||
|
||||
template <typename T1, typename WeaknessTag1, typename WriteBarrierPolicy1,
|
||||
typename CheckingPolicy1, typename T2, typename WeaknessTag2,
|
||||
typename WriteBarrierPolicy2, typename CheckingPolicy2,
|
||||
typename StorageType>
|
||||
V8_INLINE bool operator>=(
|
||||
const BasicMember<T1, WeaknessTag1, WriteBarrierPolicy1, CheckingPolicy1,
|
||||
StorageType>& member1,
|
||||
const BasicMember<T2, WeaknessTag2, WriteBarrierPolicy2, CheckingPolicy2,
|
||||
StorageType>& member2) {
|
||||
static_assert(
|
||||
internal::IsDecayedSameV<T1, T2>,
|
||||
"Comparison works only for same pointer type modulo cv-qualifiers");
|
||||
return member1.GetRawStorage() >= member2.GetRawStorage();
|
||||
}
|
||||
|
||||
template <typename T, typename WriteBarrierPolicy, typename CheckingPolicy,
|
||||
typename StorageType>
|
||||
struct IsWeak<internal::BasicMember<T, WeakMemberTag, WriteBarrierPolicy,
|
||||
CheckingPolicy, StorageType>>
|
||||
: std::true_type {};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
/**
|
||||
* Members are used in classes to contain strong pointers to other garbage
|
||||
* collected objects. All Member fields of a class must be traced in the class'
|
||||
* trace method.
|
||||
*/
|
||||
template <typename T>
|
||||
using Member = internal::BasicMember<
|
||||
T, internal::StrongMemberTag, internal::DijkstraWriteBarrierPolicy,
|
||||
internal::DefaultMemberCheckingPolicy, internal::DefaultMemberStorage>;
|
||||
|
||||
/**
|
||||
* WeakMember is similar to Member in that it is used to point to other garbage
|
||||
* collected objects. However instead of creating a strong pointer to the
|
||||
* object, the WeakMember creates a weak pointer, which does not keep the
|
||||
* pointee alive. Hence if all pointers to to a heap allocated object are weak
|
||||
* the object will be garbage collected. At the time of GC the weak pointers
|
||||
* will automatically be set to null.
|
||||
*/
|
||||
template <typename T>
|
||||
using WeakMember = internal::BasicMember<
|
||||
T, internal::WeakMemberTag, internal::DijkstraWriteBarrierPolicy,
|
||||
internal::DefaultMemberCheckingPolicy, internal::DefaultMemberStorage>;
|
||||
|
||||
/**
|
||||
* UntracedMember is a pointer to an on-heap object that is not traced for some
|
||||
* reason. Do not use this unless you know what you are doing. Keeping raw
|
||||
* pointers to on-heap objects is prohibited unless used from stack. Pointee
|
||||
* must be kept alive through other means.
|
||||
*/
|
||||
template <typename T>
|
||||
using UntracedMember = internal::BasicMember<
|
||||
T, internal::UntracedMemberTag, internal::NoWriteBarrierPolicy,
|
||||
internal::DefaultMemberCheckingPolicy, internal::DefaultMemberStorage>;
|
||||
|
||||
namespace subtle {
|
||||
|
||||
/**
|
||||
* UncompressedMember. Use with care in hot paths that would otherwise cause
|
||||
* many decompression cycles.
|
||||
*/
|
||||
template <typename T>
|
||||
using UncompressedMember = internal::BasicMember<
|
||||
T, internal::StrongMemberTag, internal::DijkstraWriteBarrierPolicy,
|
||||
internal::DefaultMemberCheckingPolicy, internal::RawPointer>;
|
||||
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
/**
|
||||
* CompressedMember. Default implementation of cppgc::Member on builds with
|
||||
* pointer compression.
|
||||
*/
|
||||
template <typename T>
|
||||
using CompressedMember = internal::BasicMember<
|
||||
T, internal::StrongMemberTag, internal::DijkstraWriteBarrierPolicy,
|
||||
internal::DefaultMemberCheckingPolicy, internal::CompressedPointer>;
|
||||
#endif // defined(CPPGC_POINTER_COMPRESSION)
|
||||
|
||||
} // namespace subtle
|
||||
|
||||
namespace internal {
|
||||
|
||||
struct Dummy;
|
||||
|
||||
static constexpr size_t kSizeOfMember = sizeof(Member<Dummy>);
|
||||
static constexpr size_t kSizeOfUncompressedMember =
|
||||
sizeof(subtle::UncompressedMember<Dummy>);
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
static constexpr size_t kSizeofCompressedMember =
|
||||
sizeof(subtle::CompressedMember<Dummy>);
|
||||
#endif // defined(CPPGC_POINTER_COMPRESSION)
|
||||
|
||||
} // namespace internal
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_MEMBER_H_
|
||||
65
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/name-provider.h
generated
vendored
Normal file
65
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/name-provider.h
generated
vendored
Normal file
@@ -0,0 +1,65 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_NAME_PROVIDER_H_
|
||||
#define INCLUDE_CPPGC_NAME_PROVIDER_H_
|
||||
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
/**
|
||||
* NameProvider allows for providing a human-readable name for garbage-collected
|
||||
* objects.
|
||||
*
|
||||
* There's two cases of names to distinguish:
|
||||
* a. Explicitly specified names via using NameProvider. Such names are always
|
||||
* preserved in the system.
|
||||
* b. Internal names that Oilpan infers from a C++ type on the class hierarchy
|
||||
* of the object. This is not necessarily the type of the actually
|
||||
* instantiated object.
|
||||
*
|
||||
* Depending on the build configuration, Oilpan may hide names, i.e., represent
|
||||
* them with kHiddenName, of case b. to avoid exposing internal details.
|
||||
*/
|
||||
class V8_EXPORT NameProvider {
|
||||
public:
|
||||
/**
|
||||
* Name that is used when hiding internals.
|
||||
*/
|
||||
static constexpr const char kHiddenName[] = "InternalNode";
|
||||
|
||||
/**
|
||||
* Name that is used in case compiler support is missing for composing a name
|
||||
* from C++ types.
|
||||
*/
|
||||
static constexpr const char kNoNameDeducible[] = "<No name>";
|
||||
|
||||
/**
|
||||
* Indicating whether the build supports extracting C++ names as object names.
|
||||
*
|
||||
* @returns true if C++ names should be hidden and represented by kHiddenName.
|
||||
*/
|
||||
static constexpr bool SupportsCppClassNamesAsObjectNames() {
|
||||
#if CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
return true;
|
||||
#else // !CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
return false;
|
||||
#endif // !CPPGC_SUPPORTS_OBJECT_NAMES
|
||||
}
|
||||
|
||||
virtual ~NameProvider() = default;
|
||||
|
||||
/**
|
||||
* Specifies a name for the garbage-collected object. Such names will never
|
||||
* be hidden, as they are explicitly specified by the user of this API.
|
||||
*
|
||||
* @returns a human readable name for the object.
|
||||
*/
|
||||
virtual const char* GetHumanReadableName() const = 0;
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_NAME_PROVIDER_H_
|
||||
58
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/object-size-trait.h
generated
vendored
Normal file
58
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/object-size-trait.h
generated
vendored
Normal file
@@ -0,0 +1,58 @@
|
||||
// Copyright 2021 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_OBJECT_SIZE_TRAIT_H_
|
||||
#define INCLUDE_CPPGC_OBJECT_SIZE_TRAIT_H_
|
||||
|
||||
#include <cstddef>
|
||||
|
||||
#include "cppgc/type-traits.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
namespace internal {
|
||||
|
||||
struct V8_EXPORT BaseObjectSizeTrait {
|
||||
protected:
|
||||
static size_t GetObjectSizeForGarbageCollected(const void*);
|
||||
static size_t GetObjectSizeForGarbageCollectedMixin(const void*);
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
namespace subtle {
|
||||
|
||||
/**
|
||||
* Trait specifying how to get the size of an object that was allocated using
|
||||
* `MakeGarbageCollected()`. Also supports querying the size with an inner
|
||||
* pointer to a mixin.
|
||||
*/
|
||||
template <typename T, bool = IsGarbageCollectedMixinTypeV<T>>
|
||||
struct ObjectSizeTrait;
|
||||
|
||||
template <typename T>
|
||||
struct ObjectSizeTrait<T, false> : cppgc::internal::BaseObjectSizeTrait {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
static_assert(IsGarbageCollectedTypeV<T>,
|
||||
"T must be of type GarbageCollected or GarbageCollectedMixin");
|
||||
|
||||
static size_t GetSize(const T& object) {
|
||||
return GetObjectSizeForGarbageCollected(&object);
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct ObjectSizeTrait<T, true> : cppgc::internal::BaseObjectSizeTrait {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
|
||||
static size_t GetSize(const T& object) {
|
||||
return GetObjectSizeForGarbageCollectedMixin(&object);
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace subtle
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_OBJECT_SIZE_TRAIT_H_
|
||||
377
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/persistent.h
generated
vendored
Normal file
377
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/persistent.h
generated
vendored
Normal file
@@ -0,0 +1,377 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_PERSISTENT_H_
|
||||
#define INCLUDE_CPPGC_PERSISTENT_H_
|
||||
|
||||
#include <type_traits>
|
||||
|
||||
#include "cppgc/internal/persistent-node.h"
|
||||
#include "cppgc/internal/pointer-policies.h"
|
||||
#include "cppgc/sentinel-pointer.h"
|
||||
#include "cppgc/source-location.h"
|
||||
#include "cppgc/type-traits.h"
|
||||
#include "cppgc/visitor.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
// PersistentBase always refers to the object as const object and defers to
|
||||
// BasicPersistent on casting to the right type as needed.
|
||||
class PersistentBase {
|
||||
protected:
|
||||
PersistentBase() = default;
|
||||
explicit PersistentBase(const void* raw) : raw_(raw) {}
|
||||
|
||||
const void* GetValue() const { return raw_; }
|
||||
void SetValue(const void* value) { raw_ = value; }
|
||||
|
||||
PersistentNode* GetNode() const { return node_; }
|
||||
void SetNode(PersistentNode* node) { node_ = node; }
|
||||
|
||||
// Performs a shallow clear which assumes that internal persistent nodes are
|
||||
// destroyed elsewhere.
|
||||
void ClearFromGC() const {
|
||||
raw_ = nullptr;
|
||||
node_ = nullptr;
|
||||
}
|
||||
|
||||
protected:
|
||||
mutable const void* raw_ = nullptr;
|
||||
mutable PersistentNode* node_ = nullptr;
|
||||
|
||||
friend class PersistentRegionBase;
|
||||
};
|
||||
|
||||
// The basic class from which all Persistent classes are generated.
|
||||
template <typename T, typename WeaknessPolicy, typename LocationPolicy,
|
||||
typename CheckingPolicy>
|
||||
class BasicPersistent final : public PersistentBase,
|
||||
public LocationPolicy,
|
||||
private WeaknessPolicy,
|
||||
private CheckingPolicy {
|
||||
public:
|
||||
using typename WeaknessPolicy::IsStrongPersistent;
|
||||
using PointeeType = T;
|
||||
|
||||
// Null-state/sentinel constructors.
|
||||
BasicPersistent( // NOLINT
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: LocationPolicy(loc) {}
|
||||
|
||||
BasicPersistent(std::nullptr_t, // NOLINT
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: LocationPolicy(loc) {}
|
||||
|
||||
BasicPersistent( // NOLINT
|
||||
SentinelPointer s, const SourceLocation& loc = SourceLocation::Current())
|
||||
: PersistentBase(s), LocationPolicy(loc) {}
|
||||
|
||||
// Raw value constructors.
|
||||
BasicPersistent(T* raw, // NOLINT
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: PersistentBase(raw), LocationPolicy(loc) {
|
||||
if (!IsValid()) return;
|
||||
SetNode(WeaknessPolicy::GetPersistentRegion(GetValue())
|
||||
.AllocateNode(this, &TraceAsRoot));
|
||||
this->CheckPointer(Get());
|
||||
}
|
||||
|
||||
BasicPersistent(T& raw, // NOLINT
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: BasicPersistent(&raw, loc) {}
|
||||
|
||||
// Copy ctor.
|
||||
BasicPersistent(const BasicPersistent& other,
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: BasicPersistent(other.Get(), loc) {}
|
||||
|
||||
// Heterogeneous ctor.
|
||||
template <typename U, typename OtherWeaknessPolicy,
|
||||
typename OtherLocationPolicy, typename OtherCheckingPolicy,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
// NOLINTNEXTLINE
|
||||
BasicPersistent(
|
||||
const BasicPersistent<U, OtherWeaknessPolicy, OtherLocationPolicy,
|
||||
OtherCheckingPolicy>& other,
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: BasicPersistent(other.Get(), loc) {}
|
||||
|
||||
// Move ctor. The heterogeneous move ctor is not supported since e.g.
|
||||
// persistent can't reuse persistent node from weak persistent.
|
||||
BasicPersistent(
|
||||
BasicPersistent&& other,
|
||||
const SourceLocation& loc = SourceLocation::Current()) noexcept
|
||||
: PersistentBase(std::move(other)), LocationPolicy(std::move(other)) {
|
||||
if (!IsValid()) return;
|
||||
GetNode()->UpdateOwner(this);
|
||||
other.SetValue(nullptr);
|
||||
other.SetNode(nullptr);
|
||||
this->CheckPointer(Get());
|
||||
}
|
||||
|
||||
// Constructor from member.
|
||||
template <typename U, typename MemberBarrierPolicy,
|
||||
typename MemberWeaknessTag, typename MemberCheckingPolicy,
|
||||
typename MemberStorageType,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
// NOLINTNEXTLINE
|
||||
BasicPersistent(const internal::BasicMember<
|
||||
U, MemberBarrierPolicy, MemberWeaknessTag,
|
||||
MemberCheckingPolicy, MemberStorageType>& member,
|
||||
const SourceLocation& loc = SourceLocation::Current())
|
||||
: BasicPersistent(member.Get(), loc) {}
|
||||
|
||||
~BasicPersistent() { Clear(); }
|
||||
|
||||
// Copy assignment.
|
||||
BasicPersistent& operator=(const BasicPersistent& other) {
|
||||
return operator=(other.Get());
|
||||
}
|
||||
|
||||
template <typename U, typename OtherWeaknessPolicy,
|
||||
typename OtherLocationPolicy, typename OtherCheckingPolicy,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
BasicPersistent& operator=(
|
||||
const BasicPersistent<U, OtherWeaknessPolicy, OtherLocationPolicy,
|
||||
OtherCheckingPolicy>& other) {
|
||||
return operator=(other.Get());
|
||||
}
|
||||
|
||||
// Move assignment.
|
||||
BasicPersistent& operator=(BasicPersistent&& other) noexcept {
|
||||
if (this == &other) return *this;
|
||||
Clear();
|
||||
PersistentBase::operator=(std::move(other));
|
||||
LocationPolicy::operator=(std::move(other));
|
||||
if (!IsValid()) return *this;
|
||||
GetNode()->UpdateOwner(this);
|
||||
other.SetValue(nullptr);
|
||||
other.SetNode(nullptr);
|
||||
this->CheckPointer(Get());
|
||||
return *this;
|
||||
}
|
||||
|
||||
// Assignment from member.
|
||||
template <typename U, typename MemberBarrierPolicy,
|
||||
typename MemberWeaknessTag, typename MemberCheckingPolicy,
|
||||
typename MemberStorageType,
|
||||
typename = std::enable_if_t<std::is_base_of<T, U>::value>>
|
||||
BasicPersistent& operator=(
|
||||
const internal::BasicMember<U, MemberBarrierPolicy, MemberWeaknessTag,
|
||||
MemberCheckingPolicy, MemberStorageType>&
|
||||
member) {
|
||||
return operator=(member.Get());
|
||||
}
|
||||
|
||||
BasicPersistent& operator=(T* other) {
|
||||
Assign(other);
|
||||
return *this;
|
||||
}
|
||||
|
||||
BasicPersistent& operator=(std::nullptr_t) {
|
||||
Clear();
|
||||
return *this;
|
||||
}
|
||||
|
||||
BasicPersistent& operator=(SentinelPointer s) {
|
||||
Assign(s);
|
||||
return *this;
|
||||
}
|
||||
|
||||
explicit operator bool() const { return Get(); }
|
||||
// Historically we allow implicit conversions to T*.
|
||||
// NOLINTNEXTLINE
|
||||
operator T*() const { return Get(); }
|
||||
T* operator->() const { return Get(); }
|
||||
T& operator*() const { return *Get(); }
|
||||
|
||||
// CFI cast exemption to allow passing SentinelPointer through T* and support
|
||||
// heterogeneous assignments between different Member and Persistent handles
|
||||
// based on their actual types.
|
||||
V8_CLANG_NO_SANITIZE("cfi-unrelated-cast") T* Get() const {
|
||||
// The const_cast below removes the constness from PersistentBase storage.
|
||||
// The following static_cast re-adds any constness if specified through the
|
||||
// user-visible template parameter T.
|
||||
return static_cast<T*>(const_cast<void*>(GetValue()));
|
||||
}
|
||||
|
||||
void Clear() {
|
||||
// Simplified version of `Assign()` to allow calling without a complete type
|
||||
// `T`.
|
||||
if (IsValid()) {
|
||||
WeaknessPolicy::GetPersistentRegion(GetValue()).FreeNode(GetNode());
|
||||
SetNode(nullptr);
|
||||
}
|
||||
SetValue(nullptr);
|
||||
}
|
||||
|
||||
T* Release() {
|
||||
T* result = Get();
|
||||
Clear();
|
||||
return result;
|
||||
}
|
||||
|
||||
template <typename U, typename OtherWeaknessPolicy = WeaknessPolicy,
|
||||
typename OtherLocationPolicy = LocationPolicy,
|
||||
typename OtherCheckingPolicy = CheckingPolicy>
|
||||
BasicPersistent<U, OtherWeaknessPolicy, OtherLocationPolicy,
|
||||
OtherCheckingPolicy>
|
||||
To() const {
|
||||
return BasicPersistent<U, OtherWeaknessPolicy, OtherLocationPolicy,
|
||||
OtherCheckingPolicy>(static_cast<U*>(Get()));
|
||||
}
|
||||
|
||||
private:
|
||||
static void TraceAsRoot(RootVisitor& root_visitor, const void* ptr) {
|
||||
root_visitor.Trace(*static_cast<const BasicPersistent*>(ptr));
|
||||
}
|
||||
|
||||
bool IsValid() const {
|
||||
// Ideally, handling kSentinelPointer would be done by the embedder. On the
|
||||
// other hand, having Persistent aware of it is beneficial since no node
|
||||
// gets wasted.
|
||||
return GetValue() != nullptr && GetValue() != kSentinelPointer;
|
||||
}
|
||||
|
||||
void Assign(T* ptr) {
|
||||
if (IsValid()) {
|
||||
if (ptr && ptr != kSentinelPointer) {
|
||||
// Simply assign the pointer reusing the existing node.
|
||||
SetValue(ptr);
|
||||
this->CheckPointer(ptr);
|
||||
return;
|
||||
}
|
||||
WeaknessPolicy::GetPersistentRegion(GetValue()).FreeNode(GetNode());
|
||||
SetNode(nullptr);
|
||||
}
|
||||
SetValue(ptr);
|
||||
if (!IsValid()) return;
|
||||
SetNode(WeaknessPolicy::GetPersistentRegion(GetValue())
|
||||
.AllocateNode(this, &TraceAsRoot));
|
||||
this->CheckPointer(Get());
|
||||
}
|
||||
|
||||
void ClearFromGC() const {
|
||||
if (IsValid()) {
|
||||
WeaknessPolicy::GetPersistentRegion(GetValue()).FreeNode(GetNode());
|
||||
PersistentBase::ClearFromGC();
|
||||
}
|
||||
}
|
||||
|
||||
// Set Get() for details.
|
||||
V8_CLANG_NO_SANITIZE("cfi-unrelated-cast")
|
||||
T* GetFromGC() const {
|
||||
return static_cast<T*>(const_cast<void*>(GetValue()));
|
||||
}
|
||||
|
||||
friend class internal::RootVisitor;
|
||||
};
|
||||
|
||||
template <typename T1, typename WeaknessPolicy1, typename LocationPolicy1,
|
||||
typename CheckingPolicy1, typename T2, typename WeaknessPolicy2,
|
||||
typename LocationPolicy2, typename CheckingPolicy2>
|
||||
bool operator==(const BasicPersistent<T1, WeaknessPolicy1, LocationPolicy1,
|
||||
CheckingPolicy1>& p1,
|
||||
const BasicPersistent<T2, WeaknessPolicy2, LocationPolicy2,
|
||||
CheckingPolicy2>& p2) {
|
||||
return p1.Get() == p2.Get();
|
||||
}
|
||||
|
||||
template <typename T1, typename WeaknessPolicy1, typename LocationPolicy1,
|
||||
typename CheckingPolicy1, typename T2, typename WeaknessPolicy2,
|
||||
typename LocationPolicy2, typename CheckingPolicy2>
|
||||
bool operator!=(const BasicPersistent<T1, WeaknessPolicy1, LocationPolicy1,
|
||||
CheckingPolicy1>& p1,
|
||||
const BasicPersistent<T2, WeaknessPolicy2, LocationPolicy2,
|
||||
CheckingPolicy2>& p2) {
|
||||
return !(p1 == p2);
|
||||
}
|
||||
|
||||
template <typename T1, typename PersistentWeaknessPolicy,
|
||||
typename PersistentLocationPolicy, typename PersistentCheckingPolicy,
|
||||
typename T2, typename MemberWriteBarrierPolicy,
|
||||
typename MemberWeaknessTag, typename MemberCheckingPolicy,
|
||||
typename MemberStorageType>
|
||||
bool operator==(
|
||||
const BasicPersistent<T1, PersistentWeaknessPolicy,
|
||||
PersistentLocationPolicy, PersistentCheckingPolicy>&
|
||||
p,
|
||||
const BasicMember<T2, MemberWeaknessTag, MemberWriteBarrierPolicy,
|
||||
MemberCheckingPolicy, MemberStorageType>& m) {
|
||||
return p.Get() == m.Get();
|
||||
}
|
||||
|
||||
template <typename T1, typename PersistentWeaknessPolicy,
|
||||
typename PersistentLocationPolicy, typename PersistentCheckingPolicy,
|
||||
typename T2, typename MemberWriteBarrierPolicy,
|
||||
typename MemberWeaknessTag, typename MemberCheckingPolicy,
|
||||
typename MemberStorageType>
|
||||
bool operator!=(
|
||||
const BasicPersistent<T1, PersistentWeaknessPolicy,
|
||||
PersistentLocationPolicy, PersistentCheckingPolicy>&
|
||||
p,
|
||||
const BasicMember<T2, MemberWeaknessTag, MemberWriteBarrierPolicy,
|
||||
MemberCheckingPolicy, MemberStorageType>& m) {
|
||||
return !(p == m);
|
||||
}
|
||||
|
||||
template <typename T1, typename MemberWriteBarrierPolicy,
|
||||
typename MemberWeaknessTag, typename MemberCheckingPolicy,
|
||||
typename MemberStorageType, typename T2,
|
||||
typename PersistentWeaknessPolicy, typename PersistentLocationPolicy,
|
||||
typename PersistentCheckingPolicy>
|
||||
bool operator==(
|
||||
const BasicMember<T2, MemberWeaknessTag, MemberWriteBarrierPolicy,
|
||||
MemberCheckingPolicy, MemberStorageType>& m,
|
||||
const BasicPersistent<T1, PersistentWeaknessPolicy,
|
||||
PersistentLocationPolicy, PersistentCheckingPolicy>&
|
||||
p) {
|
||||
return m.Get() == p.Get();
|
||||
}
|
||||
|
||||
template <typename T1, typename MemberWriteBarrierPolicy,
|
||||
typename MemberWeaknessTag, typename MemberCheckingPolicy,
|
||||
typename MemberStorageType, typename T2,
|
||||
typename PersistentWeaknessPolicy, typename PersistentLocationPolicy,
|
||||
typename PersistentCheckingPolicy>
|
||||
bool operator!=(
|
||||
const BasicMember<T2, MemberWeaknessTag, MemberWriteBarrierPolicy,
|
||||
MemberCheckingPolicy, MemberStorageType>& m,
|
||||
const BasicPersistent<T1, PersistentWeaknessPolicy,
|
||||
PersistentLocationPolicy, PersistentCheckingPolicy>&
|
||||
p) {
|
||||
return !(m == p);
|
||||
}
|
||||
|
||||
template <typename T, typename LocationPolicy, typename CheckingPolicy>
|
||||
struct IsWeak<BasicPersistent<T, internal::WeakPersistentPolicy, LocationPolicy,
|
||||
CheckingPolicy>> : std::true_type {};
|
||||
} // namespace internal
|
||||
|
||||
/**
|
||||
* Persistent is a way to create a strong pointer from an off-heap object to
|
||||
* another on-heap object. As long as the Persistent handle is alive the GC will
|
||||
* keep the object pointed to alive. The Persistent handle is always a GC root
|
||||
* from the point of view of the GC. Persistent must be constructed and
|
||||
* destructed in the same thread.
|
||||
*/
|
||||
template <typename T>
|
||||
using Persistent =
|
||||
internal::BasicPersistent<T, internal::StrongPersistentPolicy>;
|
||||
|
||||
/**
|
||||
* WeakPersistent is a way to create a weak pointer from an off-heap object to
|
||||
* an on-heap object. The pointer is automatically cleared when the pointee gets
|
||||
* collected. WeakPersistent must be constructed and destructed in the same
|
||||
* thread.
|
||||
*/
|
||||
template <typename T>
|
||||
using WeakPersistent =
|
||||
internal::BasicPersistent<T, internal::WeakPersistentPolicy>;
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_PERSISTENT_H_
|
||||
163
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/platform.h
generated
vendored
Normal file
163
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/platform.h
generated
vendored
Normal file
@@ -0,0 +1,163 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_PLATFORM_H_
|
||||
#define INCLUDE_CPPGC_PLATFORM_H_
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "cppgc/source-location.h"
|
||||
#include "v8-platform.h" // NOLINT(build/include_directory)
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
// TODO(v8:10346): Create separate includes for concepts that are not
|
||||
// V8-specific.
|
||||
using IdleTask = v8::IdleTask;
|
||||
using JobHandle = v8::JobHandle;
|
||||
using JobDelegate = v8::JobDelegate;
|
||||
using JobTask = v8::JobTask;
|
||||
using PageAllocator = v8::PageAllocator;
|
||||
using Task = v8::Task;
|
||||
using TaskPriority = v8::TaskPriority;
|
||||
using TaskRunner = v8::TaskRunner;
|
||||
using TracingController = v8::TracingController;
|
||||
|
||||
/**
|
||||
* Platform interface used by Heap. Contains allocators and executors.
|
||||
*/
|
||||
class V8_EXPORT Platform {
|
||||
public:
|
||||
virtual ~Platform() = default;
|
||||
|
||||
/**
|
||||
* \returns the allocator used by cppgc to allocate its heap and various
|
||||
* support structures. Returning nullptr results in using the `PageAllocator`
|
||||
* provided by `cppgc::InitializeProcess()` instead.
|
||||
*/
|
||||
virtual PageAllocator* GetPageAllocator() = 0;
|
||||
|
||||
/**
|
||||
* Monotonically increasing time in seconds from an arbitrary fixed point in
|
||||
* the past. This function is expected to return at least
|
||||
* millisecond-precision values. For this reason,
|
||||
* it is recommended that the fixed point be no further in the past than
|
||||
* the epoch.
|
||||
**/
|
||||
virtual double MonotonicallyIncreasingTime() = 0;
|
||||
|
||||
/**
|
||||
* Foreground task runner that should be used by a Heap.
|
||||
*/
|
||||
virtual std::shared_ptr<TaskRunner> GetForegroundTaskRunner() {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
/**
|
||||
* Posts `job_task` to run in parallel. Returns a `JobHandle` associated with
|
||||
* the `Job`, which can be joined or canceled.
|
||||
* This avoids degenerate cases:
|
||||
* - Calling `CallOnWorkerThread()` for each work item, causing significant
|
||||
* overhead.
|
||||
* - Fixed number of `CallOnWorkerThread()` calls that split the work and
|
||||
* might run for a long time. This is problematic when many components post
|
||||
* "num cores" tasks and all expect to use all the cores. In these cases,
|
||||
* the scheduler lacks context to be fair to multiple same-priority requests
|
||||
* and/or ability to request lower priority work to yield when high priority
|
||||
* work comes in.
|
||||
* A canonical implementation of `job_task` looks like:
|
||||
* \code
|
||||
* class MyJobTask : public JobTask {
|
||||
* public:
|
||||
* MyJobTask(...) : worker_queue_(...) {}
|
||||
* // JobTask implementation.
|
||||
* void Run(JobDelegate* delegate) override {
|
||||
* while (!delegate->ShouldYield()) {
|
||||
* // Smallest unit of work.
|
||||
* auto work_item = worker_queue_.TakeWorkItem(); // Thread safe.
|
||||
* if (!work_item) return;
|
||||
* ProcessWork(work_item);
|
||||
* }
|
||||
* }
|
||||
*
|
||||
* size_t GetMaxConcurrency() const override {
|
||||
* return worker_queue_.GetSize(); // Thread safe.
|
||||
* }
|
||||
* };
|
||||
*
|
||||
* // ...
|
||||
* auto handle = PostJob(TaskPriority::kUserVisible,
|
||||
* std::make_unique<MyJobTask>(...));
|
||||
* handle->Join();
|
||||
* \endcode
|
||||
*
|
||||
* `PostJob()` and methods of the returned JobHandle/JobDelegate, must never
|
||||
* be called while holding a lock that could be acquired by `JobTask::Run()`
|
||||
* or `JobTask::GetMaxConcurrency()` -- that could result in a deadlock. This
|
||||
* is because (1) `JobTask::GetMaxConcurrency()` may be invoked while holding
|
||||
* internal lock (A), hence `JobTask::GetMaxConcurrency()` can only use a lock
|
||||
* (B) if that lock is *never* held while calling back into `JobHandle` from
|
||||
* any thread (A=>B/B=>A deadlock) and (2) `JobTask::Run()` or
|
||||
* `JobTask::GetMaxConcurrency()` may be invoked synchronously from
|
||||
* `JobHandle` (B=>JobHandle::foo=>B deadlock).
|
||||
*
|
||||
* A sufficient `PostJob()` implementation that uses the default Job provided
|
||||
* in libplatform looks like:
|
||||
* \code
|
||||
* std::unique_ptr<JobHandle> PostJob(
|
||||
* TaskPriority priority, std::unique_ptr<JobTask> job_task) override {
|
||||
* return std::make_unique<DefaultJobHandle>(
|
||||
* std::make_shared<DefaultJobState>(
|
||||
* this, std::move(job_task), kNumThreads));
|
||||
* }
|
||||
* \endcode
|
||||
*/
|
||||
virtual std::unique_ptr<JobHandle> PostJob(
|
||||
TaskPriority priority, std::unique_ptr<JobTask> job_task) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an instance of a `TracingController`. This must be non-nullptr. The
|
||||
* default implementation returns an empty `TracingController` that consumes
|
||||
* trace data without effect.
|
||||
*/
|
||||
virtual TracingController* GetTracingController();
|
||||
};
|
||||
|
||||
/**
|
||||
* Process-global initialization of the garbage collector. Must be called before
|
||||
* creating a Heap.
|
||||
*
|
||||
* Can be called multiple times when paired with `ShutdownProcess()`.
|
||||
*
|
||||
* \param page_allocator The allocator used for maintaining meta data. Must stay
|
||||
* always alive and not change between multiple calls to InitializeProcess. If
|
||||
* no allocator is provided, a default internal version will be used.
|
||||
* \param desired_heap_size Desired amount of virtual address space to reserve
|
||||
* for the heap, in bytes. Actual size will be clamped to minimum and maximum
|
||||
* values based on compile-time settings and may be rounded up. If this
|
||||
* parameter is zero, a default value will be used.
|
||||
*/
|
||||
V8_EXPORT void InitializeProcess(PageAllocator* page_allocator = nullptr,
|
||||
size_t desired_heap_size = 0);
|
||||
|
||||
/**
|
||||
* Must be called after destroying the last used heap. Some process-global
|
||||
* metadata may not be returned and reused upon a subsequent
|
||||
* `InitializeProcess()` call.
|
||||
*/
|
||||
V8_EXPORT void ShutdownProcess();
|
||||
|
||||
namespace internal {
|
||||
|
||||
V8_EXPORT void Fatal(const std::string& reason = std::string(),
|
||||
const SourceLocation& = SourceLocation::Current());
|
||||
|
||||
} // namespace internal
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_PLATFORM_H_
|
||||
75
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/prefinalizer.h
generated
vendored
Normal file
75
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/prefinalizer.h
generated
vendored
Normal file
@@ -0,0 +1,75 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_PREFINALIZER_H_
|
||||
#define INCLUDE_CPPGC_PREFINALIZER_H_
|
||||
|
||||
#include "cppgc/internal/compiler-specific.h"
|
||||
#include "cppgc/liveness-broker.h"
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
namespace internal {
|
||||
|
||||
class V8_EXPORT PrefinalizerRegistration final {
|
||||
public:
|
||||
using Callback = bool (*)(const cppgc::LivenessBroker&, void*);
|
||||
|
||||
PrefinalizerRegistration(void*, Callback);
|
||||
|
||||
void* operator new(size_t, void* location) = delete;
|
||||
void* operator new(size_t) = delete;
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
/**
|
||||
* Macro must be used in the private section of `Class` and registers a
|
||||
* prefinalization callback `void Class::PreFinalizer()`. The callback is
|
||||
* invoked on garbage collection after the collector has found an object to be
|
||||
* dead.
|
||||
*
|
||||
* Callback properties:
|
||||
* - The callback is invoked before a possible destructor for the corresponding
|
||||
* object.
|
||||
* - The callback may access the whole object graph, irrespective of whether
|
||||
* objects are considered dead or alive.
|
||||
* - The callback is invoked on the same thread as the object was created on.
|
||||
*
|
||||
* Example:
|
||||
* \code
|
||||
* class WithPrefinalizer : public GarbageCollected<WithPrefinalizer> {
|
||||
* CPPGC_USING_PRE_FINALIZER(WithPrefinalizer, Dispose);
|
||||
*
|
||||
* public:
|
||||
* void Trace(Visitor*) const {}
|
||||
* void Dispose() { prefinalizer_called = true; }
|
||||
* ~WithPrefinalizer() {
|
||||
* // prefinalizer_called == true
|
||||
* }
|
||||
* private:
|
||||
* bool prefinalizer_called = false;
|
||||
* };
|
||||
* \endcode
|
||||
*/
|
||||
#define CPPGC_USING_PRE_FINALIZER(Class, PreFinalizer) \
|
||||
public: \
|
||||
static bool InvokePreFinalizer(const cppgc::LivenessBroker& liveness_broker, \
|
||||
void* object) { \
|
||||
static_assert(cppgc::IsGarbageCollectedOrMixinTypeV<Class>, \
|
||||
"Only garbage collected objects can have prefinalizers"); \
|
||||
Class* self = static_cast<Class*>(object); \
|
||||
if (liveness_broker.IsHeapObjectAlive(self)) return false; \
|
||||
self->PreFinalizer(); \
|
||||
return true; \
|
||||
} \
|
||||
\
|
||||
private: \
|
||||
CPPGC_NO_UNIQUE_ADDRESS cppgc::internal::PrefinalizerRegistration \
|
||||
prefinalizer_dummy_{this, Class::InvokePreFinalizer}; \
|
||||
static_assert(true, "Force semicolon.")
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_PREFINALIZER_H_
|
||||
36
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/process-heap-statistics.h
generated
vendored
Normal file
36
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/process-heap-statistics.h
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_PROCESS_HEAP_STATISTICS_H_
|
||||
#define INCLUDE_CPPGC_PROCESS_HEAP_STATISTICS_H_
|
||||
|
||||
#include <atomic>
|
||||
#include <cstddef>
|
||||
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
class ProcessHeapStatisticsUpdater;
|
||||
} // namespace internal
|
||||
|
||||
class V8_EXPORT ProcessHeapStatistics final {
|
||||
public:
|
||||
static size_t TotalAllocatedObjectSize() {
|
||||
return total_allocated_object_size_.load(std::memory_order_relaxed);
|
||||
}
|
||||
static size_t TotalAllocatedSpace() {
|
||||
return total_allocated_space_.load(std::memory_order_relaxed);
|
||||
}
|
||||
|
||||
private:
|
||||
static std::atomic_size_t total_allocated_space_;
|
||||
static std::atomic_size_t total_allocated_object_size_;
|
||||
|
||||
friend class internal::ProcessHeapStatisticsUpdater;
|
||||
};
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_PROCESS_HEAP_STATISTICS_H_
|
||||
39
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/sentinel-pointer.h
generated
vendored
Normal file
39
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/sentinel-pointer.h
generated
vendored
Normal file
@@ -0,0 +1,39 @@
|
||||
// Copyright 2021 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_SENTINEL_POINTER_H_
|
||||
#define INCLUDE_CPPGC_SENTINEL_POINTER_H_
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
#include "cppgc/internal/api-constants.h"
|
||||
|
||||
namespace cppgc {
|
||||
namespace internal {
|
||||
|
||||
// Special tag type used to denote some sentinel member. The semantics of the
|
||||
// sentinel is defined by the embedder.
|
||||
struct SentinelPointer {
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
static constexpr intptr_t kSentinelValue =
|
||||
1 << api_constants::kPointerCompressionShift;
|
||||
#else // !defined(CPPGC_POINTER_COMPRESSION)
|
||||
static constexpr intptr_t kSentinelValue = 0b10;
|
||||
#endif // !defined(CPPGC_POINTER_COMPRESSION)
|
||||
template <typename T>
|
||||
operator T*() const {
|
||||
return reinterpret_cast<T*>(kSentinelValue);
|
||||
}
|
||||
// Hidden friends.
|
||||
friend bool operator==(SentinelPointer, SentinelPointer) { return true; }
|
||||
friend bool operator!=(SentinelPointer, SentinelPointer) { return false; }
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
constexpr internal::SentinelPointer kSentinelPointer;
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_SENTINEL_POINTER_H_
|
||||
16
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/source-location.h
generated
vendored
Normal file
16
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/source-location.h
generated
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_SOURCE_LOCATION_H_
|
||||
#define INCLUDE_CPPGC_SOURCE_LOCATION_H_
|
||||
|
||||
#include "v8-source-location.h"
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
using SourceLocation = v8::SourceLocation;
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_SOURCE_LOCATION_H_
|
||||
106
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/testing.h
generated
vendored
Normal file
106
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/testing.h
generated
vendored
Normal file
@@ -0,0 +1,106 @@
|
||||
// Copyright 2021 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_TESTING_H_
|
||||
#define INCLUDE_CPPGC_TESTING_H_
|
||||
|
||||
#include "cppgc/common.h"
|
||||
#include "cppgc/macros.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
class HeapHandle;
|
||||
|
||||
/**
|
||||
* Namespace contains testing helpers.
|
||||
*/
|
||||
namespace testing {
|
||||
|
||||
/**
|
||||
* Overrides the state of the stack with the provided value. Parameters passed
|
||||
* to explicit garbage collection calls still take precedence. Must not be
|
||||
* nested.
|
||||
*
|
||||
* This scope is useful to make the garbage collector consider the stack when
|
||||
* tasks that invoke garbage collection (through the provided platform) contain
|
||||
* interesting pointers on its stack.
|
||||
*/
|
||||
class V8_EXPORT V8_NODISCARD OverrideEmbedderStackStateScope final {
|
||||
CPPGC_STACK_ALLOCATED();
|
||||
|
||||
public:
|
||||
/**
|
||||
* Constructs a scoped object that automatically enters and leaves the scope.
|
||||
*
|
||||
* \param heap_handle The corresponding heap.
|
||||
*/
|
||||
explicit OverrideEmbedderStackStateScope(HeapHandle& heap_handle,
|
||||
EmbedderStackState state);
|
||||
~OverrideEmbedderStackStateScope();
|
||||
|
||||
OverrideEmbedderStackStateScope(const OverrideEmbedderStackStateScope&) =
|
||||
delete;
|
||||
OverrideEmbedderStackStateScope& operator=(
|
||||
const OverrideEmbedderStackStateScope&) = delete;
|
||||
|
||||
private:
|
||||
HeapHandle& heap_handle_;
|
||||
};
|
||||
|
||||
/**
|
||||
* Testing interface for managed heaps that allows for controlling garbage
|
||||
* collection timings. Embedders should use this class when testing the
|
||||
* interaction of their code with incremental/concurrent garbage collection.
|
||||
*/
|
||||
class V8_EXPORT StandaloneTestingHeap final {
|
||||
public:
|
||||
explicit StandaloneTestingHeap(HeapHandle&);
|
||||
|
||||
/**
|
||||
* Start an incremental garbage collection.
|
||||
*/
|
||||
void StartGarbageCollection();
|
||||
|
||||
/**
|
||||
* Perform an incremental step. This will also schedule concurrent steps if
|
||||
* needed.
|
||||
*
|
||||
* \param stack_state The state of the stack during the step.
|
||||
*/
|
||||
bool PerformMarkingStep(EmbedderStackState stack_state);
|
||||
|
||||
/**
|
||||
* Finalize the current garbage collection cycle atomically.
|
||||
* Assumes that garbage collection is in progress.
|
||||
*
|
||||
* \param stack_state The state of the stack for finalizing the garbage
|
||||
* collection cycle.
|
||||
*/
|
||||
void FinalizeGarbageCollection(EmbedderStackState stack_state);
|
||||
|
||||
/**
|
||||
* Toggle main thread marking on/off. Allows to stress concurrent marking
|
||||
* (e.g. to better detect data races).
|
||||
*
|
||||
* \param should_mark Denotes whether the main thread should contribute to
|
||||
* marking. Defaults to true.
|
||||
*/
|
||||
void ToggleMainThreadMarking(bool should_mark);
|
||||
|
||||
/**
|
||||
* Force enable compaction for the next garbage collection cycle.
|
||||
*/
|
||||
void ForceCompactionForNextGarbageCollection();
|
||||
|
||||
private:
|
||||
HeapHandle& heap_handle_;
|
||||
};
|
||||
|
||||
V8_EXPORT bool IsHeapObjectOld(void*);
|
||||
|
||||
} // namespace testing
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_TESTING_H_
|
||||
128
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/trace-trait.h
generated
vendored
Normal file
128
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/trace-trait.h
generated
vendored
Normal file
@@ -0,0 +1,128 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_TRACE_TRAIT_H_
|
||||
#define INCLUDE_CPPGC_TRACE_TRAIT_H_
|
||||
|
||||
#include <type_traits>
|
||||
|
||||
#include "cppgc/type-traits.h"
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
class Visitor;
|
||||
|
||||
namespace internal {
|
||||
|
||||
class RootVisitor;
|
||||
|
||||
using TraceRootCallback = void (*)(RootVisitor&, const void* object);
|
||||
|
||||
// Implementation of the default TraceTrait handling GarbageCollected and
|
||||
// GarbageCollectedMixin.
|
||||
template <typename T,
|
||||
bool =
|
||||
IsGarbageCollectedMixinTypeV<typename std::remove_const<T>::type>>
|
||||
struct TraceTraitImpl;
|
||||
|
||||
} // namespace internal
|
||||
|
||||
/**
|
||||
* Callback for invoking tracing on a given object.
|
||||
*
|
||||
* \param visitor The visitor to dispatch to.
|
||||
* \param object The object to invoke tracing on.
|
||||
*/
|
||||
using TraceCallback = void (*)(Visitor* visitor, const void* object);
|
||||
|
||||
/**
|
||||
* Describes how to trace an object, i.e., how to visit all Oilpan-relevant
|
||||
* fields of an object.
|
||||
*/
|
||||
struct TraceDescriptor {
|
||||
/**
|
||||
* Adjusted base pointer, i.e., the pointer to the class inheriting directly
|
||||
* from GarbageCollected, of the object that is being traced.
|
||||
*/
|
||||
const void* base_object_payload;
|
||||
/**
|
||||
* Callback for tracing the object.
|
||||
*/
|
||||
TraceCallback callback;
|
||||
};
|
||||
|
||||
/**
|
||||
* Callback for getting a TraceDescriptor for a given address.
|
||||
*
|
||||
* \param address Possibly inner address of an object.
|
||||
* \returns a TraceDescriptor for the provided address.
|
||||
*/
|
||||
using TraceDescriptorCallback = TraceDescriptor (*)(const void* address);
|
||||
|
||||
namespace internal {
|
||||
|
||||
struct V8_EXPORT TraceTraitFromInnerAddressImpl {
|
||||
static TraceDescriptor GetTraceDescriptor(const void* address);
|
||||
};
|
||||
|
||||
/**
|
||||
* Trait specifying how the garbage collector processes an object of type T.
|
||||
*
|
||||
* Advanced users may override handling by creating a specialization for their
|
||||
* type.
|
||||
*/
|
||||
template <typename T>
|
||||
struct TraceTraitBase {
|
||||
static_assert(internal::IsTraceableV<T>, "T must have a Trace() method");
|
||||
|
||||
/**
|
||||
* Accessor for retrieving a TraceDescriptor to process an object of type T.
|
||||
*
|
||||
* \param self The object to be processed.
|
||||
* \returns a TraceDescriptor to process the object.
|
||||
*/
|
||||
static TraceDescriptor GetTraceDescriptor(const void* self) {
|
||||
return internal::TraceTraitImpl<T>::GetTraceDescriptor(
|
||||
static_cast<const T*>(self));
|
||||
}
|
||||
|
||||
/**
|
||||
* Function invoking the tracing for an object of type T.
|
||||
*
|
||||
* \param visitor The visitor to dispatch to.
|
||||
* \param self The object to invoke tracing on.
|
||||
*/
|
||||
static void Trace(Visitor* visitor, const void* self) {
|
||||
static_cast<const T*>(self)->Trace(visitor);
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
template <typename T>
|
||||
struct TraceTrait : public internal::TraceTraitBase<T> {};
|
||||
|
||||
namespace internal {
|
||||
|
||||
template <typename T>
|
||||
struct TraceTraitImpl<T, false> {
|
||||
static_assert(IsGarbageCollectedTypeV<T>,
|
||||
"T must be of type GarbageCollected or GarbageCollectedMixin");
|
||||
static TraceDescriptor GetTraceDescriptor(const void* self) {
|
||||
return {self, TraceTrait<T>::Trace};
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct TraceTraitImpl<T, true> {
|
||||
static TraceDescriptor GetTraceDescriptor(const void* self) {
|
||||
return internal::TraceTraitFromInnerAddressImpl::GetTraceDescriptor(self);
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_TRACE_TRAIT_H_
|
||||
271
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/type-traits.h
generated
vendored
Normal file
271
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/type-traits.h
generated
vendored
Normal file
@@ -0,0 +1,271 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_TYPE_TRAITS_H_
|
||||
#define INCLUDE_CPPGC_TYPE_TRAITS_H_
|
||||
|
||||
// This file should stay with minimal dependencies to allow embedder to check
|
||||
// against Oilpan types without including any other parts.
|
||||
#include <cstddef>
|
||||
#include <type_traits>
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
class Visitor;
|
||||
|
||||
namespace internal {
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
class BasicMember;
|
||||
struct DijkstraWriteBarrierPolicy;
|
||||
struct NoWriteBarrierPolicy;
|
||||
class StrongMemberTag;
|
||||
class UntracedMemberTag;
|
||||
class WeakMemberTag;
|
||||
|
||||
// Not supposed to be specialized by the user.
|
||||
template <typename T>
|
||||
struct IsWeak : std::false_type {};
|
||||
|
||||
// IsTraceMethodConst is used to verify that all Trace methods are marked as
|
||||
// const. It is equivalent to IsTraceable but for a non-const object.
|
||||
template <typename T, typename = void>
|
||||
struct IsTraceMethodConst : std::false_type {};
|
||||
|
||||
template <typename T>
|
||||
struct IsTraceMethodConst<T, std::void_t<decltype(std::declval<const T>().Trace(
|
||||
std::declval<Visitor*>()))>> : std::true_type {
|
||||
};
|
||||
|
||||
template <typename T, typename = void>
|
||||
struct IsTraceable : std::false_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct IsTraceable<
|
||||
T, std::void_t<decltype(std::declval<T>().Trace(std::declval<Visitor*>()))>>
|
||||
: std::true_type {
|
||||
// All Trace methods should be marked as const. If an object of type
|
||||
// 'T' is traceable then any object of type 'const T' should also
|
||||
// be traceable.
|
||||
static_assert(IsTraceMethodConst<T>(),
|
||||
"Trace methods should be marked as const.");
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
constexpr bool IsTraceableV = IsTraceable<T>::value;
|
||||
|
||||
template <typename T, typename = void>
|
||||
struct HasGarbageCollectedMixinTypeMarker : std::false_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct HasGarbageCollectedMixinTypeMarker<
|
||||
T, std::void_t<
|
||||
typename std::remove_const_t<T>::IsGarbageCollectedMixinTypeMarker>>
|
||||
: std::true_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T, typename = void>
|
||||
struct HasGarbageCollectedTypeMarker : std::false_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct HasGarbageCollectedTypeMarker<
|
||||
T,
|
||||
std::void_t<typename std::remove_const_t<T>::IsGarbageCollectedTypeMarker>>
|
||||
: std::true_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T, bool = HasGarbageCollectedTypeMarker<T>::value,
|
||||
bool = HasGarbageCollectedMixinTypeMarker<T>::value>
|
||||
struct IsGarbageCollectedMixinType : std::false_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct IsGarbageCollectedMixinType<T, false, true> : std::true_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T, bool = HasGarbageCollectedTypeMarker<T>::value>
|
||||
struct IsGarbageCollectedType : std::false_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct IsGarbageCollectedType<T, true> : std::true_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct IsGarbageCollectedOrMixinType
|
||||
: std::integral_constant<bool, IsGarbageCollectedType<T>::value ||
|
||||
IsGarbageCollectedMixinType<T>::value> {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T, bool = (HasGarbageCollectedTypeMarker<T>::value &&
|
||||
HasGarbageCollectedMixinTypeMarker<T>::value)>
|
||||
struct IsGarbageCollectedWithMixinType : std::false_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct IsGarbageCollectedWithMixinType<T, true> : std::true_type {
|
||||
static_assert(sizeof(T), "T must be fully defined");
|
||||
};
|
||||
|
||||
template <typename BasicMemberCandidate, typename WeaknessTag,
|
||||
typename WriteBarrierPolicy>
|
||||
struct IsSubclassOfBasicMemberTemplate {
|
||||
private:
|
||||
template <typename T, typename CheckingPolicy, typename StorageType>
|
||||
static std::true_type SubclassCheck(
|
||||
const BasicMember<T, WeaknessTag, WriteBarrierPolicy, CheckingPolicy,
|
||||
StorageType>*);
|
||||
static std::false_type SubclassCheck(...);
|
||||
|
||||
public:
|
||||
static constexpr bool value = decltype(SubclassCheck(
|
||||
std::declval<std::decay_t<BasicMemberCandidate>*>()))::value;
|
||||
};
|
||||
|
||||
template <typename T,
|
||||
bool = IsSubclassOfBasicMemberTemplate<
|
||||
T, StrongMemberTag, DijkstraWriteBarrierPolicy>::value>
|
||||
struct IsMemberType : std::false_type {};
|
||||
|
||||
template <typename T>
|
||||
struct IsMemberType<T, true> : std::true_type {};
|
||||
|
||||
template <typename T, bool = IsSubclassOfBasicMemberTemplate<
|
||||
T, WeakMemberTag, DijkstraWriteBarrierPolicy>::value>
|
||||
struct IsWeakMemberType : std::false_type {};
|
||||
|
||||
template <typename T>
|
||||
struct IsWeakMemberType<T, true> : std::true_type {};
|
||||
|
||||
template <typename T, bool = IsSubclassOfBasicMemberTemplate<
|
||||
T, UntracedMemberTag, NoWriteBarrierPolicy>::value>
|
||||
struct IsUntracedMemberType : std::false_type {};
|
||||
|
||||
template <typename T>
|
||||
struct IsUntracedMemberType<T, true> : std::true_type {};
|
||||
|
||||
template <typename T>
|
||||
struct IsComplete {
|
||||
private:
|
||||
template <typename U, size_t = sizeof(U)>
|
||||
static std::true_type IsSizeOfKnown(U*);
|
||||
static std::false_type IsSizeOfKnown(...);
|
||||
|
||||
public:
|
||||
static constexpr bool value =
|
||||
decltype(IsSizeOfKnown(std::declval<T*>()))::value;
|
||||
};
|
||||
|
||||
template <typename T, typename U>
|
||||
constexpr bool IsDecayedSameV =
|
||||
std::is_same_v<std::decay_t<T>, std::decay_t<U>>;
|
||||
|
||||
template <typename B, typename D>
|
||||
constexpr bool IsStrictlyBaseOfV =
|
||||
std::is_base_of_v<std::decay_t<B>, std::decay_t<D>> &&
|
||||
!IsDecayedSameV<B, D>;
|
||||
|
||||
template <typename T>
|
||||
constexpr bool IsAnyMemberTypeV = false;
|
||||
|
||||
template <typename T, typename WeaknessTag, typename WriteBarrierPolicy,
|
||||
typename CheckingPolicy, typename StorageType>
|
||||
constexpr bool IsAnyMemberTypeV<internal::BasicMember<
|
||||
T, WeaknessTag, WriteBarrierPolicy, CheckingPolicy, StorageType>> = true;
|
||||
|
||||
} // namespace internal
|
||||
|
||||
/**
|
||||
* Value is true for types that inherit from `GarbageCollectedMixin` but not
|
||||
* `GarbageCollected<T>` (i.e., they are free mixins), and false otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsGarbageCollectedMixinTypeV =
|
||||
internal::IsGarbageCollectedMixinType<T>::value;
|
||||
|
||||
/**
|
||||
* Value is true for types that inherit from `GarbageCollected<T>`, and false
|
||||
* otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsGarbageCollectedTypeV =
|
||||
internal::IsGarbageCollectedType<T>::value;
|
||||
|
||||
/**
|
||||
* Value is true for types that inherit from either `GarbageCollected<T>` or
|
||||
* `GarbageCollectedMixin`, and false otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsGarbageCollectedOrMixinTypeV =
|
||||
internal::IsGarbageCollectedOrMixinType<T>::value;
|
||||
|
||||
/**
|
||||
* Value is true for types that inherit from `GarbageCollected<T>` and
|
||||
* `GarbageCollectedMixin`, and false otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsGarbageCollectedWithMixinTypeV =
|
||||
internal::IsGarbageCollectedWithMixinType<T>::value;
|
||||
|
||||
/**
|
||||
* Value is true for types of type `Member<T>`, and false otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsMemberTypeV = internal::IsMemberType<T>::value;
|
||||
|
||||
/**
|
||||
* Value is true for types of type `UntracedMember<T>`, and false otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsUntracedMemberTypeV = internal::IsUntracedMemberType<T>::value;
|
||||
|
||||
/**
|
||||
* Value is true for types of type `WeakMember<T>`, and false otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsWeakMemberTypeV = internal::IsWeakMemberType<T>::value;
|
||||
|
||||
/**
|
||||
* Value is true for types that are considered weak references, and false
|
||||
* otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsWeakV = internal::IsWeak<T>::value;
|
||||
|
||||
/**
|
||||
* Value is true for types that are complete, and false otherwise.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsCompleteV = internal::IsComplete<T>::value;
|
||||
|
||||
/**
|
||||
* Value is true for member types `Member<T>` and `WeakMember<T>`.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsMemberOrWeakMemberTypeV =
|
||||
IsMemberTypeV<T> || IsWeakMemberTypeV<T>;
|
||||
|
||||
/**
|
||||
* Value is true for any member type.
|
||||
*/
|
||||
template <typename T>
|
||||
constexpr bool IsAnyMemberTypeV = internal::IsAnyMemberTypeV<std::decay_t<T>>;
|
||||
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_TYPE_TRAITS_H_
|
||||
504
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/visitor.h
generated
vendored
Normal file
504
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/cppgc/visitor.h
generated
vendored
Normal file
@@ -0,0 +1,504 @@
|
||||
// Copyright 2020 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef INCLUDE_CPPGC_VISITOR_H_
|
||||
#define INCLUDE_CPPGC_VISITOR_H_
|
||||
|
||||
#include <type_traits>
|
||||
|
||||
#include "cppgc/custom-space.h"
|
||||
#include "cppgc/ephemeron-pair.h"
|
||||
#include "cppgc/garbage-collected.h"
|
||||
#include "cppgc/internal/logging.h"
|
||||
#include "cppgc/internal/member-storage.h"
|
||||
#include "cppgc/internal/pointer-policies.h"
|
||||
#include "cppgc/liveness-broker.h"
|
||||
#include "cppgc/member.h"
|
||||
#include "cppgc/sentinel-pointer.h"
|
||||
#include "cppgc/source-location.h"
|
||||
#include "cppgc/trace-trait.h"
|
||||
#include "cppgc/type-traits.h"
|
||||
|
||||
namespace cppgc {
|
||||
|
||||
namespace internal {
|
||||
template <typename T, typename WeaknessPolicy, typename LocationPolicy,
|
||||
typename CheckingPolicy>
|
||||
class BasicCrossThreadPersistent;
|
||||
template <typename T, typename WeaknessPolicy, typename LocationPolicy,
|
||||
typename CheckingPolicy>
|
||||
class BasicPersistent;
|
||||
class ConservativeTracingVisitor;
|
||||
class VisitorBase;
|
||||
class VisitorFactory;
|
||||
} // namespace internal
|
||||
|
||||
using WeakCallback = void (*)(const LivenessBroker&, const void*);
|
||||
|
||||
/**
|
||||
* Visitor passed to trace methods. All managed pointers must have called the
|
||||
* Visitor's trace method on them.
|
||||
*
|
||||
* \code
|
||||
* class Foo final : public GarbageCollected<Foo> {
|
||||
* public:
|
||||
* void Trace(Visitor* visitor) const {
|
||||
* visitor->Trace(foo_);
|
||||
* visitor->Trace(weak_foo_);
|
||||
* }
|
||||
* private:
|
||||
* Member<Foo> foo_;
|
||||
* WeakMember<Foo> weak_foo_;
|
||||
* };
|
||||
* \endcode
|
||||
*/
|
||||
class V8_EXPORT Visitor {
|
||||
public:
|
||||
class Key {
|
||||
private:
|
||||
Key() = default;
|
||||
friend class internal::VisitorFactory;
|
||||
};
|
||||
|
||||
explicit Visitor(Key) {}
|
||||
|
||||
virtual ~Visitor() = default;
|
||||
|
||||
/**
|
||||
* Trace method for Member.
|
||||
*
|
||||
* \param member Member reference retaining an object.
|
||||
*/
|
||||
template <typename T>
|
||||
void Trace(const Member<T>& member) {
|
||||
const T* value = member.GetRawAtomic();
|
||||
CPPGC_DCHECK(value != kSentinelPointer);
|
||||
TraceImpl(value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trace method for WeakMember.
|
||||
*
|
||||
* \param weak_member WeakMember reference weakly retaining an object.
|
||||
*/
|
||||
template <typename T>
|
||||
void Trace(const WeakMember<T>& weak_member) {
|
||||
static_assert(sizeof(T), "Pointee type must be fully defined.");
|
||||
static_assert(internal::IsGarbageCollectedOrMixinType<T>::value,
|
||||
"T must be GarbageCollected or GarbageCollectedMixin type");
|
||||
static_assert(!internal::IsAllocatedOnCompactableSpace<T>::value,
|
||||
"Weak references to compactable objects are not allowed");
|
||||
|
||||
const T* value = weak_member.GetRawAtomic();
|
||||
|
||||
// Bailout assumes that WeakMember emits write barrier.
|
||||
if (!value) {
|
||||
return;
|
||||
}
|
||||
|
||||
CPPGC_DCHECK(value != kSentinelPointer);
|
||||
VisitWeak(value, TraceTrait<T>::GetTraceDescriptor(value),
|
||||
&HandleWeak<WeakMember<T>>, &weak_member);
|
||||
}
|
||||
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
/**
|
||||
* Trace method for UncompressedMember.
|
||||
*
|
||||
* \param member UncompressedMember reference retaining an object.
|
||||
*/
|
||||
template <typename T>
|
||||
void Trace(const subtle::UncompressedMember<T>& member) {
|
||||
const T* value = member.GetRawAtomic();
|
||||
CPPGC_DCHECK(value != kSentinelPointer);
|
||||
TraceImpl(value);
|
||||
}
|
||||
#endif // defined(CPPGC_POINTER_COMPRESSION)
|
||||
|
||||
template <typename T>
|
||||
void TraceMultiple(const subtle::UncompressedMember<T>* start, size_t len) {
|
||||
static_assert(sizeof(T), "Pointee type must be fully defined.");
|
||||
static_assert(internal::IsGarbageCollectedOrMixinType<T>::value,
|
||||
"T must be GarbageCollected or GarbageCollectedMixin type");
|
||||
VisitMultipleUncompressedMember(start, len,
|
||||
&TraceTrait<T>::GetTraceDescriptor);
|
||||
}
|
||||
|
||||
template <typename T,
|
||||
std::enable_if_t<!std::is_same_v<
|
||||
Member<T>, subtle::UncompressedMember<T>>>* = nullptr>
|
||||
void TraceMultiple(const Member<T>* start, size_t len) {
|
||||
static_assert(sizeof(T), "Pointee type must be fully defined.");
|
||||
static_assert(internal::IsGarbageCollectedOrMixinType<T>::value,
|
||||
"T must be GarbageCollected or GarbageCollectedMixin type");
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
static_assert(std::is_same_v<Member<T>, subtle::CompressedMember<T>>,
|
||||
"Member and CompressedMember must be the same.");
|
||||
VisitMultipleCompressedMember(start, len,
|
||||
&TraceTrait<T>::GetTraceDescriptor);
|
||||
#endif // defined(CPPGC_POINTER_COMPRESSION)
|
||||
}
|
||||
|
||||
/**
|
||||
* Trace method for inlined objects that are not allocated themselves but
|
||||
* otherwise follow managed heap layout and have a Trace() method.
|
||||
*
|
||||
* \param object reference of the inlined object.
|
||||
*/
|
||||
template <typename T>
|
||||
void Trace(const T& object) {
|
||||
#if V8_ENABLE_CHECKS
|
||||
// This object is embedded in potentially multiple nested objects. The
|
||||
// outermost object must not be in construction as such objects are (a) not
|
||||
// processed immediately, and (b) only processed conservatively if not
|
||||
// otherwise possible.
|
||||
CheckObjectNotInConstruction(&object);
|
||||
#endif // V8_ENABLE_CHECKS
|
||||
TraceTrait<T>::Trace(this, &object);
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
void TraceMultiple(const T* start, size_t len) {
|
||||
#if V8_ENABLE_CHECKS
|
||||
// This object is embedded in potentially multiple nested objects. The
|
||||
// outermost object must not be in construction as such objects are (a) not
|
||||
// processed immediately, and (b) only processed conservatively if not
|
||||
// otherwise possible.
|
||||
CheckObjectNotInConstruction(start);
|
||||
#endif // V8_ENABLE_CHECKS
|
||||
for (size_t i = 0; i < len; ++i) {
|
||||
const T* object = &start[i];
|
||||
if constexpr (std::is_polymorphic_v<T>) {
|
||||
// The object's vtable may be uninitialized in which case the object is
|
||||
// not traced.
|
||||
if (*reinterpret_cast<const uintptr_t*>(object) == 0) continue;
|
||||
}
|
||||
TraceTrait<T>::Trace(this, object);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers a weak callback method on the object of type T. See
|
||||
* LivenessBroker for an usage example.
|
||||
*
|
||||
* \param object of type T specifying a weak callback method.
|
||||
*/
|
||||
template <typename T, void (T::*method)(const LivenessBroker&)>
|
||||
void RegisterWeakCallbackMethod(const T* object) {
|
||||
RegisterWeakCallback(&WeakCallbackMethodDelegate<T, method>, object);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trace method for EphemeronPair.
|
||||
*
|
||||
* \param ephemeron_pair EphemeronPair reference weakly retaining a key object
|
||||
* and strongly retaining a value object in case the key object is alive.
|
||||
*/
|
||||
template <typename K, typename V>
|
||||
void Trace(const EphemeronPair<K, V>& ephemeron_pair) {
|
||||
TraceEphemeron(ephemeron_pair.key, &ephemeron_pair.value);
|
||||
RegisterWeakCallbackMethod<EphemeronPair<K, V>,
|
||||
&EphemeronPair<K, V>::ClearValueIfKeyIsDead>(
|
||||
&ephemeron_pair);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trace method for a single ephemeron. Used for tracing a raw ephemeron in
|
||||
* which the `key` and `value` are kept separately.
|
||||
*
|
||||
* \param weak_member_key WeakMember reference weakly retaining a key object.
|
||||
* \param member_value Member reference with ephemeron semantics.
|
||||
*/
|
||||
template <typename KeyType, typename ValueType>
|
||||
void TraceEphemeron(const WeakMember<KeyType>& weak_member_key,
|
||||
const Member<ValueType>* member_value) {
|
||||
const KeyType* key = weak_member_key.GetRawAtomic();
|
||||
if (!key) return;
|
||||
|
||||
// `value` must always be non-null.
|
||||
CPPGC_DCHECK(member_value);
|
||||
const ValueType* value = member_value->GetRawAtomic();
|
||||
if (!value) return;
|
||||
|
||||
// KeyType and ValueType may refer to GarbageCollectedMixin.
|
||||
TraceDescriptor value_desc =
|
||||
TraceTrait<ValueType>::GetTraceDescriptor(value);
|
||||
CPPGC_DCHECK(value_desc.base_object_payload);
|
||||
const void* key_base_object_payload =
|
||||
TraceTrait<KeyType>::GetTraceDescriptor(key).base_object_payload;
|
||||
CPPGC_DCHECK(key_base_object_payload);
|
||||
|
||||
VisitEphemeron(key_base_object_payload, value, value_desc);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trace method for a single ephemeron. Used for tracing a raw ephemeron in
|
||||
* which the `key` and `value` are kept separately. Note that this overload
|
||||
* is for non-GarbageCollected `value`s that can be traced though.
|
||||
*
|
||||
* \param key `WeakMember` reference weakly retaining a key object.
|
||||
* \param value Reference weakly retaining a value object. Note that
|
||||
* `ValueType` here should not be `Member`. It is expected that
|
||||
* `TraceTrait<ValueType>::GetTraceDescriptor(value)` returns a
|
||||
* `TraceDescriptor` with a null base pointer but a valid trace method.
|
||||
*/
|
||||
template <typename KeyType, typename ValueType>
|
||||
void TraceEphemeron(const WeakMember<KeyType>& weak_member_key,
|
||||
const ValueType* value) {
|
||||
static_assert(!IsGarbageCollectedOrMixinTypeV<ValueType>,
|
||||
"garbage-collected types must use WeakMember and Member");
|
||||
const KeyType* key = weak_member_key.GetRawAtomic();
|
||||
if (!key) return;
|
||||
|
||||
// `value` must always be non-null.
|
||||
CPPGC_DCHECK(value);
|
||||
TraceDescriptor value_desc =
|
||||
TraceTrait<ValueType>::GetTraceDescriptor(value);
|
||||
// `value_desc.base_object_payload` must be null as this override is only
|
||||
// taken for non-garbage-collected values.
|
||||
CPPGC_DCHECK(!value_desc.base_object_payload);
|
||||
|
||||
// KeyType might be a GarbageCollectedMixin.
|
||||
const void* key_base_object_payload =
|
||||
TraceTrait<KeyType>::GetTraceDescriptor(key).base_object_payload;
|
||||
CPPGC_DCHECK(key_base_object_payload);
|
||||
|
||||
VisitEphemeron(key_base_object_payload, value, value_desc);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trace method that strongifies a WeakMember.
|
||||
*
|
||||
* \param weak_member WeakMember reference retaining an object.
|
||||
*/
|
||||
template <typename T>
|
||||
void TraceStrongly(const WeakMember<T>& weak_member) {
|
||||
const T* value = weak_member.GetRawAtomic();
|
||||
CPPGC_DCHECK(value != kSentinelPointer);
|
||||
TraceImpl(value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trace method for retaining containers strongly.
|
||||
*
|
||||
* \param object reference to the container.
|
||||
*/
|
||||
template <typename T>
|
||||
void TraceStrongContainer(const T* object) {
|
||||
TraceImpl(object);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trace method for retaining containers weakly. Note that weak containers
|
||||
* should emit write barriers.
|
||||
*
|
||||
* \param object reference to the container.
|
||||
* \param callback to be invoked.
|
||||
* \param callback_data custom data that is passed to the callback.
|
||||
*/
|
||||
template <typename T>
|
||||
void TraceWeakContainer(const T* object, WeakCallback callback,
|
||||
const void* callback_data) {
|
||||
if (!object) return;
|
||||
VisitWeakContainer(object, TraceTrait<T>::GetTraceDescriptor(object),
|
||||
TraceTrait<T>::GetWeakTraceDescriptor(object), callback,
|
||||
callback_data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers a slot containing a reference to an object allocated on a
|
||||
* compactable space. Such references maybe be arbitrarily moved by the GC.
|
||||
*
|
||||
* \param slot location of reference to object that might be moved by the GC.
|
||||
* The slot must contain an uncompressed pointer.
|
||||
*/
|
||||
template <typename T>
|
||||
void RegisterMovableReference(const T** slot) {
|
||||
static_assert(internal::IsAllocatedOnCompactableSpace<T>::value,
|
||||
"Only references to objects allocated on compactable spaces "
|
||||
"should be registered as movable slots.");
|
||||
static_assert(!IsGarbageCollectedMixinTypeV<T>,
|
||||
"Mixin types do not support compaction.");
|
||||
HandleMovableReference(reinterpret_cast<const void**>(slot));
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers a weak callback that is invoked during garbage collection.
|
||||
*
|
||||
* \param callback to be invoked.
|
||||
* \param data custom data that is passed to the callback.
|
||||
*/
|
||||
virtual void RegisterWeakCallback(WeakCallback callback, const void* data) {}
|
||||
|
||||
/**
|
||||
* Defers tracing an object from a concurrent thread to the mutator thread.
|
||||
* Should be called by Trace methods of types that are not safe to trace
|
||||
* concurrently.
|
||||
*
|
||||
* \param parameter tells the trace callback which object was deferred.
|
||||
* \param callback to be invoked for tracing on the mutator thread.
|
||||
* \param deferred_size size of deferred object.
|
||||
*
|
||||
* \returns false if the object does not need to be deferred (i.e. currently
|
||||
* traced on the mutator thread) and true otherwise (i.e. currently traced on
|
||||
* a concurrent thread).
|
||||
*/
|
||||
virtual V8_WARN_UNUSED_RESULT bool DeferTraceToMutatorThreadIfConcurrent(
|
||||
const void* parameter, TraceCallback callback, size_t deferred_size) {
|
||||
// By default tracing is not deferred.
|
||||
return false;
|
||||
}
|
||||
|
||||
protected:
|
||||
virtual void Visit(const void* self, TraceDescriptor) {}
|
||||
virtual void VisitWeak(const void* self, TraceDescriptor, WeakCallback,
|
||||
const void* weak_member) {}
|
||||
virtual void VisitEphemeron(const void* key, const void* value,
|
||||
TraceDescriptor value_desc) {}
|
||||
virtual void VisitWeakContainer(const void* self, TraceDescriptor strong_desc,
|
||||
TraceDescriptor weak_desc,
|
||||
WeakCallback callback, const void* data) {}
|
||||
virtual void HandleMovableReference(const void**) {}
|
||||
|
||||
virtual void VisitMultipleUncompressedMember(
|
||||
const void* start, size_t len,
|
||||
TraceDescriptorCallback get_trace_descriptor) {
|
||||
// Default implementation merely delegates to Visit().
|
||||
const char* it = static_cast<const char*>(start);
|
||||
const char* end = it + len * internal::kSizeOfUncompressedMember;
|
||||
for (; it < end; it += internal::kSizeOfUncompressedMember) {
|
||||
const auto* current = reinterpret_cast<const internal::RawPointer*>(it);
|
||||
const void* object = current->LoadAtomic();
|
||||
if (!object) continue;
|
||||
|
||||
Visit(object, get_trace_descriptor(object));
|
||||
}
|
||||
}
|
||||
|
||||
#if defined(CPPGC_POINTER_COMPRESSION)
|
||||
virtual void VisitMultipleCompressedMember(
|
||||
const void* start, size_t len,
|
||||
TraceDescriptorCallback get_trace_descriptor) {
|
||||
// Default implementation merely delegates to Visit().
|
||||
const char* it = static_cast<const char*>(start);
|
||||
const char* end = it + len * internal::kSizeofCompressedMember;
|
||||
for (; it < end; it += internal::kSizeofCompressedMember) {
|
||||
const auto* current =
|
||||
reinterpret_cast<const internal::CompressedPointer*>(it);
|
||||
const void* object = current->LoadAtomic();
|
||||
if (!object) continue;
|
||||
|
||||
Visit(object, get_trace_descriptor(object));
|
||||
}
|
||||
}
|
||||
#endif // defined(CPPGC_POINTER_COMPRESSION)
|
||||
|
||||
private:
|
||||
template <typename T, void (T::*method)(const LivenessBroker&)>
|
||||
static void WeakCallbackMethodDelegate(const LivenessBroker& info,
|
||||
const void* self) {
|
||||
// Callback is registered through a potential const Trace method but needs
|
||||
// to be able to modify fields. See HandleWeak.
|
||||
(const_cast<T*>(static_cast<const T*>(self))->*method)(info);
|
||||
}
|
||||
|
||||
template <typename PointerType>
|
||||
static void HandleWeak(const LivenessBroker& info, const void* object) {
|
||||
const PointerType* weak = static_cast<const PointerType*>(object);
|
||||
if (!info.IsHeapObjectAlive(weak->GetFromGC())) {
|
||||
weak->ClearFromGC();
|
||||
}
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
void TraceImpl(const T* t) {
|
||||
static_assert(sizeof(T), "Pointee type must be fully defined.");
|
||||
static_assert(internal::IsGarbageCollectedOrMixinType<T>::value,
|
||||
"T must be GarbageCollected or GarbageCollectedMixin type");
|
||||
if (!t) {
|
||||
return;
|
||||
}
|
||||
Visit(t, TraceTrait<T>::GetTraceDescriptor(t));
|
||||
}
|
||||
|
||||
#if V8_ENABLE_CHECKS
|
||||
void CheckObjectNotInConstruction(const void* address);
|
||||
#endif // V8_ENABLE_CHECKS
|
||||
|
||||
template <typename T, typename WeaknessPolicy, typename LocationPolicy,
|
||||
typename CheckingPolicy>
|
||||
friend class internal::BasicCrossThreadPersistent;
|
||||
template <typename T, typename WeaknessPolicy, typename LocationPolicy,
|
||||
typename CheckingPolicy>
|
||||
friend class internal::BasicPersistent;
|
||||
friend class internal::ConservativeTracingVisitor;
|
||||
friend class internal::VisitorBase;
|
||||
};
|
||||
|
||||
namespace internal {
|
||||
|
||||
class V8_EXPORT RootVisitor {
|
||||
public:
|
||||
explicit RootVisitor(Visitor::Key) {}
|
||||
|
||||
virtual ~RootVisitor() = default;
|
||||
|
||||
template <typename AnyStrongPersistentType,
|
||||
std::enable_if_t<
|
||||
AnyStrongPersistentType::IsStrongPersistent::value>* = nullptr>
|
||||
void Trace(const AnyStrongPersistentType& p) {
|
||||
using PointeeType = typename AnyStrongPersistentType::PointeeType;
|
||||
const void* object = Extract(p);
|
||||
if (!object) {
|
||||
return;
|
||||
}
|
||||
VisitRoot(object, TraceTrait<PointeeType>::GetTraceDescriptor(object),
|
||||
p.Location());
|
||||
}
|
||||
|
||||
template <typename AnyWeakPersistentType,
|
||||
std::enable_if_t<
|
||||
!AnyWeakPersistentType::IsStrongPersistent::value>* = nullptr>
|
||||
void Trace(const AnyWeakPersistentType& p) {
|
||||
using PointeeType = typename AnyWeakPersistentType::PointeeType;
|
||||
static_assert(!internal::IsAllocatedOnCompactableSpace<PointeeType>::value,
|
||||
"Weak references to compactable objects are not allowed");
|
||||
const void* object = Extract(p);
|
||||
if (!object) {
|
||||
return;
|
||||
}
|
||||
VisitWeakRoot(object, TraceTrait<PointeeType>::GetTraceDescriptor(object),
|
||||
&HandleWeak<AnyWeakPersistentType>, &p, p.Location());
|
||||
}
|
||||
|
||||
protected:
|
||||
virtual void VisitRoot(const void*, TraceDescriptor, const SourceLocation&) {}
|
||||
virtual void VisitWeakRoot(const void* self, TraceDescriptor, WeakCallback,
|
||||
const void* weak_root, const SourceLocation&) {}
|
||||
|
||||
private:
|
||||
template <typename AnyPersistentType>
|
||||
static const void* Extract(AnyPersistentType& p) {
|
||||
using PointeeType = typename AnyPersistentType::PointeeType;
|
||||
static_assert(sizeof(PointeeType),
|
||||
"Persistent's pointee type must be fully defined");
|
||||
static_assert(internal::IsGarbageCollectedOrMixinType<PointeeType>::value,
|
||||
"Persistent's pointee type must be GarbageCollected or "
|
||||
"GarbageCollectedMixin");
|
||||
return p.GetFromGC();
|
||||
}
|
||||
|
||||
template <typename PointerType>
|
||||
static void HandleWeak(const LivenessBroker& info, const void* object) {
|
||||
const PointerType* weak = static_cast<const PointerType*>(object);
|
||||
if (!info.IsHeapObjectAlive(weak->GetFromGC())) {
|
||||
weak->ClearFromGC();
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
} // namespace cppgc
|
||||
|
||||
#endif // INCLUDE_CPPGC_VISITOR_H_
|
||||
615
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/js_native_api.h
generated
vendored
Normal file
615
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/js_native_api.h
generated
vendored
Normal file
@@ -0,0 +1,615 @@
|
||||
#ifndef SRC_JS_NATIVE_API_H_
|
||||
#define SRC_JS_NATIVE_API_H_
|
||||
|
||||
// This file needs to be compatible with C compilers.
|
||||
#include <stdbool.h> // NOLINT(modernize-deprecated-headers)
|
||||
#include <stddef.h> // NOLINT(modernize-deprecated-headers)
|
||||
|
||||
// Use INT_MAX, this should only be consumed by the pre-processor anyway.
|
||||
#define NAPI_VERSION_EXPERIMENTAL 2147483647
|
||||
#ifndef NAPI_VERSION
|
||||
#ifdef NAPI_EXPERIMENTAL
|
||||
#define NAPI_VERSION NAPI_VERSION_EXPERIMENTAL
|
||||
#else
|
||||
// The baseline version for N-API.
|
||||
// The NAPI_VERSION controls which version will be used by default when
|
||||
// compilling a native addon. If the addon developer specifically wants to use
|
||||
// functions available in a new version of N-API that is not yet ported in all
|
||||
// LTS versions, they can set NAPI_VERSION knowing that they have specifically
|
||||
// depended on that version.
|
||||
#define NAPI_VERSION 8
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#include "js_native_api_types.h"
|
||||
|
||||
// If you need __declspec(dllimport), either include <node_api.h> instead, or
|
||||
// define NAPI_EXTERN as __declspec(dllimport) on the compiler's command line.
|
||||
#ifndef NAPI_EXTERN
|
||||
#ifdef _WIN32
|
||||
#define NAPI_EXTERN __declspec(dllexport)
|
||||
#elif defined(__wasm__)
|
||||
#define NAPI_EXTERN \
|
||||
__attribute__((visibility("default"))) \
|
||||
__attribute__((__import_module__("napi")))
|
||||
#else
|
||||
#define NAPI_EXTERN __attribute__((visibility("default")))
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#define NAPI_AUTO_LENGTH SIZE_MAX
|
||||
|
||||
#ifdef __cplusplus
|
||||
#define EXTERN_C_START extern "C" {
|
||||
#define EXTERN_C_END }
|
||||
#else
|
||||
#define EXTERN_C_START
|
||||
#define EXTERN_C_END
|
||||
#endif
|
||||
|
||||
EXTERN_C_START
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_last_error_info(
|
||||
node_api_basic_env env, const napi_extended_error_info** result);
|
||||
|
||||
// Getters for defined singletons
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_undefined(napi_env env,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_null(napi_env env,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_global(napi_env env,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_boolean(napi_env env,
|
||||
bool value,
|
||||
napi_value* result);
|
||||
|
||||
// Methods to create Primitive types/Objects
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_object(napi_env env,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_array(napi_env env,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_array_with_length(napi_env env, size_t length, napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_double(napi_env env,
|
||||
double value,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_int32(napi_env env,
|
||||
int32_t value,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_uint32(napi_env env,
|
||||
uint32_t value,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_int64(napi_env env,
|
||||
int64_t value,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_string_latin1(
|
||||
napi_env env, const char* str, size_t length, napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_string_utf8(napi_env env,
|
||||
const char* str,
|
||||
size_t length,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_string_utf16(napi_env env,
|
||||
const char16_t* str,
|
||||
size_t length,
|
||||
napi_value* result);
|
||||
#if NAPI_VERSION >= 10
|
||||
NAPI_EXTERN napi_status NAPI_CDECL node_api_create_external_string_latin1(
|
||||
napi_env env,
|
||||
char* str,
|
||||
size_t length,
|
||||
node_api_basic_finalize finalize_callback,
|
||||
void* finalize_hint,
|
||||
napi_value* result,
|
||||
bool* copied);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
node_api_create_external_string_utf16(napi_env env,
|
||||
char16_t* str,
|
||||
size_t length,
|
||||
node_api_basic_finalize finalize_callback,
|
||||
void* finalize_hint,
|
||||
napi_value* result,
|
||||
bool* copied);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL node_api_create_property_key_latin1(
|
||||
napi_env env, const char* str, size_t length, napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL node_api_create_property_key_utf8(
|
||||
napi_env env, const char* str, size_t length, napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL node_api_create_property_key_utf16(
|
||||
napi_env env, const char16_t* str, size_t length, napi_value* result);
|
||||
#endif // NAPI_VERSION >= 10
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_symbol(napi_env env,
|
||||
napi_value description,
|
||||
napi_value* result);
|
||||
#if NAPI_VERSION >= 9
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
node_api_symbol_for(napi_env env,
|
||||
const char* utf8description,
|
||||
size_t length,
|
||||
napi_value* result);
|
||||
#endif // NAPI_VERSION >= 9
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_function(napi_env env,
|
||||
const char* utf8name,
|
||||
size_t length,
|
||||
napi_callback cb,
|
||||
void* data,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_error(napi_env env,
|
||||
napi_value code,
|
||||
napi_value msg,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_type_error(napi_env env,
|
||||
napi_value code,
|
||||
napi_value msg,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_range_error(napi_env env,
|
||||
napi_value code,
|
||||
napi_value msg,
|
||||
napi_value* result);
|
||||
#if NAPI_VERSION >= 9
|
||||
NAPI_EXTERN napi_status NAPI_CDECL node_api_create_syntax_error(
|
||||
napi_env env, napi_value code, napi_value msg, napi_value* result);
|
||||
#endif // NAPI_VERSION >= 9
|
||||
|
||||
// Methods to get the native napi_value from Primitive type
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_typeof(napi_env env,
|
||||
napi_value value,
|
||||
napi_valuetype* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_double(napi_env env,
|
||||
napi_value value,
|
||||
double* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_int32(napi_env env,
|
||||
napi_value value,
|
||||
int32_t* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_uint32(napi_env env,
|
||||
napi_value value,
|
||||
uint32_t* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_int64(napi_env env,
|
||||
napi_value value,
|
||||
int64_t* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_bool(napi_env env,
|
||||
napi_value value,
|
||||
bool* result);
|
||||
|
||||
// Copies LATIN-1 encoded bytes from a string into a buffer.
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_string_latin1(
|
||||
napi_env env, napi_value value, char* buf, size_t bufsize, size_t* result);
|
||||
|
||||
// Copies UTF-8 encoded bytes from a string into a buffer.
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_string_utf8(
|
||||
napi_env env, napi_value value, char* buf, size_t bufsize, size_t* result);
|
||||
|
||||
// Copies UTF-16 encoded bytes from a string into a buffer.
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_string_utf16(napi_env env,
|
||||
napi_value value,
|
||||
char16_t* buf,
|
||||
size_t bufsize,
|
||||
size_t* result);
|
||||
|
||||
// Methods to coerce values
|
||||
// These APIs may execute user scripts
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_coerce_to_bool(napi_env env,
|
||||
napi_value value,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_coerce_to_number(napi_env env,
|
||||
napi_value value,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_coerce_to_object(napi_env env,
|
||||
napi_value value,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_coerce_to_string(napi_env env,
|
||||
napi_value value,
|
||||
napi_value* result);
|
||||
|
||||
// Methods to work with Objects
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_prototype(napi_env env,
|
||||
napi_value object,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_property_names(napi_env env,
|
||||
napi_value object,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_set_property(napi_env env,
|
||||
napi_value object,
|
||||
napi_value key,
|
||||
napi_value value);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_has_property(napi_env env,
|
||||
napi_value object,
|
||||
napi_value key,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_property(napi_env env,
|
||||
napi_value object,
|
||||
napi_value key,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_delete_property(napi_env env,
|
||||
napi_value object,
|
||||
napi_value key,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_has_own_property(napi_env env,
|
||||
napi_value object,
|
||||
napi_value key,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_set_named_property(napi_env env,
|
||||
napi_value object,
|
||||
const char* utf8name,
|
||||
napi_value value);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_has_named_property(napi_env env,
|
||||
napi_value object,
|
||||
const char* utf8name,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_named_property(napi_env env,
|
||||
napi_value object,
|
||||
const char* utf8name,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_set_element(napi_env env,
|
||||
napi_value object,
|
||||
uint32_t index,
|
||||
napi_value value);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_has_element(napi_env env,
|
||||
napi_value object,
|
||||
uint32_t index,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_element(napi_env env,
|
||||
napi_value object,
|
||||
uint32_t index,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_delete_element(napi_env env,
|
||||
napi_value object,
|
||||
uint32_t index,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_define_properties(napi_env env,
|
||||
napi_value object,
|
||||
size_t property_count,
|
||||
const napi_property_descriptor* properties);
|
||||
|
||||
// Methods to work with Arrays
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_is_array(napi_env env,
|
||||
napi_value value,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_array_length(napi_env env,
|
||||
napi_value value,
|
||||
uint32_t* result);
|
||||
|
||||
// Methods to compare values
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_strict_equals(napi_env env,
|
||||
napi_value lhs,
|
||||
napi_value rhs,
|
||||
bool* result);
|
||||
|
||||
// Methods to work with Functions
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_call_function(napi_env env,
|
||||
napi_value recv,
|
||||
napi_value func,
|
||||
size_t argc,
|
||||
const napi_value* argv,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_new_instance(napi_env env,
|
||||
napi_value constructor,
|
||||
size_t argc,
|
||||
const napi_value* argv,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_instanceof(napi_env env,
|
||||
napi_value object,
|
||||
napi_value constructor,
|
||||
bool* result);
|
||||
|
||||
// Methods to work with napi_callbacks
|
||||
|
||||
// Gets all callback info in a single call. (Ugly, but faster.)
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_cb_info(
|
||||
napi_env env, // [in] Node-API environment handle
|
||||
napi_callback_info cbinfo, // [in] Opaque callback-info handle
|
||||
size_t* argc, // [in-out] Specifies the size of the provided argv array
|
||||
// and receives the actual count of args.
|
||||
napi_value* argv, // [out] Array of values
|
||||
napi_value* this_arg, // [out] Receives the JS 'this' arg for the call
|
||||
void** data); // [out] Receives the data pointer for the callback.
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_new_target(
|
||||
napi_env env, napi_callback_info cbinfo, napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_define_class(napi_env env,
|
||||
const char* utf8name,
|
||||
size_t length,
|
||||
napi_callback constructor,
|
||||
void* data,
|
||||
size_t property_count,
|
||||
const napi_property_descriptor* properties,
|
||||
napi_value* result);
|
||||
|
||||
// Methods to work with external data objects
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_wrap(napi_env env,
|
||||
napi_value js_object,
|
||||
void* native_object,
|
||||
node_api_basic_finalize finalize_cb,
|
||||
void* finalize_hint,
|
||||
napi_ref* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_unwrap(napi_env env,
|
||||
napi_value js_object,
|
||||
void** result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_remove_wrap(napi_env env,
|
||||
napi_value js_object,
|
||||
void** result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_external(napi_env env,
|
||||
void* data,
|
||||
node_api_basic_finalize finalize_cb,
|
||||
void* finalize_hint,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_external(napi_env env,
|
||||
napi_value value,
|
||||
void** result);
|
||||
|
||||
// Methods to control object lifespan
|
||||
|
||||
// Set initial_refcount to 0 for a weak reference, >0 for a strong reference.
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_reference(napi_env env,
|
||||
napi_value value,
|
||||
uint32_t initial_refcount,
|
||||
napi_ref* result);
|
||||
|
||||
// Deletes a reference. The referenced value is released, and may
|
||||
// be GC'd unless there are other references to it.
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_delete_reference(napi_env env,
|
||||
napi_ref ref);
|
||||
|
||||
// Increments the reference count, optionally returning the resulting count.
|
||||
// After this call the reference will be a strong reference because its
|
||||
// refcount is >0, and the referenced object is effectively "pinned".
|
||||
// Calling this when the refcount is 0 and the object is unavailable
|
||||
// results in an error.
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_reference_ref(napi_env env,
|
||||
napi_ref ref,
|
||||
uint32_t* result);
|
||||
|
||||
// Decrements the reference count, optionally returning the resulting count.
|
||||
// If the result is 0 the reference is now weak and the object may be GC'd
|
||||
// at any time if there are no other references. Calling this when the
|
||||
// refcount is already 0 results in an error.
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_reference_unref(napi_env env,
|
||||
napi_ref ref,
|
||||
uint32_t* result);
|
||||
|
||||
// Attempts to get a referenced value. If the reference is weak,
|
||||
// the value might no longer be available, in that case the call
|
||||
// is still successful but the result is NULL.
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_reference_value(napi_env env,
|
||||
napi_ref ref,
|
||||
napi_value* result);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_open_handle_scope(napi_env env, napi_handle_scope* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_close_handle_scope(napi_env env, napi_handle_scope scope);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_open_escapable_handle_scope(
|
||||
napi_env env, napi_escapable_handle_scope* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_close_escapable_handle_scope(
|
||||
napi_env env, napi_escapable_handle_scope scope);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_escape_handle(napi_env env,
|
||||
napi_escapable_handle_scope scope,
|
||||
napi_value escapee,
|
||||
napi_value* result);
|
||||
|
||||
// Methods to support error handling
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_throw(napi_env env, napi_value error);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_throw_error(napi_env env,
|
||||
const char* code,
|
||||
const char* msg);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_throw_type_error(napi_env env,
|
||||
const char* code,
|
||||
const char* msg);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_throw_range_error(napi_env env,
|
||||
const char* code,
|
||||
const char* msg);
|
||||
#if NAPI_VERSION >= 9
|
||||
NAPI_EXTERN napi_status NAPI_CDECL node_api_throw_syntax_error(napi_env env,
|
||||
const char* code,
|
||||
const char* msg);
|
||||
#endif // NAPI_VERSION >= 9
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_is_error(napi_env env,
|
||||
napi_value value,
|
||||
bool* result);
|
||||
|
||||
// Methods to support catching exceptions
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_is_exception_pending(napi_env env,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_get_and_clear_last_exception(napi_env env, napi_value* result);
|
||||
|
||||
// Methods to work with array buffers and typed arrays
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_is_arraybuffer(napi_env env,
|
||||
napi_value value,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_arraybuffer(napi_env env,
|
||||
size_t byte_length,
|
||||
void** data,
|
||||
napi_value* result);
|
||||
#ifndef NODE_API_NO_EXTERNAL_BUFFERS_ALLOWED
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_external_arraybuffer(napi_env env,
|
||||
void* external_data,
|
||||
size_t byte_length,
|
||||
node_api_basic_finalize finalize_cb,
|
||||
void* finalize_hint,
|
||||
napi_value* result);
|
||||
#endif // NODE_API_NO_EXTERNAL_BUFFERS_ALLOWED
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_arraybuffer_info(
|
||||
napi_env env, napi_value arraybuffer, void** data, size_t* byte_length);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_is_typedarray(napi_env env,
|
||||
napi_value value,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_typedarray(napi_env env,
|
||||
napi_typedarray_type type,
|
||||
size_t length,
|
||||
napi_value arraybuffer,
|
||||
size_t byte_offset,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_get_typedarray_info(napi_env env,
|
||||
napi_value typedarray,
|
||||
napi_typedarray_type* type,
|
||||
size_t* length,
|
||||
void** data,
|
||||
napi_value* arraybuffer,
|
||||
size_t* byte_offset);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_dataview(napi_env env,
|
||||
size_t length,
|
||||
napi_value arraybuffer,
|
||||
size_t byte_offset,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_is_dataview(napi_env env,
|
||||
napi_value value,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_get_dataview_info(napi_env env,
|
||||
napi_value dataview,
|
||||
size_t* bytelength,
|
||||
void** data,
|
||||
napi_value* arraybuffer,
|
||||
size_t* byte_offset);
|
||||
|
||||
// version management
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_version(node_api_basic_env env,
|
||||
uint32_t* result);
|
||||
|
||||
// Promises
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_promise(napi_env env,
|
||||
napi_deferred* deferred,
|
||||
napi_value* promise);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_resolve_deferred(napi_env env,
|
||||
napi_deferred deferred,
|
||||
napi_value resolution);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_reject_deferred(napi_env env,
|
||||
napi_deferred deferred,
|
||||
napi_value rejection);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_is_promise(napi_env env,
|
||||
napi_value value,
|
||||
bool* is_promise);
|
||||
|
||||
// Running a script
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_run_script(napi_env env,
|
||||
napi_value script,
|
||||
napi_value* result);
|
||||
|
||||
// Memory management
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_adjust_external_memory(
|
||||
node_api_basic_env env, int64_t change_in_bytes, int64_t* adjusted_value);
|
||||
|
||||
#if NAPI_VERSION >= 5
|
||||
|
||||
// Dates
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_date(napi_env env,
|
||||
double time,
|
||||
napi_value* result);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_is_date(napi_env env,
|
||||
napi_value value,
|
||||
bool* is_date);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_date_value(napi_env env,
|
||||
napi_value value,
|
||||
double* result);
|
||||
|
||||
// Add finalizer for pointer
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_add_finalizer(napi_env env,
|
||||
napi_value js_object,
|
||||
void* finalize_data,
|
||||
node_api_basic_finalize finalize_cb,
|
||||
void* finalize_hint,
|
||||
napi_ref* result);
|
||||
|
||||
#endif // NAPI_VERSION >= 5
|
||||
|
||||
#ifdef NAPI_EXPERIMENTAL
|
||||
#define NODE_API_EXPERIMENTAL_HAS_POST_FINALIZER
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
node_api_post_finalizer(node_api_basic_env env,
|
||||
napi_finalize finalize_cb,
|
||||
void* finalize_data,
|
||||
void* finalize_hint);
|
||||
|
||||
#endif // NAPI_EXPERIMENTAL
|
||||
|
||||
#if NAPI_VERSION >= 6
|
||||
|
||||
// BigInt
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_bigint_int64(napi_env env,
|
||||
int64_t value,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_bigint_uint64(napi_env env, uint64_t value, napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_bigint_words(napi_env env,
|
||||
int sign_bit,
|
||||
size_t word_count,
|
||||
const uint64_t* words,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_bigint_int64(napi_env env,
|
||||
napi_value value,
|
||||
int64_t* result,
|
||||
bool* lossless);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_value_bigint_uint64(
|
||||
napi_env env, napi_value value, uint64_t* result, bool* lossless);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_get_value_bigint_words(napi_env env,
|
||||
napi_value value,
|
||||
int* sign_bit,
|
||||
size_t* word_count,
|
||||
uint64_t* words);
|
||||
|
||||
// Object
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_get_all_property_names(napi_env env,
|
||||
napi_value object,
|
||||
napi_key_collection_mode key_mode,
|
||||
napi_key_filter key_filter,
|
||||
napi_key_conversion key_conversion,
|
||||
napi_value* result);
|
||||
|
||||
// Instance data
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_set_instance_data(node_api_basic_env env,
|
||||
void* data,
|
||||
napi_finalize finalize_cb,
|
||||
void* finalize_hint);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_get_instance_data(node_api_basic_env env, void** data);
|
||||
#endif // NAPI_VERSION >= 6
|
||||
|
||||
#if NAPI_VERSION >= 7
|
||||
// ArrayBuffer detaching
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_detach_arraybuffer(napi_env env, napi_value arraybuffer);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_is_detached_arraybuffer(napi_env env, napi_value value, bool* result);
|
||||
#endif // NAPI_VERSION >= 7
|
||||
|
||||
#if NAPI_VERSION >= 8
|
||||
// Type tagging
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_type_tag_object(
|
||||
napi_env env, napi_value value, const napi_type_tag* type_tag);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_check_object_type_tag(napi_env env,
|
||||
napi_value value,
|
||||
const napi_type_tag* type_tag,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_object_freeze(napi_env env,
|
||||
napi_value object);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_object_seal(napi_env env,
|
||||
napi_value object);
|
||||
#endif // NAPI_VERSION >= 8
|
||||
|
||||
EXTERN_C_END
|
||||
|
||||
#endif // SRC_JS_NATIVE_API_H_
|
||||
211
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/js_native_api_types.h
generated
vendored
Normal file
211
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/js_native_api_types.h
generated
vendored
Normal file
@@ -0,0 +1,211 @@
|
||||
#ifndef SRC_JS_NATIVE_API_TYPES_H_
|
||||
#define SRC_JS_NATIVE_API_TYPES_H_
|
||||
|
||||
// This file needs to be compatible with C compilers.
|
||||
// This is a public include file, and these includes have essentially
|
||||
// became part of it's API.
|
||||
#include <stddef.h> // NOLINT(modernize-deprecated-headers)
|
||||
#include <stdint.h> // NOLINT(modernize-deprecated-headers)
|
||||
|
||||
#if !defined __cplusplus || (defined(_MSC_VER) && _MSC_VER < 1900)
|
||||
typedef uint16_t char16_t;
|
||||
#endif
|
||||
|
||||
#ifndef NAPI_CDECL
|
||||
#ifdef _WIN32
|
||||
#define NAPI_CDECL __cdecl
|
||||
#else
|
||||
#define NAPI_CDECL
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// JSVM API types are all opaque pointers for ABI stability
|
||||
// typedef undefined structs instead of void* for compile time type safety
|
||||
typedef struct napi_env__* napi_env;
|
||||
|
||||
// We need to mark APIs which can be called during garbage collection (GC),
|
||||
// meaning that they do not affect the state of the JS engine, and can
|
||||
// therefore be called synchronously from a finalizer that itself runs
|
||||
// synchronously during GC. Such APIs can receive either a `napi_env` or a
|
||||
// `node_api_basic_env` as their first parameter, because we should be able to
|
||||
// also call them during normal, non-garbage-collecting operations, whereas
|
||||
// APIs that affect the state of the JS engine can only receive a `napi_env` as
|
||||
// their first parameter, because we must not call them during GC. In lieu of
|
||||
// inheritance, we use the properties of the const qualifier to accomplish
|
||||
// this, because both a const and a non-const value can be passed to an API
|
||||
// expecting a const value, but only a non-const value can be passed to an API
|
||||
// expecting a non-const value.
|
||||
//
|
||||
// In conjunction with appropriate CFLAGS to warn us if we're passing a const
|
||||
// (basic) environment into an API that expects a non-const environment, and
|
||||
// the definition of basic finalizer function pointer types below, which
|
||||
// receive a basic environment as their first parameter, and can thus only call
|
||||
// basic APIs (unless the user explicitly casts the environment), we achieve
|
||||
// the ability to ensure at compile time that we do not call APIs that affect
|
||||
// the state of the JS engine from a synchronous (basic) finalizer.
|
||||
#if !defined(NAPI_EXPERIMENTAL) || \
|
||||
(defined(NAPI_EXPERIMENTAL) && \
|
||||
(defined(NODE_API_EXPERIMENTAL_NOGC_ENV_OPT_OUT) || \
|
||||
defined(NODE_API_EXPERIMENTAL_BASIC_ENV_OPT_OUT)))
|
||||
typedef struct napi_env__* node_api_nogc_env;
|
||||
#else
|
||||
typedef const struct napi_env__* node_api_nogc_env;
|
||||
#endif
|
||||
typedef node_api_nogc_env node_api_basic_env;
|
||||
|
||||
typedef struct napi_value__* napi_value;
|
||||
typedef struct napi_ref__* napi_ref;
|
||||
typedef struct napi_handle_scope__* napi_handle_scope;
|
||||
typedef struct napi_escapable_handle_scope__* napi_escapable_handle_scope;
|
||||
typedef struct napi_callback_info__* napi_callback_info;
|
||||
typedef struct napi_deferred__* napi_deferred;
|
||||
|
||||
typedef enum {
|
||||
napi_default = 0,
|
||||
napi_writable = 1 << 0,
|
||||
napi_enumerable = 1 << 1,
|
||||
napi_configurable = 1 << 2,
|
||||
|
||||
// Used with napi_define_class to distinguish static properties
|
||||
// from instance properties. Ignored by napi_define_properties.
|
||||
napi_static = 1 << 10,
|
||||
|
||||
#if NAPI_VERSION >= 8
|
||||
// Default for class methods.
|
||||
napi_default_method = napi_writable | napi_configurable,
|
||||
|
||||
// Default for object properties, like in JS obj[prop].
|
||||
napi_default_jsproperty = napi_writable | napi_enumerable | napi_configurable,
|
||||
#endif // NAPI_VERSION >= 8
|
||||
} napi_property_attributes;
|
||||
|
||||
typedef enum {
|
||||
// ES6 types (corresponds to typeof)
|
||||
napi_undefined,
|
||||
napi_null,
|
||||
napi_boolean,
|
||||
napi_number,
|
||||
napi_string,
|
||||
napi_symbol,
|
||||
napi_object,
|
||||
napi_function,
|
||||
napi_external,
|
||||
napi_bigint,
|
||||
} napi_valuetype;
|
||||
|
||||
typedef enum {
|
||||
napi_int8_array,
|
||||
napi_uint8_array,
|
||||
napi_uint8_clamped_array,
|
||||
napi_int16_array,
|
||||
napi_uint16_array,
|
||||
napi_int32_array,
|
||||
napi_uint32_array,
|
||||
napi_float32_array,
|
||||
napi_float64_array,
|
||||
napi_bigint64_array,
|
||||
napi_biguint64_array,
|
||||
} napi_typedarray_type;
|
||||
|
||||
typedef enum {
|
||||
napi_ok,
|
||||
napi_invalid_arg,
|
||||
napi_object_expected,
|
||||
napi_string_expected,
|
||||
napi_name_expected,
|
||||
napi_function_expected,
|
||||
napi_number_expected,
|
||||
napi_boolean_expected,
|
||||
napi_array_expected,
|
||||
napi_generic_failure,
|
||||
napi_pending_exception,
|
||||
napi_cancelled,
|
||||
napi_escape_called_twice,
|
||||
napi_handle_scope_mismatch,
|
||||
napi_callback_scope_mismatch,
|
||||
napi_queue_full,
|
||||
napi_closing,
|
||||
napi_bigint_expected,
|
||||
napi_date_expected,
|
||||
napi_arraybuffer_expected,
|
||||
napi_detachable_arraybuffer_expected,
|
||||
napi_would_deadlock, // unused
|
||||
napi_no_external_buffers_allowed,
|
||||
napi_cannot_run_js,
|
||||
} napi_status;
|
||||
// Note: when adding a new enum value to `napi_status`, please also update
|
||||
// * `const int last_status` in the definition of `napi_get_last_error_info()'
|
||||
// in file js_native_api_v8.cc.
|
||||
// * `const char* error_messages[]` in file js_native_api_v8.cc with a brief
|
||||
// message explaining the error.
|
||||
// * the definition of `napi_status` in doc/api/n-api.md to reflect the newly
|
||||
// added value(s).
|
||||
|
||||
typedef napi_value(NAPI_CDECL* napi_callback)(napi_env env,
|
||||
napi_callback_info info);
|
||||
typedef void(NAPI_CDECL* napi_finalize)(napi_env env,
|
||||
void* finalize_data,
|
||||
void* finalize_hint);
|
||||
|
||||
#if !defined(NAPI_EXPERIMENTAL) || \
|
||||
(defined(NAPI_EXPERIMENTAL) && \
|
||||
(defined(NODE_API_EXPERIMENTAL_NOGC_ENV_OPT_OUT) || \
|
||||
defined(NODE_API_EXPERIMENTAL_BASIC_ENV_OPT_OUT)))
|
||||
typedef napi_finalize node_api_nogc_finalize;
|
||||
#else
|
||||
typedef void(NAPI_CDECL* node_api_nogc_finalize)(node_api_nogc_env env,
|
||||
void* finalize_data,
|
||||
void* finalize_hint);
|
||||
#endif
|
||||
typedef node_api_nogc_finalize node_api_basic_finalize;
|
||||
|
||||
typedef struct {
|
||||
// One of utf8name or name should be NULL.
|
||||
const char* utf8name;
|
||||
napi_value name;
|
||||
|
||||
napi_callback method;
|
||||
napi_callback getter;
|
||||
napi_callback setter;
|
||||
napi_value value;
|
||||
|
||||
napi_property_attributes attributes;
|
||||
void* data;
|
||||
} napi_property_descriptor;
|
||||
|
||||
typedef struct {
|
||||
const char* error_message;
|
||||
void* engine_reserved;
|
||||
uint32_t engine_error_code;
|
||||
napi_status error_code;
|
||||
} napi_extended_error_info;
|
||||
|
||||
#if NAPI_VERSION >= 6
|
||||
typedef enum {
|
||||
napi_key_include_prototypes,
|
||||
napi_key_own_only
|
||||
} napi_key_collection_mode;
|
||||
|
||||
typedef enum {
|
||||
napi_key_all_properties = 0,
|
||||
napi_key_writable = 1,
|
||||
napi_key_enumerable = 1 << 1,
|
||||
napi_key_configurable = 1 << 2,
|
||||
napi_key_skip_strings = 1 << 3,
|
||||
napi_key_skip_symbols = 1 << 4
|
||||
} napi_key_filter;
|
||||
|
||||
typedef enum {
|
||||
napi_key_keep_numbers,
|
||||
napi_key_numbers_to_strings
|
||||
} napi_key_conversion;
|
||||
#endif // NAPI_VERSION >= 6
|
||||
|
||||
#if NAPI_VERSION >= 8
|
||||
typedef struct {
|
||||
uint64_t lower;
|
||||
uint64_t upper;
|
||||
} napi_type_tag;
|
||||
#endif // NAPI_VERSION >= 8
|
||||
|
||||
#endif // SRC_JS_NATIVE_API_TYPES_H_
|
||||
29
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/libplatform/libplatform-export.h
generated
vendored
Normal file
29
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/libplatform/libplatform-export.h
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
// Copyright 2016 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef V8_LIBPLATFORM_LIBPLATFORM_EXPORT_H_
|
||||
#define V8_LIBPLATFORM_LIBPLATFORM_EXPORT_H_
|
||||
|
||||
#if defined(_WIN32)
|
||||
|
||||
#ifdef BUILDING_V8_PLATFORM_SHARED
|
||||
#define V8_PLATFORM_EXPORT __declspec(dllexport)
|
||||
#elif USING_V8_PLATFORM_SHARED
|
||||
#define V8_PLATFORM_EXPORT __declspec(dllimport)
|
||||
#else
|
||||
#define V8_PLATFORM_EXPORT
|
||||
#endif // BUILDING_V8_PLATFORM_SHARED
|
||||
|
||||
#else // defined(_WIN32)
|
||||
|
||||
// Setup for Linux shared library export.
|
||||
#ifdef BUILDING_V8_PLATFORM_SHARED
|
||||
#define V8_PLATFORM_EXPORT __attribute__((visibility("default")))
|
||||
#else
|
||||
#define V8_PLATFORM_EXPORT
|
||||
#endif
|
||||
|
||||
#endif // defined(_WIN32)
|
||||
|
||||
#endif // V8_LIBPLATFORM_LIBPLATFORM_EXPORT_H_
|
||||
112
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/libplatform/libplatform.h
generated
vendored
Normal file
112
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/libplatform/libplatform.h
generated
vendored
Normal file
@@ -0,0 +1,112 @@
|
||||
// Copyright 2014 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef V8_LIBPLATFORM_LIBPLATFORM_H_
|
||||
#define V8_LIBPLATFORM_LIBPLATFORM_H_
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "libplatform/libplatform-export.h"
|
||||
#include "libplatform/v8-tracing.h"
|
||||
#include "v8-platform.h" // NOLINT(build/include_directory)
|
||||
#include "v8config.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace v8 {
|
||||
namespace platform {
|
||||
|
||||
enum class IdleTaskSupport { kDisabled, kEnabled };
|
||||
enum class InProcessStackDumping { kDisabled, kEnabled };
|
||||
|
||||
enum class MessageLoopBehavior : bool {
|
||||
kDoNotWait = false,
|
||||
kWaitForWork = true
|
||||
};
|
||||
|
||||
enum class PriorityMode : bool { kDontApply, kApply };
|
||||
|
||||
/**
|
||||
* Returns a new instance of the default v8::Platform implementation.
|
||||
*
|
||||
* The caller will take ownership of the returned pointer. |thread_pool_size|
|
||||
* is the number of worker threads to allocate for background jobs. If a value
|
||||
* of zero is passed, a suitable default based on the current number of
|
||||
* processors online will be chosen.
|
||||
* If |idle_task_support| is enabled then the platform will accept idle
|
||||
* tasks (IdleTasksEnabled will return true) and will rely on the embedder
|
||||
* calling v8::platform::RunIdleTasks to process the idle tasks.
|
||||
* If |tracing_controller| is nullptr, the default platform will create a
|
||||
* v8::platform::TracingController instance and use it.
|
||||
* If |priority_mode| is PriorityMode::kApply, the default platform will use
|
||||
* multiple task queues executed by threads different system-level priorities
|
||||
* (where available) to schedule tasks.
|
||||
*/
|
||||
V8_PLATFORM_EXPORT std::unique_ptr<v8::Platform> NewDefaultPlatform(
|
||||
int thread_pool_size = 0,
|
||||
IdleTaskSupport idle_task_support = IdleTaskSupport::kDisabled,
|
||||
InProcessStackDumping in_process_stack_dumping =
|
||||
InProcessStackDumping::kDisabled,
|
||||
std::unique_ptr<v8::TracingController> tracing_controller = {},
|
||||
PriorityMode priority_mode = PriorityMode::kDontApply);
|
||||
|
||||
/**
|
||||
* The same as NewDefaultPlatform but disables the worker thread pool.
|
||||
* It must be used with the --single-threaded V8 flag.
|
||||
*/
|
||||
V8_PLATFORM_EXPORT std::unique_ptr<v8::Platform>
|
||||
NewSingleThreadedDefaultPlatform(
|
||||
IdleTaskSupport idle_task_support = IdleTaskSupport::kDisabled,
|
||||
InProcessStackDumping in_process_stack_dumping =
|
||||
InProcessStackDumping::kDisabled,
|
||||
std::unique_ptr<v8::TracingController> tracing_controller = {});
|
||||
|
||||
/**
|
||||
* Returns a new instance of the default v8::JobHandle implementation.
|
||||
*
|
||||
* The job will be executed by spawning up to |num_worker_threads| many worker
|
||||
* threads on the provided |platform| with the given |priority|.
|
||||
*/
|
||||
V8_PLATFORM_EXPORT std::unique_ptr<v8::JobHandle> NewDefaultJobHandle(
|
||||
v8::Platform* platform, v8::TaskPriority priority,
|
||||
std::unique_ptr<v8::JobTask> job_task, size_t num_worker_threads);
|
||||
|
||||
/**
|
||||
* Pumps the message loop for the given isolate.
|
||||
*
|
||||
* The caller has to make sure that this is called from the right thread.
|
||||
* Returns true if a task was executed, and false otherwise. If the call to
|
||||
* PumpMessageLoop is nested within another call to PumpMessageLoop, only
|
||||
* nestable tasks may run. Otherwise, any task may run. Unless requested through
|
||||
* the |behavior| parameter, this call does not block if no task is pending. The
|
||||
* |platform| has to be created using |NewDefaultPlatform|.
|
||||
*/
|
||||
V8_PLATFORM_EXPORT bool PumpMessageLoop(
|
||||
v8::Platform* platform, v8::Isolate* isolate,
|
||||
MessageLoopBehavior behavior = MessageLoopBehavior::kDoNotWait);
|
||||
|
||||
/**
|
||||
* Runs pending idle tasks for at most |idle_time_in_seconds| seconds.
|
||||
*
|
||||
* The caller has to make sure that this is called from the right thread.
|
||||
* This call does not block if no task is pending. The |platform| has to be
|
||||
* created using |NewDefaultPlatform|.
|
||||
*/
|
||||
V8_PLATFORM_EXPORT void RunIdleTasks(v8::Platform* platform,
|
||||
v8::Isolate* isolate,
|
||||
double idle_time_in_seconds);
|
||||
|
||||
/**
|
||||
* Notifies the given platform about the Isolate getting deleted soon. Has to be
|
||||
* called for all Isolates which are deleted - unless we're shutting down the
|
||||
* platform.
|
||||
*
|
||||
* The |platform| has to be created using |NewDefaultPlatform|.
|
||||
*
|
||||
*/
|
||||
V8_PLATFORM_EXPORT void NotifyIsolateShutdown(v8::Platform* platform,
|
||||
Isolate* isolate);
|
||||
|
||||
} // namespace platform
|
||||
} // namespace v8
|
||||
|
||||
#endif // V8_LIBPLATFORM_LIBPLATFORM_H_
|
||||
333
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/libplatform/v8-tracing.h
generated
vendored
Normal file
333
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/libplatform/v8-tracing.h
generated
vendored
Normal file
@@ -0,0 +1,333 @@
|
||||
// Copyright 2016 the V8 project authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef V8_LIBPLATFORM_V8_TRACING_H_
|
||||
#define V8_LIBPLATFORM_V8_TRACING_H_
|
||||
|
||||
#include <atomic>
|
||||
#include <fstream>
|
||||
#include <memory>
|
||||
#include <unordered_set>
|
||||
#include <vector>
|
||||
|
||||
#include "libplatform/libplatform-export.h"
|
||||
#include "v8-platform.h" // NOLINT(build/include_directory)
|
||||
|
||||
namespace perfetto {
|
||||
namespace trace_processor {
|
||||
class TraceProcessorStorage;
|
||||
}
|
||||
class TracingSession;
|
||||
}
|
||||
|
||||
namespace v8 {
|
||||
|
||||
namespace base {
|
||||
class Mutex;
|
||||
} // namespace base
|
||||
|
||||
namespace platform {
|
||||
namespace tracing {
|
||||
|
||||
class TraceEventListener;
|
||||
|
||||
const int kTraceMaxNumArgs = 2;
|
||||
|
||||
class V8_PLATFORM_EXPORT TraceObject {
|
||||
public:
|
||||
union ArgValue {
|
||||
uint64_t as_uint;
|
||||
int64_t as_int;
|
||||
double as_double;
|
||||
const void* as_pointer;
|
||||
const char* as_string;
|
||||
};
|
||||
|
||||
TraceObject() = default;
|
||||
~TraceObject();
|
||||
void Initialize(
|
||||
char phase, const uint8_t* category_enabled_flag, const char* name,
|
||||
const char* scope, uint64_t id, uint64_t bind_id, int num_args,
|
||||
const char** arg_names, const uint8_t* arg_types,
|
||||
const uint64_t* arg_values,
|
||||
std::unique_ptr<v8::ConvertableToTraceFormat>* arg_convertables,
|
||||
unsigned int flags, int64_t timestamp, int64_t cpu_timestamp);
|
||||
void UpdateDuration(int64_t timestamp, int64_t cpu_timestamp);
|
||||
void InitializeForTesting(
|
||||
char phase, const uint8_t* category_enabled_flag, const char* name,
|
||||
const char* scope, uint64_t id, uint64_t bind_id, int num_args,
|
||||
const char** arg_names, const uint8_t* arg_types,
|
||||
const uint64_t* arg_values,
|
||||
std::unique_ptr<v8::ConvertableToTraceFormat>* arg_convertables,
|
||||
unsigned int flags, int pid, int tid, int64_t ts, int64_t tts,
|
||||
uint64_t duration, uint64_t cpu_duration);
|
||||
|
||||
int pid() const { return pid_; }
|
||||
int tid() const { return tid_; }
|
||||
char phase() const { return phase_; }
|
||||
const uint8_t* category_enabled_flag() const {
|
||||
return category_enabled_flag_;
|
||||
}
|
||||
const char* name() const { return name_; }
|
||||
const char* scope() const { return scope_; }
|
||||
uint64_t id() const { return id_; }
|
||||
uint64_t bind_id() const { return bind_id_; }
|
||||
int num_args() const { return num_args_; }
|
||||
const char** arg_names() { return arg_names_; }
|
||||
uint8_t* arg_types() { return arg_types_; }
|
||||
ArgValue* arg_values() { return arg_values_; }
|
||||
std::unique_ptr<v8::ConvertableToTraceFormat>* arg_convertables() {
|
||||
return arg_convertables_;
|
||||
}
|
||||
unsigned int flags() const { return flags_; }
|
||||
int64_t ts() { return ts_; }
|
||||
int64_t tts() { return tts_; }
|
||||
uint64_t duration() { return duration_; }
|
||||
uint64_t cpu_duration() { return cpu_duration_; }
|
||||
|
||||
private:
|
||||
int pid_;
|
||||
int tid_;
|
||||
char phase_;
|
||||
const char* name_;
|
||||
const char* scope_;
|
||||
const uint8_t* category_enabled_flag_;
|
||||
uint64_t id_;
|
||||
uint64_t bind_id_;
|
||||
int num_args_ = 0;
|
||||
const char* arg_names_[kTraceMaxNumArgs];
|
||||
uint8_t arg_types_[kTraceMaxNumArgs];
|
||||
ArgValue arg_values_[kTraceMaxNumArgs];
|
||||
std::unique_ptr<v8::ConvertableToTraceFormat>
|
||||
arg_convertables_[kTraceMaxNumArgs];
|
||||
char* parameter_copy_storage_ = nullptr;
|
||||
unsigned int flags_;
|
||||
int64_t ts_;
|
||||
int64_t tts_;
|
||||
uint64_t duration_;
|
||||
uint64_t cpu_duration_;
|
||||
|
||||
// Disallow copy and assign
|
||||
TraceObject(const TraceObject&) = delete;
|
||||
void operator=(const TraceObject&) = delete;
|
||||
};
|
||||
|
||||
class V8_PLATFORM_EXPORT TraceWriter {
|
||||
public:
|
||||
TraceWriter() = default;
|
||||
virtual ~TraceWriter() = default;
|
||||
virtual void AppendTraceEvent(TraceObject* trace_event) = 0;
|
||||
virtual void Flush() = 0;
|
||||
|
||||
static TraceWriter* CreateJSONTraceWriter(std::ostream& stream);
|
||||
static TraceWriter* CreateJSONTraceWriter(std::ostream& stream,
|
||||
const std::string& tag);
|
||||
|
||||
static TraceWriter* CreateSystemInstrumentationTraceWriter();
|
||||
|
||||
private:
|
||||
// Disallow copy and assign
|
||||
TraceWriter(const TraceWriter&) = delete;
|
||||
void operator=(const TraceWriter&) = delete;
|
||||
};
|
||||
|
||||
class V8_PLATFORM_EXPORT TraceBufferChunk {
|
||||
public:
|
||||
explicit TraceBufferChunk(uint32_t seq);
|
||||
|
||||
void Reset(uint32_t new_seq);
|
||||
bool IsFull() const { return next_free_ == kChunkSize; }
|
||||
TraceObject* AddTraceEvent(size_t* event_index);
|
||||
TraceObject* GetEventAt(size_t index) { return &chunk_[index]; }
|
||||
|
||||
uint32_t seq() const { return seq_; }
|
||||
size_t size() const { return next_free_; }
|
||||
|
||||
static const size_t kChunkSize = 64;
|
||||
|
||||
private:
|
||||
size_t next_free_ = 0;
|
||||
TraceObject chunk_[kChunkSize];
|
||||
uint32_t seq_;
|
||||
|
||||
// Disallow copy and assign
|
||||
TraceBufferChunk(const TraceBufferChunk&) = delete;
|
||||
void operator=(const TraceBufferChunk&) = delete;
|
||||
};
|
||||
|
||||
class V8_PLATFORM_EXPORT TraceBuffer {
|
||||
public:
|
||||
TraceBuffer() = default;
|
||||
virtual ~TraceBuffer() = default;
|
||||
|
||||
virtual TraceObject* AddTraceEvent(uint64_t* handle) = 0;
|
||||
virtual TraceObject* GetEventByHandle(uint64_t handle) = 0;
|
||||
virtual bool Flush() = 0;
|
||||
|
||||
static const size_t kRingBufferChunks = 1024;
|
||||
|
||||
static TraceBuffer* CreateTraceBufferRingBuffer(size_t max_chunks,
|
||||
TraceWriter* trace_writer);
|
||||
|
||||
private:
|
||||
// Disallow copy and assign
|
||||
TraceBuffer(const TraceBuffer&) = delete;
|
||||
void operator=(const TraceBuffer&) = delete;
|
||||
};
|
||||
|
||||
// Options determines how the trace buffer stores data.
|
||||
enum TraceRecordMode {
|
||||
// Record until the trace buffer is full.
|
||||
RECORD_UNTIL_FULL,
|
||||
|
||||
// Record until the user ends the trace. The trace buffer is a fixed size
|
||||
// and we use it as a ring buffer during recording.
|
||||
RECORD_CONTINUOUSLY,
|
||||
|
||||
// Record until the trace buffer is full, but with a huge buffer size.
|
||||
RECORD_AS_MUCH_AS_POSSIBLE,
|
||||
|
||||
// Echo to console. Events are discarded.
|
||||
ECHO_TO_CONSOLE,
|
||||
};
|
||||
|
||||
class V8_PLATFORM_EXPORT TraceConfig {
|
||||
public:
|
||||
typedef std::vector<std::string> StringList;
|
||||
|
||||
static TraceConfig* CreateDefaultTraceConfig();
|
||||
|
||||
TraceConfig() : enable_systrace_(false), enable_argument_filter_(false) {}
|
||||
TraceRecordMode GetTraceRecordMode() const { return record_mode_; }
|
||||
const StringList& GetEnabledCategories() const {
|
||||
return included_categories_;
|
||||
}
|
||||
bool IsSystraceEnabled() const { return enable_systrace_; }
|
||||
bool IsArgumentFilterEnabled() const { return enable_argument_filter_; }
|
||||
|
||||
void SetTraceRecordMode(TraceRecordMode mode) { record_mode_ = mode; }
|
||||
void EnableSystrace() { enable_systrace_ = true; }
|
||||
void EnableArgumentFilter() { enable_argument_filter_ = true; }
|
||||
|
||||
void AddIncludedCategory(const char* included_category);
|
||||
|
||||
bool IsCategoryGroupEnabled(const char* category_group) const;
|
||||
|
||||
private:
|
||||
TraceRecordMode record_mode_;
|
||||
bool enable_systrace_ : 1;
|
||||
bool enable_argument_filter_ : 1;
|
||||
StringList included_categories_;
|
||||
|
||||
// Disallow copy and assign
|
||||
TraceConfig(const TraceConfig&) = delete;
|
||||
void operator=(const TraceConfig&) = delete;
|
||||
};
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
#define V8_PLATFORM_NON_EXPORTED_BASE(code) \
|
||||
__pragma(warning(suppress : 4275)) code
|
||||
#else
|
||||
#define V8_PLATFORM_NON_EXPORTED_BASE(code) code
|
||||
#endif // defined(_MSC_VER)
|
||||
|
||||
class V8_PLATFORM_EXPORT TracingController
|
||||
: public V8_PLATFORM_NON_EXPORTED_BASE(v8::TracingController) {
|
||||
public:
|
||||
TracingController();
|
||||
~TracingController() override;
|
||||
|
||||
#if defined(V8_USE_PERFETTO)
|
||||
// Must be called before StartTracing() if V8_USE_PERFETTO is true. Provides
|
||||
// the output stream for the JSON trace data.
|
||||
void InitializeForPerfetto(std::ostream* output_stream);
|
||||
// Provide an optional listener for testing that will receive trace events.
|
||||
// Must be called before StartTracing().
|
||||
void SetTraceEventListenerForTesting(TraceEventListener* listener);
|
||||
#else // defined(V8_USE_PERFETTO)
|
||||
// The pointer returned from GetCategoryGroupEnabled() points to a value with
|
||||
// zero or more of the following bits. Used in this class only. The
|
||||
// TRACE_EVENT macros should only use the value as a bool. These values must
|
||||
// be in sync with macro values in TraceEvent.h in Blink.
|
||||
enum CategoryGroupEnabledFlags {
|
||||
// Category group enabled for the recording mode.
|
||||
ENABLED_FOR_RECORDING = 1 << 0,
|
||||
// Category group enabled by SetEventCallbackEnabled().
|
||||
ENABLED_FOR_EVENT_CALLBACK = 1 << 2,
|
||||
// Category group enabled to export events to ETW.
|
||||
ENABLED_FOR_ETW_EXPORT = 1 << 3
|
||||
};
|
||||
|
||||
// Takes ownership of |trace_buffer|.
|
||||
void Initialize(TraceBuffer* trace_buffer);
|
||||
|
||||
// v8::TracingController implementation.
|
||||
const uint8_t* GetCategoryGroupEnabled(const char* category_group) override;
|
||||
uint64_t AddTraceEvent(
|
||||
char phase, const uint8_t* category_enabled_flag, const char* name,
|
||||
const char* scope, uint64_t id, uint64_t bind_id, int32_t num_args,
|
||||
const char** arg_names, const uint8_t* arg_types,
|
||||
const uint64_t* arg_values,
|
||||
std::unique_ptr<v8::ConvertableToTraceFormat>* arg_convertables,
|
||||
unsigned int flags) override;
|
||||
uint64_t AddTraceEventWithTimestamp(
|
||||
char phase, const uint8_t* category_enabled_flag, const char* name,
|
||||
const char* scope, uint64_t id, uint64_t bind_id, int32_t num_args,
|
||||
const char** arg_names, const uint8_t* arg_types,
|
||||
const uint64_t* arg_values,
|
||||
std::unique_ptr<v8::ConvertableToTraceFormat>* arg_convertables,
|
||||
unsigned int flags, int64_t timestamp) override;
|
||||
void UpdateTraceEventDuration(const uint8_t* category_enabled_flag,
|
||||
const char* name, uint64_t handle) override;
|
||||
|
||||
static const char* GetCategoryGroupName(const uint8_t* category_enabled_flag);
|
||||
|
||||
void AddTraceStateObserver(
|
||||
v8::TracingController::TraceStateObserver* observer) override;
|
||||
void RemoveTraceStateObserver(
|
||||
v8::TracingController::TraceStateObserver* observer) override;
|
||||
#endif // !defined(V8_USE_PERFETTO)
|
||||
|
||||
void StartTracing(TraceConfig* trace_config);
|
||||
void StopTracing();
|
||||
|
||||
protected:
|
||||
#if !defined(V8_USE_PERFETTO)
|
||||
virtual int64_t CurrentTimestampMicroseconds();
|
||||
virtual int64_t CurrentCpuTimestampMicroseconds();
|
||||
#endif // !defined(V8_USE_PERFETTO)
|
||||
|
||||
private:
|
||||
#if !defined(V8_USE_PERFETTO)
|
||||
void UpdateCategoryGroupEnabledFlag(size_t category_index);
|
||||
void UpdateCategoryGroupEnabledFlags();
|
||||
#endif // !defined(V8_USE_PERFETTO)
|
||||
|
||||
std::unique_ptr<base::Mutex> mutex_;
|
||||
std::unique_ptr<TraceConfig> trace_config_;
|
||||
std::atomic_bool recording_{false};
|
||||
|
||||
#if defined(V8_USE_PERFETTO)
|
||||
std::ostream* output_stream_ = nullptr;
|
||||
std::unique_ptr<perfetto::trace_processor::TraceProcessorStorage>
|
||||
trace_processor_;
|
||||
TraceEventListener* listener_for_testing_ = nullptr;
|
||||
std::unique_ptr<perfetto::TracingSession> tracing_session_;
|
||||
#else // !defined(V8_USE_PERFETTO)
|
||||
std::unordered_set<v8::TracingController::TraceStateObserver*> observers_;
|
||||
std::unique_ptr<TraceBuffer> trace_buffer_;
|
||||
#endif // !defined(V8_USE_PERFETTO)
|
||||
|
||||
// Disallow copy and assign
|
||||
TracingController(const TracingController&) = delete;
|
||||
void operator=(const TracingController&) = delete;
|
||||
};
|
||||
|
||||
#undef V8_PLATFORM_NON_EXPORTED_BASE
|
||||
|
||||
} // namespace tracing
|
||||
} // namespace platform
|
||||
} // namespace v8
|
||||
|
||||
#endif // V8_LIBPLATFORM_V8_TRACING_H_
|
||||
1578
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node.h
generated
vendored
Normal file
1578
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node.h
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
269
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_api.h
generated
vendored
Normal file
269
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_api.h
generated
vendored
Normal file
@@ -0,0 +1,269 @@
|
||||
#ifndef SRC_NODE_API_H_
|
||||
#define SRC_NODE_API_H_
|
||||
|
||||
#if defined(BUILDING_NODE_EXTENSION) && !defined(NAPI_EXTERN)
|
||||
#ifdef _WIN32
|
||||
// Building native addon against node
|
||||
#define NAPI_EXTERN __declspec(dllimport)
|
||||
#elif defined(__wasm__)
|
||||
#define NAPI_EXTERN __attribute__((__import_module__("napi")))
|
||||
#endif
|
||||
#endif
|
||||
#include "js_native_api.h"
|
||||
#include "node_api_types.h"
|
||||
|
||||
struct uv_loop_s; // Forward declaration.
|
||||
|
||||
#ifdef _WIN32
|
||||
#define NAPI_MODULE_EXPORT __declspec(dllexport)
|
||||
#else
|
||||
#ifdef __EMSCRIPTEN__
|
||||
#define NAPI_MODULE_EXPORT \
|
||||
__attribute__((visibility("default"))) __attribute__((used))
|
||||
#else
|
||||
#define NAPI_MODULE_EXPORT __attribute__((visibility("default")))
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if defined(__GNUC__)
|
||||
#define NAPI_NO_RETURN __attribute__((noreturn))
|
||||
#elif defined(_WIN32)
|
||||
#define NAPI_NO_RETURN __declspec(noreturn)
|
||||
#else
|
||||
#define NAPI_NO_RETURN
|
||||
#endif
|
||||
|
||||
typedef napi_value(NAPI_CDECL* napi_addon_register_func)(napi_env env,
|
||||
napi_value exports);
|
||||
typedef int32_t(NAPI_CDECL* node_api_addon_get_api_version_func)(void);
|
||||
|
||||
// Used by deprecated registration method napi_module_register.
|
||||
typedef struct napi_module {
|
||||
int nm_version;
|
||||
unsigned int nm_flags;
|
||||
const char* nm_filename;
|
||||
napi_addon_register_func nm_register_func;
|
||||
const char* nm_modname;
|
||||
void* nm_priv;
|
||||
void* reserved[4];
|
||||
} napi_module;
|
||||
|
||||
#define NAPI_MODULE_VERSION 1
|
||||
|
||||
#define NAPI_MODULE_INITIALIZER_X(base, version) \
|
||||
NAPI_MODULE_INITIALIZER_X_HELPER(base, version)
|
||||
#define NAPI_MODULE_INITIALIZER_X_HELPER(base, version) base##version
|
||||
|
||||
#ifdef __wasm__
|
||||
#define NAPI_MODULE_INITIALIZER_BASE napi_register_wasm_v
|
||||
#else
|
||||
#define NAPI_MODULE_INITIALIZER_BASE napi_register_module_v
|
||||
#endif
|
||||
|
||||
#define NODE_API_MODULE_GET_API_VERSION_BASE node_api_module_get_api_version_v
|
||||
|
||||
#define NAPI_MODULE_INITIALIZER \
|
||||
NAPI_MODULE_INITIALIZER_X(NAPI_MODULE_INITIALIZER_BASE, NAPI_MODULE_VERSION)
|
||||
|
||||
#define NODE_API_MODULE_GET_API_VERSION \
|
||||
NAPI_MODULE_INITIALIZER_X(NODE_API_MODULE_GET_API_VERSION_BASE, \
|
||||
NAPI_MODULE_VERSION)
|
||||
|
||||
#define NAPI_MODULE_INIT() \
|
||||
EXTERN_C_START \
|
||||
NAPI_MODULE_EXPORT int32_t NODE_API_MODULE_GET_API_VERSION(void) { \
|
||||
return NAPI_VERSION; \
|
||||
} \
|
||||
NAPI_MODULE_EXPORT napi_value NAPI_MODULE_INITIALIZER(napi_env env, \
|
||||
napi_value exports); \
|
||||
EXTERN_C_END \
|
||||
napi_value NAPI_MODULE_INITIALIZER(napi_env env, napi_value exports)
|
||||
|
||||
#define NAPI_MODULE(modname, regfunc) \
|
||||
NAPI_MODULE_INIT() { return regfunc(env, exports); }
|
||||
|
||||
// Deprecated. Use NAPI_MODULE.
|
||||
#define NAPI_MODULE_X(modname, regfunc, priv, flags) \
|
||||
NAPI_MODULE(modname, regfunc)
|
||||
|
||||
EXTERN_C_START
|
||||
|
||||
// Deprecated. Replaced by symbol-based registration defined by NAPI_MODULE
|
||||
// and NAPI_MODULE_INIT macros.
|
||||
NAPI_EXTERN void NAPI_CDECL
|
||||
napi_module_register(napi_module* mod);
|
||||
|
||||
NAPI_EXTERN NAPI_NO_RETURN void NAPI_CDECL
|
||||
napi_fatal_error(const char* location,
|
||||
size_t location_len,
|
||||
const char* message,
|
||||
size_t message_len);
|
||||
|
||||
// Methods for custom handling of async operations
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_async_init(napi_env env,
|
||||
napi_value async_resource,
|
||||
napi_value async_resource_name,
|
||||
napi_async_context* result);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_async_destroy(napi_env env, napi_async_context async_context);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_make_callback(napi_env env,
|
||||
napi_async_context async_context,
|
||||
napi_value recv,
|
||||
napi_value func,
|
||||
size_t argc,
|
||||
const napi_value* argv,
|
||||
napi_value* result);
|
||||
|
||||
// Methods to provide node::Buffer functionality with napi types
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_buffer(napi_env env,
|
||||
size_t length,
|
||||
void** data,
|
||||
napi_value* result);
|
||||
#ifndef NODE_API_NO_EXTERNAL_BUFFERS_ALLOWED
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_external_buffer(napi_env env,
|
||||
size_t length,
|
||||
void* data,
|
||||
node_api_basic_finalize finalize_cb,
|
||||
void* finalize_hint,
|
||||
napi_value* result);
|
||||
#endif // NODE_API_NO_EXTERNAL_BUFFERS_ALLOWED
|
||||
|
||||
#if NAPI_VERSION >= 10
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
node_api_create_buffer_from_arraybuffer(napi_env env,
|
||||
napi_value arraybuffer,
|
||||
size_t byte_offset,
|
||||
size_t byte_length,
|
||||
napi_value* result);
|
||||
#endif // NAPI_VERSION >= 10
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_create_buffer_copy(napi_env env,
|
||||
size_t length,
|
||||
const void* data,
|
||||
void** result_data,
|
||||
napi_value* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_is_buffer(napi_env env,
|
||||
napi_value value,
|
||||
bool* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_buffer_info(napi_env env,
|
||||
napi_value value,
|
||||
void** data,
|
||||
size_t* length);
|
||||
|
||||
// Methods to manage simple async operations
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_async_work(napi_env env,
|
||||
napi_value async_resource,
|
||||
napi_value async_resource_name,
|
||||
napi_async_execute_callback execute,
|
||||
napi_async_complete_callback complete,
|
||||
void* data,
|
||||
napi_async_work* result);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_delete_async_work(napi_env env,
|
||||
napi_async_work work);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_queue_async_work(node_api_basic_env env,
|
||||
napi_async_work work);
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_cancel_async_work(node_api_basic_env env, napi_async_work work);
|
||||
|
||||
// version management
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_node_version(
|
||||
node_api_basic_env env, const napi_node_version** version);
|
||||
|
||||
#if NAPI_VERSION >= 2
|
||||
|
||||
// Return the current libuv event loop for a given environment
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_get_uv_event_loop(node_api_basic_env env, struct uv_loop_s** loop);
|
||||
|
||||
#endif // NAPI_VERSION >= 2
|
||||
|
||||
#if NAPI_VERSION >= 3
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_fatal_exception(napi_env env,
|
||||
napi_value err);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_add_env_cleanup_hook(
|
||||
node_api_basic_env env, napi_cleanup_hook fun, void* arg);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_remove_env_cleanup_hook(
|
||||
node_api_basic_env env, napi_cleanup_hook fun, void* arg);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_open_callback_scope(napi_env env,
|
||||
napi_value resource_object,
|
||||
napi_async_context context,
|
||||
napi_callback_scope* result);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_close_callback_scope(napi_env env, napi_callback_scope scope);
|
||||
|
||||
#endif // NAPI_VERSION >= 3
|
||||
|
||||
#if NAPI_VERSION >= 4
|
||||
|
||||
// Calling into JS from other threads
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_create_threadsafe_function(napi_env env,
|
||||
napi_value func,
|
||||
napi_value async_resource,
|
||||
napi_value async_resource_name,
|
||||
size_t max_queue_size,
|
||||
size_t initial_thread_count,
|
||||
void* thread_finalize_data,
|
||||
napi_finalize thread_finalize_cb,
|
||||
void* context,
|
||||
napi_threadsafe_function_call_js call_js_cb,
|
||||
napi_threadsafe_function* result);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_get_threadsafe_function_context(
|
||||
napi_threadsafe_function func, void** result);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_call_threadsafe_function(napi_threadsafe_function func,
|
||||
void* data,
|
||||
napi_threadsafe_function_call_mode is_blocking);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_acquire_threadsafe_function(napi_threadsafe_function func);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_release_threadsafe_function(
|
||||
napi_threadsafe_function func, napi_threadsafe_function_release_mode mode);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_unref_threadsafe_function(
|
||||
node_api_basic_env env, napi_threadsafe_function func);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL napi_ref_threadsafe_function(
|
||||
node_api_basic_env env, napi_threadsafe_function func);
|
||||
|
||||
#endif // NAPI_VERSION >= 4
|
||||
|
||||
#if NAPI_VERSION >= 8
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_add_async_cleanup_hook(node_api_basic_env env,
|
||||
napi_async_cleanup_hook hook,
|
||||
void* arg,
|
||||
napi_async_cleanup_hook_handle* remove_handle);
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
napi_remove_async_cleanup_hook(napi_async_cleanup_hook_handle remove_handle);
|
||||
|
||||
#endif // NAPI_VERSION >= 8
|
||||
|
||||
#if NAPI_VERSION >= 9
|
||||
|
||||
NAPI_EXTERN napi_status NAPI_CDECL
|
||||
node_api_get_module_file_name(node_api_basic_env env, const char** result);
|
||||
|
||||
#endif // NAPI_VERSION >= 9
|
||||
|
||||
EXTERN_C_END
|
||||
|
||||
#endif // SRC_NODE_API_H_
|
||||
52
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_api_types.h
generated
vendored
Normal file
52
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_api_types.h
generated
vendored
Normal file
@@ -0,0 +1,52 @@
|
||||
#ifndef SRC_NODE_API_TYPES_H_
|
||||
#define SRC_NODE_API_TYPES_H_
|
||||
|
||||
#include "js_native_api_types.h"
|
||||
|
||||
typedef struct napi_callback_scope__* napi_callback_scope;
|
||||
typedef struct napi_async_context__* napi_async_context;
|
||||
typedef struct napi_async_work__* napi_async_work;
|
||||
|
||||
#if NAPI_VERSION >= 3
|
||||
typedef void(NAPI_CDECL* napi_cleanup_hook)(void* arg);
|
||||
#endif // NAPI_VERSION >= 3
|
||||
|
||||
#if NAPI_VERSION >= 4
|
||||
typedef struct napi_threadsafe_function__* napi_threadsafe_function;
|
||||
#endif // NAPI_VERSION >= 4
|
||||
|
||||
#if NAPI_VERSION >= 4
|
||||
typedef enum {
|
||||
napi_tsfn_release,
|
||||
napi_tsfn_abort
|
||||
} napi_threadsafe_function_release_mode;
|
||||
|
||||
typedef enum {
|
||||
napi_tsfn_nonblocking,
|
||||
napi_tsfn_blocking
|
||||
} napi_threadsafe_function_call_mode;
|
||||
#endif // NAPI_VERSION >= 4
|
||||
|
||||
typedef void(NAPI_CDECL* napi_async_execute_callback)(napi_env env, void* data);
|
||||
typedef void(NAPI_CDECL* napi_async_complete_callback)(napi_env env,
|
||||
napi_status status,
|
||||
void* data);
|
||||
#if NAPI_VERSION >= 4
|
||||
typedef void(NAPI_CDECL* napi_threadsafe_function_call_js)(
|
||||
napi_env env, napi_value js_callback, void* context, void* data);
|
||||
#endif // NAPI_VERSION >= 4
|
||||
|
||||
typedef struct {
|
||||
uint32_t major;
|
||||
uint32_t minor;
|
||||
uint32_t patch;
|
||||
const char* release;
|
||||
} napi_node_version;
|
||||
|
||||
#if NAPI_VERSION >= 8
|
||||
typedef struct napi_async_cleanup_hook_handle__* napi_async_cleanup_hook_handle;
|
||||
typedef void(NAPI_CDECL* napi_async_cleanup_hook)(
|
||||
napi_async_cleanup_hook_handle handle, void* data);
|
||||
#endif // NAPI_VERSION >= 8
|
||||
|
||||
#endif // SRC_NODE_API_TYPES_H_
|
||||
92
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_buffer.h
generated
vendored
Normal file
92
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_buffer.h
generated
vendored
Normal file
@@ -0,0 +1,92 @@
|
||||
// Copyright Joyent, Inc. and other Node contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||
// copy of this software and associated documentation files (the
|
||||
// "Software"), to deal in the Software without restriction, including
|
||||
// without limitation the rights to use, copy, modify, merge, publish,
|
||||
// distribute, sublicense, and/or sell copies of the Software, and to permit
|
||||
// persons to whom the Software is furnished to do so, subject to the
|
||||
// following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be included
|
||||
// in all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
||||
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
|
||||
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
||||
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
|
||||
// USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
#ifndef SRC_NODE_BUFFER_H_
|
||||
#define SRC_NODE_BUFFER_H_
|
||||
|
||||
#include "node.h"
|
||||
#include "v8.h"
|
||||
|
||||
namespace node {
|
||||
|
||||
namespace Buffer {
|
||||
|
||||
static const size_t kMaxLength = v8::Uint8Array::kMaxLength;
|
||||
|
||||
typedef void (*FreeCallback)(char* data, void* hint);
|
||||
|
||||
NODE_EXTERN bool HasInstance(v8::Local<v8::Value> val);
|
||||
NODE_EXTERN bool HasInstance(v8::Local<v8::Object> val);
|
||||
NODE_EXTERN char* Data(v8::Local<v8::Value> val);
|
||||
NODE_EXTERN char* Data(v8::Local<v8::Object> val);
|
||||
NODE_EXTERN size_t Length(v8::Local<v8::Value> val);
|
||||
NODE_EXTERN size_t Length(v8::Local<v8::Object> val);
|
||||
|
||||
// public constructor - data is copied
|
||||
NODE_EXTERN v8::MaybeLocal<v8::Object> Copy(v8::Isolate* isolate,
|
||||
const char* data,
|
||||
size_t len);
|
||||
|
||||
// public constructor
|
||||
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate, size_t length);
|
||||
|
||||
// public constructor from string
|
||||
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
|
||||
v8::Local<v8::String> string,
|
||||
enum encoding enc = UTF8);
|
||||
|
||||
// public constructor - data is used, callback is passed data on object gc
|
||||
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
|
||||
char* data,
|
||||
size_t length,
|
||||
FreeCallback callback,
|
||||
void* hint);
|
||||
|
||||
// public constructor - data is used.
|
||||
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
|
||||
char* data,
|
||||
size_t len);
|
||||
|
||||
// Creates a Buffer instance over an existing ArrayBuffer.
|
||||
NODE_EXTERN v8::MaybeLocal<v8::Uint8Array> New(v8::Isolate* isolate,
|
||||
v8::Local<v8::ArrayBuffer> ab,
|
||||
size_t byte_offset,
|
||||
size_t length);
|
||||
|
||||
// This is verbose to be explicit with inline commenting
|
||||
static inline bool IsWithinBounds(size_t off, size_t len, size_t max) {
|
||||
// Asking to seek too far into the buffer
|
||||
// check to avoid wrapping in subsequent subtraction
|
||||
if (off > max)
|
||||
return false;
|
||||
|
||||
// Asking for more than is left over in the buffer
|
||||
if (max - off < len)
|
||||
return false;
|
||||
|
||||
// Otherwise we're in bounds
|
||||
return true;
|
||||
}
|
||||
|
||||
} // namespace Buffer
|
||||
} // namespace node
|
||||
|
||||
#endif // SRC_NODE_BUFFER_H_
|
||||
132
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_object_wrap.h
generated
vendored
Normal file
132
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_object_wrap.h
generated
vendored
Normal file
@@ -0,0 +1,132 @@
|
||||
// Copyright Joyent, Inc. and other Node contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||
// copy of this software and associated documentation files (the
|
||||
// "Software"), to deal in the Software without restriction, including
|
||||
// without limitation the rights to use, copy, modify, merge, publish,
|
||||
// distribute, sublicense, and/or sell copies of the Software, and to permit
|
||||
// persons to whom the Software is furnished to do so, subject to the
|
||||
// following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be included
|
||||
// in all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
||||
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
|
||||
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
||||
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
|
||||
// USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
#ifndef SRC_NODE_OBJECT_WRAP_H_
|
||||
#define SRC_NODE_OBJECT_WRAP_H_
|
||||
|
||||
#include "v8.h"
|
||||
#include <cassert>
|
||||
|
||||
|
||||
namespace node {
|
||||
|
||||
class ObjectWrap {
|
||||
public:
|
||||
ObjectWrap() {
|
||||
refs_ = 0;
|
||||
}
|
||||
|
||||
|
||||
virtual ~ObjectWrap() {
|
||||
if (persistent().IsEmpty())
|
||||
return;
|
||||
persistent().ClearWeak();
|
||||
persistent().Reset();
|
||||
}
|
||||
|
||||
|
||||
template <class T>
|
||||
static inline T* Unwrap(v8::Local<v8::Object> handle) {
|
||||
assert(!handle.IsEmpty());
|
||||
assert(handle->InternalFieldCount() > 0);
|
||||
// Cast to ObjectWrap before casting to T. A direct cast from void
|
||||
// to T won't work right when T has more than one base class.
|
||||
void* ptr = handle->GetAlignedPointerFromInternalField(0);
|
||||
ObjectWrap* wrap = static_cast<ObjectWrap*>(ptr);
|
||||
return static_cast<T*>(wrap);
|
||||
}
|
||||
|
||||
|
||||
inline v8::Local<v8::Object> handle() {
|
||||
return handle(v8::Isolate::GetCurrent());
|
||||
}
|
||||
|
||||
|
||||
inline v8::Local<v8::Object> handle(v8::Isolate* isolate) {
|
||||
return v8::Local<v8::Object>::New(isolate, persistent());
|
||||
}
|
||||
|
||||
|
||||
// NOLINTNEXTLINE(runtime/v8_persistent)
|
||||
inline v8::Persistent<v8::Object>& persistent() {
|
||||
return handle_;
|
||||
}
|
||||
|
||||
|
||||
protected:
|
||||
inline void Wrap(v8::Local<v8::Object> handle) {
|
||||
assert(persistent().IsEmpty());
|
||||
assert(handle->InternalFieldCount() > 0);
|
||||
handle->SetAlignedPointerInInternalField(0, this);
|
||||
persistent().Reset(v8::Isolate::GetCurrent(), handle);
|
||||
MakeWeak();
|
||||
}
|
||||
|
||||
|
||||
inline void MakeWeak() {
|
||||
persistent().SetWeak(this, WeakCallback, v8::WeakCallbackType::kParameter);
|
||||
}
|
||||
|
||||
/* Ref() marks the object as being attached to an event loop.
|
||||
* Refed objects will not be garbage collected, even if
|
||||
* all references are lost.
|
||||
*/
|
||||
virtual void Ref() {
|
||||
assert(!persistent().IsEmpty());
|
||||
persistent().ClearWeak();
|
||||
refs_++;
|
||||
}
|
||||
|
||||
/* Unref() marks an object as detached from the event loop. This is its
|
||||
* default state. When an object with a "weak" reference changes from
|
||||
* attached to detached state it will be freed. Be careful not to access
|
||||
* the object after making this call as it might be gone!
|
||||
* (A "weak reference" means an object that only has a
|
||||
* persistent handle.)
|
||||
*
|
||||
* DO NOT CALL THIS FROM DESTRUCTOR
|
||||
*/
|
||||
virtual void Unref() {
|
||||
assert(!persistent().IsEmpty());
|
||||
assert(!persistent().IsWeak());
|
||||
assert(refs_ > 0);
|
||||
if (--refs_ == 0)
|
||||
MakeWeak();
|
||||
}
|
||||
|
||||
int refs_; // ro
|
||||
|
||||
private:
|
||||
static void WeakCallback(
|
||||
const v8::WeakCallbackInfo<ObjectWrap>& data) {
|
||||
ObjectWrap* wrap = data.GetParameter();
|
||||
assert(wrap->refs_ == 0);
|
||||
wrap->handle_.Reset();
|
||||
delete wrap;
|
||||
}
|
||||
|
||||
// NOLINTNEXTLINE(runtime/v8_persistent)
|
||||
v8::Persistent<v8::Object> handle_;
|
||||
};
|
||||
|
||||
} // namespace node
|
||||
|
||||
#endif // SRC_NODE_OBJECT_WRAP_H_
|
||||
110
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_version.h
generated
vendored
Normal file
110
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/node_version.h
generated
vendored
Normal file
@@ -0,0 +1,110 @@
|
||||
// Copyright Joyent, Inc. and other Node contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||
// copy of this software and associated documentation files (the
|
||||
// "Software"), to deal in the Software without restriction, including
|
||||
// without limitation the rights to use, copy, modify, merge, publish,
|
||||
// distribute, sublicense, and/or sell copies of the Software, and to permit
|
||||
// persons to whom the Software is furnished to do so, subject to the
|
||||
// following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be included
|
||||
// in all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
||||
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
|
||||
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
||||
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
|
||||
// USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
#ifndef SRC_NODE_VERSION_H_
|
||||
#define SRC_NODE_VERSION_H_
|
||||
|
||||
#define NODE_MAJOR_VERSION 22
|
||||
#define NODE_MINOR_VERSION 17
|
||||
#define NODE_PATCH_VERSION 0
|
||||
|
||||
#define NODE_VERSION_IS_LTS 1
|
||||
#define NODE_VERSION_LTS_CODENAME "Jod"
|
||||
|
||||
#define NODE_VERSION_IS_RELEASE 1
|
||||
|
||||
#ifndef NODE_STRINGIFY
|
||||
#define NODE_STRINGIFY(n) NODE_STRINGIFY_HELPER(n)
|
||||
#define NODE_STRINGIFY_HELPER(n) #n
|
||||
#endif
|
||||
|
||||
#ifndef NODE_RELEASE
|
||||
#define NODE_RELEASE "node"
|
||||
#endif
|
||||
|
||||
#ifndef NODE_TAG
|
||||
# if NODE_VERSION_IS_RELEASE
|
||||
# define NODE_TAG ""
|
||||
# else
|
||||
# define NODE_TAG "-pre"
|
||||
# endif
|
||||
#else
|
||||
// NODE_TAG is passed without quotes when rc.exe is run from msbuild
|
||||
# define NODE_EXE_VERSION NODE_STRINGIFY(NODE_MAJOR_VERSION) "." \
|
||||
NODE_STRINGIFY(NODE_MINOR_VERSION) "." \
|
||||
NODE_STRINGIFY(NODE_PATCH_VERSION) \
|
||||
NODE_STRINGIFY(NODE_TAG)
|
||||
#endif
|
||||
|
||||
# define NODE_VERSION_STRING NODE_STRINGIFY(NODE_MAJOR_VERSION) "." \
|
||||
NODE_STRINGIFY(NODE_MINOR_VERSION) "." \
|
||||
NODE_STRINGIFY(NODE_PATCH_VERSION) \
|
||||
NODE_TAG
|
||||
#ifndef NODE_EXE_VERSION
|
||||
# define NODE_EXE_VERSION NODE_VERSION_STRING
|
||||
#endif
|
||||
|
||||
#define NODE_VERSION "v" NODE_VERSION_STRING
|
||||
|
||||
|
||||
#define NODE_VERSION_AT_LEAST(major, minor, patch) \
|
||||
(( (major) < NODE_MAJOR_VERSION) \
|
||||
|| ((major) == NODE_MAJOR_VERSION && (minor) < NODE_MINOR_VERSION) \
|
||||
|| ((major) == NODE_MAJOR_VERSION && \
|
||||
(minor) == NODE_MINOR_VERSION && (patch) <= NODE_PATCH_VERSION))
|
||||
|
||||
/**
|
||||
* Node.js will refuse to load modules that weren't compiled against its own
|
||||
* module ABI number, exposed as the process.versions.modules property.
|
||||
*
|
||||
* Node.js will refuse to load modules with a non-matching ABI version. The
|
||||
* version number here should be changed whenever an ABI-incompatible API change
|
||||
* is made in the C++ side, including in V8 or other dependencies.
|
||||
*
|
||||
* Node.js will not change the module version during a Major release line
|
||||
* We will, at times update the version of V8 shipped in the release line
|
||||
* if it can be made ABI compatible with the previous version.
|
||||
*
|
||||
* Embedders building Node.js can define NODE_EMBEDDER_MODULE_VERSION to
|
||||
* override the default value of NODE_MODULE_VERSION.
|
||||
*
|
||||
* The registry of used NODE_MODULE_VERSION numbers is located at
|
||||
* https://github.com/nodejs/node/blob/HEAD/doc/abi_version_registry.json
|
||||
* Extenders, embedders and other consumers of Node.js that require ABI
|
||||
* version matching should open a pull request to reserve a number in this
|
||||
* registry.
|
||||
*/
|
||||
#if defined(NODE_EMBEDDER_MODULE_VERSION)
|
||||
#define NODE_MODULE_VERSION NODE_EMBEDDER_MODULE_VERSION
|
||||
#else
|
||||
#define NODE_MODULE_VERSION 127
|
||||
#endif
|
||||
|
||||
// The NAPI_VERSION supported by the runtime. This is the inclusive range of
|
||||
// versions which the Node.js binary being built supports.
|
||||
#define NODE_API_SUPPORTED_VERSION_MAX 10
|
||||
#define NODE_API_SUPPORTED_VERSION_MIN 1
|
||||
|
||||
// Node API modules use NAPI_VERSION 8 by default if it is not explicitly
|
||||
// specified. It must be always 8.
|
||||
#define NODE_API_DEFAULT_MODULE_API_VERSION 8
|
||||
|
||||
#endif // SRC_NODE_VERSION_H_
|
||||
111
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/aes.h
generated
vendored
Normal file
111
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/aes.h
generated
vendored
Normal file
@@ -0,0 +1,111 @@
|
||||
/*
|
||||
* Copyright 2002-2020 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#ifndef OPENSSL_AES_H
|
||||
# define OPENSSL_AES_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_AES_H
|
||||
# endif
|
||||
|
||||
# include <openssl/opensslconf.h>
|
||||
|
||||
# include <stddef.h>
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
# define AES_BLOCK_SIZE 16
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
|
||||
# define AES_ENCRYPT 1
|
||||
# define AES_DECRYPT 0
|
||||
|
||||
# define AES_MAXNR 14
|
||||
|
||||
|
||||
/* This should be a hidden type, but EVP requires that the size be known */
|
||||
struct aes_key_st {
|
||||
# ifdef AES_LONG
|
||||
unsigned long rd_key[4 * (AES_MAXNR + 1)];
|
||||
# else
|
||||
unsigned int rd_key[4 * (AES_MAXNR + 1)];
|
||||
# endif
|
||||
int rounds;
|
||||
};
|
||||
typedef struct aes_key_st AES_KEY;
|
||||
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0 const char *AES_options(void);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
||||
AES_KEY *key);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
||||
AES_KEY *key);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_encrypt(const unsigned char *in, unsigned char *out,
|
||||
const AES_KEY *key);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_decrypt(const unsigned char *in, unsigned char *out,
|
||||
const AES_KEY *key);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_ecb_encrypt(const unsigned char *in, unsigned char *out,
|
||||
const AES_KEY *key, const int enc);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_cbc_encrypt(const unsigned char *in, unsigned char *out,
|
||||
size_t length, const AES_KEY *key,
|
||||
unsigned char *ivec, const int enc);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_cfb128_encrypt(const unsigned char *in, unsigned char *out,
|
||||
size_t length, const AES_KEY *key,
|
||||
unsigned char *ivec, int *num, const int enc);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_cfb1_encrypt(const unsigned char *in, unsigned char *out,
|
||||
size_t length, const AES_KEY *key,
|
||||
unsigned char *ivec, int *num, const int enc);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_cfb8_encrypt(const unsigned char *in, unsigned char *out,
|
||||
size_t length, const AES_KEY *key,
|
||||
unsigned char *ivec, int *num, const int enc);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_ofb128_encrypt(const unsigned char *in, unsigned char *out,
|
||||
size_t length, const AES_KEY *key,
|
||||
unsigned char *ivec, int *num);
|
||||
|
||||
/* NB: the IV is _two_ blocks long */
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_ige_encrypt(const unsigned char *in, unsigned char *out,
|
||||
size_t length, const AES_KEY *key,
|
||||
unsigned char *ivec, const int enc);
|
||||
/* NB: the IV is _four_ blocks long */
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void AES_bi_ige_encrypt(const unsigned char *in, unsigned char *out,
|
||||
size_t length, const AES_KEY *key, const AES_KEY *key2,
|
||||
const unsigned char *ivec, const int enc);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int AES_wrap_key(AES_KEY *key, const unsigned char *iv,
|
||||
unsigned char *out, const unsigned char *in,
|
||||
unsigned int inlen);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int AES_unwrap_key(AES_KEY *key, const unsigned char *iv,
|
||||
unsigned char *out, const unsigned char *in,
|
||||
unsigned int inlen);
|
||||
# endif
|
||||
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
|
||||
#endif
|
||||
33
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/crypto/buildinf.h
generated
vendored
Normal file
33
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/crypto/buildinf.h
generated
vendored
Normal file
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by util/mkbuildinf.pl
|
||||
*
|
||||
* Copyright 2014-2025 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#define PLATFORM "platform: BSD-x86"
|
||||
#define DATE "built on: Wed Mar 5 20:59:02 2025 UTC"
|
||||
|
||||
/*
|
||||
* Generate compiler_flags as an array of individual characters. This is a
|
||||
* workaround for the situation where CFLAGS gets too long for a C90 string
|
||||
* literal
|
||||
*/
|
||||
static const char compiler_flags[] = {
|
||||
'c','o','m','p','i','l','e','r',':',' ','g','c','c',' ','-','f',
|
||||
'P','I','C',' ','-','p','t','h','r','e','a','d',' ','-','W','a',
|
||||
',','-','-','n','o','e','x','e','c','s','t','a','c','k',' ','-',
|
||||
'W','a','l','l',' ','-','O','3',' ','-','f','o','m','i','t','-',
|
||||
'f','r','a','m','e','-','p','o','i','n','t','e','r',' ','-','D',
|
||||
'L','_','E','N','D','I','A','N',' ','-','D','O','P','E','N','S',
|
||||
'S','L','_','P','I','C',' ','-','D','_','T','H','R','E','A','D',
|
||||
'_','S','A','F','E',' ','-','D','_','R','E','E','N','T','R','A',
|
||||
'N','T',' ','-','D','O','P','E','N','S','S','L','_','B','U','I',
|
||||
'L','D','I','N','G','_','O','P','E','N','S','S','L',' ','-','D',
|
||||
'N','D','E','B','U','G','\0'
|
||||
};
|
||||
29
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/crypto/bn_conf.h
generated
vendored
Normal file
29
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/crypto/bn_conf.h
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
/* WARNING: do not edit! */
|
||||
/* Generated by Makefile from include/crypto/bn_conf.h.in */
|
||||
/*
|
||||
* Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#ifndef OSSL_CRYPTO_BN_CONF_H
|
||||
# define OSSL_CRYPTO_BN_CONF_H
|
||||
# pragma once
|
||||
|
||||
/*
|
||||
* The contents of this file are not used in the UEFI build, as
|
||||
* both 32-bit and 64-bit builds are supported from a single run
|
||||
* of the Configure script.
|
||||
*/
|
||||
|
||||
/* Should we define BN_DIV2W here? */
|
||||
|
||||
/* Only one for the following should be defined */
|
||||
#undef SIXTY_FOUR_BIT_LONG
|
||||
#undef SIXTY_FOUR_BIT
|
||||
#define THIRTY_TWO_BIT
|
||||
|
||||
#endif
|
||||
19
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/crypto/dso_conf.h
generated
vendored
Normal file
19
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/crypto/dso_conf.h
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
/* WARNING: do not edit! */
|
||||
/* Generated by Makefile from include/crypto/dso_conf.h.in */
|
||||
/*
|
||||
* Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#ifndef OSSL_CRYPTO_DSO_CONF_H
|
||||
# define OSSL_CRYPTO_DSO_CONF_H
|
||||
# pragma once
|
||||
|
||||
# define DSO_DLFCN
|
||||
# define HAVE_DLFCN_H
|
||||
# define DSO_EXTENSION ".so"
|
||||
#endif
|
||||
1128
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/asn1.h
generated
vendored
Normal file
1128
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/asn1.h
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
946
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/asn1t.h
generated
vendored
Normal file
946
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/asn1t.h
generated
vendored
Normal file
@@ -0,0 +1,946 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/asn1t.h.in
|
||||
*
|
||||
* Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_ASN1T_H
|
||||
# define OPENSSL_ASN1T_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_ASN1T_H
|
||||
# endif
|
||||
|
||||
# include <stddef.h>
|
||||
# include <openssl/e_os2.h>
|
||||
# include <openssl/asn1.h>
|
||||
|
||||
# ifdef OPENSSL_BUILD_SHLIBCRYPTO
|
||||
# undef OPENSSL_EXTERN
|
||||
# define OPENSSL_EXTERN OPENSSL_EXPORT
|
||||
# endif
|
||||
|
||||
/* ASN1 template defines, structures and functions */
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*-
|
||||
* These are the possible values for the itype field of the
|
||||
* ASN1_ITEM structure and determine how it is interpreted.
|
||||
*
|
||||
* For PRIMITIVE types the underlying type
|
||||
* determines the behaviour if items is NULL.
|
||||
*
|
||||
* Otherwise templates must contain a single
|
||||
* template and the type is treated in the
|
||||
* same way as the type specified in the template.
|
||||
*
|
||||
* For SEQUENCE types the templates field points
|
||||
* to the members, the size field is the
|
||||
* structure size.
|
||||
*
|
||||
* For CHOICE types the templates field points
|
||||
* to each possible member (typically a union)
|
||||
* and the 'size' field is the offset of the
|
||||
* selector.
|
||||
*
|
||||
* The 'funcs' field is used for application-specific
|
||||
* data and functions.
|
||||
*
|
||||
* The EXTERN type uses a new style d2i/i2d.
|
||||
* The new style should be used where possible
|
||||
* because it avoids things like the d2i IMPLICIT
|
||||
* hack.
|
||||
*
|
||||
* MSTRING is a multiple string type, it is used
|
||||
* for a CHOICE of character strings where the
|
||||
* actual strings all occupy an ASN1_STRING
|
||||
* structure. In this case the 'utype' field
|
||||
* has a special meaning, it is used as a mask
|
||||
* of acceptable types using the B_ASN1 constants.
|
||||
*
|
||||
* NDEF_SEQUENCE is the same as SEQUENCE except
|
||||
* that it will use indefinite length constructed
|
||||
* encoding if requested.
|
||||
*
|
||||
*/
|
||||
|
||||
# define ASN1_ITYPE_PRIMITIVE 0x0
|
||||
# define ASN1_ITYPE_SEQUENCE 0x1
|
||||
# define ASN1_ITYPE_CHOICE 0x2
|
||||
/* unused value 0x3 */
|
||||
# define ASN1_ITYPE_EXTERN 0x4
|
||||
# define ASN1_ITYPE_MSTRING 0x5
|
||||
# define ASN1_ITYPE_NDEF_SEQUENCE 0x6
|
||||
|
||||
/* Macro to obtain ASN1_ADB pointer from a type (only used internally) */
|
||||
# define ASN1_ADB_ptr(iptr) ((const ASN1_ADB *)((iptr)()))
|
||||
|
||||
/* Macros for start and end of ASN1_ITEM definition */
|
||||
|
||||
# define ASN1_ITEM_start(itname) \
|
||||
const ASN1_ITEM * itname##_it(void) \
|
||||
{ \
|
||||
static const ASN1_ITEM local_it = {
|
||||
|
||||
# define static_ASN1_ITEM_start(itname) \
|
||||
static ASN1_ITEM_start(itname)
|
||||
|
||||
# define ASN1_ITEM_end(itname) \
|
||||
}; \
|
||||
return &local_it; \
|
||||
}
|
||||
|
||||
/* Macros to aid ASN1 template writing */
|
||||
|
||||
# define ASN1_ITEM_TEMPLATE(tname) \
|
||||
static const ASN1_TEMPLATE tname##_item_tt
|
||||
|
||||
# define ASN1_ITEM_TEMPLATE_END(tname) \
|
||||
;\
|
||||
ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_PRIMITIVE,\
|
||||
-1,\
|
||||
&tname##_item_tt,\
|
||||
0,\
|
||||
NULL,\
|
||||
0,\
|
||||
#tname \
|
||||
ASN1_ITEM_end(tname)
|
||||
# define static_ASN1_ITEM_TEMPLATE_END(tname) \
|
||||
;\
|
||||
static_ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_PRIMITIVE,\
|
||||
-1,\
|
||||
&tname##_item_tt,\
|
||||
0,\
|
||||
NULL,\
|
||||
0,\
|
||||
#tname \
|
||||
ASN1_ITEM_end(tname)
|
||||
|
||||
/* This is a ASN1 type which just embeds a template */
|
||||
|
||||
/*-
|
||||
* This pair helps declare a SEQUENCE. We can do:
|
||||
*
|
||||
* ASN1_SEQUENCE(stname) = {
|
||||
* ... SEQUENCE components ...
|
||||
* } ASN1_SEQUENCE_END(stname)
|
||||
*
|
||||
* This will produce an ASN1_ITEM called stname_it
|
||||
* for a structure called stname.
|
||||
*
|
||||
* If you want the same structure but a different
|
||||
* name then use:
|
||||
*
|
||||
* ASN1_SEQUENCE(itname) = {
|
||||
* ... SEQUENCE components ...
|
||||
* } ASN1_SEQUENCE_END_name(stname, itname)
|
||||
*
|
||||
* This will create an item called itname_it using
|
||||
* a structure called stname.
|
||||
*/
|
||||
|
||||
# define ASN1_SEQUENCE(tname) \
|
||||
static const ASN1_TEMPLATE tname##_seq_tt[]
|
||||
|
||||
# define ASN1_SEQUENCE_END(stname) ASN1_SEQUENCE_END_name(stname, stname)
|
||||
|
||||
# define static_ASN1_SEQUENCE_END(stname) static_ASN1_SEQUENCE_END_name(stname, stname)
|
||||
|
||||
# define ASN1_SEQUENCE_END_name(stname, tname) \
|
||||
;\
|
||||
ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_SEQUENCE,\
|
||||
V_ASN1_SEQUENCE,\
|
||||
tname##_seq_tt,\
|
||||
sizeof(tname##_seq_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
NULL,\
|
||||
sizeof(stname),\
|
||||
#tname \
|
||||
ASN1_ITEM_end(tname)
|
||||
|
||||
# define static_ASN1_SEQUENCE_END_name(stname, tname) \
|
||||
;\
|
||||
static_ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_SEQUENCE,\
|
||||
V_ASN1_SEQUENCE,\
|
||||
tname##_seq_tt,\
|
||||
sizeof(tname##_seq_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
NULL,\
|
||||
sizeof(stname),\
|
||||
#stname \
|
||||
ASN1_ITEM_end(tname)
|
||||
|
||||
# define ASN1_NDEF_SEQUENCE(tname) \
|
||||
ASN1_SEQUENCE(tname)
|
||||
|
||||
# define ASN1_NDEF_SEQUENCE_cb(tname, cb) \
|
||||
ASN1_SEQUENCE_cb(tname, cb)
|
||||
|
||||
# define ASN1_SEQUENCE_cb(tname, cb) \
|
||||
static const ASN1_AUX tname##_aux = {NULL, 0, 0, 0, cb, 0, NULL}; \
|
||||
ASN1_SEQUENCE(tname)
|
||||
|
||||
# define ASN1_SEQUENCE_const_cb(tname, const_cb) \
|
||||
static const ASN1_AUX tname##_aux = \
|
||||
{NULL, ASN1_AFLG_CONST_CB, 0, 0, NULL, 0, const_cb}; \
|
||||
ASN1_SEQUENCE(tname)
|
||||
|
||||
# define ASN1_SEQUENCE_cb_const_cb(tname, cb, const_cb) \
|
||||
static const ASN1_AUX tname##_aux = \
|
||||
{NULL, ASN1_AFLG_CONST_CB, 0, 0, cb, 0, const_cb}; \
|
||||
ASN1_SEQUENCE(tname)
|
||||
|
||||
# define ASN1_SEQUENCE_ref(tname, cb) \
|
||||
static const ASN1_AUX tname##_aux = {NULL, ASN1_AFLG_REFCOUNT, offsetof(tname, references), offsetof(tname, lock), cb, 0, NULL}; \
|
||||
ASN1_SEQUENCE(tname)
|
||||
|
||||
# define ASN1_SEQUENCE_enc(tname, enc, cb) \
|
||||
static const ASN1_AUX tname##_aux = {NULL, ASN1_AFLG_ENCODING, 0, 0, cb, offsetof(tname, enc), NULL}; \
|
||||
ASN1_SEQUENCE(tname)
|
||||
|
||||
# define ASN1_NDEF_SEQUENCE_END(tname) \
|
||||
;\
|
||||
ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_NDEF_SEQUENCE,\
|
||||
V_ASN1_SEQUENCE,\
|
||||
tname##_seq_tt,\
|
||||
sizeof(tname##_seq_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
NULL,\
|
||||
sizeof(tname),\
|
||||
#tname \
|
||||
ASN1_ITEM_end(tname)
|
||||
# define static_ASN1_NDEF_SEQUENCE_END(tname) \
|
||||
;\
|
||||
static_ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_NDEF_SEQUENCE,\
|
||||
V_ASN1_SEQUENCE,\
|
||||
tname##_seq_tt,\
|
||||
sizeof(tname##_seq_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
NULL,\
|
||||
sizeof(tname),\
|
||||
#tname \
|
||||
ASN1_ITEM_end(tname)
|
||||
|
||||
|
||||
# define ASN1_SEQUENCE_END_enc(stname, tname) ASN1_SEQUENCE_END_ref(stname, tname)
|
||||
|
||||
# define ASN1_SEQUENCE_END_cb(stname, tname) ASN1_SEQUENCE_END_ref(stname, tname)
|
||||
# define static_ASN1_SEQUENCE_END_cb(stname, tname) static_ASN1_SEQUENCE_END_ref(stname, tname)
|
||||
|
||||
# define ASN1_SEQUENCE_END_ref(stname, tname) \
|
||||
;\
|
||||
ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_SEQUENCE,\
|
||||
V_ASN1_SEQUENCE,\
|
||||
tname##_seq_tt,\
|
||||
sizeof(tname##_seq_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
&tname##_aux,\
|
||||
sizeof(stname),\
|
||||
#tname \
|
||||
ASN1_ITEM_end(tname)
|
||||
# define static_ASN1_SEQUENCE_END_ref(stname, tname) \
|
||||
;\
|
||||
static_ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_SEQUENCE,\
|
||||
V_ASN1_SEQUENCE,\
|
||||
tname##_seq_tt,\
|
||||
sizeof(tname##_seq_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
&tname##_aux,\
|
||||
sizeof(stname),\
|
||||
#stname \
|
||||
ASN1_ITEM_end(tname)
|
||||
|
||||
# define ASN1_NDEF_SEQUENCE_END_cb(stname, tname) \
|
||||
;\
|
||||
ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_NDEF_SEQUENCE,\
|
||||
V_ASN1_SEQUENCE,\
|
||||
tname##_seq_tt,\
|
||||
sizeof(tname##_seq_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
&tname##_aux,\
|
||||
sizeof(stname),\
|
||||
#stname \
|
||||
ASN1_ITEM_end(tname)
|
||||
|
||||
/*-
|
||||
* This pair helps declare a CHOICE type. We can do:
|
||||
*
|
||||
* ASN1_CHOICE(chname) = {
|
||||
* ... CHOICE options ...
|
||||
* ASN1_CHOICE_END(chname)
|
||||
*
|
||||
* This will produce an ASN1_ITEM called chname_it
|
||||
* for a structure called chname. The structure
|
||||
* definition must look like this:
|
||||
* typedef struct {
|
||||
* int type;
|
||||
* union {
|
||||
* ASN1_SOMETHING *opt1;
|
||||
* ASN1_SOMEOTHER *opt2;
|
||||
* } value;
|
||||
* } chname;
|
||||
*
|
||||
* the name of the selector must be 'type'.
|
||||
* to use an alternative selector name use the
|
||||
* ASN1_CHOICE_END_selector() version.
|
||||
*/
|
||||
|
||||
# define ASN1_CHOICE(tname) \
|
||||
static const ASN1_TEMPLATE tname##_ch_tt[]
|
||||
|
||||
# define ASN1_CHOICE_cb(tname, cb) \
|
||||
static const ASN1_AUX tname##_aux = {NULL, 0, 0, 0, cb, 0, NULL}; \
|
||||
ASN1_CHOICE(tname)
|
||||
|
||||
# define ASN1_CHOICE_END(stname) ASN1_CHOICE_END_name(stname, stname)
|
||||
|
||||
# define static_ASN1_CHOICE_END(stname) static_ASN1_CHOICE_END_name(stname, stname)
|
||||
|
||||
# define ASN1_CHOICE_END_name(stname, tname) ASN1_CHOICE_END_selector(stname, tname, type)
|
||||
|
||||
# define static_ASN1_CHOICE_END_name(stname, tname) static_ASN1_CHOICE_END_selector(stname, tname, type)
|
||||
|
||||
# define ASN1_CHOICE_END_selector(stname, tname, selname) \
|
||||
;\
|
||||
ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_CHOICE,\
|
||||
offsetof(stname,selname) ,\
|
||||
tname##_ch_tt,\
|
||||
sizeof(tname##_ch_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
NULL,\
|
||||
sizeof(stname),\
|
||||
#stname \
|
||||
ASN1_ITEM_end(tname)
|
||||
|
||||
# define static_ASN1_CHOICE_END_selector(stname, tname, selname) \
|
||||
;\
|
||||
static_ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_CHOICE,\
|
||||
offsetof(stname,selname) ,\
|
||||
tname##_ch_tt,\
|
||||
sizeof(tname##_ch_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
NULL,\
|
||||
sizeof(stname),\
|
||||
#stname \
|
||||
ASN1_ITEM_end(tname)
|
||||
|
||||
# define ASN1_CHOICE_END_cb(stname, tname, selname) \
|
||||
;\
|
||||
ASN1_ITEM_start(tname) \
|
||||
ASN1_ITYPE_CHOICE,\
|
||||
offsetof(stname,selname) ,\
|
||||
tname##_ch_tt,\
|
||||
sizeof(tname##_ch_tt) / sizeof(ASN1_TEMPLATE),\
|
||||
&tname##_aux,\
|
||||
sizeof(stname),\
|
||||
#stname \
|
||||
ASN1_ITEM_end(tname)
|
||||
|
||||
/* This helps with the template wrapper form of ASN1_ITEM */
|
||||
|
||||
# define ASN1_EX_TEMPLATE_TYPE(flags, tag, name, type) { \
|
||||
(flags), (tag), 0,\
|
||||
#name, ASN1_ITEM_ref(type) }
|
||||
|
||||
/* These help with SEQUENCE or CHOICE components */
|
||||
|
||||
/* used to declare other types */
|
||||
|
||||
# define ASN1_EX_TYPE(flags, tag, stname, field, type) { \
|
||||
(flags), (tag), offsetof(stname, field),\
|
||||
#field, ASN1_ITEM_ref(type) }
|
||||
|
||||
/* implicit and explicit helper macros */
|
||||
|
||||
# define ASN1_IMP_EX(stname, field, type, tag, ex) \
|
||||
ASN1_EX_TYPE(ASN1_TFLG_IMPLICIT | (ex), tag, stname, field, type)
|
||||
|
||||
# define ASN1_EXP_EX(stname, field, type, tag, ex) \
|
||||
ASN1_EX_TYPE(ASN1_TFLG_EXPLICIT | (ex), tag, stname, field, type)
|
||||
|
||||
/* Any defined by macros: the field used is in the table itself */
|
||||
|
||||
# define ASN1_ADB_OBJECT(tblname) { ASN1_TFLG_ADB_OID, -1, 0, #tblname, tblname##_adb }
|
||||
# define ASN1_ADB_INTEGER(tblname) { ASN1_TFLG_ADB_INT, -1, 0, #tblname, tblname##_adb }
|
||||
|
||||
/* Plain simple type */
|
||||
# define ASN1_SIMPLE(stname, field, type) ASN1_EX_TYPE(0,0, stname, field, type)
|
||||
/* Embedded simple type */
|
||||
# define ASN1_EMBED(stname, field, type) ASN1_EX_TYPE(ASN1_TFLG_EMBED,0, stname, field, type)
|
||||
|
||||
/* OPTIONAL simple type */
|
||||
# define ASN1_OPT(stname, field, type) ASN1_EX_TYPE(ASN1_TFLG_OPTIONAL, 0, stname, field, type)
|
||||
# define ASN1_OPT_EMBED(stname, field, type) ASN1_EX_TYPE(ASN1_TFLG_OPTIONAL|ASN1_TFLG_EMBED, 0, stname, field, type)
|
||||
|
||||
/* IMPLICIT tagged simple type */
|
||||
# define ASN1_IMP(stname, field, type, tag) ASN1_IMP_EX(stname, field, type, tag, 0)
|
||||
# define ASN1_IMP_EMBED(stname, field, type, tag) ASN1_IMP_EX(stname, field, type, tag, ASN1_TFLG_EMBED)
|
||||
|
||||
/* IMPLICIT tagged OPTIONAL simple type */
|
||||
# define ASN1_IMP_OPT(stname, field, type, tag) ASN1_IMP_EX(stname, field, type, tag, ASN1_TFLG_OPTIONAL)
|
||||
# define ASN1_IMP_OPT_EMBED(stname, field, type, tag) ASN1_IMP_EX(stname, field, type, tag, ASN1_TFLG_OPTIONAL|ASN1_TFLG_EMBED)
|
||||
|
||||
/* Same as above but EXPLICIT */
|
||||
|
||||
# define ASN1_EXP(stname, field, type, tag) ASN1_EXP_EX(stname, field, type, tag, 0)
|
||||
# define ASN1_EXP_EMBED(stname, field, type, tag) ASN1_EXP_EX(stname, field, type, tag, ASN1_TFLG_EMBED)
|
||||
# define ASN1_EXP_OPT(stname, field, type, tag) ASN1_EXP_EX(stname, field, type, tag, ASN1_TFLG_OPTIONAL)
|
||||
# define ASN1_EXP_OPT_EMBED(stname, field, type, tag) ASN1_EXP_EX(stname, field, type, tag, ASN1_TFLG_OPTIONAL|ASN1_TFLG_EMBED)
|
||||
|
||||
/* SEQUENCE OF type */
|
||||
# define ASN1_SEQUENCE_OF(stname, field, type) \
|
||||
ASN1_EX_TYPE(ASN1_TFLG_SEQUENCE_OF, 0, stname, field, type)
|
||||
|
||||
/* OPTIONAL SEQUENCE OF */
|
||||
# define ASN1_SEQUENCE_OF_OPT(stname, field, type) \
|
||||
ASN1_EX_TYPE(ASN1_TFLG_SEQUENCE_OF|ASN1_TFLG_OPTIONAL, 0, stname, field, type)
|
||||
|
||||
/* Same as above but for SET OF */
|
||||
|
||||
# define ASN1_SET_OF(stname, field, type) \
|
||||
ASN1_EX_TYPE(ASN1_TFLG_SET_OF, 0, stname, field, type)
|
||||
|
||||
# define ASN1_SET_OF_OPT(stname, field, type) \
|
||||
ASN1_EX_TYPE(ASN1_TFLG_SET_OF|ASN1_TFLG_OPTIONAL, 0, stname, field, type)
|
||||
|
||||
/* Finally compound types of SEQUENCE, SET, IMPLICIT, EXPLICIT and OPTIONAL */
|
||||
|
||||
# define ASN1_IMP_SET_OF(stname, field, type, tag) \
|
||||
ASN1_IMP_EX(stname, field, type, tag, ASN1_TFLG_SET_OF)
|
||||
|
||||
# define ASN1_EXP_SET_OF(stname, field, type, tag) \
|
||||
ASN1_EXP_EX(stname, field, type, tag, ASN1_TFLG_SET_OF)
|
||||
|
||||
# define ASN1_IMP_SET_OF_OPT(stname, field, type, tag) \
|
||||
ASN1_IMP_EX(stname, field, type, tag, ASN1_TFLG_SET_OF|ASN1_TFLG_OPTIONAL)
|
||||
|
||||
# define ASN1_EXP_SET_OF_OPT(stname, field, type, tag) \
|
||||
ASN1_EXP_EX(stname, field, type, tag, ASN1_TFLG_SET_OF|ASN1_TFLG_OPTIONAL)
|
||||
|
||||
# define ASN1_IMP_SEQUENCE_OF(stname, field, type, tag) \
|
||||
ASN1_IMP_EX(stname, field, type, tag, ASN1_TFLG_SEQUENCE_OF)
|
||||
|
||||
# define ASN1_IMP_SEQUENCE_OF_OPT(stname, field, type, tag) \
|
||||
ASN1_IMP_EX(stname, field, type, tag, ASN1_TFLG_SEQUENCE_OF|ASN1_TFLG_OPTIONAL)
|
||||
|
||||
# define ASN1_EXP_SEQUENCE_OF(stname, field, type, tag) \
|
||||
ASN1_EXP_EX(stname, field, type, tag, ASN1_TFLG_SEQUENCE_OF)
|
||||
|
||||
# define ASN1_EXP_SEQUENCE_OF_OPT(stname, field, type, tag) \
|
||||
ASN1_EXP_EX(stname, field, type, tag, ASN1_TFLG_SEQUENCE_OF|ASN1_TFLG_OPTIONAL)
|
||||
|
||||
/* EXPLICIT using indefinite length constructed form */
|
||||
# define ASN1_NDEF_EXP(stname, field, type, tag) \
|
||||
ASN1_EXP_EX(stname, field, type, tag, ASN1_TFLG_NDEF)
|
||||
|
||||
/* EXPLICIT OPTIONAL using indefinite length constructed form */
|
||||
# define ASN1_NDEF_EXP_OPT(stname, field, type, tag) \
|
||||
ASN1_EXP_EX(stname, field, type, tag, ASN1_TFLG_OPTIONAL|ASN1_TFLG_NDEF)
|
||||
|
||||
/* Macros for the ASN1_ADB structure */
|
||||
|
||||
# define ASN1_ADB(name) \
|
||||
static const ASN1_ADB_TABLE name##_adbtbl[]
|
||||
|
||||
# define ASN1_ADB_END(name, flags, field, adb_cb, def, none) \
|
||||
;\
|
||||
static const ASN1_ITEM *name##_adb(void) \
|
||||
{ \
|
||||
static const ASN1_ADB internal_adb = \
|
||||
{\
|
||||
flags,\
|
||||
offsetof(name, field),\
|
||||
adb_cb,\
|
||||
name##_adbtbl,\
|
||||
sizeof(name##_adbtbl) / sizeof(ASN1_ADB_TABLE),\
|
||||
def,\
|
||||
none\
|
||||
}; \
|
||||
return (const ASN1_ITEM *) &internal_adb; \
|
||||
} \
|
||||
void dummy_function(void)
|
||||
|
||||
# define ADB_ENTRY(val, template) {val, template}
|
||||
|
||||
# define ASN1_ADB_TEMPLATE(name) \
|
||||
static const ASN1_TEMPLATE name##_tt
|
||||
|
||||
/*
|
||||
* This is the ASN1 template structure that defines a wrapper round the
|
||||
* actual type. It determines the actual position of the field in the value
|
||||
* structure, various flags such as OPTIONAL and the field name.
|
||||
*/
|
||||
|
||||
struct ASN1_TEMPLATE_st {
|
||||
unsigned long flags; /* Various flags */
|
||||
long tag; /* tag, not used if no tagging */
|
||||
unsigned long offset; /* Offset of this field in structure */
|
||||
const char *field_name; /* Field name */
|
||||
ASN1_ITEM_EXP *item; /* Relevant ASN1_ITEM or ASN1_ADB */
|
||||
};
|
||||
|
||||
/* Macro to extract ASN1_ITEM and ASN1_ADB pointer from ASN1_TEMPLATE */
|
||||
|
||||
# define ASN1_TEMPLATE_item(t) (t->item_ptr)
|
||||
# define ASN1_TEMPLATE_adb(t) (t->item_ptr)
|
||||
|
||||
typedef struct ASN1_ADB_TABLE_st ASN1_ADB_TABLE;
|
||||
typedef struct ASN1_ADB_st ASN1_ADB;
|
||||
|
||||
struct ASN1_ADB_st {
|
||||
unsigned long flags; /* Various flags */
|
||||
unsigned long offset; /* Offset of selector field */
|
||||
int (*adb_cb)(long *psel); /* Application callback */
|
||||
const ASN1_ADB_TABLE *tbl; /* Table of possible types */
|
||||
long tblcount; /* Number of entries in tbl */
|
||||
const ASN1_TEMPLATE *default_tt; /* Type to use if no match */
|
||||
const ASN1_TEMPLATE *null_tt; /* Type to use if selector is NULL */
|
||||
};
|
||||
|
||||
struct ASN1_ADB_TABLE_st {
|
||||
long value; /* NID for an object or value for an int */
|
||||
const ASN1_TEMPLATE tt; /* item for this value */
|
||||
};
|
||||
|
||||
/* template flags */
|
||||
|
||||
/* Field is optional */
|
||||
# define ASN1_TFLG_OPTIONAL (0x1)
|
||||
|
||||
/* Field is a SET OF */
|
||||
# define ASN1_TFLG_SET_OF (0x1 << 1)
|
||||
|
||||
/* Field is a SEQUENCE OF */
|
||||
# define ASN1_TFLG_SEQUENCE_OF (0x2 << 1)
|
||||
|
||||
/*
|
||||
* Special case: this refers to a SET OF that will be sorted into DER order
|
||||
* when encoded *and* the corresponding STACK will be modified to match the
|
||||
* new order.
|
||||
*/
|
||||
# define ASN1_TFLG_SET_ORDER (0x3 << 1)
|
||||
|
||||
/* Mask for SET OF or SEQUENCE OF */
|
||||
# define ASN1_TFLG_SK_MASK (0x3 << 1)
|
||||
|
||||
/*
|
||||
* These flags mean the tag should be taken from the tag field. If EXPLICIT
|
||||
* then the underlying type is used for the inner tag.
|
||||
*/
|
||||
|
||||
/* IMPLICIT tagging */
|
||||
# define ASN1_TFLG_IMPTAG (0x1 << 3)
|
||||
|
||||
/* EXPLICIT tagging, inner tag from underlying type */
|
||||
# define ASN1_TFLG_EXPTAG (0x2 << 3)
|
||||
|
||||
# define ASN1_TFLG_TAG_MASK (0x3 << 3)
|
||||
|
||||
/* context specific IMPLICIT */
|
||||
# define ASN1_TFLG_IMPLICIT (ASN1_TFLG_IMPTAG|ASN1_TFLG_CONTEXT)
|
||||
|
||||
/* context specific EXPLICIT */
|
||||
# define ASN1_TFLG_EXPLICIT (ASN1_TFLG_EXPTAG|ASN1_TFLG_CONTEXT)
|
||||
|
||||
/*
|
||||
* If tagging is in force these determine the type of tag to use. Otherwise
|
||||
* the tag is determined by the underlying type. These values reflect the
|
||||
* actual octet format.
|
||||
*/
|
||||
|
||||
/* Universal tag */
|
||||
# define ASN1_TFLG_UNIVERSAL (0x0<<6)
|
||||
/* Application tag */
|
||||
# define ASN1_TFLG_APPLICATION (0x1<<6)
|
||||
/* Context specific tag */
|
||||
# define ASN1_TFLG_CONTEXT (0x2<<6)
|
||||
/* Private tag */
|
||||
# define ASN1_TFLG_PRIVATE (0x3<<6)
|
||||
|
||||
# define ASN1_TFLG_TAG_CLASS (0x3<<6)
|
||||
|
||||
/*
|
||||
* These are for ANY DEFINED BY type. In this case the 'item' field points to
|
||||
* an ASN1_ADB structure which contains a table of values to decode the
|
||||
* relevant type
|
||||
*/
|
||||
|
||||
# define ASN1_TFLG_ADB_MASK (0x3<<8)
|
||||
|
||||
# define ASN1_TFLG_ADB_OID (0x1<<8)
|
||||
|
||||
# define ASN1_TFLG_ADB_INT (0x1<<9)
|
||||
|
||||
/*
|
||||
* This flag when present in a SEQUENCE OF, SET OF or EXPLICIT causes
|
||||
* indefinite length constructed encoding to be used if required.
|
||||
*/
|
||||
|
||||
# define ASN1_TFLG_NDEF (0x1<<11)
|
||||
|
||||
/* Field is embedded and not a pointer */
|
||||
# define ASN1_TFLG_EMBED (0x1 << 12)
|
||||
|
||||
/* This is the actual ASN1 item itself */
|
||||
|
||||
struct ASN1_ITEM_st {
|
||||
char itype; /* The item type, primitive, SEQUENCE, CHOICE
|
||||
* or extern */
|
||||
long utype; /* underlying type */
|
||||
const ASN1_TEMPLATE *templates; /* If SEQUENCE or CHOICE this contains
|
||||
* the contents */
|
||||
long tcount; /* Number of templates if SEQUENCE or CHOICE */
|
||||
const void *funcs; /* further data and type-specific functions */
|
||||
/* funcs can be ASN1_PRIMITIVE_FUNCS*, ASN1_EXTERN_FUNCS*, or ASN1_AUX* */
|
||||
long size; /* Structure size (usually) */
|
||||
const char *sname; /* Structure name */
|
||||
};
|
||||
|
||||
/*
|
||||
* Cache for ASN1 tag and length, so we don't keep re-reading it for things
|
||||
* like CHOICE
|
||||
*/
|
||||
|
||||
struct ASN1_TLC_st {
|
||||
char valid; /* Values below are valid */
|
||||
int ret; /* return value */
|
||||
long plen; /* length */
|
||||
int ptag; /* class value */
|
||||
int pclass; /* class value */
|
||||
int hdrlen; /* header length */
|
||||
};
|
||||
|
||||
/* Typedefs for ASN1 function pointers */
|
||||
typedef int ASN1_ex_d2i(ASN1_VALUE **pval, const unsigned char **in, long len,
|
||||
const ASN1_ITEM *it, int tag, int aclass, char opt,
|
||||
ASN1_TLC *ctx);
|
||||
|
||||
typedef int ASN1_ex_d2i_ex(ASN1_VALUE **pval, const unsigned char **in, long len,
|
||||
const ASN1_ITEM *it, int tag, int aclass, char opt,
|
||||
ASN1_TLC *ctx, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
typedef int ASN1_ex_i2d(const ASN1_VALUE **pval, unsigned char **out,
|
||||
const ASN1_ITEM *it, int tag, int aclass);
|
||||
typedef int ASN1_ex_new_func(ASN1_VALUE **pval, const ASN1_ITEM *it);
|
||||
typedef int ASN1_ex_new_ex_func(ASN1_VALUE **pval, const ASN1_ITEM *it,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
typedef void ASN1_ex_free_func(ASN1_VALUE **pval, const ASN1_ITEM *it);
|
||||
|
||||
typedef int ASN1_ex_print_func(BIO *out, const ASN1_VALUE **pval,
|
||||
int indent, const char *fname,
|
||||
const ASN1_PCTX *pctx);
|
||||
|
||||
typedef int ASN1_primitive_i2c(const ASN1_VALUE **pval, unsigned char *cont,
|
||||
int *putype, const ASN1_ITEM *it);
|
||||
typedef int ASN1_primitive_c2i(ASN1_VALUE **pval, const unsigned char *cont,
|
||||
int len, int utype, char *free_cont,
|
||||
const ASN1_ITEM *it);
|
||||
typedef int ASN1_primitive_print(BIO *out, const ASN1_VALUE **pval,
|
||||
const ASN1_ITEM *it, int indent,
|
||||
const ASN1_PCTX *pctx);
|
||||
|
||||
typedef struct ASN1_EXTERN_FUNCS_st {
|
||||
void *app_data;
|
||||
ASN1_ex_new_func *asn1_ex_new;
|
||||
ASN1_ex_free_func *asn1_ex_free;
|
||||
ASN1_ex_free_func *asn1_ex_clear;
|
||||
ASN1_ex_d2i *asn1_ex_d2i;
|
||||
ASN1_ex_i2d *asn1_ex_i2d;
|
||||
ASN1_ex_print_func *asn1_ex_print;
|
||||
ASN1_ex_new_ex_func *asn1_ex_new_ex;
|
||||
ASN1_ex_d2i_ex *asn1_ex_d2i_ex;
|
||||
} ASN1_EXTERN_FUNCS;
|
||||
|
||||
typedef struct ASN1_PRIMITIVE_FUNCS_st {
|
||||
void *app_data;
|
||||
unsigned long flags;
|
||||
ASN1_ex_new_func *prim_new;
|
||||
ASN1_ex_free_func *prim_free;
|
||||
ASN1_ex_free_func *prim_clear;
|
||||
ASN1_primitive_c2i *prim_c2i;
|
||||
ASN1_primitive_i2c *prim_i2c;
|
||||
ASN1_primitive_print *prim_print;
|
||||
} ASN1_PRIMITIVE_FUNCS;
|
||||
|
||||
/*
|
||||
* This is the ASN1_AUX structure: it handles various miscellaneous
|
||||
* requirements. For example the use of reference counts and an informational
|
||||
* callback. The "informational callback" is called at various points during
|
||||
* the ASN1 encoding and decoding. It can be used to provide minor
|
||||
* customisation of the structures used. This is most useful where the
|
||||
* supplied routines *almost* do the right thing but need some extra help at
|
||||
* a few points. If the callback returns zero then it is assumed a fatal
|
||||
* error has occurred and the main operation should be abandoned. If major
|
||||
* changes in the default behaviour are required then an external type is
|
||||
* more appropriate.
|
||||
* For the operations ASN1_OP_I2D_PRE, ASN1_OP_I2D_POST, ASN1_OP_PRINT_PRE, and
|
||||
* ASN1_OP_PRINT_POST, meanwhile a variant of the callback with const parameter
|
||||
* 'in' is provided to make clear statically that its input is not modified. If
|
||||
* and only if this variant is in use the flag ASN1_AFLG_CONST_CB must be set.
|
||||
*/
|
||||
|
||||
typedef int ASN1_aux_cb(int operation, ASN1_VALUE **in, const ASN1_ITEM *it,
|
||||
void *exarg);
|
||||
typedef int ASN1_aux_const_cb(int operation, const ASN1_VALUE **in,
|
||||
const ASN1_ITEM *it, void *exarg);
|
||||
|
||||
typedef struct ASN1_AUX_st {
|
||||
void *app_data;
|
||||
int flags;
|
||||
int ref_offset; /* Offset of reference value */
|
||||
int ref_lock; /* Offset of lock value */
|
||||
ASN1_aux_cb *asn1_cb;
|
||||
int enc_offset; /* Offset of ASN1_ENCODING structure */
|
||||
ASN1_aux_const_cb *asn1_const_cb; /* for ASN1_OP_I2D_ and ASN1_OP_PRINT_ */
|
||||
} ASN1_AUX;
|
||||
|
||||
/* For print related callbacks exarg points to this structure */
|
||||
typedef struct ASN1_PRINT_ARG_st {
|
||||
BIO *out;
|
||||
int indent;
|
||||
const ASN1_PCTX *pctx;
|
||||
} ASN1_PRINT_ARG;
|
||||
|
||||
/* For streaming related callbacks exarg points to this structure */
|
||||
typedef struct ASN1_STREAM_ARG_st {
|
||||
/* BIO to stream through */
|
||||
BIO *out;
|
||||
/* BIO with filters appended */
|
||||
BIO *ndef_bio;
|
||||
/* Streaming I/O boundary */
|
||||
unsigned char **boundary;
|
||||
} ASN1_STREAM_ARG;
|
||||
|
||||
/* Flags in ASN1_AUX */
|
||||
|
||||
/* Use a reference count */
|
||||
# define ASN1_AFLG_REFCOUNT 1
|
||||
/* Save the encoding of structure (useful for signatures) */
|
||||
# define ASN1_AFLG_ENCODING 2
|
||||
/* The Sequence length is invalid */
|
||||
# define ASN1_AFLG_BROKEN 4
|
||||
/* Use the new asn1_const_cb */
|
||||
# define ASN1_AFLG_CONST_CB 8
|
||||
|
||||
/* operation values for asn1_cb */
|
||||
|
||||
# define ASN1_OP_NEW_PRE 0
|
||||
# define ASN1_OP_NEW_POST 1
|
||||
# define ASN1_OP_FREE_PRE 2
|
||||
# define ASN1_OP_FREE_POST 3
|
||||
# define ASN1_OP_D2I_PRE 4
|
||||
# define ASN1_OP_D2I_POST 5
|
||||
# define ASN1_OP_I2D_PRE 6
|
||||
# define ASN1_OP_I2D_POST 7
|
||||
# define ASN1_OP_PRINT_PRE 8
|
||||
# define ASN1_OP_PRINT_POST 9
|
||||
# define ASN1_OP_STREAM_PRE 10
|
||||
# define ASN1_OP_STREAM_POST 11
|
||||
# define ASN1_OP_DETACHED_PRE 12
|
||||
# define ASN1_OP_DETACHED_POST 13
|
||||
# define ASN1_OP_DUP_PRE 14
|
||||
# define ASN1_OP_DUP_POST 15
|
||||
# define ASN1_OP_GET0_LIBCTX 16
|
||||
# define ASN1_OP_GET0_PROPQ 17
|
||||
|
||||
/* Macro to implement a primitive type */
|
||||
# define IMPLEMENT_ASN1_TYPE(stname) IMPLEMENT_ASN1_TYPE_ex(stname, stname, 0)
|
||||
# define IMPLEMENT_ASN1_TYPE_ex(itname, vname, ex) \
|
||||
ASN1_ITEM_start(itname) \
|
||||
ASN1_ITYPE_PRIMITIVE, V_##vname, NULL, 0, NULL, ex, #itname \
|
||||
ASN1_ITEM_end(itname)
|
||||
|
||||
/* Macro to implement a multi string type */
|
||||
# define IMPLEMENT_ASN1_MSTRING(itname, mask) \
|
||||
ASN1_ITEM_start(itname) \
|
||||
ASN1_ITYPE_MSTRING, mask, NULL, 0, NULL, sizeof(ASN1_STRING), #itname \
|
||||
ASN1_ITEM_end(itname)
|
||||
|
||||
# define IMPLEMENT_EXTERN_ASN1(sname, tag, fptrs) \
|
||||
ASN1_ITEM_start(sname) \
|
||||
ASN1_ITYPE_EXTERN, \
|
||||
tag, \
|
||||
NULL, \
|
||||
0, \
|
||||
&fptrs, \
|
||||
0, \
|
||||
#sname \
|
||||
ASN1_ITEM_end(sname)
|
||||
|
||||
/* Macro to implement standard functions in terms of ASN1_ITEM structures */
|
||||
|
||||
# define IMPLEMENT_ASN1_FUNCTIONS(stname) IMPLEMENT_ASN1_FUNCTIONS_fname(stname, stname, stname)
|
||||
|
||||
# define IMPLEMENT_ASN1_FUNCTIONS_name(stname, itname) IMPLEMENT_ASN1_FUNCTIONS_fname(stname, itname, itname)
|
||||
|
||||
# define IMPLEMENT_ASN1_FUNCTIONS_ENCODE_name(stname, itname) \
|
||||
IMPLEMENT_ASN1_FUNCTIONS_ENCODE_fname(stname, itname, itname)
|
||||
|
||||
# define IMPLEMENT_STATIC_ASN1_ALLOC_FUNCTIONS(stname) \
|
||||
IMPLEMENT_ASN1_ALLOC_FUNCTIONS_pfname(static, stname, stname, stname)
|
||||
|
||||
# define IMPLEMENT_ASN1_ALLOC_FUNCTIONS(stname) \
|
||||
IMPLEMENT_ASN1_ALLOC_FUNCTIONS_fname(stname, stname, stname)
|
||||
|
||||
# define IMPLEMENT_ASN1_ALLOC_FUNCTIONS_pfname(pre, stname, itname, fname) \
|
||||
pre stname *fname##_new(void) \
|
||||
{ \
|
||||
return (stname *)ASN1_item_new(ASN1_ITEM_rptr(itname)); \
|
||||
} \
|
||||
pre void fname##_free(stname *a) \
|
||||
{ \
|
||||
ASN1_item_free((ASN1_VALUE *)a, ASN1_ITEM_rptr(itname)); \
|
||||
}
|
||||
|
||||
# define IMPLEMENT_ASN1_ALLOC_FUNCTIONS_fname(stname, itname, fname) \
|
||||
stname *fname##_new(void) \
|
||||
{ \
|
||||
return (stname *)ASN1_item_new(ASN1_ITEM_rptr(itname)); \
|
||||
} \
|
||||
void fname##_free(stname *a) \
|
||||
{ \
|
||||
ASN1_item_free((ASN1_VALUE *)a, ASN1_ITEM_rptr(itname)); \
|
||||
}
|
||||
|
||||
# define IMPLEMENT_ASN1_FUNCTIONS_fname(stname, itname, fname) \
|
||||
IMPLEMENT_ASN1_ENCODE_FUNCTIONS_fname(stname, itname, fname) \
|
||||
IMPLEMENT_ASN1_ALLOC_FUNCTIONS_fname(stname, itname, fname)
|
||||
|
||||
# define IMPLEMENT_ASN1_ENCODE_FUNCTIONS_fname(stname, itname, fname) \
|
||||
stname *d2i_##fname(stname **a, const unsigned char **in, long len) \
|
||||
{ \
|
||||
return (stname *)ASN1_item_d2i((ASN1_VALUE **)a, in, len, ASN1_ITEM_rptr(itname));\
|
||||
} \
|
||||
int i2d_##fname(const stname *a, unsigned char **out) \
|
||||
{ \
|
||||
return ASN1_item_i2d((const ASN1_VALUE *)a, out, ASN1_ITEM_rptr(itname));\
|
||||
}
|
||||
|
||||
# define IMPLEMENT_ASN1_NDEF_FUNCTION(stname) \
|
||||
int i2d_##stname##_NDEF(const stname *a, unsigned char **out) \
|
||||
{ \
|
||||
return ASN1_item_ndef_i2d((const ASN1_VALUE *)a, out, ASN1_ITEM_rptr(stname));\
|
||||
}
|
||||
|
||||
# define IMPLEMENT_STATIC_ASN1_ENCODE_FUNCTIONS(stname) \
|
||||
static stname *d2i_##stname(stname **a, \
|
||||
const unsigned char **in, long len) \
|
||||
{ \
|
||||
return (stname *)ASN1_item_d2i((ASN1_VALUE **)a, in, len, \
|
||||
ASN1_ITEM_rptr(stname)); \
|
||||
} \
|
||||
static int i2d_##stname(const stname *a, unsigned char **out) \
|
||||
{ \
|
||||
return ASN1_item_i2d((const ASN1_VALUE *)a, out, \
|
||||
ASN1_ITEM_rptr(stname)); \
|
||||
}
|
||||
|
||||
# define IMPLEMENT_ASN1_DUP_FUNCTION(stname) \
|
||||
stname * stname##_dup(const stname *x) \
|
||||
{ \
|
||||
return ASN1_item_dup(ASN1_ITEM_rptr(stname), x); \
|
||||
}
|
||||
|
||||
# define IMPLEMENT_ASN1_PRINT_FUNCTION(stname) \
|
||||
IMPLEMENT_ASN1_PRINT_FUNCTION_fname(stname, stname, stname)
|
||||
|
||||
# define IMPLEMENT_ASN1_PRINT_FUNCTION_fname(stname, itname, fname) \
|
||||
int fname##_print_ctx(BIO *out, const stname *x, int indent, \
|
||||
const ASN1_PCTX *pctx) \
|
||||
{ \
|
||||
return ASN1_item_print(out, (const ASN1_VALUE *)x, indent, \
|
||||
ASN1_ITEM_rptr(itname), pctx); \
|
||||
}
|
||||
|
||||
/* external definitions for primitive types */
|
||||
|
||||
DECLARE_ASN1_ITEM(ASN1_BOOLEAN)
|
||||
DECLARE_ASN1_ITEM(ASN1_TBOOLEAN)
|
||||
DECLARE_ASN1_ITEM(ASN1_FBOOLEAN)
|
||||
DECLARE_ASN1_ITEM(ASN1_SEQUENCE)
|
||||
DECLARE_ASN1_ITEM(CBIGNUM)
|
||||
DECLARE_ASN1_ITEM(BIGNUM)
|
||||
DECLARE_ASN1_ITEM(INT32)
|
||||
DECLARE_ASN1_ITEM(ZINT32)
|
||||
DECLARE_ASN1_ITEM(UINT32)
|
||||
DECLARE_ASN1_ITEM(ZUINT32)
|
||||
DECLARE_ASN1_ITEM(INT64)
|
||||
DECLARE_ASN1_ITEM(ZINT64)
|
||||
DECLARE_ASN1_ITEM(UINT64)
|
||||
DECLARE_ASN1_ITEM(ZUINT64)
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
/*
|
||||
* LONG and ZLONG are strongly discouraged for use as stored data, as the
|
||||
* underlying C type (long) differs in size depending on the architecture.
|
||||
* They are designed with 32-bit longs in mind.
|
||||
*/
|
||||
DECLARE_ASN1_ITEM(LONG)
|
||||
DECLARE_ASN1_ITEM(ZLONG)
|
||||
# endif
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(ASN1_VALUE, ASN1_VALUE, ASN1_VALUE)
|
||||
#define sk_ASN1_VALUE_num(sk) OPENSSL_sk_num(ossl_check_const_ASN1_VALUE_sk_type(sk))
|
||||
#define sk_ASN1_VALUE_value(sk, idx) ((ASN1_VALUE *)OPENSSL_sk_value(ossl_check_const_ASN1_VALUE_sk_type(sk), (idx)))
|
||||
#define sk_ASN1_VALUE_new(cmp) ((STACK_OF(ASN1_VALUE) *)OPENSSL_sk_new(ossl_check_ASN1_VALUE_compfunc_type(cmp)))
|
||||
#define sk_ASN1_VALUE_new_null() ((STACK_OF(ASN1_VALUE) *)OPENSSL_sk_new_null())
|
||||
#define sk_ASN1_VALUE_new_reserve(cmp, n) ((STACK_OF(ASN1_VALUE) *)OPENSSL_sk_new_reserve(ossl_check_ASN1_VALUE_compfunc_type(cmp), (n)))
|
||||
#define sk_ASN1_VALUE_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_ASN1_VALUE_sk_type(sk), (n))
|
||||
#define sk_ASN1_VALUE_free(sk) OPENSSL_sk_free(ossl_check_ASN1_VALUE_sk_type(sk))
|
||||
#define sk_ASN1_VALUE_zero(sk) OPENSSL_sk_zero(ossl_check_ASN1_VALUE_sk_type(sk))
|
||||
#define sk_ASN1_VALUE_delete(sk, i) ((ASN1_VALUE *)OPENSSL_sk_delete(ossl_check_ASN1_VALUE_sk_type(sk), (i)))
|
||||
#define sk_ASN1_VALUE_delete_ptr(sk, ptr) ((ASN1_VALUE *)OPENSSL_sk_delete_ptr(ossl_check_ASN1_VALUE_sk_type(sk), ossl_check_ASN1_VALUE_type(ptr)))
|
||||
#define sk_ASN1_VALUE_push(sk, ptr) OPENSSL_sk_push(ossl_check_ASN1_VALUE_sk_type(sk), ossl_check_ASN1_VALUE_type(ptr))
|
||||
#define sk_ASN1_VALUE_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_ASN1_VALUE_sk_type(sk), ossl_check_ASN1_VALUE_type(ptr))
|
||||
#define sk_ASN1_VALUE_pop(sk) ((ASN1_VALUE *)OPENSSL_sk_pop(ossl_check_ASN1_VALUE_sk_type(sk)))
|
||||
#define sk_ASN1_VALUE_shift(sk) ((ASN1_VALUE *)OPENSSL_sk_shift(ossl_check_ASN1_VALUE_sk_type(sk)))
|
||||
#define sk_ASN1_VALUE_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_ASN1_VALUE_sk_type(sk),ossl_check_ASN1_VALUE_freefunc_type(freefunc))
|
||||
#define sk_ASN1_VALUE_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_ASN1_VALUE_sk_type(sk), ossl_check_ASN1_VALUE_type(ptr), (idx))
|
||||
#define sk_ASN1_VALUE_set(sk, idx, ptr) ((ASN1_VALUE *)OPENSSL_sk_set(ossl_check_ASN1_VALUE_sk_type(sk), (idx), ossl_check_ASN1_VALUE_type(ptr)))
|
||||
#define sk_ASN1_VALUE_find(sk, ptr) OPENSSL_sk_find(ossl_check_ASN1_VALUE_sk_type(sk), ossl_check_ASN1_VALUE_type(ptr))
|
||||
#define sk_ASN1_VALUE_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_ASN1_VALUE_sk_type(sk), ossl_check_ASN1_VALUE_type(ptr))
|
||||
#define sk_ASN1_VALUE_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_ASN1_VALUE_sk_type(sk), ossl_check_ASN1_VALUE_type(ptr), pnum)
|
||||
#define sk_ASN1_VALUE_sort(sk) OPENSSL_sk_sort(ossl_check_ASN1_VALUE_sk_type(sk))
|
||||
#define sk_ASN1_VALUE_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_ASN1_VALUE_sk_type(sk))
|
||||
#define sk_ASN1_VALUE_dup(sk) ((STACK_OF(ASN1_VALUE) *)OPENSSL_sk_dup(ossl_check_const_ASN1_VALUE_sk_type(sk)))
|
||||
#define sk_ASN1_VALUE_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(ASN1_VALUE) *)OPENSSL_sk_deep_copy(ossl_check_const_ASN1_VALUE_sk_type(sk), ossl_check_ASN1_VALUE_copyfunc_type(copyfunc), ossl_check_ASN1_VALUE_freefunc_type(freefunc)))
|
||||
#define sk_ASN1_VALUE_set_cmp_func(sk, cmp) ((sk_ASN1_VALUE_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_ASN1_VALUE_sk_type(sk), ossl_check_ASN1_VALUE_compfunc_type(cmp)))
|
||||
|
||||
|
||||
|
||||
/* Functions used internally by the ASN1 code */
|
||||
|
||||
int ASN1_item_ex_new(ASN1_VALUE **pval, const ASN1_ITEM *it);
|
||||
void ASN1_item_ex_free(ASN1_VALUE **pval, const ASN1_ITEM *it);
|
||||
|
||||
int ASN1_item_ex_d2i(ASN1_VALUE **pval, const unsigned char **in, long len,
|
||||
const ASN1_ITEM *it, int tag, int aclass, char opt,
|
||||
ASN1_TLC *ctx);
|
||||
|
||||
int ASN1_item_ex_i2d(const ASN1_VALUE **pval, unsigned char **out,
|
||||
const ASN1_ITEM *it, int tag, int aclass);
|
||||
|
||||
/* Legacy compatibility */
|
||||
# define IMPLEMENT_ASN1_FUNCTIONS_const(name) IMPLEMENT_ASN1_FUNCTIONS(name)
|
||||
# define IMPLEMENT_ASN1_ENCODE_FUNCTIONS_const_fname(stname, itname, fname) \
|
||||
IMPLEMENT_ASN1_ENCODE_FUNCTIONS_fname(stname, itname, fname)
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
887
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/bio.h
generated
vendored
Normal file
887
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/bio.h
generated
vendored
Normal file
@@ -0,0 +1,887 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/bio.h.in
|
||||
*
|
||||
* Copyright 1995-2022 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
#ifndef OPENSSL_BIO_H
|
||||
# define OPENSSL_BIO_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_BIO_H
|
||||
# endif
|
||||
|
||||
# include <openssl/e_os2.h>
|
||||
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
# include <stdio.h>
|
||||
# endif
|
||||
# include <stdarg.h>
|
||||
|
||||
# include <openssl/crypto.h>
|
||||
# include <openssl/bioerr.h>
|
||||
# include <openssl/core.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* There are the classes of BIOs */
|
||||
# define BIO_TYPE_DESCRIPTOR 0x0100 /* socket, fd, connect or accept */
|
||||
# define BIO_TYPE_FILTER 0x0200
|
||||
# define BIO_TYPE_SOURCE_SINK 0x0400
|
||||
|
||||
/* These are the 'types' of BIOs */
|
||||
# define BIO_TYPE_NONE 0
|
||||
# define BIO_TYPE_MEM ( 1|BIO_TYPE_SOURCE_SINK)
|
||||
# define BIO_TYPE_FILE ( 2|BIO_TYPE_SOURCE_SINK)
|
||||
|
||||
# define BIO_TYPE_FD ( 4|BIO_TYPE_SOURCE_SINK|BIO_TYPE_DESCRIPTOR)
|
||||
# define BIO_TYPE_SOCKET ( 5|BIO_TYPE_SOURCE_SINK|BIO_TYPE_DESCRIPTOR)
|
||||
# define BIO_TYPE_NULL ( 6|BIO_TYPE_SOURCE_SINK)
|
||||
# define BIO_TYPE_SSL ( 7|BIO_TYPE_FILTER)
|
||||
# define BIO_TYPE_MD ( 8|BIO_TYPE_FILTER)
|
||||
# define BIO_TYPE_BUFFER ( 9|BIO_TYPE_FILTER)
|
||||
# define BIO_TYPE_CIPHER (10|BIO_TYPE_FILTER)
|
||||
# define BIO_TYPE_BASE64 (11|BIO_TYPE_FILTER)
|
||||
# define BIO_TYPE_CONNECT (12|BIO_TYPE_SOURCE_SINK|BIO_TYPE_DESCRIPTOR)
|
||||
# define BIO_TYPE_ACCEPT (13|BIO_TYPE_SOURCE_SINK|BIO_TYPE_DESCRIPTOR)
|
||||
|
||||
# define BIO_TYPE_NBIO_TEST (16|BIO_TYPE_FILTER)/* server proxy BIO */
|
||||
# define BIO_TYPE_NULL_FILTER (17|BIO_TYPE_FILTER)
|
||||
# define BIO_TYPE_BIO (19|BIO_TYPE_SOURCE_SINK)/* half a BIO pair */
|
||||
# define BIO_TYPE_LINEBUFFER (20|BIO_TYPE_FILTER)
|
||||
# define BIO_TYPE_DGRAM (21|BIO_TYPE_SOURCE_SINK|BIO_TYPE_DESCRIPTOR)
|
||||
# define BIO_TYPE_ASN1 (22|BIO_TYPE_FILTER)
|
||||
# define BIO_TYPE_COMP (23|BIO_TYPE_FILTER)
|
||||
# ifndef OPENSSL_NO_SCTP
|
||||
# define BIO_TYPE_DGRAM_SCTP (24|BIO_TYPE_SOURCE_SINK|BIO_TYPE_DESCRIPTOR)
|
||||
# endif
|
||||
# define BIO_TYPE_CORE_TO_PROV (25|BIO_TYPE_SOURCE_SINK)
|
||||
|
||||
#define BIO_TYPE_START 128
|
||||
|
||||
/*
|
||||
* BIO_FILENAME_READ|BIO_CLOSE to open or close on free.
|
||||
* BIO_set_fp(in,stdin,BIO_NOCLOSE);
|
||||
*/
|
||||
# define BIO_NOCLOSE 0x00
|
||||
# define BIO_CLOSE 0x01
|
||||
|
||||
/*
|
||||
* These are used in the following macros and are passed to BIO_ctrl()
|
||||
*/
|
||||
# define BIO_CTRL_RESET 1/* opt - rewind/zero etc */
|
||||
# define BIO_CTRL_EOF 2/* opt - are we at the eof */
|
||||
# define BIO_CTRL_INFO 3/* opt - extra tit-bits */
|
||||
# define BIO_CTRL_SET 4/* man - set the 'IO' type */
|
||||
# define BIO_CTRL_GET 5/* man - get the 'IO' type */
|
||||
# define BIO_CTRL_PUSH 6/* opt - internal, used to signify change */
|
||||
# define BIO_CTRL_POP 7/* opt - internal, used to signify change */
|
||||
# define BIO_CTRL_GET_CLOSE 8/* man - set the 'close' on free */
|
||||
# define BIO_CTRL_SET_CLOSE 9/* man - set the 'close' on free */
|
||||
# define BIO_CTRL_PENDING 10/* opt - is their more data buffered */
|
||||
# define BIO_CTRL_FLUSH 11/* opt - 'flush' buffered output */
|
||||
# define BIO_CTRL_DUP 12/* man - extra stuff for 'duped' BIO */
|
||||
# define BIO_CTRL_WPENDING 13/* opt - number of bytes still to write */
|
||||
# define BIO_CTRL_SET_CALLBACK 14/* opt - set callback function */
|
||||
# define BIO_CTRL_GET_CALLBACK 15/* opt - set callback function */
|
||||
|
||||
# define BIO_CTRL_PEEK 29/* BIO_f_buffer special */
|
||||
# define BIO_CTRL_SET_FILENAME 30/* BIO_s_file special */
|
||||
|
||||
/* dgram BIO stuff */
|
||||
# define BIO_CTRL_DGRAM_CONNECT 31/* BIO dgram special */
|
||||
# define BIO_CTRL_DGRAM_SET_CONNECTED 32/* allow for an externally connected
|
||||
* socket to be passed in */
|
||||
# define BIO_CTRL_DGRAM_SET_RECV_TIMEOUT 33/* setsockopt, essentially */
|
||||
# define BIO_CTRL_DGRAM_GET_RECV_TIMEOUT 34/* getsockopt, essentially */
|
||||
# define BIO_CTRL_DGRAM_SET_SEND_TIMEOUT 35/* setsockopt, essentially */
|
||||
# define BIO_CTRL_DGRAM_GET_SEND_TIMEOUT 36/* getsockopt, essentially */
|
||||
|
||||
# define BIO_CTRL_DGRAM_GET_RECV_TIMER_EXP 37/* flag whether the last */
|
||||
# define BIO_CTRL_DGRAM_GET_SEND_TIMER_EXP 38/* I/O operation timed out */
|
||||
|
||||
/* #ifdef IP_MTU_DISCOVER */
|
||||
# define BIO_CTRL_DGRAM_MTU_DISCOVER 39/* set DF bit on egress packets */
|
||||
/* #endif */
|
||||
|
||||
# define BIO_CTRL_DGRAM_QUERY_MTU 40/* as kernel for current MTU */
|
||||
# define BIO_CTRL_DGRAM_GET_FALLBACK_MTU 47
|
||||
# define BIO_CTRL_DGRAM_GET_MTU 41/* get cached value for MTU */
|
||||
# define BIO_CTRL_DGRAM_SET_MTU 42/* set cached value for MTU.
|
||||
* want to use this if asking
|
||||
* the kernel fails */
|
||||
|
||||
# define BIO_CTRL_DGRAM_MTU_EXCEEDED 43/* check whether the MTU was
|
||||
* exceed in the previous write
|
||||
* operation */
|
||||
|
||||
# define BIO_CTRL_DGRAM_GET_PEER 46
|
||||
# define BIO_CTRL_DGRAM_SET_PEER 44/* Destination for the data */
|
||||
|
||||
# define BIO_CTRL_DGRAM_SET_NEXT_TIMEOUT 45/* Next DTLS handshake timeout
|
||||
* to adjust socket timeouts */
|
||||
# define BIO_CTRL_DGRAM_SET_DONT_FRAG 48
|
||||
|
||||
# define BIO_CTRL_DGRAM_GET_MTU_OVERHEAD 49
|
||||
|
||||
/* Deliberately outside of OPENSSL_NO_SCTP - used in bss_dgram.c */
|
||||
# define BIO_CTRL_DGRAM_SCTP_SET_IN_HANDSHAKE 50
|
||||
# ifndef OPENSSL_NO_SCTP
|
||||
/* SCTP stuff */
|
||||
# define BIO_CTRL_DGRAM_SCTP_ADD_AUTH_KEY 51
|
||||
# define BIO_CTRL_DGRAM_SCTP_NEXT_AUTH_KEY 52
|
||||
# define BIO_CTRL_DGRAM_SCTP_AUTH_CCS_RCVD 53
|
||||
# define BIO_CTRL_DGRAM_SCTP_GET_SNDINFO 60
|
||||
# define BIO_CTRL_DGRAM_SCTP_SET_SNDINFO 61
|
||||
# define BIO_CTRL_DGRAM_SCTP_GET_RCVINFO 62
|
||||
# define BIO_CTRL_DGRAM_SCTP_SET_RCVINFO 63
|
||||
# define BIO_CTRL_DGRAM_SCTP_GET_PRINFO 64
|
||||
# define BIO_CTRL_DGRAM_SCTP_SET_PRINFO 65
|
||||
# define BIO_CTRL_DGRAM_SCTP_SAVE_SHUTDOWN 70
|
||||
# endif
|
||||
|
||||
# define BIO_CTRL_DGRAM_SET_PEEK_MODE 71
|
||||
|
||||
/*
|
||||
* internal BIO:
|
||||
* # define BIO_CTRL_SET_KTLS_SEND 72
|
||||
* # define BIO_CTRL_SET_KTLS_SEND_CTRL_MSG 74
|
||||
* # define BIO_CTRL_CLEAR_KTLS_CTRL_MSG 75
|
||||
*/
|
||||
|
||||
# define BIO_CTRL_GET_KTLS_SEND 73
|
||||
# define BIO_CTRL_GET_KTLS_RECV 76
|
||||
|
||||
# define BIO_CTRL_DGRAM_SCTP_WAIT_FOR_DRY 77
|
||||
# define BIO_CTRL_DGRAM_SCTP_MSG_WAITING 78
|
||||
|
||||
/* BIO_f_prefix controls */
|
||||
# define BIO_CTRL_SET_PREFIX 79
|
||||
# define BIO_CTRL_SET_INDENT 80
|
||||
# define BIO_CTRL_GET_INDENT 81
|
||||
|
||||
# ifndef OPENSSL_NO_KTLS
|
||||
# define BIO_get_ktls_send(b) \
|
||||
(BIO_ctrl(b, BIO_CTRL_GET_KTLS_SEND, 0, NULL) > 0)
|
||||
# define BIO_get_ktls_recv(b) \
|
||||
(BIO_ctrl(b, BIO_CTRL_GET_KTLS_RECV, 0, NULL) > 0)
|
||||
# else
|
||||
# define BIO_get_ktls_send(b) (0)
|
||||
# define BIO_get_ktls_recv(b) (0)
|
||||
# endif
|
||||
|
||||
/* modifiers */
|
||||
# define BIO_FP_READ 0x02
|
||||
# define BIO_FP_WRITE 0x04
|
||||
# define BIO_FP_APPEND 0x08
|
||||
# define BIO_FP_TEXT 0x10
|
||||
|
||||
# define BIO_FLAGS_READ 0x01
|
||||
# define BIO_FLAGS_WRITE 0x02
|
||||
# define BIO_FLAGS_IO_SPECIAL 0x04
|
||||
# define BIO_FLAGS_RWS (BIO_FLAGS_READ|BIO_FLAGS_WRITE|BIO_FLAGS_IO_SPECIAL)
|
||||
# define BIO_FLAGS_SHOULD_RETRY 0x08
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
/* This #define was replaced by an internal constant and should not be used. */
|
||||
# define BIO_FLAGS_UPLINK 0
|
||||
# endif
|
||||
|
||||
# define BIO_FLAGS_BASE64_NO_NL 0x100
|
||||
|
||||
/*
|
||||
* This is used with memory BIOs:
|
||||
* BIO_FLAGS_MEM_RDONLY means we shouldn't free up or change the data in any way;
|
||||
* BIO_FLAGS_NONCLEAR_RST means we shouldn't clear data on reset.
|
||||
*/
|
||||
# define BIO_FLAGS_MEM_RDONLY 0x200
|
||||
# define BIO_FLAGS_NONCLEAR_RST 0x400
|
||||
# define BIO_FLAGS_IN_EOF 0x800
|
||||
|
||||
/* the BIO FLAGS values 0x1000 to 0x4000 are reserved for internal KTLS flags */
|
||||
|
||||
typedef union bio_addr_st BIO_ADDR;
|
||||
typedef struct bio_addrinfo_st BIO_ADDRINFO;
|
||||
|
||||
int BIO_get_new_index(void);
|
||||
void BIO_set_flags(BIO *b, int flags);
|
||||
int BIO_test_flags(const BIO *b, int flags);
|
||||
void BIO_clear_flags(BIO *b, int flags);
|
||||
|
||||
# define BIO_get_flags(b) BIO_test_flags(b, ~(0x0))
|
||||
# define BIO_set_retry_special(b) \
|
||||
BIO_set_flags(b, (BIO_FLAGS_IO_SPECIAL|BIO_FLAGS_SHOULD_RETRY))
|
||||
# define BIO_set_retry_read(b) \
|
||||
BIO_set_flags(b, (BIO_FLAGS_READ|BIO_FLAGS_SHOULD_RETRY))
|
||||
# define BIO_set_retry_write(b) \
|
||||
BIO_set_flags(b, (BIO_FLAGS_WRITE|BIO_FLAGS_SHOULD_RETRY))
|
||||
|
||||
/* These are normally used internally in BIOs */
|
||||
# define BIO_clear_retry_flags(b) \
|
||||
BIO_clear_flags(b, (BIO_FLAGS_RWS|BIO_FLAGS_SHOULD_RETRY))
|
||||
# define BIO_get_retry_flags(b) \
|
||||
BIO_test_flags(b, (BIO_FLAGS_RWS|BIO_FLAGS_SHOULD_RETRY))
|
||||
|
||||
/* These should be used by the application to tell why we should retry */
|
||||
# define BIO_should_read(a) BIO_test_flags(a, BIO_FLAGS_READ)
|
||||
# define BIO_should_write(a) BIO_test_flags(a, BIO_FLAGS_WRITE)
|
||||
# define BIO_should_io_special(a) BIO_test_flags(a, BIO_FLAGS_IO_SPECIAL)
|
||||
# define BIO_retry_type(a) BIO_test_flags(a, BIO_FLAGS_RWS)
|
||||
# define BIO_should_retry(a) BIO_test_flags(a, BIO_FLAGS_SHOULD_RETRY)
|
||||
|
||||
/*
|
||||
* The next three are used in conjunction with the BIO_should_io_special()
|
||||
* condition. After this returns true, BIO *BIO_get_retry_BIO(BIO *bio, int
|
||||
* *reason); will walk the BIO stack and return the 'reason' for the special
|
||||
* and the offending BIO. Given a BIO, BIO_get_retry_reason(bio) will return
|
||||
* the code.
|
||||
*/
|
||||
/*
|
||||
* Returned from the SSL bio when the certificate retrieval code had an error
|
||||
*/
|
||||
# define BIO_RR_SSL_X509_LOOKUP 0x01
|
||||
/* Returned from the connect BIO when a connect would have blocked */
|
||||
# define BIO_RR_CONNECT 0x02
|
||||
/* Returned from the accept BIO when an accept would have blocked */
|
||||
# define BIO_RR_ACCEPT 0x03
|
||||
|
||||
/* These are passed by the BIO callback */
|
||||
# define BIO_CB_FREE 0x01
|
||||
# define BIO_CB_READ 0x02
|
||||
# define BIO_CB_WRITE 0x03
|
||||
# define BIO_CB_PUTS 0x04
|
||||
# define BIO_CB_GETS 0x05
|
||||
# define BIO_CB_CTRL 0x06
|
||||
|
||||
/*
|
||||
* The callback is called before and after the underling operation, The
|
||||
* BIO_CB_RETURN flag indicates if it is after the call
|
||||
*/
|
||||
# define BIO_CB_RETURN 0x80
|
||||
# define BIO_CB_return(a) ((a)|BIO_CB_RETURN)
|
||||
# define BIO_cb_pre(a) (!((a)&BIO_CB_RETURN))
|
||||
# define BIO_cb_post(a) ((a)&BIO_CB_RETURN)
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
typedef long (*BIO_callback_fn)(BIO *b, int oper, const char *argp, int argi,
|
||||
long argl, long ret);
|
||||
OSSL_DEPRECATEDIN_3_0 BIO_callback_fn BIO_get_callback(const BIO *b);
|
||||
OSSL_DEPRECATEDIN_3_0 void BIO_set_callback(BIO *b, BIO_callback_fn callback);
|
||||
OSSL_DEPRECATEDIN_3_0 long BIO_debug_callback(BIO *bio, int cmd,
|
||||
const char *argp, int argi,
|
||||
long argl, long ret);
|
||||
# endif
|
||||
|
||||
typedef long (*BIO_callback_fn_ex)(BIO *b, int oper, const char *argp,
|
||||
size_t len, int argi,
|
||||
long argl, int ret, size_t *processed);
|
||||
BIO_callback_fn_ex BIO_get_callback_ex(const BIO *b);
|
||||
void BIO_set_callback_ex(BIO *b, BIO_callback_fn_ex callback);
|
||||
long BIO_debug_callback_ex(BIO *bio, int oper, const char *argp, size_t len,
|
||||
int argi, long argl, int ret, size_t *processed);
|
||||
|
||||
char *BIO_get_callback_arg(const BIO *b);
|
||||
void BIO_set_callback_arg(BIO *b, char *arg);
|
||||
|
||||
typedef struct bio_method_st BIO_METHOD;
|
||||
|
||||
const char *BIO_method_name(const BIO *b);
|
||||
int BIO_method_type(const BIO *b);
|
||||
|
||||
typedef int BIO_info_cb(BIO *, int, int);
|
||||
typedef BIO_info_cb bio_info_cb; /* backward compatibility */
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(BIO, BIO, BIO)
|
||||
#define sk_BIO_num(sk) OPENSSL_sk_num(ossl_check_const_BIO_sk_type(sk))
|
||||
#define sk_BIO_value(sk, idx) ((BIO *)OPENSSL_sk_value(ossl_check_const_BIO_sk_type(sk), (idx)))
|
||||
#define sk_BIO_new(cmp) ((STACK_OF(BIO) *)OPENSSL_sk_new(ossl_check_BIO_compfunc_type(cmp)))
|
||||
#define sk_BIO_new_null() ((STACK_OF(BIO) *)OPENSSL_sk_new_null())
|
||||
#define sk_BIO_new_reserve(cmp, n) ((STACK_OF(BIO) *)OPENSSL_sk_new_reserve(ossl_check_BIO_compfunc_type(cmp), (n)))
|
||||
#define sk_BIO_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_BIO_sk_type(sk), (n))
|
||||
#define sk_BIO_free(sk) OPENSSL_sk_free(ossl_check_BIO_sk_type(sk))
|
||||
#define sk_BIO_zero(sk) OPENSSL_sk_zero(ossl_check_BIO_sk_type(sk))
|
||||
#define sk_BIO_delete(sk, i) ((BIO *)OPENSSL_sk_delete(ossl_check_BIO_sk_type(sk), (i)))
|
||||
#define sk_BIO_delete_ptr(sk, ptr) ((BIO *)OPENSSL_sk_delete_ptr(ossl_check_BIO_sk_type(sk), ossl_check_BIO_type(ptr)))
|
||||
#define sk_BIO_push(sk, ptr) OPENSSL_sk_push(ossl_check_BIO_sk_type(sk), ossl_check_BIO_type(ptr))
|
||||
#define sk_BIO_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_BIO_sk_type(sk), ossl_check_BIO_type(ptr))
|
||||
#define sk_BIO_pop(sk) ((BIO *)OPENSSL_sk_pop(ossl_check_BIO_sk_type(sk)))
|
||||
#define sk_BIO_shift(sk) ((BIO *)OPENSSL_sk_shift(ossl_check_BIO_sk_type(sk)))
|
||||
#define sk_BIO_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_BIO_sk_type(sk),ossl_check_BIO_freefunc_type(freefunc))
|
||||
#define sk_BIO_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_BIO_sk_type(sk), ossl_check_BIO_type(ptr), (idx))
|
||||
#define sk_BIO_set(sk, idx, ptr) ((BIO *)OPENSSL_sk_set(ossl_check_BIO_sk_type(sk), (idx), ossl_check_BIO_type(ptr)))
|
||||
#define sk_BIO_find(sk, ptr) OPENSSL_sk_find(ossl_check_BIO_sk_type(sk), ossl_check_BIO_type(ptr))
|
||||
#define sk_BIO_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_BIO_sk_type(sk), ossl_check_BIO_type(ptr))
|
||||
#define sk_BIO_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_BIO_sk_type(sk), ossl_check_BIO_type(ptr), pnum)
|
||||
#define sk_BIO_sort(sk) OPENSSL_sk_sort(ossl_check_BIO_sk_type(sk))
|
||||
#define sk_BIO_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_BIO_sk_type(sk))
|
||||
#define sk_BIO_dup(sk) ((STACK_OF(BIO) *)OPENSSL_sk_dup(ossl_check_const_BIO_sk_type(sk)))
|
||||
#define sk_BIO_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(BIO) *)OPENSSL_sk_deep_copy(ossl_check_const_BIO_sk_type(sk), ossl_check_BIO_copyfunc_type(copyfunc), ossl_check_BIO_freefunc_type(freefunc)))
|
||||
#define sk_BIO_set_cmp_func(sk, cmp) ((sk_BIO_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_BIO_sk_type(sk), ossl_check_BIO_compfunc_type(cmp)))
|
||||
|
||||
|
||||
|
||||
/* Prefix and suffix callback in ASN1 BIO */
|
||||
typedef int asn1_ps_func (BIO *b, unsigned char **pbuf, int *plen,
|
||||
void *parg);
|
||||
|
||||
typedef void (*BIO_dgram_sctp_notification_handler_fn) (BIO *b,
|
||||
void *context,
|
||||
void *buf);
|
||||
# ifndef OPENSSL_NO_SCTP
|
||||
/* SCTP parameter structs */
|
||||
struct bio_dgram_sctp_sndinfo {
|
||||
uint16_t snd_sid;
|
||||
uint16_t snd_flags;
|
||||
uint32_t snd_ppid;
|
||||
uint32_t snd_context;
|
||||
};
|
||||
|
||||
struct bio_dgram_sctp_rcvinfo {
|
||||
uint16_t rcv_sid;
|
||||
uint16_t rcv_ssn;
|
||||
uint16_t rcv_flags;
|
||||
uint32_t rcv_ppid;
|
||||
uint32_t rcv_tsn;
|
||||
uint32_t rcv_cumtsn;
|
||||
uint32_t rcv_context;
|
||||
};
|
||||
|
||||
struct bio_dgram_sctp_prinfo {
|
||||
uint16_t pr_policy;
|
||||
uint32_t pr_value;
|
||||
};
|
||||
# endif
|
||||
|
||||
/*
|
||||
* #define BIO_CONN_get_param_hostname BIO_ctrl
|
||||
*/
|
||||
|
||||
# define BIO_C_SET_CONNECT 100
|
||||
# define BIO_C_DO_STATE_MACHINE 101
|
||||
# define BIO_C_SET_NBIO 102
|
||||
/* # define BIO_C_SET_PROXY_PARAM 103 */
|
||||
# define BIO_C_SET_FD 104
|
||||
# define BIO_C_GET_FD 105
|
||||
# define BIO_C_SET_FILE_PTR 106
|
||||
# define BIO_C_GET_FILE_PTR 107
|
||||
# define BIO_C_SET_FILENAME 108
|
||||
# define BIO_C_SET_SSL 109
|
||||
# define BIO_C_GET_SSL 110
|
||||
# define BIO_C_SET_MD 111
|
||||
# define BIO_C_GET_MD 112
|
||||
# define BIO_C_GET_CIPHER_STATUS 113
|
||||
# define BIO_C_SET_BUF_MEM 114
|
||||
# define BIO_C_GET_BUF_MEM_PTR 115
|
||||
# define BIO_C_GET_BUFF_NUM_LINES 116
|
||||
# define BIO_C_SET_BUFF_SIZE 117
|
||||
# define BIO_C_SET_ACCEPT 118
|
||||
# define BIO_C_SSL_MODE 119
|
||||
# define BIO_C_GET_MD_CTX 120
|
||||
/* # define BIO_C_GET_PROXY_PARAM 121 */
|
||||
# define BIO_C_SET_BUFF_READ_DATA 122/* data to read first */
|
||||
# define BIO_C_GET_CONNECT 123
|
||||
# define BIO_C_GET_ACCEPT 124
|
||||
# define BIO_C_SET_SSL_RENEGOTIATE_BYTES 125
|
||||
# define BIO_C_GET_SSL_NUM_RENEGOTIATES 126
|
||||
# define BIO_C_SET_SSL_RENEGOTIATE_TIMEOUT 127
|
||||
# define BIO_C_FILE_SEEK 128
|
||||
# define BIO_C_GET_CIPHER_CTX 129
|
||||
# define BIO_C_SET_BUF_MEM_EOF_RETURN 130/* return end of input
|
||||
* value */
|
||||
# define BIO_C_SET_BIND_MODE 131
|
||||
# define BIO_C_GET_BIND_MODE 132
|
||||
# define BIO_C_FILE_TELL 133
|
||||
# define BIO_C_GET_SOCKS 134
|
||||
# define BIO_C_SET_SOCKS 135
|
||||
|
||||
# define BIO_C_SET_WRITE_BUF_SIZE 136/* for BIO_s_bio */
|
||||
# define BIO_C_GET_WRITE_BUF_SIZE 137
|
||||
# define BIO_C_MAKE_BIO_PAIR 138
|
||||
# define BIO_C_DESTROY_BIO_PAIR 139
|
||||
# define BIO_C_GET_WRITE_GUARANTEE 140
|
||||
# define BIO_C_GET_READ_REQUEST 141
|
||||
# define BIO_C_SHUTDOWN_WR 142
|
||||
# define BIO_C_NREAD0 143
|
||||
# define BIO_C_NREAD 144
|
||||
# define BIO_C_NWRITE0 145
|
||||
# define BIO_C_NWRITE 146
|
||||
# define BIO_C_RESET_READ_REQUEST 147
|
||||
# define BIO_C_SET_MD_CTX 148
|
||||
|
||||
# define BIO_C_SET_PREFIX 149
|
||||
# define BIO_C_GET_PREFIX 150
|
||||
# define BIO_C_SET_SUFFIX 151
|
||||
# define BIO_C_GET_SUFFIX 152
|
||||
|
||||
# define BIO_C_SET_EX_ARG 153
|
||||
# define BIO_C_GET_EX_ARG 154
|
||||
|
||||
# define BIO_C_SET_CONNECT_MODE 155
|
||||
|
||||
# define BIO_set_app_data(s,arg) BIO_set_ex_data(s,0,arg)
|
||||
# define BIO_get_app_data(s) BIO_get_ex_data(s,0)
|
||||
|
||||
# define BIO_set_nbio(b,n) BIO_ctrl(b,BIO_C_SET_NBIO,(n),NULL)
|
||||
|
||||
# ifndef OPENSSL_NO_SOCK
|
||||
/* IP families we support, for BIO_s_connect() and BIO_s_accept() */
|
||||
/* Note: the underlying operating system may not support some of them */
|
||||
# define BIO_FAMILY_IPV4 4
|
||||
# define BIO_FAMILY_IPV6 6
|
||||
# define BIO_FAMILY_IPANY 256
|
||||
|
||||
/* BIO_s_connect() */
|
||||
# define BIO_set_conn_hostname(b,name) BIO_ctrl(b,BIO_C_SET_CONNECT,0, \
|
||||
(char *)(name))
|
||||
# define BIO_set_conn_port(b,port) BIO_ctrl(b,BIO_C_SET_CONNECT,1, \
|
||||
(char *)(port))
|
||||
# define BIO_set_conn_address(b,addr) BIO_ctrl(b,BIO_C_SET_CONNECT,2, \
|
||||
(char *)(addr))
|
||||
# define BIO_set_conn_ip_family(b,f) BIO_int_ctrl(b,BIO_C_SET_CONNECT,3,f)
|
||||
# define BIO_get_conn_hostname(b) ((const char *)BIO_ptr_ctrl(b,BIO_C_GET_CONNECT,0))
|
||||
# define BIO_get_conn_port(b) ((const char *)BIO_ptr_ctrl(b,BIO_C_GET_CONNECT,1))
|
||||
# define BIO_get_conn_address(b) ((const BIO_ADDR *)BIO_ptr_ctrl(b,BIO_C_GET_CONNECT,2))
|
||||
# define BIO_get_conn_ip_family(b) BIO_ctrl(b,BIO_C_GET_CONNECT,3,NULL)
|
||||
# define BIO_set_conn_mode(b,n) BIO_ctrl(b,BIO_C_SET_CONNECT_MODE,(n),NULL)
|
||||
|
||||
/* BIO_s_accept() */
|
||||
# define BIO_set_accept_name(b,name) BIO_ctrl(b,BIO_C_SET_ACCEPT,0, \
|
||||
(char *)(name))
|
||||
# define BIO_set_accept_port(b,port) BIO_ctrl(b,BIO_C_SET_ACCEPT,1, \
|
||||
(char *)(port))
|
||||
# define BIO_get_accept_name(b) ((const char *)BIO_ptr_ctrl(b,BIO_C_GET_ACCEPT,0))
|
||||
# define BIO_get_accept_port(b) ((const char *)BIO_ptr_ctrl(b,BIO_C_GET_ACCEPT,1))
|
||||
# define BIO_get_peer_name(b) ((const char *)BIO_ptr_ctrl(b,BIO_C_GET_ACCEPT,2))
|
||||
# define BIO_get_peer_port(b) ((const char *)BIO_ptr_ctrl(b,BIO_C_GET_ACCEPT,3))
|
||||
/* #define BIO_set_nbio(b,n) BIO_ctrl(b,BIO_C_SET_NBIO,(n),NULL) */
|
||||
# define BIO_set_nbio_accept(b,n) BIO_ctrl(b,BIO_C_SET_ACCEPT,2,(n)?(void *)"a":NULL)
|
||||
# define BIO_set_accept_bios(b,bio) BIO_ctrl(b,BIO_C_SET_ACCEPT,3, \
|
||||
(char *)(bio))
|
||||
# define BIO_set_accept_ip_family(b,f) BIO_int_ctrl(b,BIO_C_SET_ACCEPT,4,f)
|
||||
# define BIO_get_accept_ip_family(b) BIO_ctrl(b,BIO_C_GET_ACCEPT,4,NULL)
|
||||
|
||||
/* Aliases kept for backward compatibility */
|
||||
# define BIO_BIND_NORMAL 0
|
||||
# define BIO_BIND_REUSEADDR BIO_SOCK_REUSEADDR
|
||||
# define BIO_BIND_REUSEADDR_IF_UNUSED BIO_SOCK_REUSEADDR
|
||||
# define BIO_set_bind_mode(b,mode) BIO_ctrl(b,BIO_C_SET_BIND_MODE,mode,NULL)
|
||||
# define BIO_get_bind_mode(b) BIO_ctrl(b,BIO_C_GET_BIND_MODE,0,NULL)
|
||||
# endif /* OPENSSL_NO_SOCK */
|
||||
|
||||
# define BIO_do_connect(b) BIO_do_handshake(b)
|
||||
# define BIO_do_accept(b) BIO_do_handshake(b)
|
||||
|
||||
# define BIO_do_handshake(b) BIO_ctrl(b,BIO_C_DO_STATE_MACHINE,0,NULL)
|
||||
|
||||
/* BIO_s_datagram(), BIO_s_fd(), BIO_s_socket(), BIO_s_accept() and BIO_s_connect() */
|
||||
# define BIO_set_fd(b,fd,c) BIO_int_ctrl(b,BIO_C_SET_FD,c,fd)
|
||||
# define BIO_get_fd(b,c) BIO_ctrl(b,BIO_C_GET_FD,0,(char *)(c))
|
||||
|
||||
/* BIO_s_file() */
|
||||
# define BIO_set_fp(b,fp,c) BIO_ctrl(b,BIO_C_SET_FILE_PTR,c,(char *)(fp))
|
||||
# define BIO_get_fp(b,fpp) BIO_ctrl(b,BIO_C_GET_FILE_PTR,0,(char *)(fpp))
|
||||
|
||||
/* BIO_s_fd() and BIO_s_file() */
|
||||
# define BIO_seek(b,ofs) (int)BIO_ctrl(b,BIO_C_FILE_SEEK,ofs,NULL)
|
||||
# define BIO_tell(b) (int)BIO_ctrl(b,BIO_C_FILE_TELL,0,NULL)
|
||||
|
||||
/*
|
||||
* name is cast to lose const, but might be better to route through a
|
||||
* function so we can do it safely
|
||||
*/
|
||||
# ifdef CONST_STRICT
|
||||
/*
|
||||
* If you are wondering why this isn't defined, its because CONST_STRICT is
|
||||
* purely a compile-time kludge to allow const to be checked.
|
||||
*/
|
||||
int BIO_read_filename(BIO *b, const char *name);
|
||||
# else
|
||||
# define BIO_read_filename(b,name) (int)BIO_ctrl(b,BIO_C_SET_FILENAME, \
|
||||
BIO_CLOSE|BIO_FP_READ,(char *)(name))
|
||||
# endif
|
||||
# define BIO_write_filename(b,name) (int)BIO_ctrl(b,BIO_C_SET_FILENAME, \
|
||||
BIO_CLOSE|BIO_FP_WRITE,name)
|
||||
# define BIO_append_filename(b,name) (int)BIO_ctrl(b,BIO_C_SET_FILENAME, \
|
||||
BIO_CLOSE|BIO_FP_APPEND,name)
|
||||
# define BIO_rw_filename(b,name) (int)BIO_ctrl(b,BIO_C_SET_FILENAME, \
|
||||
BIO_CLOSE|BIO_FP_READ|BIO_FP_WRITE,name)
|
||||
|
||||
/*
|
||||
* WARNING WARNING, this ups the reference count on the read bio of the SSL
|
||||
* structure. This is because the ssl read BIO is now pointed to by the
|
||||
* next_bio field in the bio. So when you free the BIO, make sure you are
|
||||
* doing a BIO_free_all() to catch the underlying BIO.
|
||||
*/
|
||||
# define BIO_set_ssl(b,ssl,c) BIO_ctrl(b,BIO_C_SET_SSL,c,(char *)(ssl))
|
||||
# define BIO_get_ssl(b,sslp) BIO_ctrl(b,BIO_C_GET_SSL,0,(char *)(sslp))
|
||||
# define BIO_set_ssl_mode(b,client) BIO_ctrl(b,BIO_C_SSL_MODE,client,NULL)
|
||||
# define BIO_set_ssl_renegotiate_bytes(b,num) \
|
||||
BIO_ctrl(b,BIO_C_SET_SSL_RENEGOTIATE_BYTES,num,NULL)
|
||||
# define BIO_get_num_renegotiates(b) \
|
||||
BIO_ctrl(b,BIO_C_GET_SSL_NUM_RENEGOTIATES,0,NULL)
|
||||
# define BIO_set_ssl_renegotiate_timeout(b,seconds) \
|
||||
BIO_ctrl(b,BIO_C_SET_SSL_RENEGOTIATE_TIMEOUT,seconds,NULL)
|
||||
|
||||
/* defined in evp.h */
|
||||
/* #define BIO_set_md(b,md) BIO_ctrl(b,BIO_C_SET_MD,1,(char *)(md)) */
|
||||
|
||||
# define BIO_get_mem_data(b,pp) BIO_ctrl(b,BIO_CTRL_INFO,0,(char *)(pp))
|
||||
# define BIO_set_mem_buf(b,bm,c) BIO_ctrl(b,BIO_C_SET_BUF_MEM,c,(char *)(bm))
|
||||
# define BIO_get_mem_ptr(b,pp) BIO_ctrl(b,BIO_C_GET_BUF_MEM_PTR,0, \
|
||||
(char *)(pp))
|
||||
# define BIO_set_mem_eof_return(b,v) \
|
||||
BIO_ctrl(b,BIO_C_SET_BUF_MEM_EOF_RETURN,v,NULL)
|
||||
|
||||
/* For the BIO_f_buffer() type */
|
||||
# define BIO_get_buffer_num_lines(b) BIO_ctrl(b,BIO_C_GET_BUFF_NUM_LINES,0,NULL)
|
||||
# define BIO_set_buffer_size(b,size) BIO_ctrl(b,BIO_C_SET_BUFF_SIZE,size,NULL)
|
||||
# define BIO_set_read_buffer_size(b,size) BIO_int_ctrl(b,BIO_C_SET_BUFF_SIZE,size,0)
|
||||
# define BIO_set_write_buffer_size(b,size) BIO_int_ctrl(b,BIO_C_SET_BUFF_SIZE,size,1)
|
||||
# define BIO_set_buffer_read_data(b,buf,num) BIO_ctrl(b,BIO_C_SET_BUFF_READ_DATA,num,buf)
|
||||
|
||||
/* Don't use the next one unless you know what you are doing :-) */
|
||||
# define BIO_dup_state(b,ret) BIO_ctrl(b,BIO_CTRL_DUP,0,(char *)(ret))
|
||||
|
||||
# define BIO_reset(b) (int)BIO_ctrl(b,BIO_CTRL_RESET,0,NULL)
|
||||
# define BIO_eof(b) (int)BIO_ctrl(b,BIO_CTRL_EOF,0,NULL)
|
||||
# define BIO_set_close(b,c) (int)BIO_ctrl(b,BIO_CTRL_SET_CLOSE,(c),NULL)
|
||||
# define BIO_get_close(b) (int)BIO_ctrl(b,BIO_CTRL_GET_CLOSE,0,NULL)
|
||||
# define BIO_pending(b) (int)BIO_ctrl(b,BIO_CTRL_PENDING,0,NULL)
|
||||
# define BIO_wpending(b) (int)BIO_ctrl(b,BIO_CTRL_WPENDING,0,NULL)
|
||||
/* ...pending macros have inappropriate return type */
|
||||
size_t BIO_ctrl_pending(BIO *b);
|
||||
size_t BIO_ctrl_wpending(BIO *b);
|
||||
# define BIO_flush(b) (int)BIO_ctrl(b,BIO_CTRL_FLUSH,0,NULL)
|
||||
# define BIO_get_info_callback(b,cbp) (int)BIO_ctrl(b,BIO_CTRL_GET_CALLBACK,0, \
|
||||
cbp)
|
||||
# define BIO_set_info_callback(b,cb) (int)BIO_callback_ctrl(b,BIO_CTRL_SET_CALLBACK,cb)
|
||||
|
||||
/* For the BIO_f_buffer() type */
|
||||
# define BIO_buffer_get_num_lines(b) BIO_ctrl(b,BIO_CTRL_GET,0,NULL)
|
||||
# define BIO_buffer_peek(b,s,l) BIO_ctrl(b,BIO_CTRL_PEEK,(l),(s))
|
||||
|
||||
/* For BIO_s_bio() */
|
||||
# define BIO_set_write_buf_size(b,size) (int)BIO_ctrl(b,BIO_C_SET_WRITE_BUF_SIZE,size,NULL)
|
||||
# define BIO_get_write_buf_size(b,size) (size_t)BIO_ctrl(b,BIO_C_GET_WRITE_BUF_SIZE,size,NULL)
|
||||
# define BIO_make_bio_pair(b1,b2) (int)BIO_ctrl(b1,BIO_C_MAKE_BIO_PAIR,0,b2)
|
||||
# define BIO_destroy_bio_pair(b) (int)BIO_ctrl(b,BIO_C_DESTROY_BIO_PAIR,0,NULL)
|
||||
# define BIO_shutdown_wr(b) (int)BIO_ctrl(b, BIO_C_SHUTDOWN_WR, 0, NULL)
|
||||
/* macros with inappropriate type -- but ...pending macros use int too: */
|
||||
# define BIO_get_write_guarantee(b) (int)BIO_ctrl(b,BIO_C_GET_WRITE_GUARANTEE,0,NULL)
|
||||
# define BIO_get_read_request(b) (int)BIO_ctrl(b,BIO_C_GET_READ_REQUEST,0,NULL)
|
||||
size_t BIO_ctrl_get_write_guarantee(BIO *b);
|
||||
size_t BIO_ctrl_get_read_request(BIO *b);
|
||||
int BIO_ctrl_reset_read_request(BIO *b);
|
||||
|
||||
/* ctrl macros for dgram */
|
||||
# define BIO_ctrl_dgram_connect(b,peer) \
|
||||
(int)BIO_ctrl(b,BIO_CTRL_DGRAM_CONNECT,0, (char *)(peer))
|
||||
# define BIO_ctrl_set_connected(b,peer) \
|
||||
(int)BIO_ctrl(b, BIO_CTRL_DGRAM_SET_CONNECTED, 0, (char *)(peer))
|
||||
# define BIO_dgram_recv_timedout(b) \
|
||||
(int)BIO_ctrl(b, BIO_CTRL_DGRAM_GET_RECV_TIMER_EXP, 0, NULL)
|
||||
# define BIO_dgram_send_timedout(b) \
|
||||
(int)BIO_ctrl(b, BIO_CTRL_DGRAM_GET_SEND_TIMER_EXP, 0, NULL)
|
||||
# define BIO_dgram_get_peer(b,peer) \
|
||||
(int)BIO_ctrl(b, BIO_CTRL_DGRAM_GET_PEER, 0, (char *)(peer))
|
||||
# define BIO_dgram_set_peer(b,peer) \
|
||||
(int)BIO_ctrl(b, BIO_CTRL_DGRAM_SET_PEER, 0, (char *)(peer))
|
||||
# define BIO_dgram_get_mtu_overhead(b) \
|
||||
(unsigned int)BIO_ctrl((b), BIO_CTRL_DGRAM_GET_MTU_OVERHEAD, 0, NULL)
|
||||
|
||||
/* ctrl macros for BIO_f_prefix */
|
||||
# define BIO_set_prefix(b,p) BIO_ctrl((b), BIO_CTRL_SET_PREFIX, 0, (void *)(p))
|
||||
# define BIO_set_indent(b,i) BIO_ctrl((b), BIO_CTRL_SET_INDENT, (i), NULL)
|
||||
# define BIO_get_indent(b) BIO_ctrl((b), BIO_CTRL_GET_INDENT, 0, NULL)
|
||||
|
||||
#define BIO_get_ex_new_index(l, p, newf, dupf, freef) \
|
||||
CRYPTO_get_ex_new_index(CRYPTO_EX_INDEX_BIO, l, p, newf, dupf, freef)
|
||||
int BIO_set_ex_data(BIO *bio, int idx, void *data);
|
||||
void *BIO_get_ex_data(const BIO *bio, int idx);
|
||||
uint64_t BIO_number_read(BIO *bio);
|
||||
uint64_t BIO_number_written(BIO *bio);
|
||||
|
||||
/* For BIO_f_asn1() */
|
||||
int BIO_asn1_set_prefix(BIO *b, asn1_ps_func *prefix,
|
||||
asn1_ps_func *prefix_free);
|
||||
int BIO_asn1_get_prefix(BIO *b, asn1_ps_func **pprefix,
|
||||
asn1_ps_func **pprefix_free);
|
||||
int BIO_asn1_set_suffix(BIO *b, asn1_ps_func *suffix,
|
||||
asn1_ps_func *suffix_free);
|
||||
int BIO_asn1_get_suffix(BIO *b, asn1_ps_func **psuffix,
|
||||
asn1_ps_func **psuffix_free);
|
||||
|
||||
const BIO_METHOD *BIO_s_file(void);
|
||||
BIO *BIO_new_file(const char *filename, const char *mode);
|
||||
BIO *BIO_new_from_core_bio(OSSL_LIB_CTX *libctx, OSSL_CORE_BIO *corebio);
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
BIO *BIO_new_fp(FILE *stream, int close_flag);
|
||||
# endif
|
||||
BIO *BIO_new_ex(OSSL_LIB_CTX *libctx, const BIO_METHOD *method);
|
||||
BIO *BIO_new(const BIO_METHOD *type);
|
||||
int BIO_free(BIO *a);
|
||||
void BIO_set_data(BIO *a, void *ptr);
|
||||
void *BIO_get_data(BIO *a);
|
||||
void BIO_set_init(BIO *a, int init);
|
||||
int BIO_get_init(BIO *a);
|
||||
void BIO_set_shutdown(BIO *a, int shut);
|
||||
int BIO_get_shutdown(BIO *a);
|
||||
void BIO_vfree(BIO *a);
|
||||
int BIO_up_ref(BIO *a);
|
||||
int BIO_read(BIO *b, void *data, int dlen);
|
||||
int BIO_read_ex(BIO *b, void *data, size_t dlen, size_t *readbytes);
|
||||
int BIO_gets(BIO *bp, char *buf, int size);
|
||||
int BIO_get_line(BIO *bio, char *buf, int size);
|
||||
int BIO_write(BIO *b, const void *data, int dlen);
|
||||
int BIO_write_ex(BIO *b, const void *data, size_t dlen, size_t *written);
|
||||
int BIO_puts(BIO *bp, const char *buf);
|
||||
int BIO_indent(BIO *b, int indent, int max);
|
||||
long BIO_ctrl(BIO *bp, int cmd, long larg, void *parg);
|
||||
long BIO_callback_ctrl(BIO *b, int cmd, BIO_info_cb *fp);
|
||||
void *BIO_ptr_ctrl(BIO *bp, int cmd, long larg);
|
||||
long BIO_int_ctrl(BIO *bp, int cmd, long larg, int iarg);
|
||||
BIO *BIO_push(BIO *b, BIO *append);
|
||||
BIO *BIO_pop(BIO *b);
|
||||
void BIO_free_all(BIO *a);
|
||||
BIO *BIO_find_type(BIO *b, int bio_type);
|
||||
BIO *BIO_next(BIO *b);
|
||||
void BIO_set_next(BIO *b, BIO *next);
|
||||
BIO *BIO_get_retry_BIO(BIO *bio, int *reason);
|
||||
int BIO_get_retry_reason(BIO *bio);
|
||||
void BIO_set_retry_reason(BIO *bio, int reason);
|
||||
BIO *BIO_dup_chain(BIO *in);
|
||||
|
||||
int BIO_nread0(BIO *bio, char **buf);
|
||||
int BIO_nread(BIO *bio, char **buf, int num);
|
||||
int BIO_nwrite0(BIO *bio, char **buf);
|
||||
int BIO_nwrite(BIO *bio, char **buf, int num);
|
||||
|
||||
const BIO_METHOD *BIO_s_mem(void);
|
||||
const BIO_METHOD *BIO_s_secmem(void);
|
||||
BIO *BIO_new_mem_buf(const void *buf, int len);
|
||||
# ifndef OPENSSL_NO_SOCK
|
||||
const BIO_METHOD *BIO_s_socket(void);
|
||||
const BIO_METHOD *BIO_s_connect(void);
|
||||
const BIO_METHOD *BIO_s_accept(void);
|
||||
# endif
|
||||
const BIO_METHOD *BIO_s_fd(void);
|
||||
const BIO_METHOD *BIO_s_log(void);
|
||||
const BIO_METHOD *BIO_s_bio(void);
|
||||
const BIO_METHOD *BIO_s_null(void);
|
||||
const BIO_METHOD *BIO_f_null(void);
|
||||
const BIO_METHOD *BIO_f_buffer(void);
|
||||
const BIO_METHOD *BIO_f_readbuffer(void);
|
||||
const BIO_METHOD *BIO_f_linebuffer(void);
|
||||
const BIO_METHOD *BIO_f_nbio_test(void);
|
||||
const BIO_METHOD *BIO_f_prefix(void);
|
||||
const BIO_METHOD *BIO_s_core(void);
|
||||
# ifndef OPENSSL_NO_DGRAM
|
||||
const BIO_METHOD *BIO_s_datagram(void);
|
||||
int BIO_dgram_non_fatal_error(int error);
|
||||
BIO *BIO_new_dgram(int fd, int close_flag);
|
||||
# ifndef OPENSSL_NO_SCTP
|
||||
const BIO_METHOD *BIO_s_datagram_sctp(void);
|
||||
BIO *BIO_new_dgram_sctp(int fd, int close_flag);
|
||||
int BIO_dgram_is_sctp(BIO *bio);
|
||||
int BIO_dgram_sctp_notification_cb(BIO *b,
|
||||
BIO_dgram_sctp_notification_handler_fn handle_notifications,
|
||||
void *context);
|
||||
int BIO_dgram_sctp_wait_for_dry(BIO *b);
|
||||
int BIO_dgram_sctp_msg_waiting(BIO *b);
|
||||
# endif
|
||||
# endif
|
||||
|
||||
# ifndef OPENSSL_NO_SOCK
|
||||
int BIO_sock_should_retry(int i);
|
||||
int BIO_sock_non_fatal_error(int error);
|
||||
int BIO_socket_wait(int fd, int for_read, time_t max_time);
|
||||
# endif
|
||||
int BIO_wait(BIO *bio, time_t max_time, unsigned int nap_milliseconds);
|
||||
int BIO_do_connect_retry(BIO *bio, int timeout, int nap_milliseconds);
|
||||
|
||||
int BIO_fd_should_retry(int i);
|
||||
int BIO_fd_non_fatal_error(int error);
|
||||
int BIO_dump_cb(int (*cb) (const void *data, size_t len, void *u),
|
||||
void *u, const void *s, int len);
|
||||
int BIO_dump_indent_cb(int (*cb) (const void *data, size_t len, void *u),
|
||||
void *u, const void *s, int len, int indent);
|
||||
int BIO_dump(BIO *b, const void *bytes, int len);
|
||||
int BIO_dump_indent(BIO *b, const void *bytes, int len, int indent);
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
int BIO_dump_fp(FILE *fp, const void *s, int len);
|
||||
int BIO_dump_indent_fp(FILE *fp, const void *s, int len, int indent);
|
||||
# endif
|
||||
int BIO_hex_string(BIO *out, int indent, int width, const void *data,
|
||||
int datalen);
|
||||
|
||||
# ifndef OPENSSL_NO_SOCK
|
||||
BIO_ADDR *BIO_ADDR_new(void);
|
||||
int BIO_ADDR_rawmake(BIO_ADDR *ap, int family,
|
||||
const void *where, size_t wherelen, unsigned short port);
|
||||
void BIO_ADDR_free(BIO_ADDR *);
|
||||
void BIO_ADDR_clear(BIO_ADDR *ap);
|
||||
int BIO_ADDR_family(const BIO_ADDR *ap);
|
||||
int BIO_ADDR_rawaddress(const BIO_ADDR *ap, void *p, size_t *l);
|
||||
unsigned short BIO_ADDR_rawport(const BIO_ADDR *ap);
|
||||
char *BIO_ADDR_hostname_string(const BIO_ADDR *ap, int numeric);
|
||||
char *BIO_ADDR_service_string(const BIO_ADDR *ap, int numeric);
|
||||
char *BIO_ADDR_path_string(const BIO_ADDR *ap);
|
||||
|
||||
const BIO_ADDRINFO *BIO_ADDRINFO_next(const BIO_ADDRINFO *bai);
|
||||
int BIO_ADDRINFO_family(const BIO_ADDRINFO *bai);
|
||||
int BIO_ADDRINFO_socktype(const BIO_ADDRINFO *bai);
|
||||
int BIO_ADDRINFO_protocol(const BIO_ADDRINFO *bai);
|
||||
const BIO_ADDR *BIO_ADDRINFO_address(const BIO_ADDRINFO *bai);
|
||||
void BIO_ADDRINFO_free(BIO_ADDRINFO *bai);
|
||||
|
||||
enum BIO_hostserv_priorities {
|
||||
BIO_PARSE_PRIO_HOST, BIO_PARSE_PRIO_SERV
|
||||
};
|
||||
int BIO_parse_hostserv(const char *hostserv, char **host, char **service,
|
||||
enum BIO_hostserv_priorities hostserv_prio);
|
||||
enum BIO_lookup_type {
|
||||
BIO_LOOKUP_CLIENT, BIO_LOOKUP_SERVER
|
||||
};
|
||||
int BIO_lookup(const char *host, const char *service,
|
||||
enum BIO_lookup_type lookup_type,
|
||||
int family, int socktype, BIO_ADDRINFO **res);
|
||||
int BIO_lookup_ex(const char *host, const char *service,
|
||||
int lookup_type, int family, int socktype, int protocol,
|
||||
BIO_ADDRINFO **res);
|
||||
int BIO_sock_error(int sock);
|
||||
int BIO_socket_ioctl(int fd, long type, void *arg);
|
||||
int BIO_socket_nbio(int fd, int mode);
|
||||
int BIO_sock_init(void);
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# define BIO_sock_cleanup() while(0) continue
|
||||
# endif
|
||||
int BIO_set_tcp_ndelay(int sock, int turn_on);
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
OSSL_DEPRECATEDIN_1_1_0 struct hostent *BIO_gethostbyname(const char *name);
|
||||
OSSL_DEPRECATEDIN_1_1_0 int BIO_get_port(const char *str, unsigned short *port_ptr);
|
||||
OSSL_DEPRECATEDIN_1_1_0 int BIO_get_host_ip(const char *str, unsigned char *ip);
|
||||
OSSL_DEPRECATEDIN_1_1_0 int BIO_get_accept_socket(char *host_port, int mode);
|
||||
OSSL_DEPRECATEDIN_1_1_0 int BIO_accept(int sock, char **ip_port);
|
||||
# endif
|
||||
|
||||
union BIO_sock_info_u {
|
||||
BIO_ADDR *addr;
|
||||
};
|
||||
enum BIO_sock_info_type {
|
||||
BIO_SOCK_INFO_ADDRESS
|
||||
};
|
||||
int BIO_sock_info(int sock,
|
||||
enum BIO_sock_info_type type, union BIO_sock_info_u *info);
|
||||
|
||||
# define BIO_SOCK_REUSEADDR 0x01
|
||||
# define BIO_SOCK_V6_ONLY 0x02
|
||||
# define BIO_SOCK_KEEPALIVE 0x04
|
||||
# define BIO_SOCK_NONBLOCK 0x08
|
||||
# define BIO_SOCK_NODELAY 0x10
|
||||
|
||||
int BIO_socket(int domain, int socktype, int protocol, int options);
|
||||
int BIO_connect(int sock, const BIO_ADDR *addr, int options);
|
||||
int BIO_bind(int sock, const BIO_ADDR *addr, int options);
|
||||
int BIO_listen(int sock, const BIO_ADDR *addr, int options);
|
||||
int BIO_accept_ex(int accept_sock, BIO_ADDR *addr, int options);
|
||||
int BIO_closesocket(int sock);
|
||||
|
||||
BIO *BIO_new_socket(int sock, int close_flag);
|
||||
BIO *BIO_new_connect(const char *host_port);
|
||||
BIO *BIO_new_accept(const char *host_port);
|
||||
# endif /* OPENSSL_NO_SOCK*/
|
||||
|
||||
BIO *BIO_new_fd(int fd, int close_flag);
|
||||
|
||||
int BIO_new_bio_pair(BIO **bio1, size_t writebuf1,
|
||||
BIO **bio2, size_t writebuf2);
|
||||
/*
|
||||
* If successful, returns 1 and in *bio1, *bio2 two BIO pair endpoints.
|
||||
* Otherwise returns 0 and sets *bio1 and *bio2 to NULL. Size 0 uses default
|
||||
* value.
|
||||
*/
|
||||
|
||||
void BIO_copy_next_retry(BIO *b);
|
||||
|
||||
/*
|
||||
* long BIO_ghbn_ctrl(int cmd,int iarg,char *parg);
|
||||
*/
|
||||
|
||||
# define ossl_bio__attr__(x)
|
||||
# if defined(__GNUC__) && defined(__STDC_VERSION__) \
|
||||
&& !defined(__MINGW32__) && !defined(__MINGW64__) \
|
||||
&& !defined(__APPLE__)
|
||||
/*
|
||||
* Because we support the 'z' modifier, which made its appearance in C99,
|
||||
* we can't use __attribute__ with pre C99 dialects.
|
||||
*/
|
||||
# if __STDC_VERSION__ >= 199901L
|
||||
# undef ossl_bio__attr__
|
||||
# define ossl_bio__attr__ __attribute__
|
||||
# if __GNUC__*10 + __GNUC_MINOR__ >= 44
|
||||
# define ossl_bio__printf__ __gnu_printf__
|
||||
# else
|
||||
# define ossl_bio__printf__ __printf__
|
||||
# endif
|
||||
# endif
|
||||
# endif
|
||||
int BIO_printf(BIO *bio, const char *format, ...)
|
||||
ossl_bio__attr__((__format__(ossl_bio__printf__, 2, 3)));
|
||||
int BIO_vprintf(BIO *bio, const char *format, va_list args)
|
||||
ossl_bio__attr__((__format__(ossl_bio__printf__, 2, 0)));
|
||||
int BIO_snprintf(char *buf, size_t n, const char *format, ...)
|
||||
ossl_bio__attr__((__format__(ossl_bio__printf__, 3, 4)));
|
||||
int BIO_vsnprintf(char *buf, size_t n, const char *format, va_list args)
|
||||
ossl_bio__attr__((__format__(ossl_bio__printf__, 3, 0)));
|
||||
# undef ossl_bio__attr__
|
||||
# undef ossl_bio__printf__
|
||||
|
||||
|
||||
BIO_METHOD *BIO_meth_new(int type, const char *name);
|
||||
void BIO_meth_free(BIO_METHOD *biom);
|
||||
int (*BIO_meth_get_write(const BIO_METHOD *biom)) (BIO *, const char *, int);
|
||||
int (*BIO_meth_get_write_ex(const BIO_METHOD *biom)) (BIO *, const char *, size_t,
|
||||
size_t *);
|
||||
int BIO_meth_set_write(BIO_METHOD *biom,
|
||||
int (*write) (BIO *, const char *, int));
|
||||
int BIO_meth_set_write_ex(BIO_METHOD *biom,
|
||||
int (*bwrite) (BIO *, const char *, size_t, size_t *));
|
||||
int (*BIO_meth_get_read(const BIO_METHOD *biom)) (BIO *, char *, int);
|
||||
int (*BIO_meth_get_read_ex(const BIO_METHOD *biom)) (BIO *, char *, size_t, size_t *);
|
||||
int BIO_meth_set_read(BIO_METHOD *biom,
|
||||
int (*read) (BIO *, char *, int));
|
||||
int BIO_meth_set_read_ex(BIO_METHOD *biom,
|
||||
int (*bread) (BIO *, char *, size_t, size_t *));
|
||||
int (*BIO_meth_get_puts(const BIO_METHOD *biom)) (BIO *, const char *);
|
||||
int BIO_meth_set_puts(BIO_METHOD *biom,
|
||||
int (*puts) (BIO *, const char *));
|
||||
int (*BIO_meth_get_gets(const BIO_METHOD *biom)) (BIO *, char *, int);
|
||||
int BIO_meth_set_gets(BIO_METHOD *biom,
|
||||
int (*ossl_gets) (BIO *, char *, int));
|
||||
long (*BIO_meth_get_ctrl(const BIO_METHOD *biom)) (BIO *, int, long, void *);
|
||||
int BIO_meth_set_ctrl(BIO_METHOD *biom,
|
||||
long (*ctrl) (BIO *, int, long, void *));
|
||||
int (*BIO_meth_get_create(const BIO_METHOD *bion)) (BIO *);
|
||||
int BIO_meth_set_create(BIO_METHOD *biom, int (*create) (BIO *));
|
||||
int (*BIO_meth_get_destroy(const BIO_METHOD *biom)) (BIO *);
|
||||
int BIO_meth_set_destroy(BIO_METHOD *biom, int (*destroy) (BIO *));
|
||||
long (*BIO_meth_get_callback_ctrl(const BIO_METHOD *biom))
|
||||
(BIO *, int, BIO_info_cb *);
|
||||
int BIO_meth_set_callback_ctrl(BIO_METHOD *biom,
|
||||
long (*callback_ctrl) (BIO *, int,
|
||||
BIO_info_cb *));
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
597
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/cmp.h
generated
vendored
Normal file
597
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/cmp.h
generated
vendored
Normal file
@@ -0,0 +1,597 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/cmp.h.in
|
||||
*
|
||||
* Copyright 2007-2023 The OpenSSL Project Authors. All Rights Reserved.
|
||||
* Copyright Nokia 2007-2019
|
||||
* Copyright Siemens AG 2015-2019
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_CMP_H
|
||||
# define OPENSSL_CMP_H
|
||||
|
||||
# include <openssl/opensslconf.h>
|
||||
# ifndef OPENSSL_NO_CMP
|
||||
|
||||
# include <openssl/crmf.h>
|
||||
# include <openssl/cmperr.h>
|
||||
# include <openssl/cmp_util.h>
|
||||
# include <openssl/http.h>
|
||||
|
||||
/* explicit #includes not strictly needed since implied by the above: */
|
||||
# include <openssl/types.h>
|
||||
# include <openssl/safestack.h>
|
||||
# include <openssl/x509.h>
|
||||
# include <openssl/x509v3.h>
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
# define OSSL_CMP_PVNO 2
|
||||
|
||||
/*-
|
||||
* PKIFailureInfo ::= BIT STRING {
|
||||
* -- since we can fail in more than one way!
|
||||
* -- More codes may be added in the future if/when required.
|
||||
* badAlg (0),
|
||||
* -- unrecognized or unsupported Algorithm Identifier
|
||||
* badMessageCheck (1),
|
||||
* -- integrity check failed (e.g., signature did not verify)
|
||||
* badRequest (2),
|
||||
* -- transaction not permitted or supported
|
||||
* badTime (3),
|
||||
* -- messageTime was not sufficiently close to the system time,
|
||||
* -- as defined by local policy
|
||||
* badCertId (4),
|
||||
* -- no certificate could be found matching the provided criteria
|
||||
* badDataFormat (5),
|
||||
* -- the data submitted has the wrong format
|
||||
* wrongAuthority (6),
|
||||
* -- the authority indicated in the request is different from the
|
||||
* -- one creating the response token
|
||||
* incorrectData (7),
|
||||
* -- the requester's data is incorrect (for notary services)
|
||||
* missingTimeStamp (8),
|
||||
* -- when the timestamp is missing but should be there
|
||||
* -- (by policy)
|
||||
* badPOP (9),
|
||||
* -- the proof-of-possession failed
|
||||
* certRevoked (10),
|
||||
* -- the certificate has already been revoked
|
||||
* certConfirmed (11),
|
||||
* -- the certificate has already been confirmed
|
||||
* wrongIntegrity (12),
|
||||
* -- invalid integrity, password based instead of signature or
|
||||
* -- vice versa
|
||||
* badRecipientNonce (13),
|
||||
* -- invalid recipient nonce, either missing or wrong value
|
||||
* timeNotAvailable (14),
|
||||
* -- the TSA's time source is not available
|
||||
* unacceptedPolicy (15),
|
||||
* -- the requested TSA policy is not supported by the TSA.
|
||||
* unacceptedExtension (16),
|
||||
* -- the requested extension is not supported by the TSA.
|
||||
* addInfoNotAvailable (17),
|
||||
* -- the additional information requested could not be
|
||||
* -- understood or is not available
|
||||
* badSenderNonce (18),
|
||||
* -- invalid sender nonce, either missing or wrong size
|
||||
* badCertTemplate (19),
|
||||
* -- invalid cert. template or missing mandatory information
|
||||
* signerNotTrusted (20),
|
||||
* -- signer of the message unknown or not trusted
|
||||
* transactionIdInUse (21),
|
||||
* -- the transaction identifier is already in use
|
||||
* unsupportedVersion (22),
|
||||
* -- the version of the message is not supported
|
||||
* notAuthorized (23),
|
||||
* -- the sender was not authorized to make the preceding
|
||||
* -- request or perform the preceding action
|
||||
* systemUnavail (24),
|
||||
* -- the request cannot be handled due to system unavailability
|
||||
* systemFailure (25),
|
||||
* -- the request cannot be handled due to system failure
|
||||
* duplicateCertReq (26)
|
||||
* -- certificate cannot be issued because a duplicate
|
||||
* -- certificate already exists
|
||||
* }
|
||||
*/
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badAlg 0
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badMessageCheck 1
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badRequest 2
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badTime 3
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badCertId 4
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badDataFormat 5
|
||||
# define OSSL_CMP_PKIFAILUREINFO_wrongAuthority 6
|
||||
# define OSSL_CMP_PKIFAILUREINFO_incorrectData 7
|
||||
# define OSSL_CMP_PKIFAILUREINFO_missingTimeStamp 8
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badPOP 9
|
||||
# define OSSL_CMP_PKIFAILUREINFO_certRevoked 10
|
||||
# define OSSL_CMP_PKIFAILUREINFO_certConfirmed 11
|
||||
# define OSSL_CMP_PKIFAILUREINFO_wrongIntegrity 12
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badRecipientNonce 13
|
||||
# define OSSL_CMP_PKIFAILUREINFO_timeNotAvailable 14
|
||||
# define OSSL_CMP_PKIFAILUREINFO_unacceptedPolicy 15
|
||||
# define OSSL_CMP_PKIFAILUREINFO_unacceptedExtension 16
|
||||
# define OSSL_CMP_PKIFAILUREINFO_addInfoNotAvailable 17
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badSenderNonce 18
|
||||
# define OSSL_CMP_PKIFAILUREINFO_badCertTemplate 19
|
||||
# define OSSL_CMP_PKIFAILUREINFO_signerNotTrusted 20
|
||||
# define OSSL_CMP_PKIFAILUREINFO_transactionIdInUse 21
|
||||
# define OSSL_CMP_PKIFAILUREINFO_unsupportedVersion 22
|
||||
# define OSSL_CMP_PKIFAILUREINFO_notAuthorized 23
|
||||
# define OSSL_CMP_PKIFAILUREINFO_systemUnavail 24
|
||||
# define OSSL_CMP_PKIFAILUREINFO_systemFailure 25
|
||||
# define OSSL_CMP_PKIFAILUREINFO_duplicateCertReq 26
|
||||
# define OSSL_CMP_PKIFAILUREINFO_MAX 26
|
||||
# define OSSL_CMP_PKIFAILUREINFO_MAX_BIT_PATTERN \
|
||||
((1 << (OSSL_CMP_PKIFAILUREINFO_MAX + 1)) - 1)
|
||||
# if OSSL_CMP_PKIFAILUREINFO_MAX_BIT_PATTERN > INT_MAX
|
||||
# error CMP_PKIFAILUREINFO_MAX bit pattern does not fit in type int
|
||||
# endif
|
||||
|
||||
typedef ASN1_BIT_STRING OSSL_CMP_PKIFAILUREINFO;
|
||||
|
||||
# define OSSL_CMP_CTX_FAILINFO_badAlg (1 << 0)
|
||||
# define OSSL_CMP_CTX_FAILINFO_badMessageCheck (1 << 1)
|
||||
# define OSSL_CMP_CTX_FAILINFO_badRequest (1 << 2)
|
||||
# define OSSL_CMP_CTX_FAILINFO_badTime (1 << 3)
|
||||
# define OSSL_CMP_CTX_FAILINFO_badCertId (1 << 4)
|
||||
# define OSSL_CMP_CTX_FAILINFO_badDataFormat (1 << 5)
|
||||
# define OSSL_CMP_CTX_FAILINFO_wrongAuthority (1 << 6)
|
||||
# define OSSL_CMP_CTX_FAILINFO_incorrectData (1 << 7)
|
||||
# define OSSL_CMP_CTX_FAILINFO_missingTimeStamp (1 << 8)
|
||||
# define OSSL_CMP_CTX_FAILINFO_badPOP (1 << 9)
|
||||
# define OSSL_CMP_CTX_FAILINFO_certRevoked (1 << 10)
|
||||
# define OSSL_CMP_CTX_FAILINFO_certConfirmed (1 << 11)
|
||||
# define OSSL_CMP_CTX_FAILINFO_wrongIntegrity (1 << 12)
|
||||
# define OSSL_CMP_CTX_FAILINFO_badRecipientNonce (1 << 13)
|
||||
# define OSSL_CMP_CTX_FAILINFO_timeNotAvailable (1 << 14)
|
||||
# define OSSL_CMP_CTX_FAILINFO_unacceptedPolicy (1 << 15)
|
||||
# define OSSL_CMP_CTX_FAILINFO_unacceptedExtension (1 << 16)
|
||||
# define OSSL_CMP_CTX_FAILINFO_addInfoNotAvailable (1 << 17)
|
||||
# define OSSL_CMP_CTX_FAILINFO_badSenderNonce (1 << 18)
|
||||
# define OSSL_CMP_CTX_FAILINFO_badCertTemplate (1 << 19)
|
||||
# define OSSL_CMP_CTX_FAILINFO_signerNotTrusted (1 << 20)
|
||||
# define OSSL_CMP_CTX_FAILINFO_transactionIdInUse (1 << 21)
|
||||
# define OSSL_CMP_CTX_FAILINFO_unsupportedVersion (1 << 22)
|
||||
# define OSSL_CMP_CTX_FAILINFO_notAuthorized (1 << 23)
|
||||
# define OSSL_CMP_CTX_FAILINFO_systemUnavail (1 << 24)
|
||||
# define OSSL_CMP_CTX_FAILINFO_systemFailure (1 << 25)
|
||||
# define OSSL_CMP_CTX_FAILINFO_duplicateCertReq (1 << 26)
|
||||
|
||||
/*-
|
||||
* PKIStatus ::= INTEGER {
|
||||
* accepted (0),
|
||||
* -- you got exactly what you asked for
|
||||
* grantedWithMods (1),
|
||||
* -- you got something like what you asked for; the
|
||||
* -- requester is responsible for ascertaining the differences
|
||||
* rejection (2),
|
||||
* -- you don't get it, more information elsewhere in the message
|
||||
* waiting (3),
|
||||
* -- the request body part has not yet been processed; expect to
|
||||
* -- hear more later (note: proper handling of this status
|
||||
* -- response MAY use the polling req/rep PKIMessages specified
|
||||
* -- in Section 5.3.22; alternatively, polling in the underlying
|
||||
* -- transport layer MAY have some utility in this regard)
|
||||
* revocationWarning (4),
|
||||
* -- this message contains a warning that a revocation is
|
||||
* -- imminent
|
||||
* revocationNotification (5),
|
||||
* -- notification that a revocation has occurred
|
||||
* keyUpdateWarning (6)
|
||||
* -- update already done for the oldCertId specified in
|
||||
* -- CertReqMsg
|
||||
* }
|
||||
*/
|
||||
# define OSSL_CMP_PKISTATUS_request -3
|
||||
# define OSSL_CMP_PKISTATUS_trans -2
|
||||
# define OSSL_CMP_PKISTATUS_unspecified -1
|
||||
# define OSSL_CMP_PKISTATUS_accepted 0
|
||||
# define OSSL_CMP_PKISTATUS_grantedWithMods 1
|
||||
# define OSSL_CMP_PKISTATUS_rejection 2
|
||||
# define OSSL_CMP_PKISTATUS_waiting 3
|
||||
# define OSSL_CMP_PKISTATUS_revocationWarning 4
|
||||
# define OSSL_CMP_PKISTATUS_revocationNotification 5
|
||||
# define OSSL_CMP_PKISTATUS_keyUpdateWarning 6
|
||||
|
||||
typedef ASN1_INTEGER OSSL_CMP_PKISTATUS;
|
||||
DECLARE_ASN1_ITEM(OSSL_CMP_PKISTATUS)
|
||||
|
||||
# define OSSL_CMP_CERTORENCCERT_CERTIFICATE 0
|
||||
# define OSSL_CMP_CERTORENCCERT_ENCRYPTEDCERT 1
|
||||
|
||||
/* data type declarations */
|
||||
typedef struct ossl_cmp_ctx_st OSSL_CMP_CTX;
|
||||
typedef struct ossl_cmp_pkiheader_st OSSL_CMP_PKIHEADER;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CMP_PKIHEADER)
|
||||
typedef struct ossl_cmp_msg_st OSSL_CMP_MSG;
|
||||
DECLARE_ASN1_DUP_FUNCTION(OSSL_CMP_MSG)
|
||||
DECLARE_ASN1_ENCODE_FUNCTIONS(OSSL_CMP_MSG, OSSL_CMP_MSG, OSSL_CMP_MSG)
|
||||
typedef struct ossl_cmp_certstatus_st OSSL_CMP_CERTSTATUS;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OSSL_CMP_CERTSTATUS, OSSL_CMP_CERTSTATUS, OSSL_CMP_CERTSTATUS)
|
||||
#define sk_OSSL_CMP_CERTSTATUS_num(sk) OPENSSL_sk_num(ossl_check_const_OSSL_CMP_CERTSTATUS_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_value(sk, idx) ((OSSL_CMP_CERTSTATUS *)OPENSSL_sk_value(ossl_check_const_OSSL_CMP_CERTSTATUS_sk_type(sk), (idx)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_new(cmp) ((STACK_OF(OSSL_CMP_CERTSTATUS) *)OPENSSL_sk_new(ossl_check_OSSL_CMP_CERTSTATUS_compfunc_type(cmp)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_new_null() ((STACK_OF(OSSL_CMP_CERTSTATUS) *)OPENSSL_sk_new_null())
|
||||
#define sk_OSSL_CMP_CERTSTATUS_new_reserve(cmp, n) ((STACK_OF(OSSL_CMP_CERTSTATUS) *)OPENSSL_sk_new_reserve(ossl_check_OSSL_CMP_CERTSTATUS_compfunc_type(cmp), (n)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), (n))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_free(sk) OPENSSL_sk_free(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_zero(sk) OPENSSL_sk_zero(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_delete(sk, i) ((OSSL_CMP_CERTSTATUS *)OPENSSL_sk_delete(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), (i)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_delete_ptr(sk, ptr) ((OSSL_CMP_CERTSTATUS *)OPENSSL_sk_delete_ptr(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), ossl_check_OSSL_CMP_CERTSTATUS_type(ptr)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_push(sk, ptr) OPENSSL_sk_push(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), ossl_check_OSSL_CMP_CERTSTATUS_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), ossl_check_OSSL_CMP_CERTSTATUS_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_pop(sk) ((OSSL_CMP_CERTSTATUS *)OPENSSL_sk_pop(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_shift(sk) ((OSSL_CMP_CERTSTATUS *)OPENSSL_sk_shift(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk),ossl_check_OSSL_CMP_CERTSTATUS_freefunc_type(freefunc))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), ossl_check_OSSL_CMP_CERTSTATUS_type(ptr), (idx))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_set(sk, idx, ptr) ((OSSL_CMP_CERTSTATUS *)OPENSSL_sk_set(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), (idx), ossl_check_OSSL_CMP_CERTSTATUS_type(ptr)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_find(sk, ptr) OPENSSL_sk_find(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), ossl_check_OSSL_CMP_CERTSTATUS_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), ossl_check_OSSL_CMP_CERTSTATUS_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), ossl_check_OSSL_CMP_CERTSTATUS_type(ptr), pnum)
|
||||
#define sk_OSSL_CMP_CERTSTATUS_sort(sk) OPENSSL_sk_sort(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OSSL_CMP_CERTSTATUS_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_dup(sk) ((STACK_OF(OSSL_CMP_CERTSTATUS) *)OPENSSL_sk_dup(ossl_check_const_OSSL_CMP_CERTSTATUS_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OSSL_CMP_CERTSTATUS) *)OPENSSL_sk_deep_copy(ossl_check_const_OSSL_CMP_CERTSTATUS_sk_type(sk), ossl_check_OSSL_CMP_CERTSTATUS_copyfunc_type(copyfunc), ossl_check_OSSL_CMP_CERTSTATUS_freefunc_type(freefunc)))
|
||||
#define sk_OSSL_CMP_CERTSTATUS_set_cmp_func(sk, cmp) ((sk_OSSL_CMP_CERTSTATUS_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OSSL_CMP_CERTSTATUS_sk_type(sk), ossl_check_OSSL_CMP_CERTSTATUS_compfunc_type(cmp)))
|
||||
|
||||
typedef struct ossl_cmp_itav_st OSSL_CMP_ITAV;
|
||||
DECLARE_ASN1_DUP_FUNCTION(OSSL_CMP_ITAV)
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OSSL_CMP_ITAV, OSSL_CMP_ITAV, OSSL_CMP_ITAV)
|
||||
#define sk_OSSL_CMP_ITAV_num(sk) OPENSSL_sk_num(ossl_check_const_OSSL_CMP_ITAV_sk_type(sk))
|
||||
#define sk_OSSL_CMP_ITAV_value(sk, idx) ((OSSL_CMP_ITAV *)OPENSSL_sk_value(ossl_check_const_OSSL_CMP_ITAV_sk_type(sk), (idx)))
|
||||
#define sk_OSSL_CMP_ITAV_new(cmp) ((STACK_OF(OSSL_CMP_ITAV) *)OPENSSL_sk_new(ossl_check_OSSL_CMP_ITAV_compfunc_type(cmp)))
|
||||
#define sk_OSSL_CMP_ITAV_new_null() ((STACK_OF(OSSL_CMP_ITAV) *)OPENSSL_sk_new_null())
|
||||
#define sk_OSSL_CMP_ITAV_new_reserve(cmp, n) ((STACK_OF(OSSL_CMP_ITAV) *)OPENSSL_sk_new_reserve(ossl_check_OSSL_CMP_ITAV_compfunc_type(cmp), (n)))
|
||||
#define sk_OSSL_CMP_ITAV_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OSSL_CMP_ITAV_sk_type(sk), (n))
|
||||
#define sk_OSSL_CMP_ITAV_free(sk) OPENSSL_sk_free(ossl_check_OSSL_CMP_ITAV_sk_type(sk))
|
||||
#define sk_OSSL_CMP_ITAV_zero(sk) OPENSSL_sk_zero(ossl_check_OSSL_CMP_ITAV_sk_type(sk))
|
||||
#define sk_OSSL_CMP_ITAV_delete(sk, i) ((OSSL_CMP_ITAV *)OPENSSL_sk_delete(ossl_check_OSSL_CMP_ITAV_sk_type(sk), (i)))
|
||||
#define sk_OSSL_CMP_ITAV_delete_ptr(sk, ptr) ((OSSL_CMP_ITAV *)OPENSSL_sk_delete_ptr(ossl_check_OSSL_CMP_ITAV_sk_type(sk), ossl_check_OSSL_CMP_ITAV_type(ptr)))
|
||||
#define sk_OSSL_CMP_ITAV_push(sk, ptr) OPENSSL_sk_push(ossl_check_OSSL_CMP_ITAV_sk_type(sk), ossl_check_OSSL_CMP_ITAV_type(ptr))
|
||||
#define sk_OSSL_CMP_ITAV_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OSSL_CMP_ITAV_sk_type(sk), ossl_check_OSSL_CMP_ITAV_type(ptr))
|
||||
#define sk_OSSL_CMP_ITAV_pop(sk) ((OSSL_CMP_ITAV *)OPENSSL_sk_pop(ossl_check_OSSL_CMP_ITAV_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_ITAV_shift(sk) ((OSSL_CMP_ITAV *)OPENSSL_sk_shift(ossl_check_OSSL_CMP_ITAV_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_ITAV_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OSSL_CMP_ITAV_sk_type(sk),ossl_check_OSSL_CMP_ITAV_freefunc_type(freefunc))
|
||||
#define sk_OSSL_CMP_ITAV_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OSSL_CMP_ITAV_sk_type(sk), ossl_check_OSSL_CMP_ITAV_type(ptr), (idx))
|
||||
#define sk_OSSL_CMP_ITAV_set(sk, idx, ptr) ((OSSL_CMP_ITAV *)OPENSSL_sk_set(ossl_check_OSSL_CMP_ITAV_sk_type(sk), (idx), ossl_check_OSSL_CMP_ITAV_type(ptr)))
|
||||
#define sk_OSSL_CMP_ITAV_find(sk, ptr) OPENSSL_sk_find(ossl_check_OSSL_CMP_ITAV_sk_type(sk), ossl_check_OSSL_CMP_ITAV_type(ptr))
|
||||
#define sk_OSSL_CMP_ITAV_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OSSL_CMP_ITAV_sk_type(sk), ossl_check_OSSL_CMP_ITAV_type(ptr))
|
||||
#define sk_OSSL_CMP_ITAV_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OSSL_CMP_ITAV_sk_type(sk), ossl_check_OSSL_CMP_ITAV_type(ptr), pnum)
|
||||
#define sk_OSSL_CMP_ITAV_sort(sk) OPENSSL_sk_sort(ossl_check_OSSL_CMP_ITAV_sk_type(sk))
|
||||
#define sk_OSSL_CMP_ITAV_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OSSL_CMP_ITAV_sk_type(sk))
|
||||
#define sk_OSSL_CMP_ITAV_dup(sk) ((STACK_OF(OSSL_CMP_ITAV) *)OPENSSL_sk_dup(ossl_check_const_OSSL_CMP_ITAV_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_ITAV_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OSSL_CMP_ITAV) *)OPENSSL_sk_deep_copy(ossl_check_const_OSSL_CMP_ITAV_sk_type(sk), ossl_check_OSSL_CMP_ITAV_copyfunc_type(copyfunc), ossl_check_OSSL_CMP_ITAV_freefunc_type(freefunc)))
|
||||
#define sk_OSSL_CMP_ITAV_set_cmp_func(sk, cmp) ((sk_OSSL_CMP_ITAV_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OSSL_CMP_ITAV_sk_type(sk), ossl_check_OSSL_CMP_ITAV_compfunc_type(cmp)))
|
||||
|
||||
typedef struct ossl_cmp_revrepcontent_st OSSL_CMP_REVREPCONTENT;
|
||||
typedef struct ossl_cmp_pkisi_st OSSL_CMP_PKISI;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CMP_PKISI)
|
||||
DECLARE_ASN1_DUP_FUNCTION(OSSL_CMP_PKISI)
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OSSL_CMP_PKISI, OSSL_CMP_PKISI, OSSL_CMP_PKISI)
|
||||
#define sk_OSSL_CMP_PKISI_num(sk) OPENSSL_sk_num(ossl_check_const_OSSL_CMP_PKISI_sk_type(sk))
|
||||
#define sk_OSSL_CMP_PKISI_value(sk, idx) ((OSSL_CMP_PKISI *)OPENSSL_sk_value(ossl_check_const_OSSL_CMP_PKISI_sk_type(sk), (idx)))
|
||||
#define sk_OSSL_CMP_PKISI_new(cmp) ((STACK_OF(OSSL_CMP_PKISI) *)OPENSSL_sk_new(ossl_check_OSSL_CMP_PKISI_compfunc_type(cmp)))
|
||||
#define sk_OSSL_CMP_PKISI_new_null() ((STACK_OF(OSSL_CMP_PKISI) *)OPENSSL_sk_new_null())
|
||||
#define sk_OSSL_CMP_PKISI_new_reserve(cmp, n) ((STACK_OF(OSSL_CMP_PKISI) *)OPENSSL_sk_new_reserve(ossl_check_OSSL_CMP_PKISI_compfunc_type(cmp), (n)))
|
||||
#define sk_OSSL_CMP_PKISI_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OSSL_CMP_PKISI_sk_type(sk), (n))
|
||||
#define sk_OSSL_CMP_PKISI_free(sk) OPENSSL_sk_free(ossl_check_OSSL_CMP_PKISI_sk_type(sk))
|
||||
#define sk_OSSL_CMP_PKISI_zero(sk) OPENSSL_sk_zero(ossl_check_OSSL_CMP_PKISI_sk_type(sk))
|
||||
#define sk_OSSL_CMP_PKISI_delete(sk, i) ((OSSL_CMP_PKISI *)OPENSSL_sk_delete(ossl_check_OSSL_CMP_PKISI_sk_type(sk), (i)))
|
||||
#define sk_OSSL_CMP_PKISI_delete_ptr(sk, ptr) ((OSSL_CMP_PKISI *)OPENSSL_sk_delete_ptr(ossl_check_OSSL_CMP_PKISI_sk_type(sk), ossl_check_OSSL_CMP_PKISI_type(ptr)))
|
||||
#define sk_OSSL_CMP_PKISI_push(sk, ptr) OPENSSL_sk_push(ossl_check_OSSL_CMP_PKISI_sk_type(sk), ossl_check_OSSL_CMP_PKISI_type(ptr))
|
||||
#define sk_OSSL_CMP_PKISI_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OSSL_CMP_PKISI_sk_type(sk), ossl_check_OSSL_CMP_PKISI_type(ptr))
|
||||
#define sk_OSSL_CMP_PKISI_pop(sk) ((OSSL_CMP_PKISI *)OPENSSL_sk_pop(ossl_check_OSSL_CMP_PKISI_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_PKISI_shift(sk) ((OSSL_CMP_PKISI *)OPENSSL_sk_shift(ossl_check_OSSL_CMP_PKISI_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_PKISI_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OSSL_CMP_PKISI_sk_type(sk),ossl_check_OSSL_CMP_PKISI_freefunc_type(freefunc))
|
||||
#define sk_OSSL_CMP_PKISI_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OSSL_CMP_PKISI_sk_type(sk), ossl_check_OSSL_CMP_PKISI_type(ptr), (idx))
|
||||
#define sk_OSSL_CMP_PKISI_set(sk, idx, ptr) ((OSSL_CMP_PKISI *)OPENSSL_sk_set(ossl_check_OSSL_CMP_PKISI_sk_type(sk), (idx), ossl_check_OSSL_CMP_PKISI_type(ptr)))
|
||||
#define sk_OSSL_CMP_PKISI_find(sk, ptr) OPENSSL_sk_find(ossl_check_OSSL_CMP_PKISI_sk_type(sk), ossl_check_OSSL_CMP_PKISI_type(ptr))
|
||||
#define sk_OSSL_CMP_PKISI_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OSSL_CMP_PKISI_sk_type(sk), ossl_check_OSSL_CMP_PKISI_type(ptr))
|
||||
#define sk_OSSL_CMP_PKISI_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OSSL_CMP_PKISI_sk_type(sk), ossl_check_OSSL_CMP_PKISI_type(ptr), pnum)
|
||||
#define sk_OSSL_CMP_PKISI_sort(sk) OPENSSL_sk_sort(ossl_check_OSSL_CMP_PKISI_sk_type(sk))
|
||||
#define sk_OSSL_CMP_PKISI_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OSSL_CMP_PKISI_sk_type(sk))
|
||||
#define sk_OSSL_CMP_PKISI_dup(sk) ((STACK_OF(OSSL_CMP_PKISI) *)OPENSSL_sk_dup(ossl_check_const_OSSL_CMP_PKISI_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_PKISI_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OSSL_CMP_PKISI) *)OPENSSL_sk_deep_copy(ossl_check_const_OSSL_CMP_PKISI_sk_type(sk), ossl_check_OSSL_CMP_PKISI_copyfunc_type(copyfunc), ossl_check_OSSL_CMP_PKISI_freefunc_type(freefunc)))
|
||||
#define sk_OSSL_CMP_PKISI_set_cmp_func(sk, cmp) ((sk_OSSL_CMP_PKISI_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OSSL_CMP_PKISI_sk_type(sk), ossl_check_OSSL_CMP_PKISI_compfunc_type(cmp)))
|
||||
|
||||
typedef struct ossl_cmp_certrepmessage_st OSSL_CMP_CERTREPMESSAGE;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OSSL_CMP_CERTREPMESSAGE, OSSL_CMP_CERTREPMESSAGE, OSSL_CMP_CERTREPMESSAGE)
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_num(sk) OPENSSL_sk_num(ossl_check_const_OSSL_CMP_CERTREPMESSAGE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_value(sk, idx) ((OSSL_CMP_CERTREPMESSAGE *)OPENSSL_sk_value(ossl_check_const_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), (idx)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_new(cmp) ((STACK_OF(OSSL_CMP_CERTREPMESSAGE) *)OPENSSL_sk_new(ossl_check_OSSL_CMP_CERTREPMESSAGE_compfunc_type(cmp)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_new_null() ((STACK_OF(OSSL_CMP_CERTREPMESSAGE) *)OPENSSL_sk_new_null())
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_new_reserve(cmp, n) ((STACK_OF(OSSL_CMP_CERTREPMESSAGE) *)OPENSSL_sk_new_reserve(ossl_check_OSSL_CMP_CERTREPMESSAGE_compfunc_type(cmp), (n)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), (n))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_free(sk) OPENSSL_sk_free(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_zero(sk) OPENSSL_sk_zero(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_delete(sk, i) ((OSSL_CMP_CERTREPMESSAGE *)OPENSSL_sk_delete(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), (i)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_delete_ptr(sk, ptr) ((OSSL_CMP_CERTREPMESSAGE *)OPENSSL_sk_delete_ptr(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), ossl_check_OSSL_CMP_CERTREPMESSAGE_type(ptr)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_push(sk, ptr) OPENSSL_sk_push(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), ossl_check_OSSL_CMP_CERTREPMESSAGE_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), ossl_check_OSSL_CMP_CERTREPMESSAGE_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_pop(sk) ((OSSL_CMP_CERTREPMESSAGE *)OPENSSL_sk_pop(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_shift(sk) ((OSSL_CMP_CERTREPMESSAGE *)OPENSSL_sk_shift(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk),ossl_check_OSSL_CMP_CERTREPMESSAGE_freefunc_type(freefunc))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), ossl_check_OSSL_CMP_CERTREPMESSAGE_type(ptr), (idx))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_set(sk, idx, ptr) ((OSSL_CMP_CERTREPMESSAGE *)OPENSSL_sk_set(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), (idx), ossl_check_OSSL_CMP_CERTREPMESSAGE_type(ptr)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_find(sk, ptr) OPENSSL_sk_find(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), ossl_check_OSSL_CMP_CERTREPMESSAGE_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), ossl_check_OSSL_CMP_CERTREPMESSAGE_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), ossl_check_OSSL_CMP_CERTREPMESSAGE_type(ptr), pnum)
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_sort(sk) OPENSSL_sk_sort(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OSSL_CMP_CERTREPMESSAGE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_dup(sk) ((STACK_OF(OSSL_CMP_CERTREPMESSAGE) *)OPENSSL_sk_dup(ossl_check_const_OSSL_CMP_CERTREPMESSAGE_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OSSL_CMP_CERTREPMESSAGE) *)OPENSSL_sk_deep_copy(ossl_check_const_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), ossl_check_OSSL_CMP_CERTREPMESSAGE_copyfunc_type(copyfunc), ossl_check_OSSL_CMP_CERTREPMESSAGE_freefunc_type(freefunc)))
|
||||
#define sk_OSSL_CMP_CERTREPMESSAGE_set_cmp_func(sk, cmp) ((sk_OSSL_CMP_CERTREPMESSAGE_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OSSL_CMP_CERTREPMESSAGE_sk_type(sk), ossl_check_OSSL_CMP_CERTREPMESSAGE_compfunc_type(cmp)))
|
||||
|
||||
typedef struct ossl_cmp_pollrep_st OSSL_CMP_POLLREP;
|
||||
typedef STACK_OF(OSSL_CMP_POLLREP) OSSL_CMP_POLLREPCONTENT;
|
||||
typedef struct ossl_cmp_certresponse_st OSSL_CMP_CERTRESPONSE;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OSSL_CMP_CERTRESPONSE, OSSL_CMP_CERTRESPONSE, OSSL_CMP_CERTRESPONSE)
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_num(sk) OPENSSL_sk_num(ossl_check_const_OSSL_CMP_CERTRESPONSE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_value(sk, idx) ((OSSL_CMP_CERTRESPONSE *)OPENSSL_sk_value(ossl_check_const_OSSL_CMP_CERTRESPONSE_sk_type(sk), (idx)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_new(cmp) ((STACK_OF(OSSL_CMP_CERTRESPONSE) *)OPENSSL_sk_new(ossl_check_OSSL_CMP_CERTRESPONSE_compfunc_type(cmp)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_new_null() ((STACK_OF(OSSL_CMP_CERTRESPONSE) *)OPENSSL_sk_new_null())
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_new_reserve(cmp, n) ((STACK_OF(OSSL_CMP_CERTRESPONSE) *)OPENSSL_sk_new_reserve(ossl_check_OSSL_CMP_CERTRESPONSE_compfunc_type(cmp), (n)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), (n))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_free(sk) OPENSSL_sk_free(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_zero(sk) OPENSSL_sk_zero(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_delete(sk, i) ((OSSL_CMP_CERTRESPONSE *)OPENSSL_sk_delete(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), (i)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_delete_ptr(sk, ptr) ((OSSL_CMP_CERTRESPONSE *)OPENSSL_sk_delete_ptr(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), ossl_check_OSSL_CMP_CERTRESPONSE_type(ptr)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_push(sk, ptr) OPENSSL_sk_push(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), ossl_check_OSSL_CMP_CERTRESPONSE_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), ossl_check_OSSL_CMP_CERTRESPONSE_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_pop(sk) ((OSSL_CMP_CERTRESPONSE *)OPENSSL_sk_pop(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_shift(sk) ((OSSL_CMP_CERTRESPONSE *)OPENSSL_sk_shift(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk),ossl_check_OSSL_CMP_CERTRESPONSE_freefunc_type(freefunc))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), ossl_check_OSSL_CMP_CERTRESPONSE_type(ptr), (idx))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_set(sk, idx, ptr) ((OSSL_CMP_CERTRESPONSE *)OPENSSL_sk_set(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), (idx), ossl_check_OSSL_CMP_CERTRESPONSE_type(ptr)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_find(sk, ptr) OPENSSL_sk_find(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), ossl_check_OSSL_CMP_CERTRESPONSE_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), ossl_check_OSSL_CMP_CERTRESPONSE_type(ptr))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), ossl_check_OSSL_CMP_CERTRESPONSE_type(ptr), pnum)
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_sort(sk) OPENSSL_sk_sort(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OSSL_CMP_CERTRESPONSE_sk_type(sk))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_dup(sk) ((STACK_OF(OSSL_CMP_CERTRESPONSE) *)OPENSSL_sk_dup(ossl_check_const_OSSL_CMP_CERTRESPONSE_sk_type(sk)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OSSL_CMP_CERTRESPONSE) *)OPENSSL_sk_deep_copy(ossl_check_const_OSSL_CMP_CERTRESPONSE_sk_type(sk), ossl_check_OSSL_CMP_CERTRESPONSE_copyfunc_type(copyfunc), ossl_check_OSSL_CMP_CERTRESPONSE_freefunc_type(freefunc)))
|
||||
#define sk_OSSL_CMP_CERTRESPONSE_set_cmp_func(sk, cmp) ((sk_OSSL_CMP_CERTRESPONSE_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OSSL_CMP_CERTRESPONSE_sk_type(sk), ossl_check_OSSL_CMP_CERTRESPONSE_compfunc_type(cmp)))
|
||||
|
||||
typedef STACK_OF(ASN1_UTF8STRING) OSSL_CMP_PKIFREETEXT;
|
||||
|
||||
/*
|
||||
* function DECLARATIONS
|
||||
*/
|
||||
|
||||
/* from cmp_asn.c */
|
||||
OSSL_CMP_ITAV *OSSL_CMP_ITAV_create(ASN1_OBJECT *type, ASN1_TYPE *value);
|
||||
void OSSL_CMP_ITAV_set0(OSSL_CMP_ITAV *itav, ASN1_OBJECT *type,
|
||||
ASN1_TYPE *value);
|
||||
ASN1_OBJECT *OSSL_CMP_ITAV_get0_type(const OSSL_CMP_ITAV *itav);
|
||||
ASN1_TYPE *OSSL_CMP_ITAV_get0_value(const OSSL_CMP_ITAV *itav);
|
||||
int OSSL_CMP_ITAV_push0_stack_item(STACK_OF(OSSL_CMP_ITAV) **itav_sk_p,
|
||||
OSSL_CMP_ITAV *itav);
|
||||
void OSSL_CMP_ITAV_free(OSSL_CMP_ITAV *itav);
|
||||
void OSSL_CMP_MSG_free(OSSL_CMP_MSG *msg);
|
||||
|
||||
/* from cmp_ctx.c */
|
||||
OSSL_CMP_CTX *OSSL_CMP_CTX_new(OSSL_LIB_CTX *libctx, const char *propq);
|
||||
void OSSL_CMP_CTX_free(OSSL_CMP_CTX *ctx);
|
||||
int OSSL_CMP_CTX_reinit(OSSL_CMP_CTX *ctx);
|
||||
/* CMP general options: */
|
||||
# define OSSL_CMP_OPT_LOG_VERBOSITY 0
|
||||
/* CMP transfer options: */
|
||||
# define OSSL_CMP_OPT_KEEP_ALIVE 10
|
||||
# define OSSL_CMP_OPT_MSG_TIMEOUT 11
|
||||
# define OSSL_CMP_OPT_TOTAL_TIMEOUT 12
|
||||
/* CMP request options: */
|
||||
# define OSSL_CMP_OPT_VALIDITY_DAYS 20
|
||||
# define OSSL_CMP_OPT_SUBJECTALTNAME_NODEFAULT 21
|
||||
# define OSSL_CMP_OPT_SUBJECTALTNAME_CRITICAL 22
|
||||
# define OSSL_CMP_OPT_POLICIES_CRITICAL 23
|
||||
# define OSSL_CMP_OPT_POPO_METHOD 24
|
||||
# define OSSL_CMP_OPT_IMPLICIT_CONFIRM 25
|
||||
# define OSSL_CMP_OPT_DISABLE_CONFIRM 26
|
||||
# define OSSL_CMP_OPT_REVOCATION_REASON 27
|
||||
/* CMP protection options: */
|
||||
# define OSSL_CMP_OPT_UNPROTECTED_SEND 30
|
||||
# define OSSL_CMP_OPT_UNPROTECTED_ERRORS 31
|
||||
# define OSSL_CMP_OPT_OWF_ALGNID 32
|
||||
# define OSSL_CMP_OPT_MAC_ALGNID 33
|
||||
# define OSSL_CMP_OPT_DIGEST_ALGNID 34
|
||||
# define OSSL_CMP_OPT_IGNORE_KEYUSAGE 35
|
||||
# define OSSL_CMP_OPT_PERMIT_TA_IN_EXTRACERTS_FOR_IR 36
|
||||
int OSSL_CMP_CTX_set_option(OSSL_CMP_CTX *ctx, int opt, int val);
|
||||
int OSSL_CMP_CTX_get_option(const OSSL_CMP_CTX *ctx, int opt);
|
||||
/* CMP-specific callback for logging and outputting the error queue: */
|
||||
int OSSL_CMP_CTX_set_log_cb(OSSL_CMP_CTX *ctx, OSSL_CMP_log_cb_t cb);
|
||||
# define OSSL_CMP_CTX_set_log_verbosity(ctx, level) \
|
||||
OSSL_CMP_CTX_set_option(ctx, OSSL_CMP_OPT_LOG_VERBOSITY, level)
|
||||
void OSSL_CMP_CTX_print_errors(const OSSL_CMP_CTX *ctx);
|
||||
/* message transfer: */
|
||||
int OSSL_CMP_CTX_set1_serverPath(OSSL_CMP_CTX *ctx, const char *path);
|
||||
int OSSL_CMP_CTX_set1_server(OSSL_CMP_CTX *ctx, const char *address);
|
||||
int OSSL_CMP_CTX_set_serverPort(OSSL_CMP_CTX *ctx, int port);
|
||||
int OSSL_CMP_CTX_set1_proxy(OSSL_CMP_CTX *ctx, const char *name);
|
||||
int OSSL_CMP_CTX_set1_no_proxy(OSSL_CMP_CTX *ctx, const char *names);
|
||||
int OSSL_CMP_CTX_set_http_cb(OSSL_CMP_CTX *ctx, OSSL_HTTP_bio_cb_t cb);
|
||||
int OSSL_CMP_CTX_set_http_cb_arg(OSSL_CMP_CTX *ctx, void *arg);
|
||||
void *OSSL_CMP_CTX_get_http_cb_arg(const OSSL_CMP_CTX *ctx);
|
||||
typedef OSSL_CMP_MSG *(*OSSL_CMP_transfer_cb_t) (OSSL_CMP_CTX *ctx,
|
||||
const OSSL_CMP_MSG *req);
|
||||
int OSSL_CMP_CTX_set_transfer_cb(OSSL_CMP_CTX *ctx, OSSL_CMP_transfer_cb_t cb);
|
||||
int OSSL_CMP_CTX_set_transfer_cb_arg(OSSL_CMP_CTX *ctx, void *arg);
|
||||
void *OSSL_CMP_CTX_get_transfer_cb_arg(const OSSL_CMP_CTX *ctx);
|
||||
/* server authentication: */
|
||||
int OSSL_CMP_CTX_set1_srvCert(OSSL_CMP_CTX *ctx, X509 *cert);
|
||||
int OSSL_CMP_CTX_set1_expected_sender(OSSL_CMP_CTX *ctx, const X509_NAME *name);
|
||||
int OSSL_CMP_CTX_set0_trustedStore(OSSL_CMP_CTX *ctx, X509_STORE *store);
|
||||
X509_STORE *OSSL_CMP_CTX_get0_trustedStore(const OSSL_CMP_CTX *ctx);
|
||||
int OSSL_CMP_CTX_set1_untrusted(OSSL_CMP_CTX *ctx, STACK_OF(X509) *certs);
|
||||
STACK_OF(X509) *OSSL_CMP_CTX_get0_untrusted(const OSSL_CMP_CTX *ctx);
|
||||
/* client authentication: */
|
||||
int OSSL_CMP_CTX_set1_cert(OSSL_CMP_CTX *ctx, X509 *cert);
|
||||
int OSSL_CMP_CTX_build_cert_chain(OSSL_CMP_CTX *ctx, X509_STORE *own_trusted,
|
||||
STACK_OF(X509) *candidates);
|
||||
int OSSL_CMP_CTX_set1_pkey(OSSL_CMP_CTX *ctx, EVP_PKEY *pkey);
|
||||
int OSSL_CMP_CTX_set1_referenceValue(OSSL_CMP_CTX *ctx,
|
||||
const unsigned char *ref, int len);
|
||||
int OSSL_CMP_CTX_set1_secretValue(OSSL_CMP_CTX *ctx,
|
||||
const unsigned char *sec, int len);
|
||||
/* CMP message header and extra certificates: */
|
||||
int OSSL_CMP_CTX_set1_recipient(OSSL_CMP_CTX *ctx, const X509_NAME *name);
|
||||
int OSSL_CMP_CTX_push0_geninfo_ITAV(OSSL_CMP_CTX *ctx, OSSL_CMP_ITAV *itav);
|
||||
int OSSL_CMP_CTX_reset_geninfo_ITAVs(OSSL_CMP_CTX *ctx);
|
||||
int OSSL_CMP_CTX_set1_extraCertsOut(OSSL_CMP_CTX *ctx,
|
||||
STACK_OF(X509) *extraCertsOut);
|
||||
/* certificate template: */
|
||||
int OSSL_CMP_CTX_set0_newPkey(OSSL_CMP_CTX *ctx, int priv, EVP_PKEY *pkey);
|
||||
EVP_PKEY *OSSL_CMP_CTX_get0_newPkey(const OSSL_CMP_CTX *ctx, int priv);
|
||||
int OSSL_CMP_CTX_set1_issuer(OSSL_CMP_CTX *ctx, const X509_NAME *name);
|
||||
int OSSL_CMP_CTX_set1_subjectName(OSSL_CMP_CTX *ctx, const X509_NAME *name);
|
||||
int OSSL_CMP_CTX_push1_subjectAltName(OSSL_CMP_CTX *ctx,
|
||||
const GENERAL_NAME *name);
|
||||
int OSSL_CMP_CTX_set0_reqExtensions(OSSL_CMP_CTX *ctx, X509_EXTENSIONS *exts);
|
||||
int OSSL_CMP_CTX_reqExtensions_have_SAN(OSSL_CMP_CTX *ctx);
|
||||
int OSSL_CMP_CTX_push0_policy(OSSL_CMP_CTX *ctx, POLICYINFO *pinfo);
|
||||
int OSSL_CMP_CTX_set1_oldCert(OSSL_CMP_CTX *ctx, X509 *cert);
|
||||
int OSSL_CMP_CTX_set1_p10CSR(OSSL_CMP_CTX *ctx, const X509_REQ *csr);
|
||||
/* misc body contents: */
|
||||
int OSSL_CMP_CTX_push0_genm_ITAV(OSSL_CMP_CTX *ctx, OSSL_CMP_ITAV *itav);
|
||||
/* certificate confirmation: */
|
||||
typedef int (*OSSL_CMP_certConf_cb_t) (OSSL_CMP_CTX *ctx, X509 *cert,
|
||||
int fail_info, const char **txt);
|
||||
int OSSL_CMP_certConf_cb(OSSL_CMP_CTX *ctx, X509 *cert, int fail_info,
|
||||
const char **text);
|
||||
int OSSL_CMP_CTX_set_certConf_cb(OSSL_CMP_CTX *ctx, OSSL_CMP_certConf_cb_t cb);
|
||||
int OSSL_CMP_CTX_set_certConf_cb_arg(OSSL_CMP_CTX *ctx, void *arg);
|
||||
void *OSSL_CMP_CTX_get_certConf_cb_arg(const OSSL_CMP_CTX *ctx);
|
||||
/* result fetching: */
|
||||
int OSSL_CMP_CTX_get_status(const OSSL_CMP_CTX *ctx);
|
||||
OSSL_CMP_PKIFREETEXT *OSSL_CMP_CTX_get0_statusString(const OSSL_CMP_CTX *ctx);
|
||||
int OSSL_CMP_CTX_get_failInfoCode(const OSSL_CMP_CTX *ctx);
|
||||
# define OSSL_CMP_PKISI_BUFLEN 1024
|
||||
X509 *OSSL_CMP_CTX_get0_newCert(const OSSL_CMP_CTX *ctx);
|
||||
STACK_OF(X509) *OSSL_CMP_CTX_get1_newChain(const OSSL_CMP_CTX *ctx);
|
||||
STACK_OF(X509) *OSSL_CMP_CTX_get1_caPubs(const OSSL_CMP_CTX *ctx);
|
||||
STACK_OF(X509) *OSSL_CMP_CTX_get1_extraCertsIn(const OSSL_CMP_CTX *ctx);
|
||||
int OSSL_CMP_CTX_set1_transactionID(OSSL_CMP_CTX *ctx,
|
||||
const ASN1_OCTET_STRING *id);
|
||||
int OSSL_CMP_CTX_set1_senderNonce(OSSL_CMP_CTX *ctx,
|
||||
const ASN1_OCTET_STRING *nonce);
|
||||
|
||||
/* from cmp_status.c */
|
||||
char *OSSL_CMP_CTX_snprint_PKIStatus(const OSSL_CMP_CTX *ctx, char *buf,
|
||||
size_t bufsize);
|
||||
char *OSSL_CMP_snprint_PKIStatusInfo(const OSSL_CMP_PKISI *statusInfo,
|
||||
char *buf, size_t bufsize);
|
||||
OSSL_CMP_PKISI *
|
||||
OSSL_CMP_STATUSINFO_new(int status, int fail_info, const char *text);
|
||||
|
||||
/* from cmp_hdr.c */
|
||||
ASN1_OCTET_STRING *OSSL_CMP_HDR_get0_transactionID(const
|
||||
OSSL_CMP_PKIHEADER *hdr);
|
||||
ASN1_OCTET_STRING *OSSL_CMP_HDR_get0_recipNonce(const OSSL_CMP_PKIHEADER *hdr);
|
||||
|
||||
/* from cmp_msg.c */
|
||||
OSSL_CMP_PKIHEADER *OSSL_CMP_MSG_get0_header(const OSSL_CMP_MSG *msg);
|
||||
int OSSL_CMP_MSG_get_bodytype(const OSSL_CMP_MSG *msg);
|
||||
int OSSL_CMP_MSG_update_transactionID(OSSL_CMP_CTX *ctx, OSSL_CMP_MSG *msg);
|
||||
int OSSL_CMP_MSG_update_recipNonce(OSSL_CMP_CTX *ctx, OSSL_CMP_MSG *msg);
|
||||
OSSL_CRMF_MSG *OSSL_CMP_CTX_setup_CRM(OSSL_CMP_CTX *ctx, int for_KUR, int rid);
|
||||
OSSL_CMP_MSG *OSSL_CMP_MSG_read(const char *file, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
int OSSL_CMP_MSG_write(const char *file, const OSSL_CMP_MSG *msg);
|
||||
OSSL_CMP_MSG *d2i_OSSL_CMP_MSG_bio(BIO *bio, OSSL_CMP_MSG **msg);
|
||||
int i2d_OSSL_CMP_MSG_bio(BIO *bio, const OSSL_CMP_MSG *msg);
|
||||
|
||||
/* from cmp_vfy.c */
|
||||
int OSSL_CMP_validate_msg(OSSL_CMP_CTX *ctx, const OSSL_CMP_MSG *msg);
|
||||
int OSSL_CMP_validate_cert_path(const OSSL_CMP_CTX *ctx,
|
||||
X509_STORE *trusted_store, X509 *cert);
|
||||
|
||||
/* from cmp_http.c */
|
||||
OSSL_CMP_MSG *OSSL_CMP_MSG_http_perform(OSSL_CMP_CTX *ctx,
|
||||
const OSSL_CMP_MSG *req);
|
||||
|
||||
/* from cmp_server.c */
|
||||
typedef struct ossl_cmp_srv_ctx_st OSSL_CMP_SRV_CTX;
|
||||
OSSL_CMP_MSG *OSSL_CMP_SRV_process_request(OSSL_CMP_SRV_CTX *srv_ctx,
|
||||
const OSSL_CMP_MSG *req);
|
||||
OSSL_CMP_MSG * OSSL_CMP_CTX_server_perform(OSSL_CMP_CTX *client_ctx,
|
||||
const OSSL_CMP_MSG *req);
|
||||
OSSL_CMP_SRV_CTX *OSSL_CMP_SRV_CTX_new(OSSL_LIB_CTX *libctx, const char *propq);
|
||||
void OSSL_CMP_SRV_CTX_free(OSSL_CMP_SRV_CTX *srv_ctx);
|
||||
typedef OSSL_CMP_PKISI *(*OSSL_CMP_SRV_cert_request_cb_t)
|
||||
(OSSL_CMP_SRV_CTX *srv_ctx, const OSSL_CMP_MSG *req, int certReqId,
|
||||
const OSSL_CRMF_MSG *crm, const X509_REQ *p10cr,
|
||||
X509 **certOut, STACK_OF(X509) **chainOut, STACK_OF(X509) **caPubs);
|
||||
typedef OSSL_CMP_PKISI *(*OSSL_CMP_SRV_rr_cb_t)(OSSL_CMP_SRV_CTX *srv_ctx,
|
||||
const OSSL_CMP_MSG *req,
|
||||
const X509_NAME *issuer,
|
||||
const ASN1_INTEGER *serial);
|
||||
typedef int (*OSSL_CMP_SRV_genm_cb_t)(OSSL_CMP_SRV_CTX *srv_ctx,
|
||||
const OSSL_CMP_MSG *req,
|
||||
const STACK_OF(OSSL_CMP_ITAV) *in,
|
||||
STACK_OF(OSSL_CMP_ITAV) **out);
|
||||
typedef void (*OSSL_CMP_SRV_error_cb_t)(OSSL_CMP_SRV_CTX *srv_ctx,
|
||||
const OSSL_CMP_MSG *req,
|
||||
const OSSL_CMP_PKISI *statusInfo,
|
||||
const ASN1_INTEGER *errorCode,
|
||||
const OSSL_CMP_PKIFREETEXT *errDetails);
|
||||
typedef int (*OSSL_CMP_SRV_certConf_cb_t)(OSSL_CMP_SRV_CTX *srv_ctx,
|
||||
const OSSL_CMP_MSG *req,
|
||||
int certReqId,
|
||||
const ASN1_OCTET_STRING *certHash,
|
||||
const OSSL_CMP_PKISI *si);
|
||||
typedef int (*OSSL_CMP_SRV_pollReq_cb_t)(OSSL_CMP_SRV_CTX *srv_ctx,
|
||||
const OSSL_CMP_MSG *req, int certReqId,
|
||||
OSSL_CMP_MSG **certReq,
|
||||
int64_t *check_after);
|
||||
int OSSL_CMP_SRV_CTX_init(OSSL_CMP_SRV_CTX *srv_ctx, void *custom_ctx,
|
||||
OSSL_CMP_SRV_cert_request_cb_t process_cert_request,
|
||||
OSSL_CMP_SRV_rr_cb_t process_rr,
|
||||
OSSL_CMP_SRV_genm_cb_t process_genm,
|
||||
OSSL_CMP_SRV_error_cb_t process_error,
|
||||
OSSL_CMP_SRV_certConf_cb_t process_certConf,
|
||||
OSSL_CMP_SRV_pollReq_cb_t process_pollReq);
|
||||
OSSL_CMP_CTX *OSSL_CMP_SRV_CTX_get0_cmp_ctx(const OSSL_CMP_SRV_CTX *srv_ctx);
|
||||
void *OSSL_CMP_SRV_CTX_get0_custom_ctx(const OSSL_CMP_SRV_CTX *srv_ctx);
|
||||
int OSSL_CMP_SRV_CTX_set_send_unprotected_errors(OSSL_CMP_SRV_CTX *srv_ctx,
|
||||
int val);
|
||||
int OSSL_CMP_SRV_CTX_set_accept_unprotected(OSSL_CMP_SRV_CTX *srv_ctx, int val);
|
||||
int OSSL_CMP_SRV_CTX_set_accept_raverified(OSSL_CMP_SRV_CTX *srv_ctx, int val);
|
||||
int OSSL_CMP_SRV_CTX_set_grant_implicit_confirm(OSSL_CMP_SRV_CTX *srv_ctx,
|
||||
int val);
|
||||
|
||||
/* from cmp_client.c */
|
||||
X509 *OSSL_CMP_exec_certreq(OSSL_CMP_CTX *ctx, int req_type,
|
||||
const OSSL_CRMF_MSG *crm);
|
||||
# define OSSL_CMP_IR 0
|
||||
# define OSSL_CMP_CR 2
|
||||
# define OSSL_CMP_P10CR 4
|
||||
# define OSSL_CMP_KUR 7
|
||||
# define OSSL_CMP_exec_IR_ses(ctx) \
|
||||
OSSL_CMP_exec_certreq(ctx, OSSL_CMP_IR, NULL)
|
||||
# define OSSL_CMP_exec_CR_ses(ctx) \
|
||||
OSSL_CMP_exec_certreq(ctx, OSSL_CMP_CR, NULL)
|
||||
# define OSSL_CMP_exec_P10CR_ses(ctx) \
|
||||
OSSL_CMP_exec_certreq(ctx, OSSL_CMP_P10CR, NULL)
|
||||
# define OSSL_CMP_exec_KUR_ses(ctx) \
|
||||
OSSL_CMP_exec_certreq(ctx, OSSL_CMP_KUR, NULL)
|
||||
int OSSL_CMP_try_certreq(OSSL_CMP_CTX *ctx, int req_type,
|
||||
const OSSL_CRMF_MSG *crm, int *checkAfter);
|
||||
int OSSL_CMP_exec_RR_ses(OSSL_CMP_CTX *ctx);
|
||||
STACK_OF(OSSL_CMP_ITAV) *OSSL_CMP_exec_GENM_ses(OSSL_CMP_CTX *ctx);
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
# endif /* !defined(OPENSSL_NO_CMP) */
|
||||
#endif /* !defined(OPENSSL_CMP_H) */
|
||||
493
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/cms.h
generated
vendored
Normal file
493
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/cms.h
generated
vendored
Normal file
@@ -0,0 +1,493 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/cms.h.in
|
||||
*
|
||||
* Copyright 2008-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_CMS_H
|
||||
# define OPENSSL_CMS_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_CMS_H
|
||||
# endif
|
||||
|
||||
# include <openssl/opensslconf.h>
|
||||
|
||||
# ifndef OPENSSL_NO_CMS
|
||||
# include <openssl/x509.h>
|
||||
# include <openssl/x509v3.h>
|
||||
# include <openssl/cmserr.h>
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
typedef struct CMS_ContentInfo_st CMS_ContentInfo;
|
||||
typedef struct CMS_SignerInfo_st CMS_SignerInfo;
|
||||
typedef struct CMS_CertificateChoices CMS_CertificateChoices;
|
||||
typedef struct CMS_RevocationInfoChoice_st CMS_RevocationInfoChoice;
|
||||
typedef struct CMS_RecipientInfo_st CMS_RecipientInfo;
|
||||
typedef struct CMS_ReceiptRequest_st CMS_ReceiptRequest;
|
||||
typedef struct CMS_Receipt_st CMS_Receipt;
|
||||
typedef struct CMS_RecipientEncryptedKey_st CMS_RecipientEncryptedKey;
|
||||
typedef struct CMS_OtherKeyAttribute_st CMS_OtherKeyAttribute;
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(CMS_SignerInfo, CMS_SignerInfo, CMS_SignerInfo)
|
||||
#define sk_CMS_SignerInfo_num(sk) OPENSSL_sk_num(ossl_check_const_CMS_SignerInfo_sk_type(sk))
|
||||
#define sk_CMS_SignerInfo_value(sk, idx) ((CMS_SignerInfo *)OPENSSL_sk_value(ossl_check_const_CMS_SignerInfo_sk_type(sk), (idx)))
|
||||
#define sk_CMS_SignerInfo_new(cmp) ((STACK_OF(CMS_SignerInfo) *)OPENSSL_sk_new(ossl_check_CMS_SignerInfo_compfunc_type(cmp)))
|
||||
#define sk_CMS_SignerInfo_new_null() ((STACK_OF(CMS_SignerInfo) *)OPENSSL_sk_new_null())
|
||||
#define sk_CMS_SignerInfo_new_reserve(cmp, n) ((STACK_OF(CMS_SignerInfo) *)OPENSSL_sk_new_reserve(ossl_check_CMS_SignerInfo_compfunc_type(cmp), (n)))
|
||||
#define sk_CMS_SignerInfo_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_CMS_SignerInfo_sk_type(sk), (n))
|
||||
#define sk_CMS_SignerInfo_free(sk) OPENSSL_sk_free(ossl_check_CMS_SignerInfo_sk_type(sk))
|
||||
#define sk_CMS_SignerInfo_zero(sk) OPENSSL_sk_zero(ossl_check_CMS_SignerInfo_sk_type(sk))
|
||||
#define sk_CMS_SignerInfo_delete(sk, i) ((CMS_SignerInfo *)OPENSSL_sk_delete(ossl_check_CMS_SignerInfo_sk_type(sk), (i)))
|
||||
#define sk_CMS_SignerInfo_delete_ptr(sk, ptr) ((CMS_SignerInfo *)OPENSSL_sk_delete_ptr(ossl_check_CMS_SignerInfo_sk_type(sk), ossl_check_CMS_SignerInfo_type(ptr)))
|
||||
#define sk_CMS_SignerInfo_push(sk, ptr) OPENSSL_sk_push(ossl_check_CMS_SignerInfo_sk_type(sk), ossl_check_CMS_SignerInfo_type(ptr))
|
||||
#define sk_CMS_SignerInfo_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_CMS_SignerInfo_sk_type(sk), ossl_check_CMS_SignerInfo_type(ptr))
|
||||
#define sk_CMS_SignerInfo_pop(sk) ((CMS_SignerInfo *)OPENSSL_sk_pop(ossl_check_CMS_SignerInfo_sk_type(sk)))
|
||||
#define sk_CMS_SignerInfo_shift(sk) ((CMS_SignerInfo *)OPENSSL_sk_shift(ossl_check_CMS_SignerInfo_sk_type(sk)))
|
||||
#define sk_CMS_SignerInfo_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_CMS_SignerInfo_sk_type(sk),ossl_check_CMS_SignerInfo_freefunc_type(freefunc))
|
||||
#define sk_CMS_SignerInfo_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_CMS_SignerInfo_sk_type(sk), ossl_check_CMS_SignerInfo_type(ptr), (idx))
|
||||
#define sk_CMS_SignerInfo_set(sk, idx, ptr) ((CMS_SignerInfo *)OPENSSL_sk_set(ossl_check_CMS_SignerInfo_sk_type(sk), (idx), ossl_check_CMS_SignerInfo_type(ptr)))
|
||||
#define sk_CMS_SignerInfo_find(sk, ptr) OPENSSL_sk_find(ossl_check_CMS_SignerInfo_sk_type(sk), ossl_check_CMS_SignerInfo_type(ptr))
|
||||
#define sk_CMS_SignerInfo_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_CMS_SignerInfo_sk_type(sk), ossl_check_CMS_SignerInfo_type(ptr))
|
||||
#define sk_CMS_SignerInfo_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_CMS_SignerInfo_sk_type(sk), ossl_check_CMS_SignerInfo_type(ptr), pnum)
|
||||
#define sk_CMS_SignerInfo_sort(sk) OPENSSL_sk_sort(ossl_check_CMS_SignerInfo_sk_type(sk))
|
||||
#define sk_CMS_SignerInfo_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_CMS_SignerInfo_sk_type(sk))
|
||||
#define sk_CMS_SignerInfo_dup(sk) ((STACK_OF(CMS_SignerInfo) *)OPENSSL_sk_dup(ossl_check_const_CMS_SignerInfo_sk_type(sk)))
|
||||
#define sk_CMS_SignerInfo_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(CMS_SignerInfo) *)OPENSSL_sk_deep_copy(ossl_check_const_CMS_SignerInfo_sk_type(sk), ossl_check_CMS_SignerInfo_copyfunc_type(copyfunc), ossl_check_CMS_SignerInfo_freefunc_type(freefunc)))
|
||||
#define sk_CMS_SignerInfo_set_cmp_func(sk, cmp) ((sk_CMS_SignerInfo_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_CMS_SignerInfo_sk_type(sk), ossl_check_CMS_SignerInfo_compfunc_type(cmp)))
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(CMS_RecipientEncryptedKey, CMS_RecipientEncryptedKey, CMS_RecipientEncryptedKey)
|
||||
#define sk_CMS_RecipientEncryptedKey_num(sk) OPENSSL_sk_num(ossl_check_const_CMS_RecipientEncryptedKey_sk_type(sk))
|
||||
#define sk_CMS_RecipientEncryptedKey_value(sk, idx) ((CMS_RecipientEncryptedKey *)OPENSSL_sk_value(ossl_check_const_CMS_RecipientEncryptedKey_sk_type(sk), (idx)))
|
||||
#define sk_CMS_RecipientEncryptedKey_new(cmp) ((STACK_OF(CMS_RecipientEncryptedKey) *)OPENSSL_sk_new(ossl_check_CMS_RecipientEncryptedKey_compfunc_type(cmp)))
|
||||
#define sk_CMS_RecipientEncryptedKey_new_null() ((STACK_OF(CMS_RecipientEncryptedKey) *)OPENSSL_sk_new_null())
|
||||
#define sk_CMS_RecipientEncryptedKey_new_reserve(cmp, n) ((STACK_OF(CMS_RecipientEncryptedKey) *)OPENSSL_sk_new_reserve(ossl_check_CMS_RecipientEncryptedKey_compfunc_type(cmp), (n)))
|
||||
#define sk_CMS_RecipientEncryptedKey_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), (n))
|
||||
#define sk_CMS_RecipientEncryptedKey_free(sk) OPENSSL_sk_free(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk))
|
||||
#define sk_CMS_RecipientEncryptedKey_zero(sk) OPENSSL_sk_zero(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk))
|
||||
#define sk_CMS_RecipientEncryptedKey_delete(sk, i) ((CMS_RecipientEncryptedKey *)OPENSSL_sk_delete(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), (i)))
|
||||
#define sk_CMS_RecipientEncryptedKey_delete_ptr(sk, ptr) ((CMS_RecipientEncryptedKey *)OPENSSL_sk_delete_ptr(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), ossl_check_CMS_RecipientEncryptedKey_type(ptr)))
|
||||
#define sk_CMS_RecipientEncryptedKey_push(sk, ptr) OPENSSL_sk_push(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), ossl_check_CMS_RecipientEncryptedKey_type(ptr))
|
||||
#define sk_CMS_RecipientEncryptedKey_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), ossl_check_CMS_RecipientEncryptedKey_type(ptr))
|
||||
#define sk_CMS_RecipientEncryptedKey_pop(sk) ((CMS_RecipientEncryptedKey *)OPENSSL_sk_pop(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk)))
|
||||
#define sk_CMS_RecipientEncryptedKey_shift(sk) ((CMS_RecipientEncryptedKey *)OPENSSL_sk_shift(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk)))
|
||||
#define sk_CMS_RecipientEncryptedKey_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk),ossl_check_CMS_RecipientEncryptedKey_freefunc_type(freefunc))
|
||||
#define sk_CMS_RecipientEncryptedKey_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), ossl_check_CMS_RecipientEncryptedKey_type(ptr), (idx))
|
||||
#define sk_CMS_RecipientEncryptedKey_set(sk, idx, ptr) ((CMS_RecipientEncryptedKey *)OPENSSL_sk_set(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), (idx), ossl_check_CMS_RecipientEncryptedKey_type(ptr)))
|
||||
#define sk_CMS_RecipientEncryptedKey_find(sk, ptr) OPENSSL_sk_find(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), ossl_check_CMS_RecipientEncryptedKey_type(ptr))
|
||||
#define sk_CMS_RecipientEncryptedKey_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), ossl_check_CMS_RecipientEncryptedKey_type(ptr))
|
||||
#define sk_CMS_RecipientEncryptedKey_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), ossl_check_CMS_RecipientEncryptedKey_type(ptr), pnum)
|
||||
#define sk_CMS_RecipientEncryptedKey_sort(sk) OPENSSL_sk_sort(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk))
|
||||
#define sk_CMS_RecipientEncryptedKey_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_CMS_RecipientEncryptedKey_sk_type(sk))
|
||||
#define sk_CMS_RecipientEncryptedKey_dup(sk) ((STACK_OF(CMS_RecipientEncryptedKey) *)OPENSSL_sk_dup(ossl_check_const_CMS_RecipientEncryptedKey_sk_type(sk)))
|
||||
#define sk_CMS_RecipientEncryptedKey_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(CMS_RecipientEncryptedKey) *)OPENSSL_sk_deep_copy(ossl_check_const_CMS_RecipientEncryptedKey_sk_type(sk), ossl_check_CMS_RecipientEncryptedKey_copyfunc_type(copyfunc), ossl_check_CMS_RecipientEncryptedKey_freefunc_type(freefunc)))
|
||||
#define sk_CMS_RecipientEncryptedKey_set_cmp_func(sk, cmp) ((sk_CMS_RecipientEncryptedKey_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_CMS_RecipientEncryptedKey_sk_type(sk), ossl_check_CMS_RecipientEncryptedKey_compfunc_type(cmp)))
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(CMS_RecipientInfo, CMS_RecipientInfo, CMS_RecipientInfo)
|
||||
#define sk_CMS_RecipientInfo_num(sk) OPENSSL_sk_num(ossl_check_const_CMS_RecipientInfo_sk_type(sk))
|
||||
#define sk_CMS_RecipientInfo_value(sk, idx) ((CMS_RecipientInfo *)OPENSSL_sk_value(ossl_check_const_CMS_RecipientInfo_sk_type(sk), (idx)))
|
||||
#define sk_CMS_RecipientInfo_new(cmp) ((STACK_OF(CMS_RecipientInfo) *)OPENSSL_sk_new(ossl_check_CMS_RecipientInfo_compfunc_type(cmp)))
|
||||
#define sk_CMS_RecipientInfo_new_null() ((STACK_OF(CMS_RecipientInfo) *)OPENSSL_sk_new_null())
|
||||
#define sk_CMS_RecipientInfo_new_reserve(cmp, n) ((STACK_OF(CMS_RecipientInfo) *)OPENSSL_sk_new_reserve(ossl_check_CMS_RecipientInfo_compfunc_type(cmp), (n)))
|
||||
#define sk_CMS_RecipientInfo_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_CMS_RecipientInfo_sk_type(sk), (n))
|
||||
#define sk_CMS_RecipientInfo_free(sk) OPENSSL_sk_free(ossl_check_CMS_RecipientInfo_sk_type(sk))
|
||||
#define sk_CMS_RecipientInfo_zero(sk) OPENSSL_sk_zero(ossl_check_CMS_RecipientInfo_sk_type(sk))
|
||||
#define sk_CMS_RecipientInfo_delete(sk, i) ((CMS_RecipientInfo *)OPENSSL_sk_delete(ossl_check_CMS_RecipientInfo_sk_type(sk), (i)))
|
||||
#define sk_CMS_RecipientInfo_delete_ptr(sk, ptr) ((CMS_RecipientInfo *)OPENSSL_sk_delete_ptr(ossl_check_CMS_RecipientInfo_sk_type(sk), ossl_check_CMS_RecipientInfo_type(ptr)))
|
||||
#define sk_CMS_RecipientInfo_push(sk, ptr) OPENSSL_sk_push(ossl_check_CMS_RecipientInfo_sk_type(sk), ossl_check_CMS_RecipientInfo_type(ptr))
|
||||
#define sk_CMS_RecipientInfo_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_CMS_RecipientInfo_sk_type(sk), ossl_check_CMS_RecipientInfo_type(ptr))
|
||||
#define sk_CMS_RecipientInfo_pop(sk) ((CMS_RecipientInfo *)OPENSSL_sk_pop(ossl_check_CMS_RecipientInfo_sk_type(sk)))
|
||||
#define sk_CMS_RecipientInfo_shift(sk) ((CMS_RecipientInfo *)OPENSSL_sk_shift(ossl_check_CMS_RecipientInfo_sk_type(sk)))
|
||||
#define sk_CMS_RecipientInfo_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_CMS_RecipientInfo_sk_type(sk),ossl_check_CMS_RecipientInfo_freefunc_type(freefunc))
|
||||
#define sk_CMS_RecipientInfo_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_CMS_RecipientInfo_sk_type(sk), ossl_check_CMS_RecipientInfo_type(ptr), (idx))
|
||||
#define sk_CMS_RecipientInfo_set(sk, idx, ptr) ((CMS_RecipientInfo *)OPENSSL_sk_set(ossl_check_CMS_RecipientInfo_sk_type(sk), (idx), ossl_check_CMS_RecipientInfo_type(ptr)))
|
||||
#define sk_CMS_RecipientInfo_find(sk, ptr) OPENSSL_sk_find(ossl_check_CMS_RecipientInfo_sk_type(sk), ossl_check_CMS_RecipientInfo_type(ptr))
|
||||
#define sk_CMS_RecipientInfo_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_CMS_RecipientInfo_sk_type(sk), ossl_check_CMS_RecipientInfo_type(ptr))
|
||||
#define sk_CMS_RecipientInfo_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_CMS_RecipientInfo_sk_type(sk), ossl_check_CMS_RecipientInfo_type(ptr), pnum)
|
||||
#define sk_CMS_RecipientInfo_sort(sk) OPENSSL_sk_sort(ossl_check_CMS_RecipientInfo_sk_type(sk))
|
||||
#define sk_CMS_RecipientInfo_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_CMS_RecipientInfo_sk_type(sk))
|
||||
#define sk_CMS_RecipientInfo_dup(sk) ((STACK_OF(CMS_RecipientInfo) *)OPENSSL_sk_dup(ossl_check_const_CMS_RecipientInfo_sk_type(sk)))
|
||||
#define sk_CMS_RecipientInfo_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(CMS_RecipientInfo) *)OPENSSL_sk_deep_copy(ossl_check_const_CMS_RecipientInfo_sk_type(sk), ossl_check_CMS_RecipientInfo_copyfunc_type(copyfunc), ossl_check_CMS_RecipientInfo_freefunc_type(freefunc)))
|
||||
#define sk_CMS_RecipientInfo_set_cmp_func(sk, cmp) ((sk_CMS_RecipientInfo_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_CMS_RecipientInfo_sk_type(sk), ossl_check_CMS_RecipientInfo_compfunc_type(cmp)))
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(CMS_RevocationInfoChoice, CMS_RevocationInfoChoice, CMS_RevocationInfoChoice)
|
||||
#define sk_CMS_RevocationInfoChoice_num(sk) OPENSSL_sk_num(ossl_check_const_CMS_RevocationInfoChoice_sk_type(sk))
|
||||
#define sk_CMS_RevocationInfoChoice_value(sk, idx) ((CMS_RevocationInfoChoice *)OPENSSL_sk_value(ossl_check_const_CMS_RevocationInfoChoice_sk_type(sk), (idx)))
|
||||
#define sk_CMS_RevocationInfoChoice_new(cmp) ((STACK_OF(CMS_RevocationInfoChoice) *)OPENSSL_sk_new(ossl_check_CMS_RevocationInfoChoice_compfunc_type(cmp)))
|
||||
#define sk_CMS_RevocationInfoChoice_new_null() ((STACK_OF(CMS_RevocationInfoChoice) *)OPENSSL_sk_new_null())
|
||||
#define sk_CMS_RevocationInfoChoice_new_reserve(cmp, n) ((STACK_OF(CMS_RevocationInfoChoice) *)OPENSSL_sk_new_reserve(ossl_check_CMS_RevocationInfoChoice_compfunc_type(cmp), (n)))
|
||||
#define sk_CMS_RevocationInfoChoice_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), (n))
|
||||
#define sk_CMS_RevocationInfoChoice_free(sk) OPENSSL_sk_free(ossl_check_CMS_RevocationInfoChoice_sk_type(sk))
|
||||
#define sk_CMS_RevocationInfoChoice_zero(sk) OPENSSL_sk_zero(ossl_check_CMS_RevocationInfoChoice_sk_type(sk))
|
||||
#define sk_CMS_RevocationInfoChoice_delete(sk, i) ((CMS_RevocationInfoChoice *)OPENSSL_sk_delete(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), (i)))
|
||||
#define sk_CMS_RevocationInfoChoice_delete_ptr(sk, ptr) ((CMS_RevocationInfoChoice *)OPENSSL_sk_delete_ptr(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), ossl_check_CMS_RevocationInfoChoice_type(ptr)))
|
||||
#define sk_CMS_RevocationInfoChoice_push(sk, ptr) OPENSSL_sk_push(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), ossl_check_CMS_RevocationInfoChoice_type(ptr))
|
||||
#define sk_CMS_RevocationInfoChoice_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), ossl_check_CMS_RevocationInfoChoice_type(ptr))
|
||||
#define sk_CMS_RevocationInfoChoice_pop(sk) ((CMS_RevocationInfoChoice *)OPENSSL_sk_pop(ossl_check_CMS_RevocationInfoChoice_sk_type(sk)))
|
||||
#define sk_CMS_RevocationInfoChoice_shift(sk) ((CMS_RevocationInfoChoice *)OPENSSL_sk_shift(ossl_check_CMS_RevocationInfoChoice_sk_type(sk)))
|
||||
#define sk_CMS_RevocationInfoChoice_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_CMS_RevocationInfoChoice_sk_type(sk),ossl_check_CMS_RevocationInfoChoice_freefunc_type(freefunc))
|
||||
#define sk_CMS_RevocationInfoChoice_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), ossl_check_CMS_RevocationInfoChoice_type(ptr), (idx))
|
||||
#define sk_CMS_RevocationInfoChoice_set(sk, idx, ptr) ((CMS_RevocationInfoChoice *)OPENSSL_sk_set(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), (idx), ossl_check_CMS_RevocationInfoChoice_type(ptr)))
|
||||
#define sk_CMS_RevocationInfoChoice_find(sk, ptr) OPENSSL_sk_find(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), ossl_check_CMS_RevocationInfoChoice_type(ptr))
|
||||
#define sk_CMS_RevocationInfoChoice_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), ossl_check_CMS_RevocationInfoChoice_type(ptr))
|
||||
#define sk_CMS_RevocationInfoChoice_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), ossl_check_CMS_RevocationInfoChoice_type(ptr), pnum)
|
||||
#define sk_CMS_RevocationInfoChoice_sort(sk) OPENSSL_sk_sort(ossl_check_CMS_RevocationInfoChoice_sk_type(sk))
|
||||
#define sk_CMS_RevocationInfoChoice_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_CMS_RevocationInfoChoice_sk_type(sk))
|
||||
#define sk_CMS_RevocationInfoChoice_dup(sk) ((STACK_OF(CMS_RevocationInfoChoice) *)OPENSSL_sk_dup(ossl_check_const_CMS_RevocationInfoChoice_sk_type(sk)))
|
||||
#define sk_CMS_RevocationInfoChoice_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(CMS_RevocationInfoChoice) *)OPENSSL_sk_deep_copy(ossl_check_const_CMS_RevocationInfoChoice_sk_type(sk), ossl_check_CMS_RevocationInfoChoice_copyfunc_type(copyfunc), ossl_check_CMS_RevocationInfoChoice_freefunc_type(freefunc)))
|
||||
#define sk_CMS_RevocationInfoChoice_set_cmp_func(sk, cmp) ((sk_CMS_RevocationInfoChoice_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_CMS_RevocationInfoChoice_sk_type(sk), ossl_check_CMS_RevocationInfoChoice_compfunc_type(cmp)))
|
||||
|
||||
|
||||
DECLARE_ASN1_FUNCTIONS(CMS_ContentInfo)
|
||||
DECLARE_ASN1_FUNCTIONS(CMS_ReceiptRequest)
|
||||
DECLARE_ASN1_PRINT_FUNCTION(CMS_ContentInfo)
|
||||
|
||||
CMS_ContentInfo *CMS_ContentInfo_new_ex(OSSL_LIB_CTX *libctx, const char *propq);
|
||||
|
||||
# define CMS_SIGNERINFO_ISSUER_SERIAL 0
|
||||
# define CMS_SIGNERINFO_KEYIDENTIFIER 1
|
||||
|
||||
# define CMS_RECIPINFO_NONE -1
|
||||
# define CMS_RECIPINFO_TRANS 0
|
||||
# define CMS_RECIPINFO_AGREE 1
|
||||
# define CMS_RECIPINFO_KEK 2
|
||||
# define CMS_RECIPINFO_PASS 3
|
||||
# define CMS_RECIPINFO_OTHER 4
|
||||
|
||||
/* S/MIME related flags */
|
||||
|
||||
# define CMS_TEXT 0x1
|
||||
# define CMS_NOCERTS 0x2
|
||||
# define CMS_NO_CONTENT_VERIFY 0x4
|
||||
# define CMS_NO_ATTR_VERIFY 0x8
|
||||
# define CMS_NOSIGS \
|
||||
(CMS_NO_CONTENT_VERIFY|CMS_NO_ATTR_VERIFY)
|
||||
# define CMS_NOINTERN 0x10
|
||||
# define CMS_NO_SIGNER_CERT_VERIFY 0x20
|
||||
# define CMS_NOVERIFY 0x20
|
||||
# define CMS_DETACHED 0x40
|
||||
# define CMS_BINARY 0x80
|
||||
# define CMS_NOATTR 0x100
|
||||
# define CMS_NOSMIMECAP 0x200
|
||||
# define CMS_NOOLDMIMETYPE 0x400
|
||||
# define CMS_CRLFEOL 0x800
|
||||
# define CMS_STREAM 0x1000
|
||||
# define CMS_NOCRL 0x2000
|
||||
# define CMS_PARTIAL 0x4000
|
||||
# define CMS_REUSE_DIGEST 0x8000
|
||||
# define CMS_USE_KEYID 0x10000
|
||||
# define CMS_DEBUG_DECRYPT 0x20000
|
||||
# define CMS_KEY_PARAM 0x40000
|
||||
# define CMS_ASCIICRLF 0x80000
|
||||
# define CMS_CADES 0x100000
|
||||
# define CMS_USE_ORIGINATOR_KEYID 0x200000
|
||||
|
||||
const ASN1_OBJECT *CMS_get0_type(const CMS_ContentInfo *cms);
|
||||
|
||||
BIO *CMS_dataInit(CMS_ContentInfo *cms, BIO *icont);
|
||||
int CMS_dataFinal(CMS_ContentInfo *cms, BIO *bio);
|
||||
|
||||
ASN1_OCTET_STRING **CMS_get0_content(CMS_ContentInfo *cms);
|
||||
int CMS_is_detached(CMS_ContentInfo *cms);
|
||||
int CMS_set_detached(CMS_ContentInfo *cms, int detached);
|
||||
|
||||
# ifdef OPENSSL_PEM_H
|
||||
DECLARE_PEM_rw(CMS, CMS_ContentInfo)
|
||||
# endif
|
||||
int CMS_stream(unsigned char ***boundary, CMS_ContentInfo *cms);
|
||||
CMS_ContentInfo *d2i_CMS_bio(BIO *bp, CMS_ContentInfo **cms);
|
||||
int i2d_CMS_bio(BIO *bp, CMS_ContentInfo *cms);
|
||||
|
||||
BIO *BIO_new_CMS(BIO *out, CMS_ContentInfo *cms);
|
||||
int i2d_CMS_bio_stream(BIO *out, CMS_ContentInfo *cms, BIO *in, int flags);
|
||||
int PEM_write_bio_CMS_stream(BIO *out, CMS_ContentInfo *cms, BIO *in,
|
||||
int flags);
|
||||
CMS_ContentInfo *SMIME_read_CMS(BIO *bio, BIO **bcont);
|
||||
CMS_ContentInfo *SMIME_read_CMS_ex(BIO *bio, int flags, BIO **bcont, CMS_ContentInfo **ci);
|
||||
int SMIME_write_CMS(BIO *bio, CMS_ContentInfo *cms, BIO *data, int flags);
|
||||
|
||||
int CMS_final(CMS_ContentInfo *cms, BIO *data, BIO *dcont,
|
||||
unsigned int flags);
|
||||
|
||||
CMS_ContentInfo *CMS_sign(X509 *signcert, EVP_PKEY *pkey,
|
||||
STACK_OF(X509) *certs, BIO *data,
|
||||
unsigned int flags);
|
||||
CMS_ContentInfo *CMS_sign_ex(X509 *signcert, EVP_PKEY *pkey,
|
||||
STACK_OF(X509) *certs, BIO *data,
|
||||
unsigned int flags, OSSL_LIB_CTX *ctx,
|
||||
const char *propq);
|
||||
|
||||
CMS_ContentInfo *CMS_sign_receipt(CMS_SignerInfo *si,
|
||||
X509 *signcert, EVP_PKEY *pkey,
|
||||
STACK_OF(X509) *certs, unsigned int flags);
|
||||
|
||||
int CMS_data(CMS_ContentInfo *cms, BIO *out, unsigned int flags);
|
||||
CMS_ContentInfo *CMS_data_create(BIO *in, unsigned int flags);
|
||||
CMS_ContentInfo *CMS_data_create_ex(BIO *in, unsigned int flags,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
|
||||
int CMS_digest_verify(CMS_ContentInfo *cms, BIO *dcont, BIO *out,
|
||||
unsigned int flags);
|
||||
CMS_ContentInfo *CMS_digest_create(BIO *in, const EVP_MD *md,
|
||||
unsigned int flags);
|
||||
CMS_ContentInfo *CMS_digest_create_ex(BIO *in, const EVP_MD *md,
|
||||
unsigned int flags, OSSL_LIB_CTX *ctx,
|
||||
const char *propq);
|
||||
|
||||
int CMS_EncryptedData_decrypt(CMS_ContentInfo *cms,
|
||||
const unsigned char *key, size_t keylen,
|
||||
BIO *dcont, BIO *out, unsigned int flags);
|
||||
|
||||
CMS_ContentInfo *CMS_EncryptedData_encrypt(BIO *in, const EVP_CIPHER *cipher,
|
||||
const unsigned char *key,
|
||||
size_t keylen, unsigned int flags);
|
||||
CMS_ContentInfo *CMS_EncryptedData_encrypt_ex(BIO *in, const EVP_CIPHER *cipher,
|
||||
const unsigned char *key,
|
||||
size_t keylen, unsigned int flags,
|
||||
OSSL_LIB_CTX *ctx,
|
||||
const char *propq);
|
||||
|
||||
int CMS_EncryptedData_set1_key(CMS_ContentInfo *cms, const EVP_CIPHER *ciph,
|
||||
const unsigned char *key, size_t keylen);
|
||||
|
||||
int CMS_verify(CMS_ContentInfo *cms, STACK_OF(X509) *certs,
|
||||
X509_STORE *store, BIO *dcont, BIO *out, unsigned int flags);
|
||||
|
||||
int CMS_verify_receipt(CMS_ContentInfo *rcms, CMS_ContentInfo *ocms,
|
||||
STACK_OF(X509) *certs,
|
||||
X509_STORE *store, unsigned int flags);
|
||||
|
||||
STACK_OF(X509) *CMS_get0_signers(CMS_ContentInfo *cms);
|
||||
|
||||
CMS_ContentInfo *CMS_encrypt(STACK_OF(X509) *certs, BIO *in,
|
||||
const EVP_CIPHER *cipher, unsigned int flags);
|
||||
CMS_ContentInfo *CMS_encrypt_ex(STACK_OF(X509) *certs, BIO *in,
|
||||
const EVP_CIPHER *cipher, unsigned int flags,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
|
||||
int CMS_decrypt(CMS_ContentInfo *cms, EVP_PKEY *pkey, X509 *cert,
|
||||
BIO *dcont, BIO *out, unsigned int flags);
|
||||
|
||||
int CMS_decrypt_set1_pkey(CMS_ContentInfo *cms, EVP_PKEY *pk, X509 *cert);
|
||||
int CMS_decrypt_set1_pkey_and_peer(CMS_ContentInfo *cms, EVP_PKEY *pk,
|
||||
X509 *cert, X509 *peer);
|
||||
int CMS_decrypt_set1_key(CMS_ContentInfo *cms,
|
||||
unsigned char *key, size_t keylen,
|
||||
const unsigned char *id, size_t idlen);
|
||||
int CMS_decrypt_set1_password(CMS_ContentInfo *cms,
|
||||
unsigned char *pass, ossl_ssize_t passlen);
|
||||
|
||||
STACK_OF(CMS_RecipientInfo) *CMS_get0_RecipientInfos(CMS_ContentInfo *cms);
|
||||
int CMS_RecipientInfo_type(CMS_RecipientInfo *ri);
|
||||
EVP_PKEY_CTX *CMS_RecipientInfo_get0_pkey_ctx(CMS_RecipientInfo *ri);
|
||||
CMS_ContentInfo *CMS_AuthEnvelopedData_create(const EVP_CIPHER *cipher);
|
||||
CMS_ContentInfo *
|
||||
CMS_AuthEnvelopedData_create_ex(const EVP_CIPHER *cipher, OSSL_LIB_CTX *ctx,
|
||||
const char *propq);
|
||||
CMS_ContentInfo *CMS_EnvelopedData_create(const EVP_CIPHER *cipher);
|
||||
CMS_ContentInfo *CMS_EnvelopedData_create_ex(const EVP_CIPHER *cipher,
|
||||
OSSL_LIB_CTX *ctx,
|
||||
const char *propq);
|
||||
|
||||
CMS_RecipientInfo *CMS_add1_recipient_cert(CMS_ContentInfo *cms,
|
||||
X509 *recip, unsigned int flags);
|
||||
CMS_RecipientInfo *CMS_add1_recipient(CMS_ContentInfo *cms, X509 *recip,
|
||||
EVP_PKEY *originatorPrivKey, X509 * originator, unsigned int flags);
|
||||
int CMS_RecipientInfo_set0_pkey(CMS_RecipientInfo *ri, EVP_PKEY *pkey);
|
||||
int CMS_RecipientInfo_ktri_cert_cmp(CMS_RecipientInfo *ri, X509 *cert);
|
||||
int CMS_RecipientInfo_ktri_get0_algs(CMS_RecipientInfo *ri,
|
||||
EVP_PKEY **pk, X509 **recip,
|
||||
X509_ALGOR **palg);
|
||||
int CMS_RecipientInfo_ktri_get0_signer_id(CMS_RecipientInfo *ri,
|
||||
ASN1_OCTET_STRING **keyid,
|
||||
X509_NAME **issuer,
|
||||
ASN1_INTEGER **sno);
|
||||
|
||||
CMS_RecipientInfo *CMS_add0_recipient_key(CMS_ContentInfo *cms, int nid,
|
||||
unsigned char *key, size_t keylen,
|
||||
unsigned char *id, size_t idlen,
|
||||
ASN1_GENERALIZEDTIME *date,
|
||||
ASN1_OBJECT *otherTypeId,
|
||||
ASN1_TYPE *otherType);
|
||||
|
||||
int CMS_RecipientInfo_kekri_get0_id(CMS_RecipientInfo *ri,
|
||||
X509_ALGOR **palg,
|
||||
ASN1_OCTET_STRING **pid,
|
||||
ASN1_GENERALIZEDTIME **pdate,
|
||||
ASN1_OBJECT **potherid,
|
||||
ASN1_TYPE **pothertype);
|
||||
|
||||
int CMS_RecipientInfo_set0_key(CMS_RecipientInfo *ri,
|
||||
unsigned char *key, size_t keylen);
|
||||
|
||||
int CMS_RecipientInfo_kekri_id_cmp(CMS_RecipientInfo *ri,
|
||||
const unsigned char *id, size_t idlen);
|
||||
|
||||
int CMS_RecipientInfo_set0_password(CMS_RecipientInfo *ri,
|
||||
unsigned char *pass,
|
||||
ossl_ssize_t passlen);
|
||||
|
||||
CMS_RecipientInfo *CMS_add0_recipient_password(CMS_ContentInfo *cms,
|
||||
int iter, int wrap_nid,
|
||||
int pbe_nid,
|
||||
unsigned char *pass,
|
||||
ossl_ssize_t passlen,
|
||||
const EVP_CIPHER *kekciph);
|
||||
|
||||
int CMS_RecipientInfo_decrypt(CMS_ContentInfo *cms, CMS_RecipientInfo *ri);
|
||||
int CMS_RecipientInfo_encrypt(const CMS_ContentInfo *cms, CMS_RecipientInfo *ri);
|
||||
|
||||
int CMS_uncompress(CMS_ContentInfo *cms, BIO *dcont, BIO *out,
|
||||
unsigned int flags);
|
||||
CMS_ContentInfo *CMS_compress(BIO *in, int comp_nid, unsigned int flags);
|
||||
|
||||
int CMS_set1_eContentType(CMS_ContentInfo *cms, const ASN1_OBJECT *oid);
|
||||
const ASN1_OBJECT *CMS_get0_eContentType(CMS_ContentInfo *cms);
|
||||
|
||||
CMS_CertificateChoices *CMS_add0_CertificateChoices(CMS_ContentInfo *cms);
|
||||
int CMS_add0_cert(CMS_ContentInfo *cms, X509 *cert);
|
||||
int CMS_add1_cert(CMS_ContentInfo *cms, X509 *cert);
|
||||
STACK_OF(X509) *CMS_get1_certs(CMS_ContentInfo *cms);
|
||||
|
||||
CMS_RevocationInfoChoice *CMS_add0_RevocationInfoChoice(CMS_ContentInfo *cms);
|
||||
int CMS_add0_crl(CMS_ContentInfo *cms, X509_CRL *crl);
|
||||
int CMS_add1_crl(CMS_ContentInfo *cms, X509_CRL *crl);
|
||||
STACK_OF(X509_CRL) *CMS_get1_crls(CMS_ContentInfo *cms);
|
||||
|
||||
int CMS_SignedData_init(CMS_ContentInfo *cms);
|
||||
CMS_SignerInfo *CMS_add1_signer(CMS_ContentInfo *cms,
|
||||
X509 *signer, EVP_PKEY *pk, const EVP_MD *md,
|
||||
unsigned int flags);
|
||||
EVP_PKEY_CTX *CMS_SignerInfo_get0_pkey_ctx(CMS_SignerInfo *si);
|
||||
EVP_MD_CTX *CMS_SignerInfo_get0_md_ctx(CMS_SignerInfo *si);
|
||||
STACK_OF(CMS_SignerInfo) *CMS_get0_SignerInfos(CMS_ContentInfo *cms);
|
||||
|
||||
void CMS_SignerInfo_set1_signer_cert(CMS_SignerInfo *si, X509 *signer);
|
||||
int CMS_SignerInfo_get0_signer_id(CMS_SignerInfo *si,
|
||||
ASN1_OCTET_STRING **keyid,
|
||||
X509_NAME **issuer, ASN1_INTEGER **sno);
|
||||
int CMS_SignerInfo_cert_cmp(CMS_SignerInfo *si, X509 *cert);
|
||||
int CMS_set1_signers_certs(CMS_ContentInfo *cms, STACK_OF(X509) *certs,
|
||||
unsigned int flags);
|
||||
void CMS_SignerInfo_get0_algs(CMS_SignerInfo *si, EVP_PKEY **pk,
|
||||
X509 **signer, X509_ALGOR **pdig,
|
||||
X509_ALGOR **psig);
|
||||
ASN1_OCTET_STRING *CMS_SignerInfo_get0_signature(CMS_SignerInfo *si);
|
||||
int CMS_SignerInfo_sign(CMS_SignerInfo *si);
|
||||
int CMS_SignerInfo_verify(CMS_SignerInfo *si);
|
||||
int CMS_SignerInfo_verify_content(CMS_SignerInfo *si, BIO *chain);
|
||||
|
||||
int CMS_add_smimecap(CMS_SignerInfo *si, STACK_OF(X509_ALGOR) *algs);
|
||||
int CMS_add_simple_smimecap(STACK_OF(X509_ALGOR) **algs,
|
||||
int algnid, int keysize);
|
||||
int CMS_add_standard_smimecap(STACK_OF(X509_ALGOR) **smcap);
|
||||
|
||||
int CMS_signed_get_attr_count(const CMS_SignerInfo *si);
|
||||
int CMS_signed_get_attr_by_NID(const CMS_SignerInfo *si, int nid,
|
||||
int lastpos);
|
||||
int CMS_signed_get_attr_by_OBJ(const CMS_SignerInfo *si, const ASN1_OBJECT *obj,
|
||||
int lastpos);
|
||||
X509_ATTRIBUTE *CMS_signed_get_attr(const CMS_SignerInfo *si, int loc);
|
||||
X509_ATTRIBUTE *CMS_signed_delete_attr(CMS_SignerInfo *si, int loc);
|
||||
int CMS_signed_add1_attr(CMS_SignerInfo *si, X509_ATTRIBUTE *attr);
|
||||
int CMS_signed_add1_attr_by_OBJ(CMS_SignerInfo *si,
|
||||
const ASN1_OBJECT *obj, int type,
|
||||
const void *bytes, int len);
|
||||
int CMS_signed_add1_attr_by_NID(CMS_SignerInfo *si,
|
||||
int nid, int type,
|
||||
const void *bytes, int len);
|
||||
int CMS_signed_add1_attr_by_txt(CMS_SignerInfo *si,
|
||||
const char *attrname, int type,
|
||||
const void *bytes, int len);
|
||||
void *CMS_signed_get0_data_by_OBJ(const CMS_SignerInfo *si,
|
||||
const ASN1_OBJECT *oid,
|
||||
int lastpos, int type);
|
||||
|
||||
int CMS_unsigned_get_attr_count(const CMS_SignerInfo *si);
|
||||
int CMS_unsigned_get_attr_by_NID(const CMS_SignerInfo *si, int nid,
|
||||
int lastpos);
|
||||
int CMS_unsigned_get_attr_by_OBJ(const CMS_SignerInfo *si,
|
||||
const ASN1_OBJECT *obj, int lastpos);
|
||||
X509_ATTRIBUTE *CMS_unsigned_get_attr(const CMS_SignerInfo *si, int loc);
|
||||
X509_ATTRIBUTE *CMS_unsigned_delete_attr(CMS_SignerInfo *si, int loc);
|
||||
int CMS_unsigned_add1_attr(CMS_SignerInfo *si, X509_ATTRIBUTE *attr);
|
||||
int CMS_unsigned_add1_attr_by_OBJ(CMS_SignerInfo *si,
|
||||
const ASN1_OBJECT *obj, int type,
|
||||
const void *bytes, int len);
|
||||
int CMS_unsigned_add1_attr_by_NID(CMS_SignerInfo *si,
|
||||
int nid, int type,
|
||||
const void *bytes, int len);
|
||||
int CMS_unsigned_add1_attr_by_txt(CMS_SignerInfo *si,
|
||||
const char *attrname, int type,
|
||||
const void *bytes, int len);
|
||||
void *CMS_unsigned_get0_data_by_OBJ(CMS_SignerInfo *si, ASN1_OBJECT *oid,
|
||||
int lastpos, int type);
|
||||
|
||||
int CMS_get1_ReceiptRequest(CMS_SignerInfo *si, CMS_ReceiptRequest **prr);
|
||||
CMS_ReceiptRequest *CMS_ReceiptRequest_create0(
|
||||
unsigned char *id, int idlen, int allorfirst,
|
||||
STACK_OF(GENERAL_NAMES) *receiptList,
|
||||
STACK_OF(GENERAL_NAMES) *receiptsTo);
|
||||
CMS_ReceiptRequest *CMS_ReceiptRequest_create0_ex(
|
||||
unsigned char *id, int idlen, int allorfirst,
|
||||
STACK_OF(GENERAL_NAMES) *receiptList,
|
||||
STACK_OF(GENERAL_NAMES) *receiptsTo,
|
||||
OSSL_LIB_CTX *ctx);
|
||||
|
||||
int CMS_add1_ReceiptRequest(CMS_SignerInfo *si, CMS_ReceiptRequest *rr);
|
||||
void CMS_ReceiptRequest_get0_values(CMS_ReceiptRequest *rr,
|
||||
ASN1_STRING **pcid,
|
||||
int *pallorfirst,
|
||||
STACK_OF(GENERAL_NAMES) **plist,
|
||||
STACK_OF(GENERAL_NAMES) **prto);
|
||||
int CMS_RecipientInfo_kari_get0_alg(CMS_RecipientInfo *ri,
|
||||
X509_ALGOR **palg,
|
||||
ASN1_OCTET_STRING **pukm);
|
||||
STACK_OF(CMS_RecipientEncryptedKey)
|
||||
*CMS_RecipientInfo_kari_get0_reks(CMS_RecipientInfo *ri);
|
||||
|
||||
int CMS_RecipientInfo_kari_get0_orig_id(CMS_RecipientInfo *ri,
|
||||
X509_ALGOR **pubalg,
|
||||
ASN1_BIT_STRING **pubkey,
|
||||
ASN1_OCTET_STRING **keyid,
|
||||
X509_NAME **issuer,
|
||||
ASN1_INTEGER **sno);
|
||||
|
||||
int CMS_RecipientInfo_kari_orig_id_cmp(CMS_RecipientInfo *ri, X509 *cert);
|
||||
|
||||
int CMS_RecipientEncryptedKey_get0_id(CMS_RecipientEncryptedKey *rek,
|
||||
ASN1_OCTET_STRING **keyid,
|
||||
ASN1_GENERALIZEDTIME **tm,
|
||||
CMS_OtherKeyAttribute **other,
|
||||
X509_NAME **issuer, ASN1_INTEGER **sno);
|
||||
int CMS_RecipientEncryptedKey_cert_cmp(CMS_RecipientEncryptedKey *rek,
|
||||
X509 *cert);
|
||||
int CMS_RecipientInfo_kari_set0_pkey(CMS_RecipientInfo *ri, EVP_PKEY *pk);
|
||||
int CMS_RecipientInfo_kari_set0_pkey_and_peer(CMS_RecipientInfo *ri, EVP_PKEY *pk, X509 *peer);
|
||||
EVP_CIPHER_CTX *CMS_RecipientInfo_kari_get0_ctx(CMS_RecipientInfo *ri);
|
||||
int CMS_RecipientInfo_kari_decrypt(CMS_ContentInfo *cms,
|
||||
CMS_RecipientInfo *ri,
|
||||
CMS_RecipientEncryptedKey *rek);
|
||||
|
||||
int CMS_SharedInfo_encode(unsigned char **pder, X509_ALGOR *kekalg,
|
||||
ASN1_OCTET_STRING *ukm, int keylen);
|
||||
|
||||
/* Backward compatibility for spelling errors. */
|
||||
# define CMS_R_UNKNOWN_DIGEST_ALGORITM CMS_R_UNKNOWN_DIGEST_ALGORITHM
|
||||
# define CMS_R_UNSUPPORTED_RECPIENTINFO_TYPE \
|
||||
CMS_R_UNSUPPORTED_RECIPIENTINFO_TYPE
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
211
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/conf.h
generated
vendored
Normal file
211
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/conf.h
generated
vendored
Normal file
@@ -0,0 +1,211 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/conf.h.in
|
||||
*
|
||||
* Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_CONF_H
|
||||
# define OPENSSL_CONF_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_CONF_H
|
||||
# endif
|
||||
|
||||
# include <openssl/bio.h>
|
||||
# include <openssl/lhash.h>
|
||||
# include <openssl/safestack.h>
|
||||
# include <openssl/e_os2.h>
|
||||
# include <openssl/types.h>
|
||||
# include <openssl/conferr.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
typedef struct {
|
||||
char *section;
|
||||
char *name;
|
||||
char *value;
|
||||
} CONF_VALUE;
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(CONF_VALUE, CONF_VALUE, CONF_VALUE)
|
||||
#define sk_CONF_VALUE_num(sk) OPENSSL_sk_num(ossl_check_const_CONF_VALUE_sk_type(sk))
|
||||
#define sk_CONF_VALUE_value(sk, idx) ((CONF_VALUE *)OPENSSL_sk_value(ossl_check_const_CONF_VALUE_sk_type(sk), (idx)))
|
||||
#define sk_CONF_VALUE_new(cmp) ((STACK_OF(CONF_VALUE) *)OPENSSL_sk_new(ossl_check_CONF_VALUE_compfunc_type(cmp)))
|
||||
#define sk_CONF_VALUE_new_null() ((STACK_OF(CONF_VALUE) *)OPENSSL_sk_new_null())
|
||||
#define sk_CONF_VALUE_new_reserve(cmp, n) ((STACK_OF(CONF_VALUE) *)OPENSSL_sk_new_reserve(ossl_check_CONF_VALUE_compfunc_type(cmp), (n)))
|
||||
#define sk_CONF_VALUE_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_CONF_VALUE_sk_type(sk), (n))
|
||||
#define sk_CONF_VALUE_free(sk) OPENSSL_sk_free(ossl_check_CONF_VALUE_sk_type(sk))
|
||||
#define sk_CONF_VALUE_zero(sk) OPENSSL_sk_zero(ossl_check_CONF_VALUE_sk_type(sk))
|
||||
#define sk_CONF_VALUE_delete(sk, i) ((CONF_VALUE *)OPENSSL_sk_delete(ossl_check_CONF_VALUE_sk_type(sk), (i)))
|
||||
#define sk_CONF_VALUE_delete_ptr(sk, ptr) ((CONF_VALUE *)OPENSSL_sk_delete_ptr(ossl_check_CONF_VALUE_sk_type(sk), ossl_check_CONF_VALUE_type(ptr)))
|
||||
#define sk_CONF_VALUE_push(sk, ptr) OPENSSL_sk_push(ossl_check_CONF_VALUE_sk_type(sk), ossl_check_CONF_VALUE_type(ptr))
|
||||
#define sk_CONF_VALUE_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_CONF_VALUE_sk_type(sk), ossl_check_CONF_VALUE_type(ptr))
|
||||
#define sk_CONF_VALUE_pop(sk) ((CONF_VALUE *)OPENSSL_sk_pop(ossl_check_CONF_VALUE_sk_type(sk)))
|
||||
#define sk_CONF_VALUE_shift(sk) ((CONF_VALUE *)OPENSSL_sk_shift(ossl_check_CONF_VALUE_sk_type(sk)))
|
||||
#define sk_CONF_VALUE_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_CONF_VALUE_sk_type(sk),ossl_check_CONF_VALUE_freefunc_type(freefunc))
|
||||
#define sk_CONF_VALUE_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_CONF_VALUE_sk_type(sk), ossl_check_CONF_VALUE_type(ptr), (idx))
|
||||
#define sk_CONF_VALUE_set(sk, idx, ptr) ((CONF_VALUE *)OPENSSL_sk_set(ossl_check_CONF_VALUE_sk_type(sk), (idx), ossl_check_CONF_VALUE_type(ptr)))
|
||||
#define sk_CONF_VALUE_find(sk, ptr) OPENSSL_sk_find(ossl_check_CONF_VALUE_sk_type(sk), ossl_check_CONF_VALUE_type(ptr))
|
||||
#define sk_CONF_VALUE_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_CONF_VALUE_sk_type(sk), ossl_check_CONF_VALUE_type(ptr))
|
||||
#define sk_CONF_VALUE_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_CONF_VALUE_sk_type(sk), ossl_check_CONF_VALUE_type(ptr), pnum)
|
||||
#define sk_CONF_VALUE_sort(sk) OPENSSL_sk_sort(ossl_check_CONF_VALUE_sk_type(sk))
|
||||
#define sk_CONF_VALUE_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_CONF_VALUE_sk_type(sk))
|
||||
#define sk_CONF_VALUE_dup(sk) ((STACK_OF(CONF_VALUE) *)OPENSSL_sk_dup(ossl_check_const_CONF_VALUE_sk_type(sk)))
|
||||
#define sk_CONF_VALUE_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(CONF_VALUE) *)OPENSSL_sk_deep_copy(ossl_check_const_CONF_VALUE_sk_type(sk), ossl_check_CONF_VALUE_copyfunc_type(copyfunc), ossl_check_CONF_VALUE_freefunc_type(freefunc)))
|
||||
#define sk_CONF_VALUE_set_cmp_func(sk, cmp) ((sk_CONF_VALUE_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_CONF_VALUE_sk_type(sk), ossl_check_CONF_VALUE_compfunc_type(cmp)))
|
||||
DEFINE_LHASH_OF_INTERNAL(CONF_VALUE);
|
||||
#define lh_CONF_VALUE_new(hfn, cmp) ((LHASH_OF(CONF_VALUE) *)OPENSSL_LH_new(ossl_check_CONF_VALUE_lh_hashfunc_type(hfn), ossl_check_CONF_VALUE_lh_compfunc_type(cmp)))
|
||||
#define lh_CONF_VALUE_free(lh) OPENSSL_LH_free(ossl_check_CONF_VALUE_lh_type(lh))
|
||||
#define lh_CONF_VALUE_flush(lh) OPENSSL_LH_flush(ossl_check_CONF_VALUE_lh_type(lh))
|
||||
#define lh_CONF_VALUE_insert(lh, ptr) ((CONF_VALUE *)OPENSSL_LH_insert(ossl_check_CONF_VALUE_lh_type(lh), ossl_check_CONF_VALUE_lh_plain_type(ptr)))
|
||||
#define lh_CONF_VALUE_delete(lh, ptr) ((CONF_VALUE *)OPENSSL_LH_delete(ossl_check_CONF_VALUE_lh_type(lh), ossl_check_const_CONF_VALUE_lh_plain_type(ptr)))
|
||||
#define lh_CONF_VALUE_retrieve(lh, ptr) ((CONF_VALUE *)OPENSSL_LH_retrieve(ossl_check_CONF_VALUE_lh_type(lh), ossl_check_const_CONF_VALUE_lh_plain_type(ptr)))
|
||||
#define lh_CONF_VALUE_error(lh) OPENSSL_LH_error(ossl_check_CONF_VALUE_lh_type(lh))
|
||||
#define lh_CONF_VALUE_num_items(lh) OPENSSL_LH_num_items(ossl_check_CONF_VALUE_lh_type(lh))
|
||||
#define lh_CONF_VALUE_node_stats_bio(lh, out) OPENSSL_LH_node_stats_bio(ossl_check_const_CONF_VALUE_lh_type(lh), out)
|
||||
#define lh_CONF_VALUE_node_usage_stats_bio(lh, out) OPENSSL_LH_node_usage_stats_bio(ossl_check_const_CONF_VALUE_lh_type(lh), out)
|
||||
#define lh_CONF_VALUE_stats_bio(lh, out) OPENSSL_LH_stats_bio(ossl_check_const_CONF_VALUE_lh_type(lh), out)
|
||||
#define lh_CONF_VALUE_get_down_load(lh) OPENSSL_LH_get_down_load(ossl_check_CONF_VALUE_lh_type(lh))
|
||||
#define lh_CONF_VALUE_set_down_load(lh, dl) OPENSSL_LH_set_down_load(ossl_check_CONF_VALUE_lh_type(lh), dl)
|
||||
#define lh_CONF_VALUE_doall(lh, dfn) OPENSSL_LH_doall(ossl_check_CONF_VALUE_lh_type(lh), ossl_check_CONF_VALUE_lh_doallfunc_type(dfn))
|
||||
|
||||
|
||||
struct conf_st;
|
||||
struct conf_method_st;
|
||||
typedef struct conf_method_st CONF_METHOD;
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# include <openssl/conftypes.h>
|
||||
# endif
|
||||
|
||||
/* Module definitions */
|
||||
typedef struct conf_imodule_st CONF_IMODULE;
|
||||
typedef struct conf_module_st CONF_MODULE;
|
||||
|
||||
STACK_OF(CONF_MODULE);
|
||||
STACK_OF(CONF_IMODULE);
|
||||
|
||||
/* DSO module function typedefs */
|
||||
typedef int conf_init_func (CONF_IMODULE *md, const CONF *cnf);
|
||||
typedef void conf_finish_func (CONF_IMODULE *md);
|
||||
|
||||
# define CONF_MFLAGS_IGNORE_ERRORS 0x1
|
||||
# define CONF_MFLAGS_IGNORE_RETURN_CODES 0x2
|
||||
# define CONF_MFLAGS_SILENT 0x4
|
||||
# define CONF_MFLAGS_NO_DSO 0x8
|
||||
# define CONF_MFLAGS_IGNORE_MISSING_FILE 0x10
|
||||
# define CONF_MFLAGS_DEFAULT_SECTION 0x20
|
||||
|
||||
int CONF_set_default_method(CONF_METHOD *meth);
|
||||
void CONF_set_nconf(CONF *conf, LHASH_OF(CONF_VALUE) *hash);
|
||||
LHASH_OF(CONF_VALUE) *CONF_load(LHASH_OF(CONF_VALUE) *conf, const char *file,
|
||||
long *eline);
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
LHASH_OF(CONF_VALUE) *CONF_load_fp(LHASH_OF(CONF_VALUE) *conf, FILE *fp,
|
||||
long *eline);
|
||||
# endif
|
||||
LHASH_OF(CONF_VALUE) *CONF_load_bio(LHASH_OF(CONF_VALUE) *conf, BIO *bp,
|
||||
long *eline);
|
||||
STACK_OF(CONF_VALUE) *CONF_get_section(LHASH_OF(CONF_VALUE) *conf,
|
||||
const char *section);
|
||||
char *CONF_get_string(LHASH_OF(CONF_VALUE) *conf, const char *group,
|
||||
const char *name);
|
||||
long CONF_get_number(LHASH_OF(CONF_VALUE) *conf, const char *group,
|
||||
const char *name);
|
||||
void CONF_free(LHASH_OF(CONF_VALUE) *conf);
|
||||
#ifndef OPENSSL_NO_STDIO
|
||||
int CONF_dump_fp(LHASH_OF(CONF_VALUE) *conf, FILE *out);
|
||||
#endif
|
||||
int CONF_dump_bio(LHASH_OF(CONF_VALUE) *conf, BIO *out);
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
OSSL_DEPRECATEDIN_1_1_0 void OPENSSL_config(const char *config_name);
|
||||
#endif
|
||||
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# define OPENSSL_no_config() \
|
||||
OPENSSL_init_crypto(OPENSSL_INIT_NO_LOAD_CONFIG, NULL)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* New conf code. The semantics are different from the functions above. If
|
||||
* that wasn't the case, the above functions would have been replaced
|
||||
*/
|
||||
|
||||
CONF *NCONF_new_ex(OSSL_LIB_CTX *libctx, CONF_METHOD *meth);
|
||||
OSSL_LIB_CTX *NCONF_get0_libctx(const CONF *conf);
|
||||
CONF *NCONF_new(CONF_METHOD *meth);
|
||||
CONF_METHOD *NCONF_default(void);
|
||||
#ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0 CONF_METHOD *NCONF_WIN32(void);
|
||||
#endif
|
||||
void NCONF_free(CONF *conf);
|
||||
void NCONF_free_data(CONF *conf);
|
||||
|
||||
int NCONF_load(CONF *conf, const char *file, long *eline);
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
int NCONF_load_fp(CONF *conf, FILE *fp, long *eline);
|
||||
# endif
|
||||
int NCONF_load_bio(CONF *conf, BIO *bp, long *eline);
|
||||
STACK_OF(OPENSSL_CSTRING) *NCONF_get_section_names(const CONF *conf);
|
||||
STACK_OF(CONF_VALUE) *NCONF_get_section(const CONF *conf,
|
||||
const char *section);
|
||||
char *NCONF_get_string(const CONF *conf, const char *group, const char *name);
|
||||
int NCONF_get_number_e(const CONF *conf, const char *group, const char *name,
|
||||
long *result);
|
||||
#ifndef OPENSSL_NO_STDIO
|
||||
int NCONF_dump_fp(const CONF *conf, FILE *out);
|
||||
#endif
|
||||
int NCONF_dump_bio(const CONF *conf, BIO *out);
|
||||
|
||||
#define NCONF_get_number(c,g,n,r) NCONF_get_number_e(c,g,n,r)
|
||||
|
||||
/* Module functions */
|
||||
|
||||
int CONF_modules_load(const CONF *cnf, const char *appname,
|
||||
unsigned long flags);
|
||||
int CONF_modules_load_file_ex(OSSL_LIB_CTX *libctx, const char *filename,
|
||||
const char *appname, unsigned long flags);
|
||||
int CONF_modules_load_file(const char *filename, const char *appname,
|
||||
unsigned long flags);
|
||||
void CONF_modules_unload(int all);
|
||||
void CONF_modules_finish(void);
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# define CONF_modules_free() while(0) continue
|
||||
#endif
|
||||
int CONF_module_add(const char *name, conf_init_func *ifunc,
|
||||
conf_finish_func *ffunc);
|
||||
|
||||
const char *CONF_imodule_get_name(const CONF_IMODULE *md);
|
||||
const char *CONF_imodule_get_value(const CONF_IMODULE *md);
|
||||
void *CONF_imodule_get_usr_data(const CONF_IMODULE *md);
|
||||
void CONF_imodule_set_usr_data(CONF_IMODULE *md, void *usr_data);
|
||||
CONF_MODULE *CONF_imodule_get_module(const CONF_IMODULE *md);
|
||||
unsigned long CONF_imodule_get_flags(const CONF_IMODULE *md);
|
||||
void CONF_imodule_set_flags(CONF_IMODULE *md, unsigned long flags);
|
||||
void *CONF_module_get_usr_data(CONF_MODULE *pmod);
|
||||
void CONF_module_set_usr_data(CONF_MODULE *pmod, void *usr_data);
|
||||
|
||||
char *CONF_get1_default_config_file(void);
|
||||
|
||||
int CONF_parse_list(const char *list, int sep, int nospc,
|
||||
int (*list_cb) (const char *elem, int len, void *usr),
|
||||
void *arg);
|
||||
|
||||
void OPENSSL_load_builtin_modules(void);
|
||||
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
@@ -0,0 +1,131 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by configdata.pm from Configurations/common0.tmpl, Configurations/unix-Makefile.tmpl
|
||||
* via Makefile.in
|
||||
*
|
||||
* Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#ifndef OPENSSL_CONFIGURATION_H
|
||||
# define OPENSSL_CONFIGURATION_H
|
||||
# pragma once
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
# ifdef OPENSSL_ALGORITHM_DEFINES
|
||||
# error OPENSSL_ALGORITHM_DEFINES no longer supported
|
||||
# endif
|
||||
|
||||
/*
|
||||
* OpenSSL was configured with the following options:
|
||||
*/
|
||||
|
||||
# define OPENSSL_CONFIGURED_API 30000
|
||||
# ifndef OPENSSL_RAND_SEED_OS
|
||||
# define OPENSSL_RAND_SEED_OS
|
||||
# endif
|
||||
# ifndef OPENSSL_THREADS
|
||||
# define OPENSSL_THREADS
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_AFALGENG
|
||||
# define OPENSSL_NO_AFALGENG
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_ASAN
|
||||
# define OPENSSL_NO_ASAN
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_COMP
|
||||
# define OPENSSL_NO_COMP
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_CRYPTO_MDEBUG
|
||||
# define OPENSSL_NO_CRYPTO_MDEBUG
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_CRYPTO_MDEBUG_BACKTRACE
|
||||
# define OPENSSL_NO_CRYPTO_MDEBUG_BACKTRACE
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_EC_NISTP_64_GCC_128
|
||||
# define OPENSSL_NO_EC_NISTP_64_GCC_128
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_EGD
|
||||
# define OPENSSL_NO_EGD
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_EXTERNAL_TESTS
|
||||
# define OPENSSL_NO_EXTERNAL_TESTS
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_FUZZ_AFL
|
||||
# define OPENSSL_NO_FUZZ_AFL
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_FUZZ_LIBFUZZER
|
||||
# define OPENSSL_NO_FUZZ_LIBFUZZER
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_KTLS
|
||||
# define OPENSSL_NO_KTLS
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_LOADERENG
|
||||
# define OPENSSL_NO_LOADERENG
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_MD2
|
||||
# define OPENSSL_NO_MD2
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_MSAN
|
||||
# define OPENSSL_NO_MSAN
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_RC5
|
||||
# define OPENSSL_NO_RC5
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_SCTP
|
||||
# define OPENSSL_NO_SCTP
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_SSL3
|
||||
# define OPENSSL_NO_SSL3
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_SSL3_METHOD
|
||||
# define OPENSSL_NO_SSL3_METHOD
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_TRACE
|
||||
# define OPENSSL_NO_TRACE
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_UBSAN
|
||||
# define OPENSSL_NO_UBSAN
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_UNIT_TEST
|
||||
# define OPENSSL_NO_UNIT_TEST
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_UPLINK
|
||||
# define OPENSSL_NO_UPLINK
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_WEAK_SSL_CIPHERS
|
||||
# define OPENSSL_NO_WEAK_SSL_CIPHERS
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_DYNAMIC_ENGINE
|
||||
# define OPENSSL_NO_DYNAMIC_ENGINE
|
||||
# endif
|
||||
|
||||
|
||||
/* Generate 80386 code? */
|
||||
# undef I386_ONLY
|
||||
|
||||
/*
|
||||
* The following are cipher-specific, but are part of the public API.
|
||||
*/
|
||||
# if !defined(OPENSSL_SYS_UEFI)
|
||||
# define BN_LLONG
|
||||
/* Only one for the following should be defined */
|
||||
# undef SIXTY_FOUR_BIT_LONG
|
||||
# undef SIXTY_FOUR_BIT
|
||||
# define THIRTY_TWO_BIT
|
||||
# endif
|
||||
|
||||
# define RC4_INT unsigned int
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
|
||||
#endif /* OPENSSL_CONFIGURATION_H */
|
||||
227
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/crmf.h
generated
vendored
Normal file
227
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/crmf.h
generated
vendored
Normal file
@@ -0,0 +1,227 @@
|
||||
/*-
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/crmf.h.in
|
||||
*
|
||||
* Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
* Copyright Nokia 2007-2019
|
||||
* Copyright Siemens AG 2015-2019
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*
|
||||
* CRMF (RFC 4211) implementation by M. Peylo, M. Viljanen, and D. von Oheimb.
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_CRMF_H
|
||||
# define OPENSSL_CRMF_H
|
||||
|
||||
# include <openssl/opensslconf.h>
|
||||
|
||||
# ifndef OPENSSL_NO_CRMF
|
||||
# include <openssl/opensslv.h>
|
||||
# include <openssl/safestack.h>
|
||||
# include <openssl/crmferr.h>
|
||||
# include <openssl/x509v3.h> /* for GENERAL_NAME etc. */
|
||||
|
||||
/* explicit #includes not strictly needed since implied by the above: */
|
||||
# include <openssl/types.h>
|
||||
# include <openssl/x509.h>
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
# define OSSL_CRMF_POPOPRIVKEY_THISMESSAGE 0
|
||||
# define OSSL_CRMF_POPOPRIVKEY_SUBSEQUENTMESSAGE 1
|
||||
# define OSSL_CRMF_POPOPRIVKEY_DHMAC 2
|
||||
# define OSSL_CRMF_POPOPRIVKEY_AGREEMAC 3
|
||||
# define OSSL_CRMF_POPOPRIVKEY_ENCRYPTEDKEY 4
|
||||
|
||||
# define OSSL_CRMF_SUBSEQUENTMESSAGE_ENCRCERT 0
|
||||
# define OSSL_CRMF_SUBSEQUENTMESSAGE_CHALLENGERESP 1
|
||||
|
||||
typedef struct ossl_crmf_encryptedvalue_st OSSL_CRMF_ENCRYPTEDVALUE;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CRMF_ENCRYPTEDVALUE)
|
||||
typedef struct ossl_crmf_msg_st OSSL_CRMF_MSG;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CRMF_MSG)
|
||||
DECLARE_ASN1_DUP_FUNCTION(OSSL_CRMF_MSG)
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OSSL_CRMF_MSG, OSSL_CRMF_MSG, OSSL_CRMF_MSG)
|
||||
#define sk_OSSL_CRMF_MSG_num(sk) OPENSSL_sk_num(ossl_check_const_OSSL_CRMF_MSG_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_MSG_value(sk, idx) ((OSSL_CRMF_MSG *)OPENSSL_sk_value(ossl_check_const_OSSL_CRMF_MSG_sk_type(sk), (idx)))
|
||||
#define sk_OSSL_CRMF_MSG_new(cmp) ((STACK_OF(OSSL_CRMF_MSG) *)OPENSSL_sk_new(ossl_check_OSSL_CRMF_MSG_compfunc_type(cmp)))
|
||||
#define sk_OSSL_CRMF_MSG_new_null() ((STACK_OF(OSSL_CRMF_MSG) *)OPENSSL_sk_new_null())
|
||||
#define sk_OSSL_CRMF_MSG_new_reserve(cmp, n) ((STACK_OF(OSSL_CRMF_MSG) *)OPENSSL_sk_new_reserve(ossl_check_OSSL_CRMF_MSG_compfunc_type(cmp), (n)))
|
||||
#define sk_OSSL_CRMF_MSG_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OSSL_CRMF_MSG_sk_type(sk), (n))
|
||||
#define sk_OSSL_CRMF_MSG_free(sk) OPENSSL_sk_free(ossl_check_OSSL_CRMF_MSG_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_MSG_zero(sk) OPENSSL_sk_zero(ossl_check_OSSL_CRMF_MSG_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_MSG_delete(sk, i) ((OSSL_CRMF_MSG *)OPENSSL_sk_delete(ossl_check_OSSL_CRMF_MSG_sk_type(sk), (i)))
|
||||
#define sk_OSSL_CRMF_MSG_delete_ptr(sk, ptr) ((OSSL_CRMF_MSG *)OPENSSL_sk_delete_ptr(ossl_check_OSSL_CRMF_MSG_sk_type(sk), ossl_check_OSSL_CRMF_MSG_type(ptr)))
|
||||
#define sk_OSSL_CRMF_MSG_push(sk, ptr) OPENSSL_sk_push(ossl_check_OSSL_CRMF_MSG_sk_type(sk), ossl_check_OSSL_CRMF_MSG_type(ptr))
|
||||
#define sk_OSSL_CRMF_MSG_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OSSL_CRMF_MSG_sk_type(sk), ossl_check_OSSL_CRMF_MSG_type(ptr))
|
||||
#define sk_OSSL_CRMF_MSG_pop(sk) ((OSSL_CRMF_MSG *)OPENSSL_sk_pop(ossl_check_OSSL_CRMF_MSG_sk_type(sk)))
|
||||
#define sk_OSSL_CRMF_MSG_shift(sk) ((OSSL_CRMF_MSG *)OPENSSL_sk_shift(ossl_check_OSSL_CRMF_MSG_sk_type(sk)))
|
||||
#define sk_OSSL_CRMF_MSG_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OSSL_CRMF_MSG_sk_type(sk),ossl_check_OSSL_CRMF_MSG_freefunc_type(freefunc))
|
||||
#define sk_OSSL_CRMF_MSG_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OSSL_CRMF_MSG_sk_type(sk), ossl_check_OSSL_CRMF_MSG_type(ptr), (idx))
|
||||
#define sk_OSSL_CRMF_MSG_set(sk, idx, ptr) ((OSSL_CRMF_MSG *)OPENSSL_sk_set(ossl_check_OSSL_CRMF_MSG_sk_type(sk), (idx), ossl_check_OSSL_CRMF_MSG_type(ptr)))
|
||||
#define sk_OSSL_CRMF_MSG_find(sk, ptr) OPENSSL_sk_find(ossl_check_OSSL_CRMF_MSG_sk_type(sk), ossl_check_OSSL_CRMF_MSG_type(ptr))
|
||||
#define sk_OSSL_CRMF_MSG_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OSSL_CRMF_MSG_sk_type(sk), ossl_check_OSSL_CRMF_MSG_type(ptr))
|
||||
#define sk_OSSL_CRMF_MSG_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OSSL_CRMF_MSG_sk_type(sk), ossl_check_OSSL_CRMF_MSG_type(ptr), pnum)
|
||||
#define sk_OSSL_CRMF_MSG_sort(sk) OPENSSL_sk_sort(ossl_check_OSSL_CRMF_MSG_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_MSG_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OSSL_CRMF_MSG_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_MSG_dup(sk) ((STACK_OF(OSSL_CRMF_MSG) *)OPENSSL_sk_dup(ossl_check_const_OSSL_CRMF_MSG_sk_type(sk)))
|
||||
#define sk_OSSL_CRMF_MSG_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OSSL_CRMF_MSG) *)OPENSSL_sk_deep_copy(ossl_check_const_OSSL_CRMF_MSG_sk_type(sk), ossl_check_OSSL_CRMF_MSG_copyfunc_type(copyfunc), ossl_check_OSSL_CRMF_MSG_freefunc_type(freefunc)))
|
||||
#define sk_OSSL_CRMF_MSG_set_cmp_func(sk, cmp) ((sk_OSSL_CRMF_MSG_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OSSL_CRMF_MSG_sk_type(sk), ossl_check_OSSL_CRMF_MSG_compfunc_type(cmp)))
|
||||
|
||||
typedef struct ossl_crmf_attributetypeandvalue_st OSSL_CRMF_ATTRIBUTETYPEANDVALUE;
|
||||
typedef struct ossl_crmf_pbmparameter_st OSSL_CRMF_PBMPARAMETER;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CRMF_PBMPARAMETER)
|
||||
typedef struct ossl_crmf_poposigningkey_st OSSL_CRMF_POPOSIGNINGKEY;
|
||||
typedef struct ossl_crmf_certrequest_st OSSL_CRMF_CERTREQUEST;
|
||||
typedef struct ossl_crmf_certid_st OSSL_CRMF_CERTID;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CRMF_CERTID)
|
||||
DECLARE_ASN1_DUP_FUNCTION(OSSL_CRMF_CERTID)
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OSSL_CRMF_CERTID, OSSL_CRMF_CERTID, OSSL_CRMF_CERTID)
|
||||
#define sk_OSSL_CRMF_CERTID_num(sk) OPENSSL_sk_num(ossl_check_const_OSSL_CRMF_CERTID_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_CERTID_value(sk, idx) ((OSSL_CRMF_CERTID *)OPENSSL_sk_value(ossl_check_const_OSSL_CRMF_CERTID_sk_type(sk), (idx)))
|
||||
#define sk_OSSL_CRMF_CERTID_new(cmp) ((STACK_OF(OSSL_CRMF_CERTID) *)OPENSSL_sk_new(ossl_check_OSSL_CRMF_CERTID_compfunc_type(cmp)))
|
||||
#define sk_OSSL_CRMF_CERTID_new_null() ((STACK_OF(OSSL_CRMF_CERTID) *)OPENSSL_sk_new_null())
|
||||
#define sk_OSSL_CRMF_CERTID_new_reserve(cmp, n) ((STACK_OF(OSSL_CRMF_CERTID) *)OPENSSL_sk_new_reserve(ossl_check_OSSL_CRMF_CERTID_compfunc_type(cmp), (n)))
|
||||
#define sk_OSSL_CRMF_CERTID_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), (n))
|
||||
#define sk_OSSL_CRMF_CERTID_free(sk) OPENSSL_sk_free(ossl_check_OSSL_CRMF_CERTID_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_CERTID_zero(sk) OPENSSL_sk_zero(ossl_check_OSSL_CRMF_CERTID_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_CERTID_delete(sk, i) ((OSSL_CRMF_CERTID *)OPENSSL_sk_delete(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), (i)))
|
||||
#define sk_OSSL_CRMF_CERTID_delete_ptr(sk, ptr) ((OSSL_CRMF_CERTID *)OPENSSL_sk_delete_ptr(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), ossl_check_OSSL_CRMF_CERTID_type(ptr)))
|
||||
#define sk_OSSL_CRMF_CERTID_push(sk, ptr) OPENSSL_sk_push(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), ossl_check_OSSL_CRMF_CERTID_type(ptr))
|
||||
#define sk_OSSL_CRMF_CERTID_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), ossl_check_OSSL_CRMF_CERTID_type(ptr))
|
||||
#define sk_OSSL_CRMF_CERTID_pop(sk) ((OSSL_CRMF_CERTID *)OPENSSL_sk_pop(ossl_check_OSSL_CRMF_CERTID_sk_type(sk)))
|
||||
#define sk_OSSL_CRMF_CERTID_shift(sk) ((OSSL_CRMF_CERTID *)OPENSSL_sk_shift(ossl_check_OSSL_CRMF_CERTID_sk_type(sk)))
|
||||
#define sk_OSSL_CRMF_CERTID_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OSSL_CRMF_CERTID_sk_type(sk),ossl_check_OSSL_CRMF_CERTID_freefunc_type(freefunc))
|
||||
#define sk_OSSL_CRMF_CERTID_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), ossl_check_OSSL_CRMF_CERTID_type(ptr), (idx))
|
||||
#define sk_OSSL_CRMF_CERTID_set(sk, idx, ptr) ((OSSL_CRMF_CERTID *)OPENSSL_sk_set(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), (idx), ossl_check_OSSL_CRMF_CERTID_type(ptr)))
|
||||
#define sk_OSSL_CRMF_CERTID_find(sk, ptr) OPENSSL_sk_find(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), ossl_check_OSSL_CRMF_CERTID_type(ptr))
|
||||
#define sk_OSSL_CRMF_CERTID_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), ossl_check_OSSL_CRMF_CERTID_type(ptr))
|
||||
#define sk_OSSL_CRMF_CERTID_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), ossl_check_OSSL_CRMF_CERTID_type(ptr), pnum)
|
||||
#define sk_OSSL_CRMF_CERTID_sort(sk) OPENSSL_sk_sort(ossl_check_OSSL_CRMF_CERTID_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_CERTID_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OSSL_CRMF_CERTID_sk_type(sk))
|
||||
#define sk_OSSL_CRMF_CERTID_dup(sk) ((STACK_OF(OSSL_CRMF_CERTID) *)OPENSSL_sk_dup(ossl_check_const_OSSL_CRMF_CERTID_sk_type(sk)))
|
||||
#define sk_OSSL_CRMF_CERTID_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OSSL_CRMF_CERTID) *)OPENSSL_sk_deep_copy(ossl_check_const_OSSL_CRMF_CERTID_sk_type(sk), ossl_check_OSSL_CRMF_CERTID_copyfunc_type(copyfunc), ossl_check_OSSL_CRMF_CERTID_freefunc_type(freefunc)))
|
||||
#define sk_OSSL_CRMF_CERTID_set_cmp_func(sk, cmp) ((sk_OSSL_CRMF_CERTID_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OSSL_CRMF_CERTID_sk_type(sk), ossl_check_OSSL_CRMF_CERTID_compfunc_type(cmp)))
|
||||
|
||||
|
||||
typedef struct ossl_crmf_pkipublicationinfo_st OSSL_CRMF_PKIPUBLICATIONINFO;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CRMF_PKIPUBLICATIONINFO)
|
||||
typedef struct ossl_crmf_singlepubinfo_st OSSL_CRMF_SINGLEPUBINFO;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CRMF_SINGLEPUBINFO)
|
||||
typedef struct ossl_crmf_certtemplate_st OSSL_CRMF_CERTTEMPLATE;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CRMF_CERTTEMPLATE)
|
||||
typedef STACK_OF(OSSL_CRMF_MSG) OSSL_CRMF_MSGS;
|
||||
DECLARE_ASN1_FUNCTIONS(OSSL_CRMF_MSGS)
|
||||
|
||||
typedef struct ossl_crmf_optionalvalidity_st OSSL_CRMF_OPTIONALVALIDITY;
|
||||
|
||||
/* crmf_pbm.c */
|
||||
OSSL_CRMF_PBMPARAMETER *OSSL_CRMF_pbmp_new(OSSL_LIB_CTX *libctx, size_t slen,
|
||||
int owfnid, size_t itercnt,
|
||||
int macnid);
|
||||
int OSSL_CRMF_pbm_new(OSSL_LIB_CTX *libctx, const char *propq,
|
||||
const OSSL_CRMF_PBMPARAMETER *pbmp,
|
||||
const unsigned char *msg, size_t msglen,
|
||||
const unsigned char *sec, size_t seclen,
|
||||
unsigned char **mac, size_t *maclen);
|
||||
|
||||
/* crmf_lib.c */
|
||||
int OSSL_CRMF_MSG_set1_regCtrl_regToken(OSSL_CRMF_MSG *msg,
|
||||
const ASN1_UTF8STRING *tok);
|
||||
ASN1_UTF8STRING
|
||||
*OSSL_CRMF_MSG_get0_regCtrl_regToken(const OSSL_CRMF_MSG *msg);
|
||||
int OSSL_CRMF_MSG_set1_regCtrl_authenticator(OSSL_CRMF_MSG *msg,
|
||||
const ASN1_UTF8STRING *auth);
|
||||
ASN1_UTF8STRING
|
||||
*OSSL_CRMF_MSG_get0_regCtrl_authenticator(const OSSL_CRMF_MSG *msg);
|
||||
int
|
||||
OSSL_CRMF_MSG_PKIPublicationInfo_push0_SinglePubInfo(OSSL_CRMF_PKIPUBLICATIONINFO *pi,
|
||||
OSSL_CRMF_SINGLEPUBINFO *spi);
|
||||
# define OSSL_CRMF_PUB_METHOD_DONTCARE 0
|
||||
# define OSSL_CRMF_PUB_METHOD_X500 1
|
||||
# define OSSL_CRMF_PUB_METHOD_WEB 2
|
||||
# define OSSL_CRMF_PUB_METHOD_LDAP 3
|
||||
int OSSL_CRMF_MSG_set0_SinglePubInfo(OSSL_CRMF_SINGLEPUBINFO *spi,
|
||||
int method, GENERAL_NAME *nm);
|
||||
# define OSSL_CRMF_PUB_ACTION_DONTPUBLISH 0
|
||||
# define OSSL_CRMF_PUB_ACTION_PLEASEPUBLISH 1
|
||||
int OSSL_CRMF_MSG_set_PKIPublicationInfo_action(OSSL_CRMF_PKIPUBLICATIONINFO *pi,
|
||||
int action);
|
||||
int OSSL_CRMF_MSG_set1_regCtrl_pkiPublicationInfo(OSSL_CRMF_MSG *msg,
|
||||
const OSSL_CRMF_PKIPUBLICATIONINFO *pi);
|
||||
OSSL_CRMF_PKIPUBLICATIONINFO
|
||||
*OSSL_CRMF_MSG_get0_regCtrl_pkiPublicationInfo(const OSSL_CRMF_MSG *msg);
|
||||
int OSSL_CRMF_MSG_set1_regCtrl_protocolEncrKey(OSSL_CRMF_MSG *msg,
|
||||
const X509_PUBKEY *pubkey);
|
||||
X509_PUBKEY
|
||||
*OSSL_CRMF_MSG_get0_regCtrl_protocolEncrKey(const OSSL_CRMF_MSG *msg);
|
||||
int OSSL_CRMF_MSG_set1_regCtrl_oldCertID(OSSL_CRMF_MSG *msg,
|
||||
const OSSL_CRMF_CERTID *cid);
|
||||
OSSL_CRMF_CERTID
|
||||
*OSSL_CRMF_MSG_get0_regCtrl_oldCertID(const OSSL_CRMF_MSG *msg);
|
||||
OSSL_CRMF_CERTID *OSSL_CRMF_CERTID_gen(const X509_NAME *issuer,
|
||||
const ASN1_INTEGER *serial);
|
||||
|
||||
int OSSL_CRMF_MSG_set1_regInfo_utf8Pairs(OSSL_CRMF_MSG *msg,
|
||||
const ASN1_UTF8STRING *utf8pairs);
|
||||
ASN1_UTF8STRING
|
||||
*OSSL_CRMF_MSG_get0_regInfo_utf8Pairs(const OSSL_CRMF_MSG *msg);
|
||||
int OSSL_CRMF_MSG_set1_regInfo_certReq(OSSL_CRMF_MSG *msg,
|
||||
const OSSL_CRMF_CERTREQUEST *cr);
|
||||
OSSL_CRMF_CERTREQUEST
|
||||
*OSSL_CRMF_MSG_get0_regInfo_certReq(const OSSL_CRMF_MSG *msg);
|
||||
|
||||
int OSSL_CRMF_MSG_set0_validity(OSSL_CRMF_MSG *crm,
|
||||
ASN1_TIME *notBefore, ASN1_TIME *notAfter);
|
||||
int OSSL_CRMF_MSG_set_certReqId(OSSL_CRMF_MSG *crm, int rid);
|
||||
int OSSL_CRMF_MSG_get_certReqId(const OSSL_CRMF_MSG *crm);
|
||||
int OSSL_CRMF_MSG_set0_extensions(OSSL_CRMF_MSG *crm, X509_EXTENSIONS *exts);
|
||||
|
||||
int OSSL_CRMF_MSG_push0_extension(OSSL_CRMF_MSG *crm, X509_EXTENSION *ext);
|
||||
# define OSSL_CRMF_POPO_NONE -1
|
||||
# define OSSL_CRMF_POPO_RAVERIFIED 0
|
||||
# define OSSL_CRMF_POPO_SIGNATURE 1
|
||||
# define OSSL_CRMF_POPO_KEYENC 2
|
||||
# define OSSL_CRMF_POPO_KEYAGREE 3
|
||||
int OSSL_CRMF_MSG_create_popo(int meth, OSSL_CRMF_MSG *crm,
|
||||
EVP_PKEY *pkey, const EVP_MD *digest,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
int OSSL_CRMF_MSGS_verify_popo(const OSSL_CRMF_MSGS *reqs,
|
||||
int rid, int acceptRAVerified,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
OSSL_CRMF_CERTTEMPLATE *OSSL_CRMF_MSG_get0_tmpl(const OSSL_CRMF_MSG *crm);
|
||||
const ASN1_INTEGER
|
||||
*OSSL_CRMF_CERTTEMPLATE_get0_serialNumber(const OSSL_CRMF_CERTTEMPLATE *tmpl);
|
||||
const X509_NAME
|
||||
*OSSL_CRMF_CERTTEMPLATE_get0_subject(const OSSL_CRMF_CERTTEMPLATE *tmpl);
|
||||
const X509_NAME
|
||||
*OSSL_CRMF_CERTTEMPLATE_get0_issuer(const OSSL_CRMF_CERTTEMPLATE *tmpl);
|
||||
X509_EXTENSIONS
|
||||
*OSSL_CRMF_CERTTEMPLATE_get0_extensions(const OSSL_CRMF_CERTTEMPLATE *tmpl);
|
||||
const X509_NAME
|
||||
*OSSL_CRMF_CERTID_get0_issuer(const OSSL_CRMF_CERTID *cid);
|
||||
const ASN1_INTEGER
|
||||
*OSSL_CRMF_CERTID_get0_serialNumber(const OSSL_CRMF_CERTID *cid);
|
||||
int OSSL_CRMF_CERTTEMPLATE_fill(OSSL_CRMF_CERTTEMPLATE *tmpl,
|
||||
EVP_PKEY *pubkey,
|
||||
const X509_NAME *subject,
|
||||
const X509_NAME *issuer,
|
||||
const ASN1_INTEGER *serial);
|
||||
X509
|
||||
*OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert(const OSSL_CRMF_ENCRYPTEDVALUE *ecert,
|
||||
OSSL_LIB_CTX *libctx, const char *propq,
|
||||
EVP_PKEY *pkey);
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
# endif /* !defined(OPENSSL_NO_CRMF) */
|
||||
#endif /* !defined(OPENSSL_CRMF_H) */
|
||||
558
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/crypto.h
generated
vendored
Normal file
558
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/crypto.h
generated
vendored
Normal file
@@ -0,0 +1,558 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/crypto.h.in
|
||||
*
|
||||
* Copyright 1995-2022 The OpenSSL Project Authors. All Rights Reserved.
|
||||
* Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_CRYPTO_H
|
||||
# define OPENSSL_CRYPTO_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_CRYPTO_H
|
||||
# endif
|
||||
|
||||
# include <stdlib.h>
|
||||
# include <time.h>
|
||||
|
||||
# include <openssl/e_os2.h>
|
||||
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
# include <stdio.h>
|
||||
# endif
|
||||
|
||||
# include <openssl/safestack.h>
|
||||
# include <openssl/opensslv.h>
|
||||
# include <openssl/types.h>
|
||||
# include <openssl/opensslconf.h>
|
||||
# include <openssl/cryptoerr.h>
|
||||
# include <openssl/core.h>
|
||||
|
||||
# ifdef CHARSET_EBCDIC
|
||||
# include <openssl/ebcdic.h>
|
||||
# endif
|
||||
|
||||
/*
|
||||
* Resolve problems on some operating systems with symbol names that clash
|
||||
* one way or another
|
||||
*/
|
||||
# include <openssl/symhacks.h>
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# include <openssl/opensslv.h>
|
||||
# endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# define SSLeay OpenSSL_version_num
|
||||
# define SSLeay_version OpenSSL_version
|
||||
# define SSLEAY_VERSION_NUMBER OPENSSL_VERSION_NUMBER
|
||||
# define SSLEAY_VERSION OPENSSL_VERSION
|
||||
# define SSLEAY_CFLAGS OPENSSL_CFLAGS
|
||||
# define SSLEAY_BUILT_ON OPENSSL_BUILT_ON
|
||||
# define SSLEAY_PLATFORM OPENSSL_PLATFORM
|
||||
# define SSLEAY_DIR OPENSSL_DIR
|
||||
|
||||
/*
|
||||
* Old type for allocating dynamic locks. No longer used. Use the new thread
|
||||
* API instead.
|
||||
*/
|
||||
typedef struct {
|
||||
int dummy;
|
||||
} CRYPTO_dynlock;
|
||||
|
||||
# endif /* OPENSSL_NO_DEPRECATED_1_1_0 */
|
||||
|
||||
typedef void CRYPTO_RWLOCK;
|
||||
|
||||
CRYPTO_RWLOCK *CRYPTO_THREAD_lock_new(void);
|
||||
__owur int CRYPTO_THREAD_read_lock(CRYPTO_RWLOCK *lock);
|
||||
__owur int CRYPTO_THREAD_write_lock(CRYPTO_RWLOCK *lock);
|
||||
int CRYPTO_THREAD_unlock(CRYPTO_RWLOCK *lock);
|
||||
void CRYPTO_THREAD_lock_free(CRYPTO_RWLOCK *lock);
|
||||
|
||||
int CRYPTO_atomic_add(int *val, int amount, int *ret, CRYPTO_RWLOCK *lock);
|
||||
int CRYPTO_atomic_or(uint64_t *val, uint64_t op, uint64_t *ret,
|
||||
CRYPTO_RWLOCK *lock);
|
||||
int CRYPTO_atomic_load(uint64_t *val, uint64_t *ret, CRYPTO_RWLOCK *lock);
|
||||
|
||||
/* No longer needed, so this is a no-op */
|
||||
#define OPENSSL_malloc_init() while(0) continue
|
||||
|
||||
# define OPENSSL_malloc(num) \
|
||||
CRYPTO_malloc(num, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_zalloc(num) \
|
||||
CRYPTO_zalloc(num, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_realloc(addr, num) \
|
||||
CRYPTO_realloc(addr, num, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_clear_realloc(addr, old_num, num) \
|
||||
CRYPTO_clear_realloc(addr, old_num, num, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_clear_free(addr, num) \
|
||||
CRYPTO_clear_free(addr, num, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_free(addr) \
|
||||
CRYPTO_free(addr, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_memdup(str, s) \
|
||||
CRYPTO_memdup((str), s, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_strdup(str) \
|
||||
CRYPTO_strdup(str, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_strndup(str, n) \
|
||||
CRYPTO_strndup(str, n, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_secure_malloc(num) \
|
||||
CRYPTO_secure_malloc(num, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_secure_zalloc(num) \
|
||||
CRYPTO_secure_zalloc(num, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_secure_free(addr) \
|
||||
CRYPTO_secure_free(addr, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_secure_clear_free(addr, num) \
|
||||
CRYPTO_secure_clear_free(addr, num, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_secure_actual_size(ptr) \
|
||||
CRYPTO_secure_actual_size(ptr)
|
||||
|
||||
size_t OPENSSL_strlcpy(char *dst, const char *src, size_t siz);
|
||||
size_t OPENSSL_strlcat(char *dst, const char *src, size_t siz);
|
||||
size_t OPENSSL_strnlen(const char *str, size_t maxlen);
|
||||
int OPENSSL_buf2hexstr_ex(char *str, size_t str_n, size_t *strlength,
|
||||
const unsigned char *buf, size_t buflen,
|
||||
const char sep);
|
||||
char *OPENSSL_buf2hexstr(const unsigned char *buf, long buflen);
|
||||
int OPENSSL_hexstr2buf_ex(unsigned char *buf, size_t buf_n, size_t *buflen,
|
||||
const char *str, const char sep);
|
||||
unsigned char *OPENSSL_hexstr2buf(const char *str, long *buflen);
|
||||
int OPENSSL_hexchar2int(unsigned char c);
|
||||
int OPENSSL_strcasecmp(const char *s1, const char *s2);
|
||||
int OPENSSL_strncasecmp(const char *s1, const char *s2, size_t n);
|
||||
|
||||
# define OPENSSL_MALLOC_MAX_NELEMS(type) (((1U<<(sizeof(int)*8-1))-1)/sizeof(type))
|
||||
|
||||
/*
|
||||
* These functions return the values of OPENSSL_VERSION_MAJOR,
|
||||
* OPENSSL_VERSION_MINOR, OPENSSL_VERSION_PATCH, OPENSSL_VERSION_PRE_RELEASE
|
||||
* and OPENSSL_VERSION_BUILD_METADATA, respectively.
|
||||
*/
|
||||
unsigned int OPENSSL_version_major(void);
|
||||
unsigned int OPENSSL_version_minor(void);
|
||||
unsigned int OPENSSL_version_patch(void);
|
||||
const char *OPENSSL_version_pre_release(void);
|
||||
const char *OPENSSL_version_build_metadata(void);
|
||||
|
||||
unsigned long OpenSSL_version_num(void);
|
||||
const char *OpenSSL_version(int type);
|
||||
# define OPENSSL_VERSION 0
|
||||
# define OPENSSL_CFLAGS 1
|
||||
# define OPENSSL_BUILT_ON 2
|
||||
# define OPENSSL_PLATFORM 3
|
||||
# define OPENSSL_DIR 4
|
||||
# define OPENSSL_ENGINES_DIR 5
|
||||
# define OPENSSL_VERSION_STRING 6
|
||||
# define OPENSSL_FULL_VERSION_STRING 7
|
||||
# define OPENSSL_MODULES_DIR 8
|
||||
# define OPENSSL_CPU_INFO 9
|
||||
|
||||
const char *OPENSSL_info(int type);
|
||||
/*
|
||||
* The series starts at 1001 to avoid confusion with the OpenSSL_version
|
||||
* types.
|
||||
*/
|
||||
# define OPENSSL_INFO_CONFIG_DIR 1001
|
||||
# define OPENSSL_INFO_ENGINES_DIR 1002
|
||||
# define OPENSSL_INFO_MODULES_DIR 1003
|
||||
# define OPENSSL_INFO_DSO_EXTENSION 1004
|
||||
# define OPENSSL_INFO_DIR_FILENAME_SEPARATOR 1005
|
||||
# define OPENSSL_INFO_LIST_SEPARATOR 1006
|
||||
# define OPENSSL_INFO_SEED_SOURCE 1007
|
||||
# define OPENSSL_INFO_CPU_SETTINGS 1008
|
||||
|
||||
int OPENSSL_issetugid(void);
|
||||
|
||||
struct crypto_ex_data_st {
|
||||
OSSL_LIB_CTX *ctx;
|
||||
STACK_OF(void) *sk;
|
||||
};
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(void, void, void)
|
||||
#define sk_void_num(sk) OPENSSL_sk_num(ossl_check_const_void_sk_type(sk))
|
||||
#define sk_void_value(sk, idx) ((void *)OPENSSL_sk_value(ossl_check_const_void_sk_type(sk), (idx)))
|
||||
#define sk_void_new(cmp) ((STACK_OF(void) *)OPENSSL_sk_new(ossl_check_void_compfunc_type(cmp)))
|
||||
#define sk_void_new_null() ((STACK_OF(void) *)OPENSSL_sk_new_null())
|
||||
#define sk_void_new_reserve(cmp, n) ((STACK_OF(void) *)OPENSSL_sk_new_reserve(ossl_check_void_compfunc_type(cmp), (n)))
|
||||
#define sk_void_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_void_sk_type(sk), (n))
|
||||
#define sk_void_free(sk) OPENSSL_sk_free(ossl_check_void_sk_type(sk))
|
||||
#define sk_void_zero(sk) OPENSSL_sk_zero(ossl_check_void_sk_type(sk))
|
||||
#define sk_void_delete(sk, i) ((void *)OPENSSL_sk_delete(ossl_check_void_sk_type(sk), (i)))
|
||||
#define sk_void_delete_ptr(sk, ptr) ((void *)OPENSSL_sk_delete_ptr(ossl_check_void_sk_type(sk), ossl_check_void_type(ptr)))
|
||||
#define sk_void_push(sk, ptr) OPENSSL_sk_push(ossl_check_void_sk_type(sk), ossl_check_void_type(ptr))
|
||||
#define sk_void_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_void_sk_type(sk), ossl_check_void_type(ptr))
|
||||
#define sk_void_pop(sk) ((void *)OPENSSL_sk_pop(ossl_check_void_sk_type(sk)))
|
||||
#define sk_void_shift(sk) ((void *)OPENSSL_sk_shift(ossl_check_void_sk_type(sk)))
|
||||
#define sk_void_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_void_sk_type(sk),ossl_check_void_freefunc_type(freefunc))
|
||||
#define sk_void_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_void_sk_type(sk), ossl_check_void_type(ptr), (idx))
|
||||
#define sk_void_set(sk, idx, ptr) ((void *)OPENSSL_sk_set(ossl_check_void_sk_type(sk), (idx), ossl_check_void_type(ptr)))
|
||||
#define sk_void_find(sk, ptr) OPENSSL_sk_find(ossl_check_void_sk_type(sk), ossl_check_void_type(ptr))
|
||||
#define sk_void_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_void_sk_type(sk), ossl_check_void_type(ptr))
|
||||
#define sk_void_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_void_sk_type(sk), ossl_check_void_type(ptr), pnum)
|
||||
#define sk_void_sort(sk) OPENSSL_sk_sort(ossl_check_void_sk_type(sk))
|
||||
#define sk_void_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_void_sk_type(sk))
|
||||
#define sk_void_dup(sk) ((STACK_OF(void) *)OPENSSL_sk_dup(ossl_check_const_void_sk_type(sk)))
|
||||
#define sk_void_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(void) *)OPENSSL_sk_deep_copy(ossl_check_const_void_sk_type(sk), ossl_check_void_copyfunc_type(copyfunc), ossl_check_void_freefunc_type(freefunc)))
|
||||
#define sk_void_set_cmp_func(sk, cmp) ((sk_void_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_void_sk_type(sk), ossl_check_void_compfunc_type(cmp)))
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Per class, we have a STACK of function pointers.
|
||||
*/
|
||||
# define CRYPTO_EX_INDEX_SSL 0
|
||||
# define CRYPTO_EX_INDEX_SSL_CTX 1
|
||||
# define CRYPTO_EX_INDEX_SSL_SESSION 2
|
||||
# define CRYPTO_EX_INDEX_X509 3
|
||||
# define CRYPTO_EX_INDEX_X509_STORE 4
|
||||
# define CRYPTO_EX_INDEX_X509_STORE_CTX 5
|
||||
# define CRYPTO_EX_INDEX_DH 6
|
||||
# define CRYPTO_EX_INDEX_DSA 7
|
||||
# define CRYPTO_EX_INDEX_EC_KEY 8
|
||||
# define CRYPTO_EX_INDEX_RSA 9
|
||||
# define CRYPTO_EX_INDEX_ENGINE 10
|
||||
# define CRYPTO_EX_INDEX_UI 11
|
||||
# define CRYPTO_EX_INDEX_BIO 12
|
||||
# define CRYPTO_EX_INDEX_APP 13
|
||||
# define CRYPTO_EX_INDEX_UI_METHOD 14
|
||||
# define CRYPTO_EX_INDEX_RAND_DRBG 15
|
||||
# define CRYPTO_EX_INDEX_DRBG CRYPTO_EX_INDEX_RAND_DRBG
|
||||
# define CRYPTO_EX_INDEX_OSSL_LIB_CTX 16
|
||||
# define CRYPTO_EX_INDEX_EVP_PKEY 17
|
||||
# define CRYPTO_EX_INDEX__COUNT 18
|
||||
|
||||
typedef void CRYPTO_EX_new (void *parent, void *ptr, CRYPTO_EX_DATA *ad,
|
||||
int idx, long argl, void *argp);
|
||||
typedef void CRYPTO_EX_free (void *parent, void *ptr, CRYPTO_EX_DATA *ad,
|
||||
int idx, long argl, void *argp);
|
||||
typedef int CRYPTO_EX_dup (CRYPTO_EX_DATA *to, const CRYPTO_EX_DATA *from,
|
||||
void **from_d, int idx, long argl, void *argp);
|
||||
__owur int CRYPTO_get_ex_new_index(int class_index, long argl, void *argp,
|
||||
CRYPTO_EX_new *new_func,
|
||||
CRYPTO_EX_dup *dup_func,
|
||||
CRYPTO_EX_free *free_func);
|
||||
/* No longer use an index. */
|
||||
int CRYPTO_free_ex_index(int class_index, int idx);
|
||||
|
||||
/*
|
||||
* Initialise/duplicate/free CRYPTO_EX_DATA variables corresponding to a
|
||||
* given class (invokes whatever per-class callbacks are applicable)
|
||||
*/
|
||||
int CRYPTO_new_ex_data(int class_index, void *obj, CRYPTO_EX_DATA *ad);
|
||||
int CRYPTO_dup_ex_data(int class_index, CRYPTO_EX_DATA *to,
|
||||
const CRYPTO_EX_DATA *from);
|
||||
|
||||
void CRYPTO_free_ex_data(int class_index, void *obj, CRYPTO_EX_DATA *ad);
|
||||
|
||||
/* Allocate a single item in the CRYPTO_EX_DATA variable */
|
||||
int CRYPTO_alloc_ex_data(int class_index, void *obj, CRYPTO_EX_DATA *ad,
|
||||
int idx);
|
||||
|
||||
/*
|
||||
* Get/set data in a CRYPTO_EX_DATA variable corresponding to a particular
|
||||
* index (relative to the class type involved)
|
||||
*/
|
||||
int CRYPTO_set_ex_data(CRYPTO_EX_DATA *ad, int idx, void *val);
|
||||
void *CRYPTO_get_ex_data(const CRYPTO_EX_DATA *ad, int idx);
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
/*
|
||||
* This function cleans up all "ex_data" state. It mustn't be called under
|
||||
* potential race-conditions.
|
||||
*/
|
||||
# define CRYPTO_cleanup_all_ex_data() while(0) continue
|
||||
|
||||
/*
|
||||
* The old locking functions have been removed completely without compatibility
|
||||
* macros. This is because the old functions either could not properly report
|
||||
* errors, or the returned error values were not clearly documented.
|
||||
* Replacing the locking functions with no-ops would cause race condition
|
||||
* issues in the affected applications. It is far better for them to fail at
|
||||
* compile time.
|
||||
* On the other hand, the locking callbacks are no longer used. Consequently,
|
||||
* the callback management functions can be safely replaced with no-op macros.
|
||||
*/
|
||||
# define CRYPTO_num_locks() (1)
|
||||
# define CRYPTO_set_locking_callback(func)
|
||||
# define CRYPTO_get_locking_callback() (NULL)
|
||||
# define CRYPTO_set_add_lock_callback(func)
|
||||
# define CRYPTO_get_add_lock_callback() (NULL)
|
||||
|
||||
/*
|
||||
* These defines where used in combination with the old locking callbacks,
|
||||
* they are not called anymore, but old code that's not called might still
|
||||
* use them.
|
||||
*/
|
||||
# define CRYPTO_LOCK 1
|
||||
# define CRYPTO_UNLOCK 2
|
||||
# define CRYPTO_READ 4
|
||||
# define CRYPTO_WRITE 8
|
||||
|
||||
/* This structure is no longer used */
|
||||
typedef struct crypto_threadid_st {
|
||||
int dummy;
|
||||
} CRYPTO_THREADID;
|
||||
/* Only use CRYPTO_THREADID_set_[numeric|pointer]() within callbacks */
|
||||
# define CRYPTO_THREADID_set_numeric(id, val)
|
||||
# define CRYPTO_THREADID_set_pointer(id, ptr)
|
||||
# define CRYPTO_THREADID_set_callback(threadid_func) (0)
|
||||
# define CRYPTO_THREADID_get_callback() (NULL)
|
||||
# define CRYPTO_THREADID_current(id)
|
||||
# define CRYPTO_THREADID_cmp(a, b) (-1)
|
||||
# define CRYPTO_THREADID_cpy(dest, src)
|
||||
# define CRYPTO_THREADID_hash(id) (0UL)
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_0_0
|
||||
# define CRYPTO_set_id_callback(func)
|
||||
# define CRYPTO_get_id_callback() (NULL)
|
||||
# define CRYPTO_thread_id() (0UL)
|
||||
# endif /* OPENSSL_NO_DEPRECATED_1_0_0 */
|
||||
|
||||
# define CRYPTO_set_dynlock_create_callback(dyn_create_function)
|
||||
# define CRYPTO_set_dynlock_lock_callback(dyn_lock_function)
|
||||
# define CRYPTO_set_dynlock_destroy_callback(dyn_destroy_function)
|
||||
# define CRYPTO_get_dynlock_create_callback() (NULL)
|
||||
# define CRYPTO_get_dynlock_lock_callback() (NULL)
|
||||
# define CRYPTO_get_dynlock_destroy_callback() (NULL)
|
||||
# endif /* OPENSSL_NO_DEPRECATED_1_1_0 */
|
||||
|
||||
typedef void *(*CRYPTO_malloc_fn)(size_t num, const char *file, int line);
|
||||
typedef void *(*CRYPTO_realloc_fn)(void *addr, size_t num, const char *file,
|
||||
int line);
|
||||
typedef void (*CRYPTO_free_fn)(void *addr, const char *file, int line);
|
||||
int CRYPTO_set_mem_functions(CRYPTO_malloc_fn malloc_fn,
|
||||
CRYPTO_realloc_fn realloc_fn,
|
||||
CRYPTO_free_fn free_fn);
|
||||
void CRYPTO_get_mem_functions(CRYPTO_malloc_fn *malloc_fn,
|
||||
CRYPTO_realloc_fn *realloc_fn,
|
||||
CRYPTO_free_fn *free_fn);
|
||||
|
||||
void *CRYPTO_malloc(size_t num, const char *file, int line);
|
||||
void *CRYPTO_zalloc(size_t num, const char *file, int line);
|
||||
void *CRYPTO_memdup(const void *str, size_t siz, const char *file, int line);
|
||||
char *CRYPTO_strdup(const char *str, const char *file, int line);
|
||||
char *CRYPTO_strndup(const char *str, size_t s, const char *file, int line);
|
||||
void CRYPTO_free(void *ptr, const char *file, int line);
|
||||
void CRYPTO_clear_free(void *ptr, size_t num, const char *file, int line);
|
||||
void *CRYPTO_realloc(void *addr, size_t num, const char *file, int line);
|
||||
void *CRYPTO_clear_realloc(void *addr, size_t old_num, size_t num,
|
||||
const char *file, int line);
|
||||
|
||||
int CRYPTO_secure_malloc_init(size_t sz, size_t minsize);
|
||||
int CRYPTO_secure_malloc_done(void);
|
||||
void *CRYPTO_secure_malloc(size_t num, const char *file, int line);
|
||||
void *CRYPTO_secure_zalloc(size_t num, const char *file, int line);
|
||||
void CRYPTO_secure_free(void *ptr, const char *file, int line);
|
||||
void CRYPTO_secure_clear_free(void *ptr, size_t num,
|
||||
const char *file, int line);
|
||||
int CRYPTO_secure_allocated(const void *ptr);
|
||||
int CRYPTO_secure_malloc_initialized(void);
|
||||
size_t CRYPTO_secure_actual_size(void *ptr);
|
||||
size_t CRYPTO_secure_used(void);
|
||||
|
||||
void OPENSSL_cleanse(void *ptr, size_t len);
|
||||
|
||||
# ifndef OPENSSL_NO_CRYPTO_MDEBUG
|
||||
/*
|
||||
* The following can be used to detect memory leaks in the library. If
|
||||
* used, it turns on malloc checking
|
||||
*/
|
||||
# define CRYPTO_MEM_CHECK_OFF 0x0 /* Control only */
|
||||
# define CRYPTO_MEM_CHECK_ON 0x1 /* Control and mode bit */
|
||||
# define CRYPTO_MEM_CHECK_ENABLE 0x2 /* Control and mode bit */
|
||||
# define CRYPTO_MEM_CHECK_DISABLE 0x3 /* Control only */
|
||||
|
||||
void CRYPTO_get_alloc_counts(int *mcount, int *rcount, int *fcount);
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define OPENSSL_mem_debug_push(info) \
|
||||
CRYPTO_mem_debug_push(info, OPENSSL_FILE, OPENSSL_LINE)
|
||||
# define OPENSSL_mem_debug_pop() \
|
||||
CRYPTO_mem_debug_pop()
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0 int CRYPTO_set_mem_debug(int flag);
|
||||
OSSL_DEPRECATEDIN_3_0 int CRYPTO_mem_ctrl(int mode);
|
||||
OSSL_DEPRECATEDIN_3_0 int CRYPTO_mem_debug_push(const char *info,
|
||||
const char *file, int line);
|
||||
OSSL_DEPRECATEDIN_3_0 int CRYPTO_mem_debug_pop(void);
|
||||
OSSL_DEPRECATEDIN_3_0 void CRYPTO_mem_debug_malloc(void *addr, size_t num,
|
||||
int flag,
|
||||
const char *file, int line);
|
||||
OSSL_DEPRECATEDIN_3_0 void CRYPTO_mem_debug_realloc(void *addr1, void *addr2,
|
||||
size_t num, int flag,
|
||||
const char *file, int line);
|
||||
OSSL_DEPRECATEDIN_3_0 void CRYPTO_mem_debug_free(void *addr, int flag,
|
||||
const char *file, int line);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int CRYPTO_mem_leaks_cb(int (*cb)(const char *str, size_t len, void *u),
|
||||
void *u);
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0 int CRYPTO_mem_leaks_fp(FILE *);
|
||||
# endif
|
||||
# endif
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0 int CRYPTO_mem_leaks(BIO *bio);
|
||||
# endif
|
||||
# endif /* OPENSSL_NO_CRYPTO_MDEBUG */
|
||||
|
||||
/* die if we have to */
|
||||
ossl_noreturn void OPENSSL_die(const char *assertion, const char *file, int line);
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# define OpenSSLDie(f,l,a) OPENSSL_die((a),(f),(l))
|
||||
# endif
|
||||
# define OPENSSL_assert(e) \
|
||||
(void)((e) ? 0 : (OPENSSL_die("assertion failed: " #e, OPENSSL_FILE, OPENSSL_LINE), 1))
|
||||
|
||||
int OPENSSL_isservice(void);
|
||||
|
||||
void OPENSSL_init(void);
|
||||
# ifdef OPENSSL_SYS_UNIX
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0 void OPENSSL_fork_prepare(void);
|
||||
OSSL_DEPRECATEDIN_3_0 void OPENSSL_fork_parent(void);
|
||||
OSSL_DEPRECATEDIN_3_0 void OPENSSL_fork_child(void);
|
||||
# endif
|
||||
# endif
|
||||
|
||||
struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result);
|
||||
int OPENSSL_gmtime_adj(struct tm *tm, int offset_day, long offset_sec);
|
||||
int OPENSSL_gmtime_diff(int *pday, int *psec,
|
||||
const struct tm *from, const struct tm *to);
|
||||
|
||||
/*
|
||||
* CRYPTO_memcmp returns zero iff the |len| bytes at |a| and |b| are equal.
|
||||
* It takes an amount of time dependent on |len|, but independent of the
|
||||
* contents of |a| and |b|. Unlike memcmp, it cannot be used to put elements
|
||||
* into a defined order as the return value when a != b is undefined, other
|
||||
* than to be non-zero.
|
||||
*/
|
||||
int CRYPTO_memcmp(const void * in_a, const void * in_b, size_t len);
|
||||
|
||||
/* Standard initialisation options */
|
||||
# define OPENSSL_INIT_NO_LOAD_CRYPTO_STRINGS 0x00000001L
|
||||
# define OPENSSL_INIT_LOAD_CRYPTO_STRINGS 0x00000002L
|
||||
# define OPENSSL_INIT_ADD_ALL_CIPHERS 0x00000004L
|
||||
# define OPENSSL_INIT_ADD_ALL_DIGESTS 0x00000008L
|
||||
# define OPENSSL_INIT_NO_ADD_ALL_CIPHERS 0x00000010L
|
||||
# define OPENSSL_INIT_NO_ADD_ALL_DIGESTS 0x00000020L
|
||||
# define OPENSSL_INIT_LOAD_CONFIG 0x00000040L
|
||||
# define OPENSSL_INIT_NO_LOAD_CONFIG 0x00000080L
|
||||
# define OPENSSL_INIT_ASYNC 0x00000100L
|
||||
# define OPENSSL_INIT_ENGINE_RDRAND 0x00000200L
|
||||
# define OPENSSL_INIT_ENGINE_DYNAMIC 0x00000400L
|
||||
# define OPENSSL_INIT_ENGINE_OPENSSL 0x00000800L
|
||||
# define OPENSSL_INIT_ENGINE_CRYPTODEV 0x00001000L
|
||||
# define OPENSSL_INIT_ENGINE_CAPI 0x00002000L
|
||||
# define OPENSSL_INIT_ENGINE_PADLOCK 0x00004000L
|
||||
# define OPENSSL_INIT_ENGINE_AFALG 0x00008000L
|
||||
/* FREE: 0x00010000L */
|
||||
# define OPENSSL_INIT_ATFORK 0x00020000L
|
||||
/* OPENSSL_INIT_BASE_ONLY 0x00040000L */
|
||||
# define OPENSSL_INIT_NO_ATEXIT 0x00080000L
|
||||
/* OPENSSL_INIT flag range 0x03f00000 reserved for OPENSSL_init_ssl() */
|
||||
/* FREE: 0x04000000L */
|
||||
/* FREE: 0x08000000L */
|
||||
/* FREE: 0x10000000L */
|
||||
/* FREE: 0x20000000L */
|
||||
/* FREE: 0x40000000L */
|
||||
/* FREE: 0x80000000L */
|
||||
/* Max OPENSSL_INIT flag value is 0x80000000 */
|
||||
|
||||
/* openssl and dasync not counted as builtin */
|
||||
# define OPENSSL_INIT_ENGINE_ALL_BUILTIN \
|
||||
(OPENSSL_INIT_ENGINE_RDRAND | OPENSSL_INIT_ENGINE_DYNAMIC \
|
||||
| OPENSSL_INIT_ENGINE_CRYPTODEV | OPENSSL_INIT_ENGINE_CAPI | \
|
||||
OPENSSL_INIT_ENGINE_PADLOCK)
|
||||
|
||||
/* Library initialisation functions */
|
||||
void OPENSSL_cleanup(void);
|
||||
int OPENSSL_init_crypto(uint64_t opts, const OPENSSL_INIT_SETTINGS *settings);
|
||||
int OPENSSL_atexit(void (*handler)(void));
|
||||
void OPENSSL_thread_stop(void);
|
||||
void OPENSSL_thread_stop_ex(OSSL_LIB_CTX *ctx);
|
||||
|
||||
/* Low-level control of initialization */
|
||||
OPENSSL_INIT_SETTINGS *OPENSSL_INIT_new(void);
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
int OPENSSL_INIT_set_config_filename(OPENSSL_INIT_SETTINGS *settings,
|
||||
const char *config_filename);
|
||||
void OPENSSL_INIT_set_config_file_flags(OPENSSL_INIT_SETTINGS *settings,
|
||||
unsigned long flags);
|
||||
int OPENSSL_INIT_set_config_appname(OPENSSL_INIT_SETTINGS *settings,
|
||||
const char *config_appname);
|
||||
# endif
|
||||
void OPENSSL_INIT_free(OPENSSL_INIT_SETTINGS *settings);
|
||||
|
||||
# if defined(OPENSSL_THREADS) && !defined(CRYPTO_TDEBUG)
|
||||
# if defined(_WIN32)
|
||||
# if defined(BASETYPES) || defined(_WINDEF_H)
|
||||
/* application has to include <windows.h> in order to use this */
|
||||
typedef DWORD CRYPTO_THREAD_LOCAL;
|
||||
typedef DWORD CRYPTO_THREAD_ID;
|
||||
|
||||
typedef LONG CRYPTO_ONCE;
|
||||
# define CRYPTO_ONCE_STATIC_INIT 0
|
||||
# endif
|
||||
# else
|
||||
# if defined(__TANDEM) && defined(_SPT_MODEL_)
|
||||
# define SPT_THREAD_SIGNAL 1
|
||||
# define SPT_THREAD_AWARE 1
|
||||
# include <spthread.h>
|
||||
# else
|
||||
# include <pthread.h>
|
||||
# endif
|
||||
typedef pthread_once_t CRYPTO_ONCE;
|
||||
typedef pthread_key_t CRYPTO_THREAD_LOCAL;
|
||||
typedef pthread_t CRYPTO_THREAD_ID;
|
||||
|
||||
# define CRYPTO_ONCE_STATIC_INIT PTHREAD_ONCE_INIT
|
||||
# endif
|
||||
# endif
|
||||
|
||||
# if !defined(CRYPTO_ONCE_STATIC_INIT)
|
||||
typedef unsigned int CRYPTO_ONCE;
|
||||
typedef unsigned int CRYPTO_THREAD_LOCAL;
|
||||
typedef unsigned int CRYPTO_THREAD_ID;
|
||||
# define CRYPTO_ONCE_STATIC_INIT 0
|
||||
# endif
|
||||
|
||||
int CRYPTO_THREAD_run_once(CRYPTO_ONCE *once, void (*init)(void));
|
||||
|
||||
int CRYPTO_THREAD_init_local(CRYPTO_THREAD_LOCAL *key, void (*cleanup)(void *));
|
||||
void *CRYPTO_THREAD_get_local(CRYPTO_THREAD_LOCAL *key);
|
||||
int CRYPTO_THREAD_set_local(CRYPTO_THREAD_LOCAL *key, void *val);
|
||||
int CRYPTO_THREAD_cleanup_local(CRYPTO_THREAD_LOCAL *key);
|
||||
|
||||
CRYPTO_THREAD_ID CRYPTO_THREAD_get_current_id(void);
|
||||
int CRYPTO_THREAD_compare_id(CRYPTO_THREAD_ID a, CRYPTO_THREAD_ID b);
|
||||
|
||||
OSSL_LIB_CTX *OSSL_LIB_CTX_new(void);
|
||||
OSSL_LIB_CTX *OSSL_LIB_CTX_new_from_dispatch(const OSSL_CORE_HANDLE *handle,
|
||||
const OSSL_DISPATCH *in);
|
||||
OSSL_LIB_CTX *OSSL_LIB_CTX_new_child(const OSSL_CORE_HANDLE *handle,
|
||||
const OSSL_DISPATCH *in);
|
||||
int OSSL_LIB_CTX_load_config(OSSL_LIB_CTX *ctx, const char *config_file);
|
||||
void OSSL_LIB_CTX_free(OSSL_LIB_CTX *);
|
||||
OSSL_LIB_CTX *OSSL_LIB_CTX_get0_global_default(void);
|
||||
OSSL_LIB_CTX *OSSL_LIB_CTX_set0_default(OSSL_LIB_CTX *libctx);
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
573
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ct.h
generated
vendored
Normal file
573
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ct.h
generated
vendored
Normal file
@@ -0,0 +1,573 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/ct.h.in
|
||||
*
|
||||
* Copyright 2016-2020 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_CT_H
|
||||
# define OPENSSL_CT_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_CT_H
|
||||
# endif
|
||||
|
||||
# include <openssl/opensslconf.h>
|
||||
|
||||
# ifndef OPENSSL_NO_CT
|
||||
# include <openssl/types.h>
|
||||
# include <openssl/safestack.h>
|
||||
# include <openssl/x509.h>
|
||||
# include <openssl/cterr.h>
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
|
||||
/* Minimum RSA key size, from RFC6962 */
|
||||
# define SCT_MIN_RSA_BITS 2048
|
||||
|
||||
/* All hashes are SHA256 in v1 of Certificate Transparency */
|
||||
# define CT_V1_HASHLEN SHA256_DIGEST_LENGTH
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(SCT, SCT, SCT)
|
||||
#define sk_SCT_num(sk) OPENSSL_sk_num(ossl_check_const_SCT_sk_type(sk))
|
||||
#define sk_SCT_value(sk, idx) ((SCT *)OPENSSL_sk_value(ossl_check_const_SCT_sk_type(sk), (idx)))
|
||||
#define sk_SCT_new(cmp) ((STACK_OF(SCT) *)OPENSSL_sk_new(ossl_check_SCT_compfunc_type(cmp)))
|
||||
#define sk_SCT_new_null() ((STACK_OF(SCT) *)OPENSSL_sk_new_null())
|
||||
#define sk_SCT_new_reserve(cmp, n) ((STACK_OF(SCT) *)OPENSSL_sk_new_reserve(ossl_check_SCT_compfunc_type(cmp), (n)))
|
||||
#define sk_SCT_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_SCT_sk_type(sk), (n))
|
||||
#define sk_SCT_free(sk) OPENSSL_sk_free(ossl_check_SCT_sk_type(sk))
|
||||
#define sk_SCT_zero(sk) OPENSSL_sk_zero(ossl_check_SCT_sk_type(sk))
|
||||
#define sk_SCT_delete(sk, i) ((SCT *)OPENSSL_sk_delete(ossl_check_SCT_sk_type(sk), (i)))
|
||||
#define sk_SCT_delete_ptr(sk, ptr) ((SCT *)OPENSSL_sk_delete_ptr(ossl_check_SCT_sk_type(sk), ossl_check_SCT_type(ptr)))
|
||||
#define sk_SCT_push(sk, ptr) OPENSSL_sk_push(ossl_check_SCT_sk_type(sk), ossl_check_SCT_type(ptr))
|
||||
#define sk_SCT_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_SCT_sk_type(sk), ossl_check_SCT_type(ptr))
|
||||
#define sk_SCT_pop(sk) ((SCT *)OPENSSL_sk_pop(ossl_check_SCT_sk_type(sk)))
|
||||
#define sk_SCT_shift(sk) ((SCT *)OPENSSL_sk_shift(ossl_check_SCT_sk_type(sk)))
|
||||
#define sk_SCT_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_SCT_sk_type(sk),ossl_check_SCT_freefunc_type(freefunc))
|
||||
#define sk_SCT_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_SCT_sk_type(sk), ossl_check_SCT_type(ptr), (idx))
|
||||
#define sk_SCT_set(sk, idx, ptr) ((SCT *)OPENSSL_sk_set(ossl_check_SCT_sk_type(sk), (idx), ossl_check_SCT_type(ptr)))
|
||||
#define sk_SCT_find(sk, ptr) OPENSSL_sk_find(ossl_check_SCT_sk_type(sk), ossl_check_SCT_type(ptr))
|
||||
#define sk_SCT_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_SCT_sk_type(sk), ossl_check_SCT_type(ptr))
|
||||
#define sk_SCT_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_SCT_sk_type(sk), ossl_check_SCT_type(ptr), pnum)
|
||||
#define sk_SCT_sort(sk) OPENSSL_sk_sort(ossl_check_SCT_sk_type(sk))
|
||||
#define sk_SCT_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_SCT_sk_type(sk))
|
||||
#define sk_SCT_dup(sk) ((STACK_OF(SCT) *)OPENSSL_sk_dup(ossl_check_const_SCT_sk_type(sk)))
|
||||
#define sk_SCT_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(SCT) *)OPENSSL_sk_deep_copy(ossl_check_const_SCT_sk_type(sk), ossl_check_SCT_copyfunc_type(copyfunc), ossl_check_SCT_freefunc_type(freefunc)))
|
||||
#define sk_SCT_set_cmp_func(sk, cmp) ((sk_SCT_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_SCT_sk_type(sk), ossl_check_SCT_compfunc_type(cmp)))
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(CTLOG, CTLOG, CTLOG)
|
||||
#define sk_CTLOG_num(sk) OPENSSL_sk_num(ossl_check_const_CTLOG_sk_type(sk))
|
||||
#define sk_CTLOG_value(sk, idx) ((CTLOG *)OPENSSL_sk_value(ossl_check_const_CTLOG_sk_type(sk), (idx)))
|
||||
#define sk_CTLOG_new(cmp) ((STACK_OF(CTLOG) *)OPENSSL_sk_new(ossl_check_CTLOG_compfunc_type(cmp)))
|
||||
#define sk_CTLOG_new_null() ((STACK_OF(CTLOG) *)OPENSSL_sk_new_null())
|
||||
#define sk_CTLOG_new_reserve(cmp, n) ((STACK_OF(CTLOG) *)OPENSSL_sk_new_reserve(ossl_check_CTLOG_compfunc_type(cmp), (n)))
|
||||
#define sk_CTLOG_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_CTLOG_sk_type(sk), (n))
|
||||
#define sk_CTLOG_free(sk) OPENSSL_sk_free(ossl_check_CTLOG_sk_type(sk))
|
||||
#define sk_CTLOG_zero(sk) OPENSSL_sk_zero(ossl_check_CTLOG_sk_type(sk))
|
||||
#define sk_CTLOG_delete(sk, i) ((CTLOG *)OPENSSL_sk_delete(ossl_check_CTLOG_sk_type(sk), (i)))
|
||||
#define sk_CTLOG_delete_ptr(sk, ptr) ((CTLOG *)OPENSSL_sk_delete_ptr(ossl_check_CTLOG_sk_type(sk), ossl_check_CTLOG_type(ptr)))
|
||||
#define sk_CTLOG_push(sk, ptr) OPENSSL_sk_push(ossl_check_CTLOG_sk_type(sk), ossl_check_CTLOG_type(ptr))
|
||||
#define sk_CTLOG_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_CTLOG_sk_type(sk), ossl_check_CTLOG_type(ptr))
|
||||
#define sk_CTLOG_pop(sk) ((CTLOG *)OPENSSL_sk_pop(ossl_check_CTLOG_sk_type(sk)))
|
||||
#define sk_CTLOG_shift(sk) ((CTLOG *)OPENSSL_sk_shift(ossl_check_CTLOG_sk_type(sk)))
|
||||
#define sk_CTLOG_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_CTLOG_sk_type(sk),ossl_check_CTLOG_freefunc_type(freefunc))
|
||||
#define sk_CTLOG_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_CTLOG_sk_type(sk), ossl_check_CTLOG_type(ptr), (idx))
|
||||
#define sk_CTLOG_set(sk, idx, ptr) ((CTLOG *)OPENSSL_sk_set(ossl_check_CTLOG_sk_type(sk), (idx), ossl_check_CTLOG_type(ptr)))
|
||||
#define sk_CTLOG_find(sk, ptr) OPENSSL_sk_find(ossl_check_CTLOG_sk_type(sk), ossl_check_CTLOG_type(ptr))
|
||||
#define sk_CTLOG_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_CTLOG_sk_type(sk), ossl_check_CTLOG_type(ptr))
|
||||
#define sk_CTLOG_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_CTLOG_sk_type(sk), ossl_check_CTLOG_type(ptr), pnum)
|
||||
#define sk_CTLOG_sort(sk) OPENSSL_sk_sort(ossl_check_CTLOG_sk_type(sk))
|
||||
#define sk_CTLOG_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_CTLOG_sk_type(sk))
|
||||
#define sk_CTLOG_dup(sk) ((STACK_OF(CTLOG) *)OPENSSL_sk_dup(ossl_check_const_CTLOG_sk_type(sk)))
|
||||
#define sk_CTLOG_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(CTLOG) *)OPENSSL_sk_deep_copy(ossl_check_const_CTLOG_sk_type(sk), ossl_check_CTLOG_copyfunc_type(copyfunc), ossl_check_CTLOG_freefunc_type(freefunc)))
|
||||
#define sk_CTLOG_set_cmp_func(sk, cmp) ((sk_CTLOG_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_CTLOG_sk_type(sk), ossl_check_CTLOG_compfunc_type(cmp)))
|
||||
|
||||
|
||||
|
||||
typedef enum {
|
||||
CT_LOG_ENTRY_TYPE_NOT_SET = -1,
|
||||
CT_LOG_ENTRY_TYPE_X509 = 0,
|
||||
CT_LOG_ENTRY_TYPE_PRECERT = 1
|
||||
} ct_log_entry_type_t;
|
||||
|
||||
typedef enum {
|
||||
SCT_VERSION_NOT_SET = -1,
|
||||
SCT_VERSION_V1 = 0
|
||||
} sct_version_t;
|
||||
|
||||
typedef enum {
|
||||
SCT_SOURCE_UNKNOWN,
|
||||
SCT_SOURCE_TLS_EXTENSION,
|
||||
SCT_SOURCE_X509V3_EXTENSION,
|
||||
SCT_SOURCE_OCSP_STAPLED_RESPONSE
|
||||
} sct_source_t;
|
||||
|
||||
typedef enum {
|
||||
SCT_VALIDATION_STATUS_NOT_SET,
|
||||
SCT_VALIDATION_STATUS_UNKNOWN_LOG,
|
||||
SCT_VALIDATION_STATUS_VALID,
|
||||
SCT_VALIDATION_STATUS_INVALID,
|
||||
SCT_VALIDATION_STATUS_UNVERIFIED,
|
||||
SCT_VALIDATION_STATUS_UNKNOWN_VERSION
|
||||
} sct_validation_status_t;
|
||||
|
||||
/******************************************
|
||||
* CT policy evaluation context functions *
|
||||
******************************************/
|
||||
|
||||
/*
|
||||
* Creates a new, empty policy evaluation context associated with the given
|
||||
* library context and property query string.
|
||||
* The caller is responsible for calling CT_POLICY_EVAL_CTX_free when finished
|
||||
* with the CT_POLICY_EVAL_CTX.
|
||||
*/
|
||||
CT_POLICY_EVAL_CTX *CT_POLICY_EVAL_CTX_new_ex(OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
|
||||
/*
|
||||
* The same as CT_POLICY_EVAL_CTX_new_ex() but the default library
|
||||
* context and property query string is used.
|
||||
*/
|
||||
CT_POLICY_EVAL_CTX *CT_POLICY_EVAL_CTX_new(void);
|
||||
|
||||
/* Deletes a policy evaluation context and anything it owns. */
|
||||
void CT_POLICY_EVAL_CTX_free(CT_POLICY_EVAL_CTX *ctx);
|
||||
|
||||
/* Gets the peer certificate that the SCTs are for */
|
||||
X509* CT_POLICY_EVAL_CTX_get0_cert(const CT_POLICY_EVAL_CTX *ctx);
|
||||
|
||||
/*
|
||||
* Sets the certificate associated with the received SCTs.
|
||||
* Increments the reference count of cert.
|
||||
* Returns 1 on success, 0 otherwise.
|
||||
*/
|
||||
int CT_POLICY_EVAL_CTX_set1_cert(CT_POLICY_EVAL_CTX *ctx, X509 *cert);
|
||||
|
||||
/* Gets the issuer of the aforementioned certificate */
|
||||
X509* CT_POLICY_EVAL_CTX_get0_issuer(const CT_POLICY_EVAL_CTX *ctx);
|
||||
|
||||
/*
|
||||
* Sets the issuer of the certificate associated with the received SCTs.
|
||||
* Increments the reference count of issuer.
|
||||
* Returns 1 on success, 0 otherwise.
|
||||
*/
|
||||
int CT_POLICY_EVAL_CTX_set1_issuer(CT_POLICY_EVAL_CTX *ctx, X509 *issuer);
|
||||
|
||||
/* Gets the CT logs that are trusted sources of SCTs */
|
||||
const CTLOG_STORE *CT_POLICY_EVAL_CTX_get0_log_store(const CT_POLICY_EVAL_CTX *ctx);
|
||||
|
||||
/* Sets the log store that is in use. It must outlive the CT_POLICY_EVAL_CTX. */
|
||||
void CT_POLICY_EVAL_CTX_set_shared_CTLOG_STORE(CT_POLICY_EVAL_CTX *ctx,
|
||||
CTLOG_STORE *log_store);
|
||||
|
||||
/*
|
||||
* Gets the time, in milliseconds since the Unix epoch, that will be used as the
|
||||
* current time when checking whether an SCT was issued in the future.
|
||||
* Such SCTs will fail validation, as required by RFC6962.
|
||||
*/
|
||||
uint64_t CT_POLICY_EVAL_CTX_get_time(const CT_POLICY_EVAL_CTX *ctx);
|
||||
|
||||
/*
|
||||
* Sets the time to evaluate SCTs against, in milliseconds since the Unix epoch.
|
||||
* If an SCT's timestamp is after this time, it will be interpreted as having
|
||||
* been issued in the future. RFC6962 states that "TLS clients MUST reject SCTs
|
||||
* whose timestamp is in the future", so an SCT will not validate in this case.
|
||||
*/
|
||||
void CT_POLICY_EVAL_CTX_set_time(CT_POLICY_EVAL_CTX *ctx, uint64_t time_in_ms);
|
||||
|
||||
/*****************
|
||||
* SCT functions *
|
||||
*****************/
|
||||
|
||||
/*
|
||||
* Creates a new, blank SCT.
|
||||
* The caller is responsible for calling SCT_free when finished with the SCT.
|
||||
*/
|
||||
SCT *SCT_new(void);
|
||||
|
||||
/*
|
||||
* Creates a new SCT from some base64-encoded strings.
|
||||
* The caller is responsible for calling SCT_free when finished with the SCT.
|
||||
*/
|
||||
SCT *SCT_new_from_base64(unsigned char version,
|
||||
const char *logid_base64,
|
||||
ct_log_entry_type_t entry_type,
|
||||
uint64_t timestamp,
|
||||
const char *extensions_base64,
|
||||
const char *signature_base64);
|
||||
|
||||
/*
|
||||
* Frees the SCT and the underlying data structures.
|
||||
*/
|
||||
void SCT_free(SCT *sct);
|
||||
|
||||
/*
|
||||
* Free a stack of SCTs, and the underlying SCTs themselves.
|
||||
* Intended to be compatible with X509V3_EXT_FREE.
|
||||
*/
|
||||
void SCT_LIST_free(STACK_OF(SCT) *a);
|
||||
|
||||
/*
|
||||
* Returns the version of the SCT.
|
||||
*/
|
||||
sct_version_t SCT_get_version(const SCT *sct);
|
||||
|
||||
/*
|
||||
* Set the version of an SCT.
|
||||
* Returns 1 on success, 0 if the version is unrecognized.
|
||||
*/
|
||||
__owur int SCT_set_version(SCT *sct, sct_version_t version);
|
||||
|
||||
/*
|
||||
* Returns the log entry type of the SCT.
|
||||
*/
|
||||
ct_log_entry_type_t SCT_get_log_entry_type(const SCT *sct);
|
||||
|
||||
/*
|
||||
* Set the log entry type of an SCT.
|
||||
* Returns 1 on success, 0 otherwise.
|
||||
*/
|
||||
__owur int SCT_set_log_entry_type(SCT *sct, ct_log_entry_type_t entry_type);
|
||||
|
||||
/*
|
||||
* Gets the ID of the log that an SCT came from.
|
||||
* Ownership of the log ID remains with the SCT.
|
||||
* Returns the length of the log ID.
|
||||
*/
|
||||
size_t SCT_get0_log_id(const SCT *sct, unsigned char **log_id);
|
||||
|
||||
/*
|
||||
* Set the log ID of an SCT to point directly to the *log_id specified.
|
||||
* The SCT takes ownership of the specified pointer.
|
||||
* Returns 1 on success, 0 otherwise.
|
||||
*/
|
||||
__owur int SCT_set0_log_id(SCT *sct, unsigned char *log_id, size_t log_id_len);
|
||||
|
||||
/*
|
||||
* Set the log ID of an SCT.
|
||||
* This makes a copy of the log_id.
|
||||
* Returns 1 on success, 0 otherwise.
|
||||
*/
|
||||
__owur int SCT_set1_log_id(SCT *sct, const unsigned char *log_id,
|
||||
size_t log_id_len);
|
||||
|
||||
/*
|
||||
* Returns the timestamp for the SCT (epoch time in milliseconds).
|
||||
*/
|
||||
uint64_t SCT_get_timestamp(const SCT *sct);
|
||||
|
||||
/*
|
||||
* Set the timestamp of an SCT (epoch time in milliseconds).
|
||||
*/
|
||||
void SCT_set_timestamp(SCT *sct, uint64_t timestamp);
|
||||
|
||||
/*
|
||||
* Return the NID for the signature used by the SCT.
|
||||
* For CT v1, this will be either NID_sha256WithRSAEncryption or
|
||||
* NID_ecdsa_with_SHA256 (or NID_undef if incorrect/unset).
|
||||
*/
|
||||
int SCT_get_signature_nid(const SCT *sct);
|
||||
|
||||
/*
|
||||
* Set the signature type of an SCT
|
||||
* For CT v1, this should be either NID_sha256WithRSAEncryption or
|
||||
* NID_ecdsa_with_SHA256.
|
||||
* Returns 1 on success, 0 otherwise.
|
||||
*/
|
||||
__owur int SCT_set_signature_nid(SCT *sct, int nid);
|
||||
|
||||
/*
|
||||
* Set *ext to point to the extension data for the SCT. ext must not be NULL.
|
||||
* The SCT retains ownership of this pointer.
|
||||
* Returns length of the data pointed to.
|
||||
*/
|
||||
size_t SCT_get0_extensions(const SCT *sct, unsigned char **ext);
|
||||
|
||||
/*
|
||||
* Set the extensions of an SCT to point directly to the *ext specified.
|
||||
* The SCT takes ownership of the specified pointer.
|
||||
*/
|
||||
void SCT_set0_extensions(SCT *sct, unsigned char *ext, size_t ext_len);
|
||||
|
||||
/*
|
||||
* Set the extensions of an SCT.
|
||||
* This takes a copy of the ext.
|
||||
* Returns 1 on success, 0 otherwise.
|
||||
*/
|
||||
__owur int SCT_set1_extensions(SCT *sct, const unsigned char *ext,
|
||||
size_t ext_len);
|
||||
|
||||
/*
|
||||
* Set *sig to point to the signature for the SCT. sig must not be NULL.
|
||||
* The SCT retains ownership of this pointer.
|
||||
* Returns length of the data pointed to.
|
||||
*/
|
||||
size_t SCT_get0_signature(const SCT *sct, unsigned char **sig);
|
||||
|
||||
/*
|
||||
* Set the signature of an SCT to point directly to the *sig specified.
|
||||
* The SCT takes ownership of the specified pointer.
|
||||
*/
|
||||
void SCT_set0_signature(SCT *sct, unsigned char *sig, size_t sig_len);
|
||||
|
||||
/*
|
||||
* Set the signature of an SCT to be a copy of the *sig specified.
|
||||
* Returns 1 on success, 0 otherwise.
|
||||
*/
|
||||
__owur int SCT_set1_signature(SCT *sct, const unsigned char *sig,
|
||||
size_t sig_len);
|
||||
|
||||
/*
|
||||
* The origin of this SCT, e.g. TLS extension, OCSP response, etc.
|
||||
*/
|
||||
sct_source_t SCT_get_source(const SCT *sct);
|
||||
|
||||
/*
|
||||
* Set the origin of this SCT, e.g. TLS extension, OCSP response, etc.
|
||||
* Returns 1 on success, 0 otherwise.
|
||||
*/
|
||||
__owur int SCT_set_source(SCT *sct, sct_source_t source);
|
||||
|
||||
/*
|
||||
* Returns a text string describing the validation status of |sct|.
|
||||
*/
|
||||
const char *SCT_validation_status_string(const SCT *sct);
|
||||
|
||||
/*
|
||||
* Pretty-prints an |sct| to |out|.
|
||||
* It will be indented by the number of spaces specified by |indent|.
|
||||
* If |logs| is not NULL, it will be used to lookup the CT log that the SCT came
|
||||
* from, so that the log name can be printed.
|
||||
*/
|
||||
void SCT_print(const SCT *sct, BIO *out, int indent, const CTLOG_STORE *logs);
|
||||
|
||||
/*
|
||||
* Pretty-prints an |sct_list| to |out|.
|
||||
* It will be indented by the number of spaces specified by |indent|.
|
||||
* SCTs will be delimited by |separator|.
|
||||
* If |logs| is not NULL, it will be used to lookup the CT log that each SCT
|
||||
* came from, so that the log names can be printed.
|
||||
*/
|
||||
void SCT_LIST_print(const STACK_OF(SCT) *sct_list, BIO *out, int indent,
|
||||
const char *separator, const CTLOG_STORE *logs);
|
||||
|
||||
/*
|
||||
* Gets the last result of validating this SCT.
|
||||
* If it has not been validated yet, returns SCT_VALIDATION_STATUS_NOT_SET.
|
||||
*/
|
||||
sct_validation_status_t SCT_get_validation_status(const SCT *sct);
|
||||
|
||||
/*
|
||||
* Validates the given SCT with the provided context.
|
||||
* Sets the "validation_status" field of the SCT.
|
||||
* Returns 1 if the SCT is valid and the signature verifies.
|
||||
* Returns 0 if the SCT is invalid or could not be verified.
|
||||
* Returns -1 if an error occurs.
|
||||
*/
|
||||
__owur int SCT_validate(SCT *sct, const CT_POLICY_EVAL_CTX *ctx);
|
||||
|
||||
/*
|
||||
* Validates the given list of SCTs with the provided context.
|
||||
* Sets the "validation_status" field of each SCT.
|
||||
* Returns 1 if there are no invalid SCTs and all signatures verify.
|
||||
* Returns 0 if at least one SCT is invalid or could not be verified.
|
||||
* Returns a negative integer if an error occurs.
|
||||
*/
|
||||
__owur int SCT_LIST_validate(const STACK_OF(SCT) *scts,
|
||||
CT_POLICY_EVAL_CTX *ctx);
|
||||
|
||||
|
||||
/*********************************
|
||||
* SCT parsing and serialization *
|
||||
*********************************/
|
||||
|
||||
/*
|
||||
* Serialize (to TLS format) a stack of SCTs and return the length.
|
||||
* "a" must not be NULL.
|
||||
* If "pp" is NULL, just return the length of what would have been serialized.
|
||||
* If "pp" is not NULL and "*pp" is null, function will allocate a new pointer
|
||||
* for data that caller is responsible for freeing (only if function returns
|
||||
* successfully).
|
||||
* If "pp" is NULL and "*pp" is not NULL, caller is responsible for ensuring
|
||||
* that "*pp" is large enough to accept all of the serialized data.
|
||||
* Returns < 0 on error, >= 0 indicating bytes written (or would have been)
|
||||
* on success.
|
||||
*/
|
||||
__owur int i2o_SCT_LIST(const STACK_OF(SCT) *a, unsigned char **pp);
|
||||
|
||||
/*
|
||||
* Convert TLS format SCT list to a stack of SCTs.
|
||||
* If "a" or "*a" is NULL, a new stack will be created that the caller is
|
||||
* responsible for freeing (by calling SCT_LIST_free).
|
||||
* "**pp" and "*pp" must not be NULL.
|
||||
* Upon success, "*pp" will point to after the last bytes read, and a stack
|
||||
* will be returned.
|
||||
* Upon failure, a NULL pointer will be returned, and the position of "*pp" is
|
||||
* not defined.
|
||||
*/
|
||||
STACK_OF(SCT) *o2i_SCT_LIST(STACK_OF(SCT) **a, const unsigned char **pp,
|
||||
size_t len);
|
||||
|
||||
/*
|
||||
* Serialize (to DER format) a stack of SCTs and return the length.
|
||||
* "a" must not be NULL.
|
||||
* If "pp" is NULL, just returns the length of what would have been serialized.
|
||||
* If "pp" is not NULL and "*pp" is null, function will allocate a new pointer
|
||||
* for data that caller is responsible for freeing (only if function returns
|
||||
* successfully).
|
||||
* If "pp" is NULL and "*pp" is not NULL, caller is responsible for ensuring
|
||||
* that "*pp" is large enough to accept all of the serialized data.
|
||||
* Returns < 0 on error, >= 0 indicating bytes written (or would have been)
|
||||
* on success.
|
||||
*/
|
||||
__owur int i2d_SCT_LIST(const STACK_OF(SCT) *a, unsigned char **pp);
|
||||
|
||||
/*
|
||||
* Parses an SCT list in DER format and returns it.
|
||||
* If "a" or "*a" is NULL, a new stack will be created that the caller is
|
||||
* responsible for freeing (by calling SCT_LIST_free).
|
||||
* "**pp" and "*pp" must not be NULL.
|
||||
* Upon success, "*pp" will point to after the last bytes read, and a stack
|
||||
* will be returned.
|
||||
* Upon failure, a NULL pointer will be returned, and the position of "*pp" is
|
||||
* not defined.
|
||||
*/
|
||||
STACK_OF(SCT) *d2i_SCT_LIST(STACK_OF(SCT) **a, const unsigned char **pp,
|
||||
long len);
|
||||
|
||||
/*
|
||||
* Serialize (to TLS format) an |sct| and write it to |out|.
|
||||
* If |out| is null, no SCT will be output but the length will still be returned.
|
||||
* If |out| points to a null pointer, a string will be allocated to hold the
|
||||
* TLS-format SCT. It is the responsibility of the caller to free it.
|
||||
* If |out| points to an allocated string, the TLS-format SCT will be written
|
||||
* to it.
|
||||
* The length of the SCT in TLS format will be returned.
|
||||
*/
|
||||
__owur int i2o_SCT(const SCT *sct, unsigned char **out);
|
||||
|
||||
/*
|
||||
* Parses an SCT in TLS format and returns it.
|
||||
* If |psct| is not null, it will end up pointing to the parsed SCT. If it
|
||||
* already points to a non-null pointer, the pointer will be free'd.
|
||||
* |in| should be a pointer to a string containing the TLS-format SCT.
|
||||
* |in| will be advanced to the end of the SCT if parsing succeeds.
|
||||
* |len| should be the length of the SCT in |in|.
|
||||
* Returns NULL if an error occurs.
|
||||
* If the SCT is an unsupported version, only the SCT's 'sct' and 'sct_len'
|
||||
* fields will be populated (with |in| and |len| respectively).
|
||||
*/
|
||||
SCT *o2i_SCT(SCT **psct, const unsigned char **in, size_t len);
|
||||
|
||||
/********************
|
||||
* CT log functions *
|
||||
********************/
|
||||
|
||||
/*
|
||||
* Creates a new CT log instance with the given |public_key| and |name| and
|
||||
* associates it with the give library context |libctx| and property query
|
||||
* string |propq|.
|
||||
* Takes ownership of |public_key| but copies |name|.
|
||||
* Returns NULL if malloc fails or if |public_key| cannot be converted to DER.
|
||||
* Should be deleted by the caller using CTLOG_free when no longer needed.
|
||||
*/
|
||||
CTLOG *CTLOG_new_ex(EVP_PKEY *public_key, const char *name, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
|
||||
/*
|
||||
* The same as CTLOG_new_ex except that the default library context and
|
||||
* property query string are used.
|
||||
*/
|
||||
CTLOG *CTLOG_new(EVP_PKEY *public_key, const char *name);
|
||||
|
||||
/*
|
||||
* Creates a new CTLOG instance with the base64-encoded SubjectPublicKeyInfo DER
|
||||
* in |pkey_base64| and associated with the given library context |libctx| and
|
||||
* property query string |propq|. The |name| is a string to help users identify
|
||||
* this log.
|
||||
* Returns 1 on success, 0 on failure.
|
||||
* Should be deleted by the caller using CTLOG_free when no longer needed.
|
||||
*/
|
||||
int CTLOG_new_from_base64_ex(CTLOG **ct_log, const char *pkey_base64,
|
||||
const char *name, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
|
||||
/*
|
||||
* The same as CTLOG_new_from_base64_ex() except that the default
|
||||
* library context and property query string are used.
|
||||
* Returns 1 on success, 0 on failure.
|
||||
*/
|
||||
int CTLOG_new_from_base64(CTLOG ** ct_log,
|
||||
const char *pkey_base64, const char *name);
|
||||
|
||||
/*
|
||||
* Deletes a CT log instance and its fields.
|
||||
*/
|
||||
void CTLOG_free(CTLOG *log);
|
||||
|
||||
/* Gets the name of the CT log */
|
||||
const char *CTLOG_get0_name(const CTLOG *log);
|
||||
/* Gets the ID of the CT log */
|
||||
void CTLOG_get0_log_id(const CTLOG *log, const uint8_t **log_id,
|
||||
size_t *log_id_len);
|
||||
/* Gets the public key of the CT log */
|
||||
EVP_PKEY *CTLOG_get0_public_key(const CTLOG *log);
|
||||
|
||||
/**************************
|
||||
* CT log store functions *
|
||||
**************************/
|
||||
|
||||
/*
|
||||
* Creates a new CT log store and associates it with the given libctx and
|
||||
* property query string.
|
||||
* Should be deleted by the caller using CTLOG_STORE_free when no longer needed.
|
||||
*/
|
||||
CTLOG_STORE *CTLOG_STORE_new_ex(OSSL_LIB_CTX *libctx, const char *propq);
|
||||
|
||||
/*
|
||||
* Same as CTLOG_STORE_new_ex except that the default libctx and
|
||||
* property query string are used.
|
||||
* Should be deleted by the caller using CTLOG_STORE_free when no longer needed.
|
||||
*/
|
||||
CTLOG_STORE *CTLOG_STORE_new(void);
|
||||
|
||||
/*
|
||||
* Deletes a CT log store and all of the CT log instances held within.
|
||||
*/
|
||||
void CTLOG_STORE_free(CTLOG_STORE *store);
|
||||
|
||||
/*
|
||||
* Finds a CT log in the store based on its log ID.
|
||||
* Returns the CT log, or NULL if no match is found.
|
||||
*/
|
||||
const CTLOG *CTLOG_STORE_get0_log_by_id(const CTLOG_STORE *store,
|
||||
const uint8_t *log_id,
|
||||
size_t log_id_len);
|
||||
|
||||
/*
|
||||
* Loads a CT log list into a |store| from a |file|.
|
||||
* Returns 1 if loading is successful, or 0 otherwise.
|
||||
*/
|
||||
__owur int CTLOG_STORE_load_file(CTLOG_STORE *store, const char *file);
|
||||
|
||||
/*
|
||||
* Loads the default CT log list into a |store|.
|
||||
* Returns 1 if loading is successful, or 0 otherwise.
|
||||
*/
|
||||
__owur int CTLOG_STORE_load_default_file(CTLOG_STORE *store);
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
504
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/err.h
generated
vendored
Normal file
504
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/err.h
generated
vendored
Normal file
@@ -0,0 +1,504 @@
|
||||
/*
|
||||
* Copyright 1995-2022 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_ERR_H
|
||||
# define OPENSSL_ERR_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_ERR_H
|
||||
# endif
|
||||
|
||||
# include <openssl/e_os2.h>
|
||||
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
# include <stdio.h>
|
||||
# include <stdlib.h>
|
||||
# endif
|
||||
|
||||
# include <openssl/types.h>
|
||||
# include <openssl/bio.h>
|
||||
# include <openssl/lhash.h>
|
||||
# include <openssl/cryptoerr_legacy.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# ifndef OPENSSL_NO_FILENAMES
|
||||
# define ERR_PUT_error(l,f,r,fn,ln) ERR_put_error(l,f,r,fn,ln)
|
||||
# else
|
||||
# define ERR_PUT_error(l,f,r,fn,ln) ERR_put_error(l,f,r,NULL,0)
|
||||
# endif
|
||||
# endif
|
||||
|
||||
# include <limits.h>
|
||||
# include <errno.h>
|
||||
|
||||
# define ERR_TXT_MALLOCED 0x01
|
||||
# define ERR_TXT_STRING 0x02
|
||||
|
||||
# if !defined(OPENSSL_NO_DEPRECATED_3_0) || defined(OSSL_FORCE_ERR_STATE)
|
||||
# define ERR_FLAG_MARK 0x01
|
||||
# define ERR_FLAG_CLEAR 0x02
|
||||
|
||||
# define ERR_NUM_ERRORS 16
|
||||
struct err_state_st {
|
||||
int err_flags[ERR_NUM_ERRORS];
|
||||
int err_marks[ERR_NUM_ERRORS];
|
||||
unsigned long err_buffer[ERR_NUM_ERRORS];
|
||||
char *err_data[ERR_NUM_ERRORS];
|
||||
size_t err_data_size[ERR_NUM_ERRORS];
|
||||
int err_data_flags[ERR_NUM_ERRORS];
|
||||
char *err_file[ERR_NUM_ERRORS];
|
||||
int err_line[ERR_NUM_ERRORS];
|
||||
char *err_func[ERR_NUM_ERRORS];
|
||||
int top, bottom;
|
||||
};
|
||||
# endif
|
||||
|
||||
/* library */
|
||||
# define ERR_LIB_NONE 1
|
||||
# define ERR_LIB_SYS 2
|
||||
# define ERR_LIB_BN 3
|
||||
# define ERR_LIB_RSA 4
|
||||
# define ERR_LIB_DH 5
|
||||
# define ERR_LIB_EVP 6
|
||||
# define ERR_LIB_BUF 7
|
||||
# define ERR_LIB_OBJ 8
|
||||
# define ERR_LIB_PEM 9
|
||||
# define ERR_LIB_DSA 10
|
||||
# define ERR_LIB_X509 11
|
||||
/* #define ERR_LIB_METH 12 */
|
||||
# define ERR_LIB_ASN1 13
|
||||
# define ERR_LIB_CONF 14
|
||||
# define ERR_LIB_CRYPTO 15
|
||||
# define ERR_LIB_EC 16
|
||||
# define ERR_LIB_SSL 20
|
||||
/* #define ERR_LIB_SSL23 21 */
|
||||
/* #define ERR_LIB_SSL2 22 */
|
||||
/* #define ERR_LIB_SSL3 23 */
|
||||
/* #define ERR_LIB_RSAREF 30 */
|
||||
/* #define ERR_LIB_PROXY 31 */
|
||||
# define ERR_LIB_BIO 32
|
||||
# define ERR_LIB_PKCS7 33
|
||||
# define ERR_LIB_X509V3 34
|
||||
# define ERR_LIB_PKCS12 35
|
||||
# define ERR_LIB_RAND 36
|
||||
# define ERR_LIB_DSO 37
|
||||
# define ERR_LIB_ENGINE 38
|
||||
# define ERR_LIB_OCSP 39
|
||||
# define ERR_LIB_UI 40
|
||||
# define ERR_LIB_COMP 41
|
||||
# define ERR_LIB_ECDSA 42
|
||||
# define ERR_LIB_ECDH 43
|
||||
# define ERR_LIB_OSSL_STORE 44
|
||||
# define ERR_LIB_FIPS 45
|
||||
# define ERR_LIB_CMS 46
|
||||
# define ERR_LIB_TS 47
|
||||
# define ERR_LIB_HMAC 48
|
||||
/* # define ERR_LIB_JPAKE 49 */
|
||||
# define ERR_LIB_CT 50
|
||||
# define ERR_LIB_ASYNC 51
|
||||
# define ERR_LIB_KDF 52
|
||||
# define ERR_LIB_SM2 53
|
||||
# define ERR_LIB_ESS 54
|
||||
# define ERR_LIB_PROP 55
|
||||
# define ERR_LIB_CRMF 56
|
||||
# define ERR_LIB_PROV 57
|
||||
# define ERR_LIB_CMP 58
|
||||
# define ERR_LIB_OSSL_ENCODER 59
|
||||
# define ERR_LIB_OSSL_DECODER 60
|
||||
# define ERR_LIB_HTTP 61
|
||||
|
||||
# define ERR_LIB_USER 128
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define ASN1err(f, r) ERR_raise_data(ERR_LIB_ASN1, (r), NULL)
|
||||
# define ASYNCerr(f, r) ERR_raise_data(ERR_LIB_ASYNC, (r), NULL)
|
||||
# define BIOerr(f, r) ERR_raise_data(ERR_LIB_BIO, (r), NULL)
|
||||
# define BNerr(f, r) ERR_raise_data(ERR_LIB_BN, (r), NULL)
|
||||
# define BUFerr(f, r) ERR_raise_data(ERR_LIB_BUF, (r), NULL)
|
||||
# define CMPerr(f, r) ERR_raise_data(ERR_LIB_CMP, (r), NULL)
|
||||
# define CMSerr(f, r) ERR_raise_data(ERR_LIB_CMS, (r), NULL)
|
||||
# define COMPerr(f, r) ERR_raise_data(ERR_LIB_COMP, (r), NULL)
|
||||
# define CONFerr(f, r) ERR_raise_data(ERR_LIB_CONF, (r), NULL)
|
||||
# define CRMFerr(f, r) ERR_raise_data(ERR_LIB_CRMF, (r), NULL)
|
||||
# define CRYPTOerr(f, r) ERR_raise_data(ERR_LIB_CRYPTO, (r), NULL)
|
||||
# define CTerr(f, r) ERR_raise_data(ERR_LIB_CT, (r), NULL)
|
||||
# define DHerr(f, r) ERR_raise_data(ERR_LIB_DH, (r), NULL)
|
||||
# define DSAerr(f, r) ERR_raise_data(ERR_LIB_DSA, (r), NULL)
|
||||
# define DSOerr(f, r) ERR_raise_data(ERR_LIB_DSO, (r), NULL)
|
||||
# define ECDHerr(f, r) ERR_raise_data(ERR_LIB_ECDH, (r), NULL)
|
||||
# define ECDSAerr(f, r) ERR_raise_data(ERR_LIB_ECDSA, (r), NULL)
|
||||
# define ECerr(f, r) ERR_raise_data(ERR_LIB_EC, (r), NULL)
|
||||
# define ENGINEerr(f, r) ERR_raise_data(ERR_LIB_ENGINE, (r), NULL)
|
||||
# define ESSerr(f, r) ERR_raise_data(ERR_LIB_ESS, (r), NULL)
|
||||
# define EVPerr(f, r) ERR_raise_data(ERR_LIB_EVP, (r), NULL)
|
||||
# define FIPSerr(f, r) ERR_raise_data(ERR_LIB_FIPS, (r), NULL)
|
||||
# define HMACerr(f, r) ERR_raise_data(ERR_LIB_HMAC, (r), NULL)
|
||||
# define HTTPerr(f, r) ERR_raise_data(ERR_LIB_HTTP, (r), NULL)
|
||||
# define KDFerr(f, r) ERR_raise_data(ERR_LIB_KDF, (r), NULL)
|
||||
# define OBJerr(f, r) ERR_raise_data(ERR_LIB_OBJ, (r), NULL)
|
||||
# define OCSPerr(f, r) ERR_raise_data(ERR_LIB_OCSP, (r), NULL)
|
||||
# define OSSL_STOREerr(f, r) ERR_raise_data(ERR_LIB_OSSL_STORE, (r), NULL)
|
||||
# define PEMerr(f, r) ERR_raise_data(ERR_LIB_PEM, (r), NULL)
|
||||
# define PKCS12err(f, r) ERR_raise_data(ERR_LIB_PKCS12, (r), NULL)
|
||||
# define PKCS7err(f, r) ERR_raise_data(ERR_LIB_PKCS7, (r), NULL)
|
||||
# define PROPerr(f, r) ERR_raise_data(ERR_LIB_PROP, (r), NULL)
|
||||
# define PROVerr(f, r) ERR_raise_data(ERR_LIB_PROV, (r), NULL)
|
||||
# define RANDerr(f, r) ERR_raise_data(ERR_LIB_RAND, (r), NULL)
|
||||
# define RSAerr(f, r) ERR_raise_data(ERR_LIB_RSA, (r), NULL)
|
||||
# define KDFerr(f, r) ERR_raise_data(ERR_LIB_KDF, (r), NULL)
|
||||
# define SM2err(f, r) ERR_raise_data(ERR_LIB_SM2, (r), NULL)
|
||||
# define SSLerr(f, r) ERR_raise_data(ERR_LIB_SSL, (r), NULL)
|
||||
# define SYSerr(f, r) ERR_raise_data(ERR_LIB_SYS, (r), NULL)
|
||||
# define TSerr(f, r) ERR_raise_data(ERR_LIB_TS, (r), NULL)
|
||||
# define UIerr(f, r) ERR_raise_data(ERR_LIB_UI, (r), NULL)
|
||||
# define X509V3err(f, r) ERR_raise_data(ERR_LIB_X509V3, (r), NULL)
|
||||
# define X509err(f, r) ERR_raise_data(ERR_LIB_X509, (r), NULL)
|
||||
# endif
|
||||
|
||||
/*-
|
||||
* The error code packs differently depending on if it records a system
|
||||
* error or an OpenSSL error.
|
||||
*
|
||||
* A system error packs like this (we follow POSIX and only allow positive
|
||||
* numbers that fit in an |int|):
|
||||
*
|
||||
* +-+-------------------------------------------------------------+
|
||||
* |1| system error number |
|
||||
* +-+-------------------------------------------------------------+
|
||||
*
|
||||
* An OpenSSL error packs like this:
|
||||
*
|
||||
* <---------------------------- 32 bits -------------------------->
|
||||
* <--- 8 bits ---><------------------ 23 bits ----------------->
|
||||
* +-+---------------+---------------------------------------------+
|
||||
* |0| library | reason |
|
||||
* +-+---------------+---------------------------------------------+
|
||||
*
|
||||
* A few of the reason bits are reserved as flags with special meaning:
|
||||
*
|
||||
* <5 bits-<>--------- 19 bits ----------------->
|
||||
* +-------+-+-----------------------------------+
|
||||
* | rflags| | reason |
|
||||
* +-------+-+-----------------------------------+
|
||||
* ^
|
||||
* |
|
||||
* ERR_RFLAG_FATAL = ERR_R_FATAL
|
||||
*
|
||||
* The reason flags are part of the overall reason code for practical
|
||||
* reasons, as they provide an easy way to place different types of
|
||||
* reason codes in different numeric ranges.
|
||||
*
|
||||
* The currently known reason flags are:
|
||||
*
|
||||
* ERR_RFLAG_FATAL Flags that the reason code is considered fatal.
|
||||
* For backward compatibility reasons, this flag
|
||||
* is also the code for ERR_R_FATAL (that reason
|
||||
* code served the dual purpose of flag and reason
|
||||
* code in one in pre-3.0 OpenSSL).
|
||||
* ERR_RFLAG_COMMON Flags that the reason code is common to all
|
||||
* libraries. All ERR_R_ macros must use this flag,
|
||||
* and no other _R_ macro is allowed to use it.
|
||||
*/
|
||||
|
||||
/* Macros to help decode recorded system errors */
|
||||
# define ERR_SYSTEM_FLAG ((unsigned int)INT_MAX + 1)
|
||||
# define ERR_SYSTEM_MASK ((unsigned int)INT_MAX)
|
||||
|
||||
/*
|
||||
* Macros to help decode recorded OpenSSL errors
|
||||
* As expressed above, RFLAGS and REASON overlap by one bit to allow
|
||||
* ERR_R_FATAL to use ERR_RFLAG_FATAL as its reason code.
|
||||
*/
|
||||
# define ERR_LIB_OFFSET 23L
|
||||
# define ERR_LIB_MASK 0xFF
|
||||
# define ERR_RFLAGS_OFFSET 18L
|
||||
# define ERR_RFLAGS_MASK 0x1F
|
||||
# define ERR_REASON_MASK 0X7FFFFF
|
||||
|
||||
/*
|
||||
* Reason flags are defined pre-shifted to easily combine with the reason
|
||||
* number.
|
||||
*/
|
||||
# define ERR_RFLAG_FATAL (0x1 << ERR_RFLAGS_OFFSET)
|
||||
# define ERR_RFLAG_COMMON (0x2 << ERR_RFLAGS_OFFSET)
|
||||
|
||||
# define ERR_SYSTEM_ERROR(errcode) (((errcode) & ERR_SYSTEM_FLAG) != 0)
|
||||
|
||||
static ossl_unused ossl_inline int ERR_GET_LIB(unsigned long errcode)
|
||||
{
|
||||
if (ERR_SYSTEM_ERROR(errcode))
|
||||
return ERR_LIB_SYS;
|
||||
return (errcode >> ERR_LIB_OFFSET) & ERR_LIB_MASK;
|
||||
}
|
||||
|
||||
static ossl_unused ossl_inline int ERR_GET_RFLAGS(unsigned long errcode)
|
||||
{
|
||||
if (ERR_SYSTEM_ERROR(errcode))
|
||||
return 0;
|
||||
return errcode & (ERR_RFLAGS_MASK << ERR_RFLAGS_OFFSET);
|
||||
}
|
||||
|
||||
static ossl_unused ossl_inline int ERR_GET_REASON(unsigned long errcode)
|
||||
{
|
||||
if (ERR_SYSTEM_ERROR(errcode))
|
||||
return errcode & ERR_SYSTEM_MASK;
|
||||
return errcode & ERR_REASON_MASK;
|
||||
}
|
||||
|
||||
static ossl_unused ossl_inline int ERR_FATAL_ERROR(unsigned long errcode)
|
||||
{
|
||||
return (ERR_GET_RFLAGS(errcode) & ERR_RFLAG_FATAL) != 0;
|
||||
}
|
||||
|
||||
static ossl_unused ossl_inline int ERR_COMMON_ERROR(unsigned long errcode)
|
||||
{
|
||||
return (ERR_GET_RFLAGS(errcode) & ERR_RFLAG_COMMON) != 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* ERR_PACK is a helper macro to properly pack OpenSSL error codes and may
|
||||
* only be used for that purpose. System errors are packed internally.
|
||||
* ERR_PACK takes reason flags and reason code combined in |reason|.
|
||||
* ERR_PACK ignores |func|, that parameter is just legacy from pre-3.0 OpenSSL.
|
||||
*/
|
||||
# define ERR_PACK(lib,func,reason) \
|
||||
( (((unsigned long)(lib) & ERR_LIB_MASK ) << ERR_LIB_OFFSET) | \
|
||||
(((unsigned long)(reason) & ERR_REASON_MASK)) )
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define SYS_F_FOPEN 0
|
||||
# define SYS_F_CONNECT 0
|
||||
# define SYS_F_GETSERVBYNAME 0
|
||||
# define SYS_F_SOCKET 0
|
||||
# define SYS_F_IOCTLSOCKET 0
|
||||
# define SYS_F_BIND 0
|
||||
# define SYS_F_LISTEN 0
|
||||
# define SYS_F_ACCEPT 0
|
||||
# define SYS_F_WSASTARTUP 0
|
||||
# define SYS_F_OPENDIR 0
|
||||
# define SYS_F_FREAD 0
|
||||
# define SYS_F_GETADDRINFO 0
|
||||
# define SYS_F_GETNAMEINFO 0
|
||||
# define SYS_F_SETSOCKOPT 0
|
||||
# define SYS_F_GETSOCKOPT 0
|
||||
# define SYS_F_GETSOCKNAME 0
|
||||
# define SYS_F_GETHOSTBYNAME 0
|
||||
# define SYS_F_FFLUSH 0
|
||||
# define SYS_F_OPEN 0
|
||||
# define SYS_F_CLOSE 0
|
||||
# define SYS_F_IOCTL 0
|
||||
# define SYS_F_STAT 0
|
||||
# define SYS_F_FCNTL 0
|
||||
# define SYS_F_FSTAT 0
|
||||
# define SYS_F_SENDFILE 0
|
||||
# endif
|
||||
|
||||
/*
|
||||
* All ERR_R_ codes must be combined with ERR_RFLAG_COMMON.
|
||||
*/
|
||||
|
||||
/* "we came from here" global reason codes, range 1..255 */
|
||||
# define ERR_R_SYS_LIB (ERR_LIB_SYS/* 2 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_BN_LIB (ERR_LIB_BN/* 3 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_RSA_LIB (ERR_LIB_RSA/* 4 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_DH_LIB (ERR_LIB_DH/* 5 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_EVP_LIB (ERR_LIB_EVP/* 6 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_BUF_LIB (ERR_LIB_BUF/* 7 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_OBJ_LIB (ERR_LIB_OBJ/* 8 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_PEM_LIB (ERR_LIB_PEM/* 9 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_DSA_LIB (ERR_LIB_DSA/* 10 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_X509_LIB (ERR_LIB_X509/* 11 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_ASN1_LIB (ERR_LIB_ASN1/* 13 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_CONF_LIB (ERR_LIB_CONF/* 14 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_CRYPTO_LIB (ERR_LIB_CRYPTO/* 15 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_EC_LIB (ERR_LIB_EC/* 16 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_SSL_LIB (ERR_LIB_SSL/* 20 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_BIO_LIB (ERR_LIB_BIO/* 32 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_PKCS7_LIB (ERR_LIB_PKCS7/* 33 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_X509V3_LIB (ERR_LIB_X509V3/* 34 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_PKCS12_LIB (ERR_LIB_PKCS12/* 35 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_RAND_LIB (ERR_LIB_RAND/* 36 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_DSO_LIB (ERR_LIB_DSO/* 37 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_ENGINE_LIB (ERR_LIB_ENGINE/* 38 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_UI_LIB (ERR_LIB_UI/* 40 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_ECDSA_LIB (ERR_LIB_ECDSA/* 42 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_OSSL_STORE_LIB (ERR_LIB_OSSL_STORE/* 44 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_CMS_LIB (ERR_LIB_CMS/* 46 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_TS_LIB (ERR_LIB_TS/* 47 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_CT_LIB (ERR_LIB_CT/* 50 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_PROV_LIB (ERR_LIB_PROV/* 57 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_ESS_LIB (ERR_LIB_ESS/* 54 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_CMP_LIB (ERR_LIB_CMP/* 58 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_OSSL_ENCODER_LIB (ERR_LIB_OSSL_ENCODER/* 59 */ | ERR_RFLAG_COMMON)
|
||||
# define ERR_R_OSSL_DECODER_LIB (ERR_LIB_OSSL_DECODER/* 60 */ | ERR_RFLAG_COMMON)
|
||||
|
||||
/* Other common error codes, range 256..2^ERR_RFLAGS_OFFSET-1 */
|
||||
# define ERR_R_FATAL (ERR_RFLAG_FATAL|ERR_RFLAG_COMMON)
|
||||
# define ERR_R_MALLOC_FAILURE (256|ERR_R_FATAL)
|
||||
# define ERR_R_SHOULD_NOT_HAVE_BEEN_CALLED (257|ERR_R_FATAL)
|
||||
# define ERR_R_PASSED_NULL_PARAMETER (258|ERR_R_FATAL)
|
||||
# define ERR_R_INTERNAL_ERROR (259|ERR_R_FATAL)
|
||||
# define ERR_R_DISABLED (260|ERR_R_FATAL)
|
||||
# define ERR_R_INIT_FAIL (261|ERR_R_FATAL)
|
||||
# define ERR_R_PASSED_INVALID_ARGUMENT (262|ERR_RFLAG_COMMON)
|
||||
# define ERR_R_OPERATION_FAIL (263|ERR_R_FATAL)
|
||||
# define ERR_R_INVALID_PROVIDER_FUNCTIONS (264|ERR_R_FATAL)
|
||||
# define ERR_R_INTERRUPTED_OR_CANCELLED (265|ERR_RFLAG_COMMON)
|
||||
# define ERR_R_NESTED_ASN1_ERROR (266|ERR_RFLAG_COMMON)
|
||||
# define ERR_R_MISSING_ASN1_EOS (267|ERR_RFLAG_COMMON)
|
||||
# define ERR_R_UNSUPPORTED (268|ERR_RFLAG_COMMON)
|
||||
# define ERR_R_FETCH_FAILED (269|ERR_RFLAG_COMMON)
|
||||
# define ERR_R_INVALID_PROPERTY_DEFINITION (270|ERR_RFLAG_COMMON)
|
||||
# define ERR_R_UNABLE_TO_GET_READ_LOCK (271|ERR_R_FATAL)
|
||||
# define ERR_R_UNABLE_TO_GET_WRITE_LOCK (272|ERR_R_FATAL)
|
||||
|
||||
typedef struct ERR_string_data_st {
|
||||
unsigned long error;
|
||||
const char *string;
|
||||
} ERR_STRING_DATA;
|
||||
|
||||
DEFINE_LHASH_OF_INTERNAL(ERR_STRING_DATA);
|
||||
#define lh_ERR_STRING_DATA_new(hfn, cmp) ((LHASH_OF(ERR_STRING_DATA) *)OPENSSL_LH_new(ossl_check_ERR_STRING_DATA_lh_hashfunc_type(hfn), ossl_check_ERR_STRING_DATA_lh_compfunc_type(cmp)))
|
||||
#define lh_ERR_STRING_DATA_free(lh) OPENSSL_LH_free(ossl_check_ERR_STRING_DATA_lh_type(lh))
|
||||
#define lh_ERR_STRING_DATA_flush(lh) OPENSSL_LH_flush(ossl_check_ERR_STRING_DATA_lh_type(lh))
|
||||
#define lh_ERR_STRING_DATA_insert(lh, ptr) ((ERR_STRING_DATA *)OPENSSL_LH_insert(ossl_check_ERR_STRING_DATA_lh_type(lh), ossl_check_ERR_STRING_DATA_lh_plain_type(ptr)))
|
||||
#define lh_ERR_STRING_DATA_delete(lh, ptr) ((ERR_STRING_DATA *)OPENSSL_LH_delete(ossl_check_ERR_STRING_DATA_lh_type(lh), ossl_check_const_ERR_STRING_DATA_lh_plain_type(ptr)))
|
||||
#define lh_ERR_STRING_DATA_retrieve(lh, ptr) ((ERR_STRING_DATA *)OPENSSL_LH_retrieve(ossl_check_ERR_STRING_DATA_lh_type(lh), ossl_check_const_ERR_STRING_DATA_lh_plain_type(ptr)))
|
||||
#define lh_ERR_STRING_DATA_error(lh) OPENSSL_LH_error(ossl_check_ERR_STRING_DATA_lh_type(lh))
|
||||
#define lh_ERR_STRING_DATA_num_items(lh) OPENSSL_LH_num_items(ossl_check_ERR_STRING_DATA_lh_type(lh))
|
||||
#define lh_ERR_STRING_DATA_node_stats_bio(lh, out) OPENSSL_LH_node_stats_bio(ossl_check_const_ERR_STRING_DATA_lh_type(lh), out)
|
||||
#define lh_ERR_STRING_DATA_node_usage_stats_bio(lh, out) OPENSSL_LH_node_usage_stats_bio(ossl_check_const_ERR_STRING_DATA_lh_type(lh), out)
|
||||
#define lh_ERR_STRING_DATA_stats_bio(lh, out) OPENSSL_LH_stats_bio(ossl_check_const_ERR_STRING_DATA_lh_type(lh), out)
|
||||
#define lh_ERR_STRING_DATA_get_down_load(lh) OPENSSL_LH_get_down_load(ossl_check_ERR_STRING_DATA_lh_type(lh))
|
||||
#define lh_ERR_STRING_DATA_set_down_load(lh, dl) OPENSSL_LH_set_down_load(ossl_check_ERR_STRING_DATA_lh_type(lh), dl)
|
||||
#define lh_ERR_STRING_DATA_doall(lh, dfn) OPENSSL_LH_doall(ossl_check_ERR_STRING_DATA_lh_type(lh), ossl_check_ERR_STRING_DATA_lh_doallfunc_type(dfn))
|
||||
|
||||
|
||||
/* 12 lines and some on an 80 column terminal */
|
||||
#define ERR_MAX_DATA_SIZE 1024
|
||||
|
||||
/* Building blocks */
|
||||
void ERR_new(void);
|
||||
void ERR_set_debug(const char *file, int line, const char *func);
|
||||
void ERR_set_error(int lib, int reason, const char *fmt, ...);
|
||||
void ERR_vset_error(int lib, int reason, const char *fmt, va_list args);
|
||||
|
||||
/* Main error raising functions */
|
||||
# define ERR_raise(lib, reason) ERR_raise_data((lib),(reason),NULL)
|
||||
# define ERR_raise_data \
|
||||
(ERR_new(), \
|
||||
ERR_set_debug(OPENSSL_FILE,OPENSSL_LINE,OPENSSL_FUNC), \
|
||||
ERR_set_error)
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
/* Backward compatibility */
|
||||
# define ERR_put_error(lib, func, reason, file, line) \
|
||||
(ERR_new(), \
|
||||
ERR_set_debug((file), (line), OPENSSL_FUNC), \
|
||||
ERR_set_error((lib), (reason), NULL))
|
||||
# endif
|
||||
|
||||
void ERR_set_error_data(char *data, int flags);
|
||||
|
||||
unsigned long ERR_get_error(void);
|
||||
unsigned long ERR_get_error_all(const char **file, int *line,
|
||||
const char **func,
|
||||
const char **data, int *flags);
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
unsigned long ERR_get_error_line(const char **file, int *line);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
unsigned long ERR_get_error_line_data(const char **file, int *line,
|
||||
const char **data, int *flags);
|
||||
#endif
|
||||
unsigned long ERR_peek_error(void);
|
||||
unsigned long ERR_peek_error_line(const char **file, int *line);
|
||||
unsigned long ERR_peek_error_func(const char **func);
|
||||
unsigned long ERR_peek_error_data(const char **data, int *flags);
|
||||
unsigned long ERR_peek_error_all(const char **file, int *line,
|
||||
const char **func,
|
||||
const char **data, int *flags);
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
unsigned long ERR_peek_error_line_data(const char **file, int *line,
|
||||
const char **data, int *flags);
|
||||
# endif
|
||||
unsigned long ERR_peek_last_error(void);
|
||||
unsigned long ERR_peek_last_error_line(const char **file, int *line);
|
||||
unsigned long ERR_peek_last_error_func(const char **func);
|
||||
unsigned long ERR_peek_last_error_data(const char **data, int *flags);
|
||||
unsigned long ERR_peek_last_error_all(const char **file, int *line,
|
||||
const char **func,
|
||||
const char **data, int *flags);
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
unsigned long ERR_peek_last_error_line_data(const char **file, int *line,
|
||||
const char **data, int *flags);
|
||||
# endif
|
||||
|
||||
void ERR_clear_error(void);
|
||||
|
||||
char *ERR_error_string(unsigned long e, char *buf);
|
||||
void ERR_error_string_n(unsigned long e, char *buf, size_t len);
|
||||
const char *ERR_lib_error_string(unsigned long e);
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0 const char *ERR_func_error_string(unsigned long e);
|
||||
# endif
|
||||
const char *ERR_reason_error_string(unsigned long e);
|
||||
|
||||
void ERR_print_errors_cb(int (*cb) (const char *str, size_t len, void *u),
|
||||
void *u);
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
void ERR_print_errors_fp(FILE *fp);
|
||||
# endif
|
||||
void ERR_print_errors(BIO *bp);
|
||||
|
||||
void ERR_add_error_data(int num, ...);
|
||||
void ERR_add_error_vdata(int num, va_list args);
|
||||
void ERR_add_error_txt(const char *sepr, const char *txt);
|
||||
void ERR_add_error_mem_bio(const char *sep, BIO *bio);
|
||||
|
||||
int ERR_load_strings(int lib, ERR_STRING_DATA *str);
|
||||
int ERR_load_strings_const(const ERR_STRING_DATA *str);
|
||||
int ERR_unload_strings(int lib, ERR_STRING_DATA *str);
|
||||
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# define ERR_load_crypto_strings() \
|
||||
OPENSSL_init_crypto(OPENSSL_INIT_LOAD_CRYPTO_STRINGS, NULL)
|
||||
# define ERR_free_strings() while(0) continue
|
||||
#endif
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
OSSL_DEPRECATEDIN_1_1_0 void ERR_remove_thread_state(void *);
|
||||
#endif
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_0_0
|
||||
OSSL_DEPRECATEDIN_1_0_0 void ERR_remove_state(unsigned long pid);
|
||||
#endif
|
||||
#ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
OSSL_DEPRECATEDIN_3_0 ERR_STATE *ERR_get_state(void);
|
||||
#endif
|
||||
|
||||
int ERR_get_next_error_library(void);
|
||||
|
||||
int ERR_set_mark(void);
|
||||
int ERR_pop_to_mark(void);
|
||||
int ERR_clear_last_mark(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
128
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ess.h
generated
vendored
Normal file
128
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ess.h
generated
vendored
Normal file
@@ -0,0 +1,128 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/ess.h.in
|
||||
*
|
||||
* Copyright 2019-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_ESS_H
|
||||
# define OPENSSL_ESS_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/opensslconf.h>
|
||||
|
||||
# include <openssl/safestack.h>
|
||||
# include <openssl/x509.h>
|
||||
# include <openssl/esserr.h>
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
|
||||
typedef struct ESS_issuer_serial ESS_ISSUER_SERIAL;
|
||||
typedef struct ESS_cert_id ESS_CERT_ID;
|
||||
typedef struct ESS_signing_cert ESS_SIGNING_CERT;
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(ESS_CERT_ID, ESS_CERT_ID, ESS_CERT_ID)
|
||||
#define sk_ESS_CERT_ID_num(sk) OPENSSL_sk_num(ossl_check_const_ESS_CERT_ID_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_value(sk, idx) ((ESS_CERT_ID *)OPENSSL_sk_value(ossl_check_const_ESS_CERT_ID_sk_type(sk), (idx)))
|
||||
#define sk_ESS_CERT_ID_new(cmp) ((STACK_OF(ESS_CERT_ID) *)OPENSSL_sk_new(ossl_check_ESS_CERT_ID_compfunc_type(cmp)))
|
||||
#define sk_ESS_CERT_ID_new_null() ((STACK_OF(ESS_CERT_ID) *)OPENSSL_sk_new_null())
|
||||
#define sk_ESS_CERT_ID_new_reserve(cmp, n) ((STACK_OF(ESS_CERT_ID) *)OPENSSL_sk_new_reserve(ossl_check_ESS_CERT_ID_compfunc_type(cmp), (n)))
|
||||
#define sk_ESS_CERT_ID_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_ESS_CERT_ID_sk_type(sk), (n))
|
||||
#define sk_ESS_CERT_ID_free(sk) OPENSSL_sk_free(ossl_check_ESS_CERT_ID_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_zero(sk) OPENSSL_sk_zero(ossl_check_ESS_CERT_ID_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_delete(sk, i) ((ESS_CERT_ID *)OPENSSL_sk_delete(ossl_check_ESS_CERT_ID_sk_type(sk), (i)))
|
||||
#define sk_ESS_CERT_ID_delete_ptr(sk, ptr) ((ESS_CERT_ID *)OPENSSL_sk_delete_ptr(ossl_check_ESS_CERT_ID_sk_type(sk), ossl_check_ESS_CERT_ID_type(ptr)))
|
||||
#define sk_ESS_CERT_ID_push(sk, ptr) OPENSSL_sk_push(ossl_check_ESS_CERT_ID_sk_type(sk), ossl_check_ESS_CERT_ID_type(ptr))
|
||||
#define sk_ESS_CERT_ID_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_ESS_CERT_ID_sk_type(sk), ossl_check_ESS_CERT_ID_type(ptr))
|
||||
#define sk_ESS_CERT_ID_pop(sk) ((ESS_CERT_ID *)OPENSSL_sk_pop(ossl_check_ESS_CERT_ID_sk_type(sk)))
|
||||
#define sk_ESS_CERT_ID_shift(sk) ((ESS_CERT_ID *)OPENSSL_sk_shift(ossl_check_ESS_CERT_ID_sk_type(sk)))
|
||||
#define sk_ESS_CERT_ID_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_ESS_CERT_ID_sk_type(sk),ossl_check_ESS_CERT_ID_freefunc_type(freefunc))
|
||||
#define sk_ESS_CERT_ID_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_ESS_CERT_ID_sk_type(sk), ossl_check_ESS_CERT_ID_type(ptr), (idx))
|
||||
#define sk_ESS_CERT_ID_set(sk, idx, ptr) ((ESS_CERT_ID *)OPENSSL_sk_set(ossl_check_ESS_CERT_ID_sk_type(sk), (idx), ossl_check_ESS_CERT_ID_type(ptr)))
|
||||
#define sk_ESS_CERT_ID_find(sk, ptr) OPENSSL_sk_find(ossl_check_ESS_CERT_ID_sk_type(sk), ossl_check_ESS_CERT_ID_type(ptr))
|
||||
#define sk_ESS_CERT_ID_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_ESS_CERT_ID_sk_type(sk), ossl_check_ESS_CERT_ID_type(ptr))
|
||||
#define sk_ESS_CERT_ID_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_ESS_CERT_ID_sk_type(sk), ossl_check_ESS_CERT_ID_type(ptr), pnum)
|
||||
#define sk_ESS_CERT_ID_sort(sk) OPENSSL_sk_sort(ossl_check_ESS_CERT_ID_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_ESS_CERT_ID_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_dup(sk) ((STACK_OF(ESS_CERT_ID) *)OPENSSL_sk_dup(ossl_check_const_ESS_CERT_ID_sk_type(sk)))
|
||||
#define sk_ESS_CERT_ID_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(ESS_CERT_ID) *)OPENSSL_sk_deep_copy(ossl_check_const_ESS_CERT_ID_sk_type(sk), ossl_check_ESS_CERT_ID_copyfunc_type(copyfunc), ossl_check_ESS_CERT_ID_freefunc_type(freefunc)))
|
||||
#define sk_ESS_CERT_ID_set_cmp_func(sk, cmp) ((sk_ESS_CERT_ID_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_ESS_CERT_ID_sk_type(sk), ossl_check_ESS_CERT_ID_compfunc_type(cmp)))
|
||||
|
||||
|
||||
|
||||
typedef struct ESS_signing_cert_v2_st ESS_SIGNING_CERT_V2;
|
||||
typedef struct ESS_cert_id_v2_st ESS_CERT_ID_V2;
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(ESS_CERT_ID_V2, ESS_CERT_ID_V2, ESS_CERT_ID_V2)
|
||||
#define sk_ESS_CERT_ID_V2_num(sk) OPENSSL_sk_num(ossl_check_const_ESS_CERT_ID_V2_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_V2_value(sk, idx) ((ESS_CERT_ID_V2 *)OPENSSL_sk_value(ossl_check_const_ESS_CERT_ID_V2_sk_type(sk), (idx)))
|
||||
#define sk_ESS_CERT_ID_V2_new(cmp) ((STACK_OF(ESS_CERT_ID_V2) *)OPENSSL_sk_new(ossl_check_ESS_CERT_ID_V2_compfunc_type(cmp)))
|
||||
#define sk_ESS_CERT_ID_V2_new_null() ((STACK_OF(ESS_CERT_ID_V2) *)OPENSSL_sk_new_null())
|
||||
#define sk_ESS_CERT_ID_V2_new_reserve(cmp, n) ((STACK_OF(ESS_CERT_ID_V2) *)OPENSSL_sk_new_reserve(ossl_check_ESS_CERT_ID_V2_compfunc_type(cmp), (n)))
|
||||
#define sk_ESS_CERT_ID_V2_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_ESS_CERT_ID_V2_sk_type(sk), (n))
|
||||
#define sk_ESS_CERT_ID_V2_free(sk) OPENSSL_sk_free(ossl_check_ESS_CERT_ID_V2_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_V2_zero(sk) OPENSSL_sk_zero(ossl_check_ESS_CERT_ID_V2_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_V2_delete(sk, i) ((ESS_CERT_ID_V2 *)OPENSSL_sk_delete(ossl_check_ESS_CERT_ID_V2_sk_type(sk), (i)))
|
||||
#define sk_ESS_CERT_ID_V2_delete_ptr(sk, ptr) ((ESS_CERT_ID_V2 *)OPENSSL_sk_delete_ptr(ossl_check_ESS_CERT_ID_V2_sk_type(sk), ossl_check_ESS_CERT_ID_V2_type(ptr)))
|
||||
#define sk_ESS_CERT_ID_V2_push(sk, ptr) OPENSSL_sk_push(ossl_check_ESS_CERT_ID_V2_sk_type(sk), ossl_check_ESS_CERT_ID_V2_type(ptr))
|
||||
#define sk_ESS_CERT_ID_V2_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_ESS_CERT_ID_V2_sk_type(sk), ossl_check_ESS_CERT_ID_V2_type(ptr))
|
||||
#define sk_ESS_CERT_ID_V2_pop(sk) ((ESS_CERT_ID_V2 *)OPENSSL_sk_pop(ossl_check_ESS_CERT_ID_V2_sk_type(sk)))
|
||||
#define sk_ESS_CERT_ID_V2_shift(sk) ((ESS_CERT_ID_V2 *)OPENSSL_sk_shift(ossl_check_ESS_CERT_ID_V2_sk_type(sk)))
|
||||
#define sk_ESS_CERT_ID_V2_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_ESS_CERT_ID_V2_sk_type(sk),ossl_check_ESS_CERT_ID_V2_freefunc_type(freefunc))
|
||||
#define sk_ESS_CERT_ID_V2_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_ESS_CERT_ID_V2_sk_type(sk), ossl_check_ESS_CERT_ID_V2_type(ptr), (idx))
|
||||
#define sk_ESS_CERT_ID_V2_set(sk, idx, ptr) ((ESS_CERT_ID_V2 *)OPENSSL_sk_set(ossl_check_ESS_CERT_ID_V2_sk_type(sk), (idx), ossl_check_ESS_CERT_ID_V2_type(ptr)))
|
||||
#define sk_ESS_CERT_ID_V2_find(sk, ptr) OPENSSL_sk_find(ossl_check_ESS_CERT_ID_V2_sk_type(sk), ossl_check_ESS_CERT_ID_V2_type(ptr))
|
||||
#define sk_ESS_CERT_ID_V2_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_ESS_CERT_ID_V2_sk_type(sk), ossl_check_ESS_CERT_ID_V2_type(ptr))
|
||||
#define sk_ESS_CERT_ID_V2_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_ESS_CERT_ID_V2_sk_type(sk), ossl_check_ESS_CERT_ID_V2_type(ptr), pnum)
|
||||
#define sk_ESS_CERT_ID_V2_sort(sk) OPENSSL_sk_sort(ossl_check_ESS_CERT_ID_V2_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_V2_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_ESS_CERT_ID_V2_sk_type(sk))
|
||||
#define sk_ESS_CERT_ID_V2_dup(sk) ((STACK_OF(ESS_CERT_ID_V2) *)OPENSSL_sk_dup(ossl_check_const_ESS_CERT_ID_V2_sk_type(sk)))
|
||||
#define sk_ESS_CERT_ID_V2_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(ESS_CERT_ID_V2) *)OPENSSL_sk_deep_copy(ossl_check_const_ESS_CERT_ID_V2_sk_type(sk), ossl_check_ESS_CERT_ID_V2_copyfunc_type(copyfunc), ossl_check_ESS_CERT_ID_V2_freefunc_type(freefunc)))
|
||||
#define sk_ESS_CERT_ID_V2_set_cmp_func(sk, cmp) ((sk_ESS_CERT_ID_V2_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_ESS_CERT_ID_V2_sk_type(sk), ossl_check_ESS_CERT_ID_V2_compfunc_type(cmp)))
|
||||
|
||||
|
||||
DECLARE_ASN1_ALLOC_FUNCTIONS(ESS_ISSUER_SERIAL)
|
||||
DECLARE_ASN1_ENCODE_FUNCTIONS_only(ESS_ISSUER_SERIAL, ESS_ISSUER_SERIAL)
|
||||
DECLARE_ASN1_DUP_FUNCTION(ESS_ISSUER_SERIAL)
|
||||
|
||||
DECLARE_ASN1_ALLOC_FUNCTIONS(ESS_CERT_ID)
|
||||
DECLARE_ASN1_ENCODE_FUNCTIONS_only(ESS_CERT_ID, ESS_CERT_ID)
|
||||
DECLARE_ASN1_DUP_FUNCTION(ESS_CERT_ID)
|
||||
|
||||
DECLARE_ASN1_FUNCTIONS(ESS_SIGNING_CERT)
|
||||
DECLARE_ASN1_DUP_FUNCTION(ESS_SIGNING_CERT)
|
||||
|
||||
DECLARE_ASN1_ALLOC_FUNCTIONS(ESS_CERT_ID_V2)
|
||||
DECLARE_ASN1_ENCODE_FUNCTIONS_only(ESS_CERT_ID_V2, ESS_CERT_ID_V2)
|
||||
DECLARE_ASN1_DUP_FUNCTION(ESS_CERT_ID_V2)
|
||||
|
||||
DECLARE_ASN1_FUNCTIONS(ESS_SIGNING_CERT_V2)
|
||||
DECLARE_ASN1_DUP_FUNCTION(ESS_SIGNING_CERT_V2)
|
||||
|
||||
ESS_SIGNING_CERT *OSSL_ESS_signing_cert_new_init(const X509 *signcert,
|
||||
const STACK_OF(X509) *certs,
|
||||
int set_issuer_serial);
|
||||
ESS_SIGNING_CERT_V2 *OSSL_ESS_signing_cert_v2_new_init(const EVP_MD *hash_alg,
|
||||
const X509 *signcert,
|
||||
const
|
||||
STACK_OF(X509) *certs,
|
||||
int set_issuer_serial);
|
||||
int OSSL_ESS_check_signing_certs(const ESS_SIGNING_CERT *ss,
|
||||
const ESS_SIGNING_CERT_V2 *ssv2,
|
||||
const STACK_OF(X509) *chain,
|
||||
int require_signing_cert);
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
36
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/fipskey.h
generated
vendored
Normal file
36
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/fipskey.h
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/fipskey.h.in
|
||||
*
|
||||
* Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#ifndef OPENSSL_FIPSKEY_H
|
||||
# define OPENSSL_FIPSKEY_H
|
||||
# pragma once
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
/*
|
||||
* The FIPS validation HMAC key, usable as an array initializer.
|
||||
*/
|
||||
#define FIPS_KEY_ELEMENTS \
|
||||
0xf4, 0x55, 0x66, 0x50, 0xac, 0x31, 0xd3, 0x54, 0x61, 0x61, 0x0b, 0xac, 0x4e, 0xd8, 0x1b, 0x1a, 0x18, 0x1b, 0x2d, 0x8a, 0x43, 0xea, 0x28, 0x54, 0xcb, 0xae, 0x22, 0xca, 0x74, 0x56, 0x08, 0x13
|
||||
|
||||
/*
|
||||
* The FIPS validation key, as a string.
|
||||
*/
|
||||
#define FIPS_KEY_STRING "f4556650ac31d35461610bac4ed81b1a181b2d8a43ea2854cbae22ca74560813"
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
|
||||
#endif
|
||||
288
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/lhash.h
generated
vendored
Normal file
288
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/lhash.h
generated
vendored
Normal file
@@ -0,0 +1,288 @@
|
||||
/*
|
||||
* Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Header for dynamic hash table routines Author - Eric Young
|
||||
*/
|
||||
|
||||
#ifndef OPENSSL_LHASH_H
|
||||
# define OPENSSL_LHASH_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_LHASH_H
|
||||
# endif
|
||||
|
||||
# include <openssl/e_os2.h>
|
||||
# include <openssl/bio.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
typedef struct lhash_node_st OPENSSL_LH_NODE;
|
||||
typedef int (*OPENSSL_LH_COMPFUNC) (const void *, const void *);
|
||||
typedef unsigned long (*OPENSSL_LH_HASHFUNC) (const void *);
|
||||
typedef void (*OPENSSL_LH_DOALL_FUNC) (void *);
|
||||
typedef void (*OPENSSL_LH_DOALL_FUNCARG) (void *, void *);
|
||||
typedef struct lhash_st OPENSSL_LHASH;
|
||||
|
||||
/*
|
||||
* Macros for declaring and implementing type-safe wrappers for LHASH
|
||||
* callbacks. This way, callbacks can be provided to LHASH structures without
|
||||
* function pointer casting and the macro-defined callbacks provide
|
||||
* per-variable casting before deferring to the underlying type-specific
|
||||
* callbacks. NB: It is possible to place a "static" in front of both the
|
||||
* DECLARE and IMPLEMENT macros if the functions are strictly internal.
|
||||
*/
|
||||
|
||||
/* First: "hash" functions */
|
||||
# define DECLARE_LHASH_HASH_FN(name, o_type) \
|
||||
unsigned long name##_LHASH_HASH(const void *);
|
||||
# define IMPLEMENT_LHASH_HASH_FN(name, o_type) \
|
||||
unsigned long name##_LHASH_HASH(const void *arg) { \
|
||||
const o_type *a = arg; \
|
||||
return name##_hash(a); }
|
||||
# define LHASH_HASH_FN(name) name##_LHASH_HASH
|
||||
|
||||
/* Second: "compare" functions */
|
||||
# define DECLARE_LHASH_COMP_FN(name, o_type) \
|
||||
int name##_LHASH_COMP(const void *, const void *);
|
||||
# define IMPLEMENT_LHASH_COMP_FN(name, o_type) \
|
||||
int name##_LHASH_COMP(const void *arg1, const void *arg2) { \
|
||||
const o_type *a = arg1; \
|
||||
const o_type *b = arg2; \
|
||||
return name##_cmp(a,b); }
|
||||
# define LHASH_COMP_FN(name) name##_LHASH_COMP
|
||||
|
||||
/* Fourth: "doall_arg" functions */
|
||||
# define DECLARE_LHASH_DOALL_ARG_FN(name, o_type, a_type) \
|
||||
void name##_LHASH_DOALL_ARG(void *, void *);
|
||||
# define IMPLEMENT_LHASH_DOALL_ARG_FN(name, o_type, a_type) \
|
||||
void name##_LHASH_DOALL_ARG(void *arg1, void *arg2) { \
|
||||
o_type *a = arg1; \
|
||||
a_type *b = arg2; \
|
||||
name##_doall_arg(a, b); }
|
||||
# define LHASH_DOALL_ARG_FN(name) name##_LHASH_DOALL_ARG
|
||||
|
||||
|
||||
# define LH_LOAD_MULT 256
|
||||
|
||||
int OPENSSL_LH_error(OPENSSL_LHASH *lh);
|
||||
OPENSSL_LHASH *OPENSSL_LH_new(OPENSSL_LH_HASHFUNC h, OPENSSL_LH_COMPFUNC c);
|
||||
void OPENSSL_LH_free(OPENSSL_LHASH *lh);
|
||||
void OPENSSL_LH_flush(OPENSSL_LHASH *lh);
|
||||
void *OPENSSL_LH_insert(OPENSSL_LHASH *lh, void *data);
|
||||
void *OPENSSL_LH_delete(OPENSSL_LHASH *lh, const void *data);
|
||||
void *OPENSSL_LH_retrieve(OPENSSL_LHASH *lh, const void *data);
|
||||
void OPENSSL_LH_doall(OPENSSL_LHASH *lh, OPENSSL_LH_DOALL_FUNC func);
|
||||
void OPENSSL_LH_doall_arg(OPENSSL_LHASH *lh, OPENSSL_LH_DOALL_FUNCARG func, void *arg);
|
||||
unsigned long OPENSSL_LH_strhash(const char *c);
|
||||
unsigned long OPENSSL_LH_num_items(const OPENSSL_LHASH *lh);
|
||||
unsigned long OPENSSL_LH_get_down_load(const OPENSSL_LHASH *lh);
|
||||
void OPENSSL_LH_set_down_load(OPENSSL_LHASH *lh, unsigned long down_load);
|
||||
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
void OPENSSL_LH_stats(const OPENSSL_LHASH *lh, FILE *fp);
|
||||
void OPENSSL_LH_node_stats(const OPENSSL_LHASH *lh, FILE *fp);
|
||||
void OPENSSL_LH_node_usage_stats(const OPENSSL_LHASH *lh, FILE *fp);
|
||||
# endif
|
||||
void OPENSSL_LH_stats_bio(const OPENSSL_LHASH *lh, BIO *out);
|
||||
void OPENSSL_LH_node_stats_bio(const OPENSSL_LHASH *lh, BIO *out);
|
||||
void OPENSSL_LH_node_usage_stats_bio(const OPENSSL_LHASH *lh, BIO *out);
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# define _LHASH OPENSSL_LHASH
|
||||
# define LHASH_NODE OPENSSL_LH_NODE
|
||||
# define lh_error OPENSSL_LH_error
|
||||
# define lh_new OPENSSL_LH_new
|
||||
# define lh_free OPENSSL_LH_free
|
||||
# define lh_insert OPENSSL_LH_insert
|
||||
# define lh_delete OPENSSL_LH_delete
|
||||
# define lh_retrieve OPENSSL_LH_retrieve
|
||||
# define lh_doall OPENSSL_LH_doall
|
||||
# define lh_doall_arg OPENSSL_LH_doall_arg
|
||||
# define lh_strhash OPENSSL_LH_strhash
|
||||
# define lh_num_items OPENSSL_LH_num_items
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
# define lh_stats OPENSSL_LH_stats
|
||||
# define lh_node_stats OPENSSL_LH_node_stats
|
||||
# define lh_node_usage_stats OPENSSL_LH_node_usage_stats
|
||||
# endif
|
||||
# define lh_stats_bio OPENSSL_LH_stats_bio
|
||||
# define lh_node_stats_bio OPENSSL_LH_node_stats_bio
|
||||
# define lh_node_usage_stats_bio OPENSSL_LH_node_usage_stats_bio
|
||||
# endif
|
||||
|
||||
/* Type checking... */
|
||||
|
||||
# define LHASH_OF(type) struct lhash_st_##type
|
||||
|
||||
/* Helper macro for internal use */
|
||||
# define DEFINE_LHASH_OF_INTERNAL(type) \
|
||||
LHASH_OF(type) { union lh_##type##_dummy { void* d1; unsigned long d2; int d3; } dummy; }; \
|
||||
typedef int (*lh_##type##_compfunc)(const type *a, const type *b); \
|
||||
typedef unsigned long (*lh_##type##_hashfunc)(const type *a); \
|
||||
typedef void (*lh_##type##_doallfunc)(type *a); \
|
||||
static ossl_unused ossl_inline type *ossl_check_##type##_lh_plain_type(type *ptr) \
|
||||
{ \
|
||||
return ptr; \
|
||||
} \
|
||||
static ossl_unused ossl_inline const type *ossl_check_const_##type##_lh_plain_type(const type *ptr) \
|
||||
{ \
|
||||
return ptr; \
|
||||
} \
|
||||
static ossl_unused ossl_inline const OPENSSL_LHASH *ossl_check_const_##type##_lh_type(const LHASH_OF(type) *lh) \
|
||||
{ \
|
||||
return (const OPENSSL_LHASH *)lh; \
|
||||
} \
|
||||
static ossl_unused ossl_inline OPENSSL_LHASH *ossl_check_##type##_lh_type(LHASH_OF(type) *lh) \
|
||||
{ \
|
||||
return (OPENSSL_LHASH *)lh; \
|
||||
} \
|
||||
static ossl_unused ossl_inline OPENSSL_LH_COMPFUNC ossl_check_##type##_lh_compfunc_type(lh_##type##_compfunc cmp) \
|
||||
{ \
|
||||
return (OPENSSL_LH_COMPFUNC)cmp; \
|
||||
} \
|
||||
static ossl_unused ossl_inline OPENSSL_LH_HASHFUNC ossl_check_##type##_lh_hashfunc_type(lh_##type##_hashfunc hfn) \
|
||||
{ \
|
||||
return (OPENSSL_LH_HASHFUNC)hfn; \
|
||||
} \
|
||||
static ossl_unused ossl_inline OPENSSL_LH_DOALL_FUNC ossl_check_##type##_lh_doallfunc_type(lh_##type##_doallfunc dfn) \
|
||||
{ \
|
||||
return (OPENSSL_LH_DOALL_FUNC)dfn; \
|
||||
} \
|
||||
LHASH_OF(type)
|
||||
|
||||
# define DEFINE_LHASH_OF(type) \
|
||||
LHASH_OF(type) { union lh_##type##_dummy { void* d1; unsigned long d2; int d3; } dummy; }; \
|
||||
static ossl_unused ossl_inline LHASH_OF(type) *lh_##type##_new(unsigned long (*hfn)(const type *), \
|
||||
int (*cfn)(const type *, const type *)) \
|
||||
{ \
|
||||
return (LHASH_OF(type) *) \
|
||||
OPENSSL_LH_new((OPENSSL_LH_HASHFUNC)hfn, (OPENSSL_LH_COMPFUNC)cfn); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void lh_##type##_free(LHASH_OF(type) *lh) \
|
||||
{ \
|
||||
OPENSSL_LH_free((OPENSSL_LHASH *)lh); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void lh_##type##_flush(LHASH_OF(type) *lh) \
|
||||
{ \
|
||||
OPENSSL_LH_flush((OPENSSL_LHASH *)lh); \
|
||||
} \
|
||||
static ossl_unused ossl_inline type *lh_##type##_insert(LHASH_OF(type) *lh, type *d) \
|
||||
{ \
|
||||
return (type *)OPENSSL_LH_insert((OPENSSL_LHASH *)lh, d); \
|
||||
} \
|
||||
static ossl_unused ossl_inline type *lh_##type##_delete(LHASH_OF(type) *lh, const type *d) \
|
||||
{ \
|
||||
return (type *)OPENSSL_LH_delete((OPENSSL_LHASH *)lh, d); \
|
||||
} \
|
||||
static ossl_unused ossl_inline type *lh_##type##_retrieve(LHASH_OF(type) *lh, const type *d) \
|
||||
{ \
|
||||
return (type *)OPENSSL_LH_retrieve((OPENSSL_LHASH *)lh, d); \
|
||||
} \
|
||||
static ossl_unused ossl_inline int lh_##type##_error(LHASH_OF(type) *lh) \
|
||||
{ \
|
||||
return OPENSSL_LH_error((OPENSSL_LHASH *)lh); \
|
||||
} \
|
||||
static ossl_unused ossl_inline unsigned long lh_##type##_num_items(LHASH_OF(type) *lh) \
|
||||
{ \
|
||||
return OPENSSL_LH_num_items((OPENSSL_LHASH *)lh); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void lh_##type##_node_stats_bio(const LHASH_OF(type) *lh, BIO *out) \
|
||||
{ \
|
||||
OPENSSL_LH_node_stats_bio((const OPENSSL_LHASH *)lh, out); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void lh_##type##_node_usage_stats_bio(const LHASH_OF(type) *lh, BIO *out) \
|
||||
{ \
|
||||
OPENSSL_LH_node_usage_stats_bio((const OPENSSL_LHASH *)lh, out); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void lh_##type##_stats_bio(const LHASH_OF(type) *lh, BIO *out) \
|
||||
{ \
|
||||
OPENSSL_LH_stats_bio((const OPENSSL_LHASH *)lh, out); \
|
||||
} \
|
||||
static ossl_unused ossl_inline unsigned long lh_##type##_get_down_load(LHASH_OF(type) *lh) \
|
||||
{ \
|
||||
return OPENSSL_LH_get_down_load((OPENSSL_LHASH *)lh); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void lh_##type##_set_down_load(LHASH_OF(type) *lh, unsigned long dl) \
|
||||
{ \
|
||||
OPENSSL_LH_set_down_load((OPENSSL_LHASH *)lh, dl); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void lh_##type##_doall(LHASH_OF(type) *lh, \
|
||||
void (*doall)(type *)) \
|
||||
{ \
|
||||
OPENSSL_LH_doall((OPENSSL_LHASH *)lh, (OPENSSL_LH_DOALL_FUNC)doall); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void lh_##type##_doall_arg(LHASH_OF(type) *lh, \
|
||||
void (*doallarg)(type *, void *), \
|
||||
void *arg) \
|
||||
{ \
|
||||
OPENSSL_LH_doall_arg((OPENSSL_LHASH *)lh, \
|
||||
(OPENSSL_LH_DOALL_FUNCARG)doallarg, arg); \
|
||||
} \
|
||||
LHASH_OF(type)
|
||||
|
||||
#define IMPLEMENT_LHASH_DOALL_ARG_CONST(type, argtype) \
|
||||
int_implement_lhash_doall(type, argtype, const type)
|
||||
|
||||
#define IMPLEMENT_LHASH_DOALL_ARG(type, argtype) \
|
||||
int_implement_lhash_doall(type, argtype, type)
|
||||
|
||||
#define int_implement_lhash_doall(type, argtype, cbargtype) \
|
||||
static ossl_unused ossl_inline void \
|
||||
lh_##type##_doall_##argtype(LHASH_OF(type) *lh, \
|
||||
void (*fn)(cbargtype *, argtype *), \
|
||||
argtype *arg) \
|
||||
{ \
|
||||
OPENSSL_LH_doall_arg((OPENSSL_LHASH *)lh, (OPENSSL_LH_DOALL_FUNCARG)fn, (void *)arg); \
|
||||
} \
|
||||
LHASH_OF(type)
|
||||
|
||||
DEFINE_LHASH_OF_INTERNAL(OPENSSL_STRING);
|
||||
#define lh_OPENSSL_STRING_new(hfn, cmp) ((LHASH_OF(OPENSSL_STRING) *)OPENSSL_LH_new(ossl_check_OPENSSL_STRING_lh_hashfunc_type(hfn), ossl_check_OPENSSL_STRING_lh_compfunc_type(cmp)))
|
||||
#define lh_OPENSSL_STRING_free(lh) OPENSSL_LH_free(ossl_check_OPENSSL_STRING_lh_type(lh))
|
||||
#define lh_OPENSSL_STRING_flush(lh) OPENSSL_LH_flush(ossl_check_OPENSSL_STRING_lh_type(lh))
|
||||
#define lh_OPENSSL_STRING_insert(lh, ptr) ((OPENSSL_STRING *)OPENSSL_LH_insert(ossl_check_OPENSSL_STRING_lh_type(lh), ossl_check_OPENSSL_STRING_lh_plain_type(ptr)))
|
||||
#define lh_OPENSSL_STRING_delete(lh, ptr) ((OPENSSL_STRING *)OPENSSL_LH_delete(ossl_check_OPENSSL_STRING_lh_type(lh), ossl_check_const_OPENSSL_STRING_lh_plain_type(ptr)))
|
||||
#define lh_OPENSSL_STRING_retrieve(lh, ptr) ((OPENSSL_STRING *)OPENSSL_LH_retrieve(ossl_check_OPENSSL_STRING_lh_type(lh), ossl_check_const_OPENSSL_STRING_lh_plain_type(ptr)))
|
||||
#define lh_OPENSSL_STRING_error(lh) OPENSSL_LH_error(ossl_check_OPENSSL_STRING_lh_type(lh))
|
||||
#define lh_OPENSSL_STRING_num_items(lh) OPENSSL_LH_num_items(ossl_check_OPENSSL_STRING_lh_type(lh))
|
||||
#define lh_OPENSSL_STRING_node_stats_bio(lh, out) OPENSSL_LH_node_stats_bio(ossl_check_const_OPENSSL_STRING_lh_type(lh), out)
|
||||
#define lh_OPENSSL_STRING_node_usage_stats_bio(lh, out) OPENSSL_LH_node_usage_stats_bio(ossl_check_const_OPENSSL_STRING_lh_type(lh), out)
|
||||
#define lh_OPENSSL_STRING_stats_bio(lh, out) OPENSSL_LH_stats_bio(ossl_check_const_OPENSSL_STRING_lh_type(lh), out)
|
||||
#define lh_OPENSSL_STRING_get_down_load(lh) OPENSSL_LH_get_down_load(ossl_check_OPENSSL_STRING_lh_type(lh))
|
||||
#define lh_OPENSSL_STRING_set_down_load(lh, dl) OPENSSL_LH_set_down_load(ossl_check_OPENSSL_STRING_lh_type(lh), dl)
|
||||
#define lh_OPENSSL_STRING_doall(lh, dfn) OPENSSL_LH_doall(ossl_check_OPENSSL_STRING_lh_type(lh), ossl_check_OPENSSL_STRING_lh_doallfunc_type(dfn))
|
||||
DEFINE_LHASH_OF_INTERNAL(OPENSSL_CSTRING);
|
||||
#define lh_OPENSSL_CSTRING_new(hfn, cmp) ((LHASH_OF(OPENSSL_CSTRING) *)OPENSSL_LH_new(ossl_check_OPENSSL_CSTRING_lh_hashfunc_type(hfn), ossl_check_OPENSSL_CSTRING_lh_compfunc_type(cmp)))
|
||||
#define lh_OPENSSL_CSTRING_free(lh) OPENSSL_LH_free(ossl_check_OPENSSL_CSTRING_lh_type(lh))
|
||||
#define lh_OPENSSL_CSTRING_flush(lh) OPENSSL_LH_flush(ossl_check_OPENSSL_CSTRING_lh_type(lh))
|
||||
#define lh_OPENSSL_CSTRING_insert(lh, ptr) ((OPENSSL_CSTRING *)OPENSSL_LH_insert(ossl_check_OPENSSL_CSTRING_lh_type(lh), ossl_check_OPENSSL_CSTRING_lh_plain_type(ptr)))
|
||||
#define lh_OPENSSL_CSTRING_delete(lh, ptr) ((OPENSSL_CSTRING *)OPENSSL_LH_delete(ossl_check_OPENSSL_CSTRING_lh_type(lh), ossl_check_const_OPENSSL_CSTRING_lh_plain_type(ptr)))
|
||||
#define lh_OPENSSL_CSTRING_retrieve(lh, ptr) ((OPENSSL_CSTRING *)OPENSSL_LH_retrieve(ossl_check_OPENSSL_CSTRING_lh_type(lh), ossl_check_const_OPENSSL_CSTRING_lh_plain_type(ptr)))
|
||||
#define lh_OPENSSL_CSTRING_error(lh) OPENSSL_LH_error(ossl_check_OPENSSL_CSTRING_lh_type(lh))
|
||||
#define lh_OPENSSL_CSTRING_num_items(lh) OPENSSL_LH_num_items(ossl_check_OPENSSL_CSTRING_lh_type(lh))
|
||||
#define lh_OPENSSL_CSTRING_node_stats_bio(lh, out) OPENSSL_LH_node_stats_bio(ossl_check_const_OPENSSL_CSTRING_lh_type(lh), out)
|
||||
#define lh_OPENSSL_CSTRING_node_usage_stats_bio(lh, out) OPENSSL_LH_node_usage_stats_bio(ossl_check_const_OPENSSL_CSTRING_lh_type(lh), out)
|
||||
#define lh_OPENSSL_CSTRING_stats_bio(lh, out) OPENSSL_LH_stats_bio(ossl_check_const_OPENSSL_CSTRING_lh_type(lh), out)
|
||||
#define lh_OPENSSL_CSTRING_get_down_load(lh) OPENSSL_LH_get_down_load(ossl_check_OPENSSL_CSTRING_lh_type(lh))
|
||||
#define lh_OPENSSL_CSTRING_set_down_load(lh, dl) OPENSSL_LH_set_down_load(ossl_check_OPENSSL_CSTRING_lh_type(lh), dl)
|
||||
#define lh_OPENSSL_CSTRING_doall(lh, dfn) OPENSSL_LH_doall(ossl_check_OPENSSL_CSTRING_lh_type(lh), ossl_check_OPENSSL_CSTRING_lh_doallfunc_type(dfn))
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
483
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ocsp.h
generated
vendored
Normal file
483
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ocsp.h
generated
vendored
Normal file
@@ -0,0 +1,483 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/ocsp.h.in
|
||||
*
|
||||
* Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_OCSP_H
|
||||
# define OPENSSL_OCSP_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_OCSP_H
|
||||
# endif
|
||||
|
||||
# include <openssl/opensslconf.h>
|
||||
# include <openssl/http.h>
|
||||
# include <openssl/asn1.h>
|
||||
|
||||
/*
|
||||
* These definitions are outside the OPENSSL_NO_OCSP guard because although for
|
||||
* historical reasons they have OCSP_* names, they can actually be used
|
||||
* independently of OCSP. E.g. see RFC5280
|
||||
*/
|
||||
/*-
|
||||
* CRLReason ::= ENUMERATED {
|
||||
* unspecified (0),
|
||||
* keyCompromise (1),
|
||||
* cACompromise (2),
|
||||
* affiliationChanged (3),
|
||||
* superseded (4),
|
||||
* cessationOfOperation (5),
|
||||
* certificateHold (6),
|
||||
* -- value 7 is not used
|
||||
* removeFromCRL (8),
|
||||
* privilegeWithdrawn (9),
|
||||
* aACompromise (10) }
|
||||
*/
|
||||
# define OCSP_REVOKED_STATUS_NOSTATUS -1
|
||||
# define OCSP_REVOKED_STATUS_UNSPECIFIED 0
|
||||
# define OCSP_REVOKED_STATUS_KEYCOMPROMISE 1
|
||||
# define OCSP_REVOKED_STATUS_CACOMPROMISE 2
|
||||
# define OCSP_REVOKED_STATUS_AFFILIATIONCHANGED 3
|
||||
# define OCSP_REVOKED_STATUS_SUPERSEDED 4
|
||||
# define OCSP_REVOKED_STATUS_CESSATIONOFOPERATION 5
|
||||
# define OCSP_REVOKED_STATUS_CERTIFICATEHOLD 6
|
||||
# define OCSP_REVOKED_STATUS_REMOVEFROMCRL 8
|
||||
# define OCSP_REVOKED_STATUS_PRIVILEGEWITHDRAWN 9
|
||||
# define OCSP_REVOKED_STATUS_AACOMPROMISE 10
|
||||
|
||||
|
||||
# ifndef OPENSSL_NO_OCSP
|
||||
|
||||
# include <openssl/x509.h>
|
||||
# include <openssl/x509v3.h>
|
||||
# include <openssl/safestack.h>
|
||||
# include <openssl/ocsperr.h>
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
/* Various flags and values */
|
||||
|
||||
# define OCSP_DEFAULT_NONCE_LENGTH 16
|
||||
|
||||
# define OCSP_NOCERTS 0x1
|
||||
# define OCSP_NOINTERN 0x2
|
||||
# define OCSP_NOSIGS 0x4
|
||||
# define OCSP_NOCHAIN 0x8
|
||||
# define OCSP_NOVERIFY 0x10
|
||||
# define OCSP_NOEXPLICIT 0x20
|
||||
# define OCSP_NOCASIGN 0x40
|
||||
# define OCSP_NODELEGATED 0x80
|
||||
# define OCSP_NOCHECKS 0x100
|
||||
# define OCSP_TRUSTOTHER 0x200
|
||||
# define OCSP_RESPID_KEY 0x400
|
||||
# define OCSP_NOTIME 0x800
|
||||
# define OCSP_PARTIAL_CHAIN 0x1000
|
||||
|
||||
typedef struct ocsp_cert_id_st OCSP_CERTID;
|
||||
typedef struct ocsp_one_request_st OCSP_ONEREQ;
|
||||
typedef struct ocsp_req_info_st OCSP_REQINFO;
|
||||
typedef struct ocsp_signature_st OCSP_SIGNATURE;
|
||||
typedef struct ocsp_request_st OCSP_REQUEST;
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OCSP_CERTID, OCSP_CERTID, OCSP_CERTID)
|
||||
#define sk_OCSP_CERTID_num(sk) OPENSSL_sk_num(ossl_check_const_OCSP_CERTID_sk_type(sk))
|
||||
#define sk_OCSP_CERTID_value(sk, idx) ((OCSP_CERTID *)OPENSSL_sk_value(ossl_check_const_OCSP_CERTID_sk_type(sk), (idx)))
|
||||
#define sk_OCSP_CERTID_new(cmp) ((STACK_OF(OCSP_CERTID) *)OPENSSL_sk_new(ossl_check_OCSP_CERTID_compfunc_type(cmp)))
|
||||
#define sk_OCSP_CERTID_new_null() ((STACK_OF(OCSP_CERTID) *)OPENSSL_sk_new_null())
|
||||
#define sk_OCSP_CERTID_new_reserve(cmp, n) ((STACK_OF(OCSP_CERTID) *)OPENSSL_sk_new_reserve(ossl_check_OCSP_CERTID_compfunc_type(cmp), (n)))
|
||||
#define sk_OCSP_CERTID_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OCSP_CERTID_sk_type(sk), (n))
|
||||
#define sk_OCSP_CERTID_free(sk) OPENSSL_sk_free(ossl_check_OCSP_CERTID_sk_type(sk))
|
||||
#define sk_OCSP_CERTID_zero(sk) OPENSSL_sk_zero(ossl_check_OCSP_CERTID_sk_type(sk))
|
||||
#define sk_OCSP_CERTID_delete(sk, i) ((OCSP_CERTID *)OPENSSL_sk_delete(ossl_check_OCSP_CERTID_sk_type(sk), (i)))
|
||||
#define sk_OCSP_CERTID_delete_ptr(sk, ptr) ((OCSP_CERTID *)OPENSSL_sk_delete_ptr(ossl_check_OCSP_CERTID_sk_type(sk), ossl_check_OCSP_CERTID_type(ptr)))
|
||||
#define sk_OCSP_CERTID_push(sk, ptr) OPENSSL_sk_push(ossl_check_OCSP_CERTID_sk_type(sk), ossl_check_OCSP_CERTID_type(ptr))
|
||||
#define sk_OCSP_CERTID_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OCSP_CERTID_sk_type(sk), ossl_check_OCSP_CERTID_type(ptr))
|
||||
#define sk_OCSP_CERTID_pop(sk) ((OCSP_CERTID *)OPENSSL_sk_pop(ossl_check_OCSP_CERTID_sk_type(sk)))
|
||||
#define sk_OCSP_CERTID_shift(sk) ((OCSP_CERTID *)OPENSSL_sk_shift(ossl_check_OCSP_CERTID_sk_type(sk)))
|
||||
#define sk_OCSP_CERTID_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OCSP_CERTID_sk_type(sk),ossl_check_OCSP_CERTID_freefunc_type(freefunc))
|
||||
#define sk_OCSP_CERTID_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OCSP_CERTID_sk_type(sk), ossl_check_OCSP_CERTID_type(ptr), (idx))
|
||||
#define sk_OCSP_CERTID_set(sk, idx, ptr) ((OCSP_CERTID *)OPENSSL_sk_set(ossl_check_OCSP_CERTID_sk_type(sk), (idx), ossl_check_OCSP_CERTID_type(ptr)))
|
||||
#define sk_OCSP_CERTID_find(sk, ptr) OPENSSL_sk_find(ossl_check_OCSP_CERTID_sk_type(sk), ossl_check_OCSP_CERTID_type(ptr))
|
||||
#define sk_OCSP_CERTID_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OCSP_CERTID_sk_type(sk), ossl_check_OCSP_CERTID_type(ptr))
|
||||
#define sk_OCSP_CERTID_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OCSP_CERTID_sk_type(sk), ossl_check_OCSP_CERTID_type(ptr), pnum)
|
||||
#define sk_OCSP_CERTID_sort(sk) OPENSSL_sk_sort(ossl_check_OCSP_CERTID_sk_type(sk))
|
||||
#define sk_OCSP_CERTID_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OCSP_CERTID_sk_type(sk))
|
||||
#define sk_OCSP_CERTID_dup(sk) ((STACK_OF(OCSP_CERTID) *)OPENSSL_sk_dup(ossl_check_const_OCSP_CERTID_sk_type(sk)))
|
||||
#define sk_OCSP_CERTID_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OCSP_CERTID) *)OPENSSL_sk_deep_copy(ossl_check_const_OCSP_CERTID_sk_type(sk), ossl_check_OCSP_CERTID_copyfunc_type(copyfunc), ossl_check_OCSP_CERTID_freefunc_type(freefunc)))
|
||||
#define sk_OCSP_CERTID_set_cmp_func(sk, cmp) ((sk_OCSP_CERTID_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OCSP_CERTID_sk_type(sk), ossl_check_OCSP_CERTID_compfunc_type(cmp)))
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OCSP_ONEREQ, OCSP_ONEREQ, OCSP_ONEREQ)
|
||||
#define sk_OCSP_ONEREQ_num(sk) OPENSSL_sk_num(ossl_check_const_OCSP_ONEREQ_sk_type(sk))
|
||||
#define sk_OCSP_ONEREQ_value(sk, idx) ((OCSP_ONEREQ *)OPENSSL_sk_value(ossl_check_const_OCSP_ONEREQ_sk_type(sk), (idx)))
|
||||
#define sk_OCSP_ONEREQ_new(cmp) ((STACK_OF(OCSP_ONEREQ) *)OPENSSL_sk_new(ossl_check_OCSP_ONEREQ_compfunc_type(cmp)))
|
||||
#define sk_OCSP_ONEREQ_new_null() ((STACK_OF(OCSP_ONEREQ) *)OPENSSL_sk_new_null())
|
||||
#define sk_OCSP_ONEREQ_new_reserve(cmp, n) ((STACK_OF(OCSP_ONEREQ) *)OPENSSL_sk_new_reserve(ossl_check_OCSP_ONEREQ_compfunc_type(cmp), (n)))
|
||||
#define sk_OCSP_ONEREQ_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OCSP_ONEREQ_sk_type(sk), (n))
|
||||
#define sk_OCSP_ONEREQ_free(sk) OPENSSL_sk_free(ossl_check_OCSP_ONEREQ_sk_type(sk))
|
||||
#define sk_OCSP_ONEREQ_zero(sk) OPENSSL_sk_zero(ossl_check_OCSP_ONEREQ_sk_type(sk))
|
||||
#define sk_OCSP_ONEREQ_delete(sk, i) ((OCSP_ONEREQ *)OPENSSL_sk_delete(ossl_check_OCSP_ONEREQ_sk_type(sk), (i)))
|
||||
#define sk_OCSP_ONEREQ_delete_ptr(sk, ptr) ((OCSP_ONEREQ *)OPENSSL_sk_delete_ptr(ossl_check_OCSP_ONEREQ_sk_type(sk), ossl_check_OCSP_ONEREQ_type(ptr)))
|
||||
#define sk_OCSP_ONEREQ_push(sk, ptr) OPENSSL_sk_push(ossl_check_OCSP_ONEREQ_sk_type(sk), ossl_check_OCSP_ONEREQ_type(ptr))
|
||||
#define sk_OCSP_ONEREQ_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OCSP_ONEREQ_sk_type(sk), ossl_check_OCSP_ONEREQ_type(ptr))
|
||||
#define sk_OCSP_ONEREQ_pop(sk) ((OCSP_ONEREQ *)OPENSSL_sk_pop(ossl_check_OCSP_ONEREQ_sk_type(sk)))
|
||||
#define sk_OCSP_ONEREQ_shift(sk) ((OCSP_ONEREQ *)OPENSSL_sk_shift(ossl_check_OCSP_ONEREQ_sk_type(sk)))
|
||||
#define sk_OCSP_ONEREQ_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OCSP_ONEREQ_sk_type(sk),ossl_check_OCSP_ONEREQ_freefunc_type(freefunc))
|
||||
#define sk_OCSP_ONEREQ_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OCSP_ONEREQ_sk_type(sk), ossl_check_OCSP_ONEREQ_type(ptr), (idx))
|
||||
#define sk_OCSP_ONEREQ_set(sk, idx, ptr) ((OCSP_ONEREQ *)OPENSSL_sk_set(ossl_check_OCSP_ONEREQ_sk_type(sk), (idx), ossl_check_OCSP_ONEREQ_type(ptr)))
|
||||
#define sk_OCSP_ONEREQ_find(sk, ptr) OPENSSL_sk_find(ossl_check_OCSP_ONEREQ_sk_type(sk), ossl_check_OCSP_ONEREQ_type(ptr))
|
||||
#define sk_OCSP_ONEREQ_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OCSP_ONEREQ_sk_type(sk), ossl_check_OCSP_ONEREQ_type(ptr))
|
||||
#define sk_OCSP_ONEREQ_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OCSP_ONEREQ_sk_type(sk), ossl_check_OCSP_ONEREQ_type(ptr), pnum)
|
||||
#define sk_OCSP_ONEREQ_sort(sk) OPENSSL_sk_sort(ossl_check_OCSP_ONEREQ_sk_type(sk))
|
||||
#define sk_OCSP_ONEREQ_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OCSP_ONEREQ_sk_type(sk))
|
||||
#define sk_OCSP_ONEREQ_dup(sk) ((STACK_OF(OCSP_ONEREQ) *)OPENSSL_sk_dup(ossl_check_const_OCSP_ONEREQ_sk_type(sk)))
|
||||
#define sk_OCSP_ONEREQ_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OCSP_ONEREQ) *)OPENSSL_sk_deep_copy(ossl_check_const_OCSP_ONEREQ_sk_type(sk), ossl_check_OCSP_ONEREQ_copyfunc_type(copyfunc), ossl_check_OCSP_ONEREQ_freefunc_type(freefunc)))
|
||||
#define sk_OCSP_ONEREQ_set_cmp_func(sk, cmp) ((sk_OCSP_ONEREQ_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OCSP_ONEREQ_sk_type(sk), ossl_check_OCSP_ONEREQ_compfunc_type(cmp)))
|
||||
|
||||
|
||||
# define OCSP_RESPONSE_STATUS_SUCCESSFUL 0
|
||||
# define OCSP_RESPONSE_STATUS_MALFORMEDREQUEST 1
|
||||
# define OCSP_RESPONSE_STATUS_INTERNALERROR 2
|
||||
# define OCSP_RESPONSE_STATUS_TRYLATER 3
|
||||
# define OCSP_RESPONSE_STATUS_SIGREQUIRED 5
|
||||
# define OCSP_RESPONSE_STATUS_UNAUTHORIZED 6
|
||||
|
||||
typedef struct ocsp_resp_bytes_st OCSP_RESPBYTES;
|
||||
|
||||
# define V_OCSP_RESPID_NAME 0
|
||||
# define V_OCSP_RESPID_KEY 1
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OCSP_RESPID, OCSP_RESPID, OCSP_RESPID)
|
||||
#define sk_OCSP_RESPID_num(sk) OPENSSL_sk_num(ossl_check_const_OCSP_RESPID_sk_type(sk))
|
||||
#define sk_OCSP_RESPID_value(sk, idx) ((OCSP_RESPID *)OPENSSL_sk_value(ossl_check_const_OCSP_RESPID_sk_type(sk), (idx)))
|
||||
#define sk_OCSP_RESPID_new(cmp) ((STACK_OF(OCSP_RESPID) *)OPENSSL_sk_new(ossl_check_OCSP_RESPID_compfunc_type(cmp)))
|
||||
#define sk_OCSP_RESPID_new_null() ((STACK_OF(OCSP_RESPID) *)OPENSSL_sk_new_null())
|
||||
#define sk_OCSP_RESPID_new_reserve(cmp, n) ((STACK_OF(OCSP_RESPID) *)OPENSSL_sk_new_reserve(ossl_check_OCSP_RESPID_compfunc_type(cmp), (n)))
|
||||
#define sk_OCSP_RESPID_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OCSP_RESPID_sk_type(sk), (n))
|
||||
#define sk_OCSP_RESPID_free(sk) OPENSSL_sk_free(ossl_check_OCSP_RESPID_sk_type(sk))
|
||||
#define sk_OCSP_RESPID_zero(sk) OPENSSL_sk_zero(ossl_check_OCSP_RESPID_sk_type(sk))
|
||||
#define sk_OCSP_RESPID_delete(sk, i) ((OCSP_RESPID *)OPENSSL_sk_delete(ossl_check_OCSP_RESPID_sk_type(sk), (i)))
|
||||
#define sk_OCSP_RESPID_delete_ptr(sk, ptr) ((OCSP_RESPID *)OPENSSL_sk_delete_ptr(ossl_check_OCSP_RESPID_sk_type(sk), ossl_check_OCSP_RESPID_type(ptr)))
|
||||
#define sk_OCSP_RESPID_push(sk, ptr) OPENSSL_sk_push(ossl_check_OCSP_RESPID_sk_type(sk), ossl_check_OCSP_RESPID_type(ptr))
|
||||
#define sk_OCSP_RESPID_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OCSP_RESPID_sk_type(sk), ossl_check_OCSP_RESPID_type(ptr))
|
||||
#define sk_OCSP_RESPID_pop(sk) ((OCSP_RESPID *)OPENSSL_sk_pop(ossl_check_OCSP_RESPID_sk_type(sk)))
|
||||
#define sk_OCSP_RESPID_shift(sk) ((OCSP_RESPID *)OPENSSL_sk_shift(ossl_check_OCSP_RESPID_sk_type(sk)))
|
||||
#define sk_OCSP_RESPID_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OCSP_RESPID_sk_type(sk),ossl_check_OCSP_RESPID_freefunc_type(freefunc))
|
||||
#define sk_OCSP_RESPID_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OCSP_RESPID_sk_type(sk), ossl_check_OCSP_RESPID_type(ptr), (idx))
|
||||
#define sk_OCSP_RESPID_set(sk, idx, ptr) ((OCSP_RESPID *)OPENSSL_sk_set(ossl_check_OCSP_RESPID_sk_type(sk), (idx), ossl_check_OCSP_RESPID_type(ptr)))
|
||||
#define sk_OCSP_RESPID_find(sk, ptr) OPENSSL_sk_find(ossl_check_OCSP_RESPID_sk_type(sk), ossl_check_OCSP_RESPID_type(ptr))
|
||||
#define sk_OCSP_RESPID_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OCSP_RESPID_sk_type(sk), ossl_check_OCSP_RESPID_type(ptr))
|
||||
#define sk_OCSP_RESPID_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OCSP_RESPID_sk_type(sk), ossl_check_OCSP_RESPID_type(ptr), pnum)
|
||||
#define sk_OCSP_RESPID_sort(sk) OPENSSL_sk_sort(ossl_check_OCSP_RESPID_sk_type(sk))
|
||||
#define sk_OCSP_RESPID_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OCSP_RESPID_sk_type(sk))
|
||||
#define sk_OCSP_RESPID_dup(sk) ((STACK_OF(OCSP_RESPID) *)OPENSSL_sk_dup(ossl_check_const_OCSP_RESPID_sk_type(sk)))
|
||||
#define sk_OCSP_RESPID_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OCSP_RESPID) *)OPENSSL_sk_deep_copy(ossl_check_const_OCSP_RESPID_sk_type(sk), ossl_check_OCSP_RESPID_copyfunc_type(copyfunc), ossl_check_OCSP_RESPID_freefunc_type(freefunc)))
|
||||
#define sk_OCSP_RESPID_set_cmp_func(sk, cmp) ((sk_OCSP_RESPID_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OCSP_RESPID_sk_type(sk), ossl_check_OCSP_RESPID_compfunc_type(cmp)))
|
||||
|
||||
|
||||
typedef struct ocsp_revoked_info_st OCSP_REVOKEDINFO;
|
||||
|
||||
# define V_OCSP_CERTSTATUS_GOOD 0
|
||||
# define V_OCSP_CERTSTATUS_REVOKED 1
|
||||
# define V_OCSP_CERTSTATUS_UNKNOWN 2
|
||||
|
||||
typedef struct ocsp_cert_status_st OCSP_CERTSTATUS;
|
||||
typedef struct ocsp_single_response_st OCSP_SINGLERESP;
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OCSP_SINGLERESP, OCSP_SINGLERESP, OCSP_SINGLERESP)
|
||||
#define sk_OCSP_SINGLERESP_num(sk) OPENSSL_sk_num(ossl_check_const_OCSP_SINGLERESP_sk_type(sk))
|
||||
#define sk_OCSP_SINGLERESP_value(sk, idx) ((OCSP_SINGLERESP *)OPENSSL_sk_value(ossl_check_const_OCSP_SINGLERESP_sk_type(sk), (idx)))
|
||||
#define sk_OCSP_SINGLERESP_new(cmp) ((STACK_OF(OCSP_SINGLERESP) *)OPENSSL_sk_new(ossl_check_OCSP_SINGLERESP_compfunc_type(cmp)))
|
||||
#define sk_OCSP_SINGLERESP_new_null() ((STACK_OF(OCSP_SINGLERESP) *)OPENSSL_sk_new_null())
|
||||
#define sk_OCSP_SINGLERESP_new_reserve(cmp, n) ((STACK_OF(OCSP_SINGLERESP) *)OPENSSL_sk_new_reserve(ossl_check_OCSP_SINGLERESP_compfunc_type(cmp), (n)))
|
||||
#define sk_OCSP_SINGLERESP_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OCSP_SINGLERESP_sk_type(sk), (n))
|
||||
#define sk_OCSP_SINGLERESP_free(sk) OPENSSL_sk_free(ossl_check_OCSP_SINGLERESP_sk_type(sk))
|
||||
#define sk_OCSP_SINGLERESP_zero(sk) OPENSSL_sk_zero(ossl_check_OCSP_SINGLERESP_sk_type(sk))
|
||||
#define sk_OCSP_SINGLERESP_delete(sk, i) ((OCSP_SINGLERESP *)OPENSSL_sk_delete(ossl_check_OCSP_SINGLERESP_sk_type(sk), (i)))
|
||||
#define sk_OCSP_SINGLERESP_delete_ptr(sk, ptr) ((OCSP_SINGLERESP *)OPENSSL_sk_delete_ptr(ossl_check_OCSP_SINGLERESP_sk_type(sk), ossl_check_OCSP_SINGLERESP_type(ptr)))
|
||||
#define sk_OCSP_SINGLERESP_push(sk, ptr) OPENSSL_sk_push(ossl_check_OCSP_SINGLERESP_sk_type(sk), ossl_check_OCSP_SINGLERESP_type(ptr))
|
||||
#define sk_OCSP_SINGLERESP_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OCSP_SINGLERESP_sk_type(sk), ossl_check_OCSP_SINGLERESP_type(ptr))
|
||||
#define sk_OCSP_SINGLERESP_pop(sk) ((OCSP_SINGLERESP *)OPENSSL_sk_pop(ossl_check_OCSP_SINGLERESP_sk_type(sk)))
|
||||
#define sk_OCSP_SINGLERESP_shift(sk) ((OCSP_SINGLERESP *)OPENSSL_sk_shift(ossl_check_OCSP_SINGLERESP_sk_type(sk)))
|
||||
#define sk_OCSP_SINGLERESP_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OCSP_SINGLERESP_sk_type(sk),ossl_check_OCSP_SINGLERESP_freefunc_type(freefunc))
|
||||
#define sk_OCSP_SINGLERESP_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OCSP_SINGLERESP_sk_type(sk), ossl_check_OCSP_SINGLERESP_type(ptr), (idx))
|
||||
#define sk_OCSP_SINGLERESP_set(sk, idx, ptr) ((OCSP_SINGLERESP *)OPENSSL_sk_set(ossl_check_OCSP_SINGLERESP_sk_type(sk), (idx), ossl_check_OCSP_SINGLERESP_type(ptr)))
|
||||
#define sk_OCSP_SINGLERESP_find(sk, ptr) OPENSSL_sk_find(ossl_check_OCSP_SINGLERESP_sk_type(sk), ossl_check_OCSP_SINGLERESP_type(ptr))
|
||||
#define sk_OCSP_SINGLERESP_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OCSP_SINGLERESP_sk_type(sk), ossl_check_OCSP_SINGLERESP_type(ptr))
|
||||
#define sk_OCSP_SINGLERESP_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OCSP_SINGLERESP_sk_type(sk), ossl_check_OCSP_SINGLERESP_type(ptr), pnum)
|
||||
#define sk_OCSP_SINGLERESP_sort(sk) OPENSSL_sk_sort(ossl_check_OCSP_SINGLERESP_sk_type(sk))
|
||||
#define sk_OCSP_SINGLERESP_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OCSP_SINGLERESP_sk_type(sk))
|
||||
#define sk_OCSP_SINGLERESP_dup(sk) ((STACK_OF(OCSP_SINGLERESP) *)OPENSSL_sk_dup(ossl_check_const_OCSP_SINGLERESP_sk_type(sk)))
|
||||
#define sk_OCSP_SINGLERESP_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OCSP_SINGLERESP) *)OPENSSL_sk_deep_copy(ossl_check_const_OCSP_SINGLERESP_sk_type(sk), ossl_check_OCSP_SINGLERESP_copyfunc_type(copyfunc), ossl_check_OCSP_SINGLERESP_freefunc_type(freefunc)))
|
||||
#define sk_OCSP_SINGLERESP_set_cmp_func(sk, cmp) ((sk_OCSP_SINGLERESP_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OCSP_SINGLERESP_sk_type(sk), ossl_check_OCSP_SINGLERESP_compfunc_type(cmp)))
|
||||
|
||||
|
||||
typedef struct ocsp_response_data_st OCSP_RESPDATA;
|
||||
|
||||
typedef struct ocsp_basic_response_st OCSP_BASICRESP;
|
||||
|
||||
typedef struct ocsp_crl_id_st OCSP_CRLID;
|
||||
typedef struct ocsp_service_locator_st OCSP_SERVICELOC;
|
||||
|
||||
# define PEM_STRING_OCSP_REQUEST "OCSP REQUEST"
|
||||
# define PEM_STRING_OCSP_RESPONSE "OCSP RESPONSE"
|
||||
|
||||
# define d2i_OCSP_REQUEST_bio(bp,p) ASN1_d2i_bio_of(OCSP_REQUEST,OCSP_REQUEST_new,d2i_OCSP_REQUEST,bp,p)
|
||||
|
||||
# define d2i_OCSP_RESPONSE_bio(bp,p) ASN1_d2i_bio_of(OCSP_RESPONSE,OCSP_RESPONSE_new,d2i_OCSP_RESPONSE,bp,p)
|
||||
|
||||
# define PEM_read_bio_OCSP_REQUEST(bp,x,cb) (OCSP_REQUEST *)PEM_ASN1_read_bio( \
|
||||
(char *(*)())d2i_OCSP_REQUEST,PEM_STRING_OCSP_REQUEST, \
|
||||
bp,(char **)(x),cb,NULL)
|
||||
|
||||
# define PEM_read_bio_OCSP_RESPONSE(bp,x,cb) (OCSP_RESPONSE *)PEM_ASN1_read_bio(\
|
||||
(char *(*)())d2i_OCSP_RESPONSE,PEM_STRING_OCSP_RESPONSE, \
|
||||
bp,(char **)(x),cb,NULL)
|
||||
|
||||
# define PEM_write_bio_OCSP_REQUEST(bp,o) \
|
||||
PEM_ASN1_write_bio((int (*)())i2d_OCSP_REQUEST,PEM_STRING_OCSP_REQUEST,\
|
||||
bp,(char *)(o), NULL,NULL,0,NULL,NULL)
|
||||
|
||||
# define PEM_write_bio_OCSP_RESPONSE(bp,o) \
|
||||
PEM_ASN1_write_bio((int (*)())i2d_OCSP_RESPONSE,PEM_STRING_OCSP_RESPONSE,\
|
||||
bp,(char *)(o), NULL,NULL,0,NULL,NULL)
|
||||
|
||||
# define i2d_OCSP_RESPONSE_bio(bp,o) ASN1_i2d_bio_of(OCSP_RESPONSE,i2d_OCSP_RESPONSE,bp,o)
|
||||
|
||||
# define i2d_OCSP_REQUEST_bio(bp,o) ASN1_i2d_bio_of(OCSP_REQUEST,i2d_OCSP_REQUEST,bp,o)
|
||||
|
||||
# define ASN1_BIT_STRING_digest(data,type,md,len) \
|
||||
ASN1_item_digest(ASN1_ITEM_rptr(ASN1_BIT_STRING),type,data,md,len)
|
||||
|
||||
# define OCSP_CERTSTATUS_dup(cs)\
|
||||
(OCSP_CERTSTATUS*)ASN1_dup((i2d_of_void *)i2d_OCSP_CERTSTATUS,\
|
||||
(d2i_of_void *)d2i_OCSP_CERTSTATUS,(char *)(cs))
|
||||
|
||||
DECLARE_ASN1_DUP_FUNCTION(OCSP_CERTID)
|
||||
|
||||
OSSL_HTTP_REQ_CTX *OCSP_sendreq_new(BIO *io, const char *path,
|
||||
const OCSP_REQUEST *req, int buf_size);
|
||||
OCSP_RESPONSE *OCSP_sendreq_bio(BIO *b, const char *path, OCSP_REQUEST *req);
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
typedef OSSL_HTTP_REQ_CTX OCSP_REQ_CTX;
|
||||
# define OCSP_REQ_CTX_new(io, buf_size) \
|
||||
OSSL_HTTP_REQ_CTX_new(io, io, buf_size)
|
||||
# define OCSP_REQ_CTX_free OSSL_HTTP_REQ_CTX_free
|
||||
# define OCSP_REQ_CTX_http(rctx, op, path) \
|
||||
(OSSL_HTTP_REQ_CTX_set_expected(rctx, NULL, 1 /* asn1 */, 0, 0) && \
|
||||
OSSL_HTTP_REQ_CTX_set_request_line(rctx, strcmp(op, "POST") == 0, \
|
||||
NULL, NULL, path))
|
||||
# define OCSP_REQ_CTX_add1_header OSSL_HTTP_REQ_CTX_add1_header
|
||||
# define OCSP_REQ_CTX_i2d(r, it, req) \
|
||||
OSSL_HTTP_REQ_CTX_set1_req(r, "application/ocsp-request", it, req)
|
||||
# define OCSP_REQ_CTX_set1_req(r, req) \
|
||||
OCSP_REQ_CTX_i2d(r, ASN1_ITEM_rptr(OCSP_REQUEST), (ASN1_VALUE *)(req))
|
||||
# define OCSP_REQ_CTX_nbio OSSL_HTTP_REQ_CTX_nbio
|
||||
# define OCSP_REQ_CTX_nbio_d2i OSSL_HTTP_REQ_CTX_nbio_d2i
|
||||
# define OCSP_sendreq_nbio(p, r) \
|
||||
OSSL_HTTP_REQ_CTX_nbio_d2i(r, (ASN1_VALUE **)(p), \
|
||||
ASN1_ITEM_rptr(OCSP_RESPONSE))
|
||||
# define OCSP_REQ_CTX_get0_mem_bio OSSL_HTTP_REQ_CTX_get0_mem_bio
|
||||
# define OCSP_set_max_response_length OSSL_HTTP_REQ_CTX_set_max_response_length
|
||||
# endif
|
||||
|
||||
OCSP_CERTID *OCSP_cert_to_id(const EVP_MD *dgst, const X509 *subject,
|
||||
const X509 *issuer);
|
||||
|
||||
OCSP_CERTID *OCSP_cert_id_new(const EVP_MD *dgst,
|
||||
const X509_NAME *issuerName,
|
||||
const ASN1_BIT_STRING *issuerKey,
|
||||
const ASN1_INTEGER *serialNumber);
|
||||
|
||||
OCSP_ONEREQ *OCSP_request_add0_id(OCSP_REQUEST *req, OCSP_CERTID *cid);
|
||||
|
||||
int OCSP_request_add1_nonce(OCSP_REQUEST *req, unsigned char *val, int len);
|
||||
int OCSP_basic_add1_nonce(OCSP_BASICRESP *resp, unsigned char *val, int len);
|
||||
int OCSP_check_nonce(OCSP_REQUEST *req, OCSP_BASICRESP *bs);
|
||||
int OCSP_copy_nonce(OCSP_BASICRESP *resp, OCSP_REQUEST *req);
|
||||
|
||||
int OCSP_request_set1_name(OCSP_REQUEST *req, const X509_NAME *nm);
|
||||
int OCSP_request_add1_cert(OCSP_REQUEST *req, X509 *cert);
|
||||
|
||||
int OCSP_request_sign(OCSP_REQUEST *req,
|
||||
X509 *signer,
|
||||
EVP_PKEY *key,
|
||||
const EVP_MD *dgst,
|
||||
STACK_OF(X509) *certs, unsigned long flags);
|
||||
|
||||
int OCSP_response_status(OCSP_RESPONSE *resp);
|
||||
OCSP_BASICRESP *OCSP_response_get1_basic(OCSP_RESPONSE *resp);
|
||||
|
||||
const ASN1_OCTET_STRING *OCSP_resp_get0_signature(const OCSP_BASICRESP *bs);
|
||||
const X509_ALGOR *OCSP_resp_get0_tbs_sigalg(const OCSP_BASICRESP *bs);
|
||||
const OCSP_RESPDATA *OCSP_resp_get0_respdata(const OCSP_BASICRESP *bs);
|
||||
int OCSP_resp_get0_signer(OCSP_BASICRESP *bs, X509 **signer,
|
||||
STACK_OF(X509) *extra_certs);
|
||||
|
||||
int OCSP_resp_count(OCSP_BASICRESP *bs);
|
||||
OCSP_SINGLERESP *OCSP_resp_get0(OCSP_BASICRESP *bs, int idx);
|
||||
const ASN1_GENERALIZEDTIME *OCSP_resp_get0_produced_at(const OCSP_BASICRESP* bs);
|
||||
const STACK_OF(X509) *OCSP_resp_get0_certs(const OCSP_BASICRESP *bs);
|
||||
int OCSP_resp_get0_id(const OCSP_BASICRESP *bs,
|
||||
const ASN1_OCTET_STRING **pid,
|
||||
const X509_NAME **pname);
|
||||
int OCSP_resp_get1_id(const OCSP_BASICRESP *bs,
|
||||
ASN1_OCTET_STRING **pid,
|
||||
X509_NAME **pname);
|
||||
|
||||
int OCSP_resp_find(OCSP_BASICRESP *bs, OCSP_CERTID *id, int last);
|
||||
int OCSP_single_get0_status(OCSP_SINGLERESP *single, int *reason,
|
||||
ASN1_GENERALIZEDTIME **revtime,
|
||||
ASN1_GENERALIZEDTIME **thisupd,
|
||||
ASN1_GENERALIZEDTIME **nextupd);
|
||||
int OCSP_resp_find_status(OCSP_BASICRESP *bs, OCSP_CERTID *id, int *status,
|
||||
int *reason,
|
||||
ASN1_GENERALIZEDTIME **revtime,
|
||||
ASN1_GENERALIZEDTIME **thisupd,
|
||||
ASN1_GENERALIZEDTIME **nextupd);
|
||||
int OCSP_check_validity(ASN1_GENERALIZEDTIME *thisupd,
|
||||
ASN1_GENERALIZEDTIME *nextupd, long sec, long maxsec);
|
||||
|
||||
int OCSP_request_verify(OCSP_REQUEST *req, STACK_OF(X509) *certs,
|
||||
X509_STORE *store, unsigned long flags);
|
||||
|
||||
# define OCSP_parse_url(url, host, port, path, ssl) \
|
||||
OSSL_HTTP_parse_url(url, ssl, NULL, host, port, NULL, path, NULL, NULL)
|
||||
|
||||
int OCSP_id_issuer_cmp(const OCSP_CERTID *a, const OCSP_CERTID *b);
|
||||
int OCSP_id_cmp(const OCSP_CERTID *a, const OCSP_CERTID *b);
|
||||
|
||||
int OCSP_request_onereq_count(OCSP_REQUEST *req);
|
||||
OCSP_ONEREQ *OCSP_request_onereq_get0(OCSP_REQUEST *req, int i);
|
||||
OCSP_CERTID *OCSP_onereq_get0_id(OCSP_ONEREQ *one);
|
||||
int OCSP_id_get0_info(ASN1_OCTET_STRING **piNameHash, ASN1_OBJECT **pmd,
|
||||
ASN1_OCTET_STRING **pikeyHash,
|
||||
ASN1_INTEGER **pserial, OCSP_CERTID *cid);
|
||||
int OCSP_request_is_signed(OCSP_REQUEST *req);
|
||||
OCSP_RESPONSE *OCSP_response_create(int status, OCSP_BASICRESP *bs);
|
||||
OCSP_SINGLERESP *OCSP_basic_add1_status(OCSP_BASICRESP *rsp,
|
||||
OCSP_CERTID *cid,
|
||||
int status, int reason,
|
||||
ASN1_TIME *revtime,
|
||||
ASN1_TIME *thisupd,
|
||||
ASN1_TIME *nextupd);
|
||||
int OCSP_basic_add1_cert(OCSP_BASICRESP *resp, X509 *cert);
|
||||
int OCSP_basic_sign(OCSP_BASICRESP *brsp,
|
||||
X509 *signer, EVP_PKEY *key, const EVP_MD *dgst,
|
||||
STACK_OF(X509) *certs, unsigned long flags);
|
||||
int OCSP_basic_sign_ctx(OCSP_BASICRESP *brsp,
|
||||
X509 *signer, EVP_MD_CTX *ctx,
|
||||
STACK_OF(X509) *certs, unsigned long flags);
|
||||
int OCSP_RESPID_set_by_name(OCSP_RESPID *respid, X509 *cert);
|
||||
int OCSP_RESPID_set_by_key_ex(OCSP_RESPID *respid, X509 *cert,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
int OCSP_RESPID_set_by_key(OCSP_RESPID *respid, X509 *cert);
|
||||
int OCSP_RESPID_match_ex(OCSP_RESPID *respid, X509 *cert, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
int OCSP_RESPID_match(OCSP_RESPID *respid, X509 *cert);
|
||||
|
||||
X509_EXTENSION *OCSP_crlID_new(const char *url, long *n, char *tim);
|
||||
|
||||
X509_EXTENSION *OCSP_accept_responses_new(char **oids);
|
||||
|
||||
X509_EXTENSION *OCSP_archive_cutoff_new(char *tim);
|
||||
|
||||
X509_EXTENSION *OCSP_url_svcloc_new(const X509_NAME *issuer, const char **urls);
|
||||
|
||||
int OCSP_REQUEST_get_ext_count(OCSP_REQUEST *x);
|
||||
int OCSP_REQUEST_get_ext_by_NID(OCSP_REQUEST *x, int nid, int lastpos);
|
||||
int OCSP_REQUEST_get_ext_by_OBJ(OCSP_REQUEST *x, const ASN1_OBJECT *obj,
|
||||
int lastpos);
|
||||
int OCSP_REQUEST_get_ext_by_critical(OCSP_REQUEST *x, int crit, int lastpos);
|
||||
X509_EXTENSION *OCSP_REQUEST_get_ext(OCSP_REQUEST *x, int loc);
|
||||
X509_EXTENSION *OCSP_REQUEST_delete_ext(OCSP_REQUEST *x, int loc);
|
||||
void *OCSP_REQUEST_get1_ext_d2i(OCSP_REQUEST *x, int nid, int *crit,
|
||||
int *idx);
|
||||
int OCSP_REQUEST_add1_ext_i2d(OCSP_REQUEST *x, int nid, void *value, int crit,
|
||||
unsigned long flags);
|
||||
int OCSP_REQUEST_add_ext(OCSP_REQUEST *x, X509_EXTENSION *ex, int loc);
|
||||
|
||||
int OCSP_ONEREQ_get_ext_count(OCSP_ONEREQ *x);
|
||||
int OCSP_ONEREQ_get_ext_by_NID(OCSP_ONEREQ *x, int nid, int lastpos);
|
||||
int OCSP_ONEREQ_get_ext_by_OBJ(OCSP_ONEREQ *x, const ASN1_OBJECT *obj, int lastpos);
|
||||
int OCSP_ONEREQ_get_ext_by_critical(OCSP_ONEREQ *x, int crit, int lastpos);
|
||||
X509_EXTENSION *OCSP_ONEREQ_get_ext(OCSP_ONEREQ *x, int loc);
|
||||
X509_EXTENSION *OCSP_ONEREQ_delete_ext(OCSP_ONEREQ *x, int loc);
|
||||
void *OCSP_ONEREQ_get1_ext_d2i(OCSP_ONEREQ *x, int nid, int *crit, int *idx);
|
||||
int OCSP_ONEREQ_add1_ext_i2d(OCSP_ONEREQ *x, int nid, void *value, int crit,
|
||||
unsigned long flags);
|
||||
int OCSP_ONEREQ_add_ext(OCSP_ONEREQ *x, X509_EXTENSION *ex, int loc);
|
||||
|
||||
int OCSP_BASICRESP_get_ext_count(OCSP_BASICRESP *x);
|
||||
int OCSP_BASICRESP_get_ext_by_NID(OCSP_BASICRESP *x, int nid, int lastpos);
|
||||
int OCSP_BASICRESP_get_ext_by_OBJ(OCSP_BASICRESP *x, const ASN1_OBJECT *obj,
|
||||
int lastpos);
|
||||
int OCSP_BASICRESP_get_ext_by_critical(OCSP_BASICRESP *x, int crit,
|
||||
int lastpos);
|
||||
X509_EXTENSION *OCSP_BASICRESP_get_ext(OCSP_BASICRESP *x, int loc);
|
||||
X509_EXTENSION *OCSP_BASICRESP_delete_ext(OCSP_BASICRESP *x, int loc);
|
||||
void *OCSP_BASICRESP_get1_ext_d2i(OCSP_BASICRESP *x, int nid, int *crit,
|
||||
int *idx);
|
||||
int OCSP_BASICRESP_add1_ext_i2d(OCSP_BASICRESP *x, int nid, void *value,
|
||||
int crit, unsigned long flags);
|
||||
int OCSP_BASICRESP_add_ext(OCSP_BASICRESP *x, X509_EXTENSION *ex, int loc);
|
||||
|
||||
int OCSP_SINGLERESP_get_ext_count(OCSP_SINGLERESP *x);
|
||||
int OCSP_SINGLERESP_get_ext_by_NID(OCSP_SINGLERESP *x, int nid, int lastpos);
|
||||
int OCSP_SINGLERESP_get_ext_by_OBJ(OCSP_SINGLERESP *x, const ASN1_OBJECT *obj,
|
||||
int lastpos);
|
||||
int OCSP_SINGLERESP_get_ext_by_critical(OCSP_SINGLERESP *x, int crit,
|
||||
int lastpos);
|
||||
X509_EXTENSION *OCSP_SINGLERESP_get_ext(OCSP_SINGLERESP *x, int loc);
|
||||
X509_EXTENSION *OCSP_SINGLERESP_delete_ext(OCSP_SINGLERESP *x, int loc);
|
||||
void *OCSP_SINGLERESP_get1_ext_d2i(OCSP_SINGLERESP *x, int nid, int *crit,
|
||||
int *idx);
|
||||
int OCSP_SINGLERESP_add1_ext_i2d(OCSP_SINGLERESP *x, int nid, void *value,
|
||||
int crit, unsigned long flags);
|
||||
int OCSP_SINGLERESP_add_ext(OCSP_SINGLERESP *x, X509_EXTENSION *ex, int loc);
|
||||
const OCSP_CERTID *OCSP_SINGLERESP_get0_id(const OCSP_SINGLERESP *x);
|
||||
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_SINGLERESP)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_CERTSTATUS)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_REVOKEDINFO)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_BASICRESP)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_RESPDATA)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_RESPID)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_RESPONSE)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_RESPBYTES)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_ONEREQ)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_CERTID)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_REQUEST)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_SIGNATURE)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_REQINFO)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_CRLID)
|
||||
DECLARE_ASN1_FUNCTIONS(OCSP_SERVICELOC)
|
||||
|
||||
const char *OCSP_response_status_str(long s);
|
||||
const char *OCSP_cert_status_str(long s);
|
||||
const char *OCSP_crl_reason_str(long s);
|
||||
|
||||
int OCSP_REQUEST_print(BIO *bp, OCSP_REQUEST *a, unsigned long flags);
|
||||
int OCSP_RESPONSE_print(BIO *bp, OCSP_RESPONSE *o, unsigned long flags);
|
||||
|
||||
int OCSP_basic_verify(OCSP_BASICRESP *bs, STACK_OF(X509) *certs,
|
||||
X509_STORE *st, unsigned long flags);
|
||||
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
# endif /* !defined(OPENSSL_NO_OCSP) */
|
||||
#endif
|
||||
114
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/opensslv.h
generated
vendored
Normal file
114
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/opensslv.h
generated
vendored
Normal file
@@ -0,0 +1,114 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/opensslv.h.in
|
||||
*
|
||||
* Copyright 1999-2020 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#ifndef OPENSSL_OPENSSLV_H
|
||||
# define OPENSSL_OPENSSLV_H
|
||||
# pragma once
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
/*
|
||||
* SECTION 1: VERSION DATA. These will change for each release
|
||||
*/
|
||||
|
||||
/*
|
||||
* Base version macros
|
||||
*
|
||||
* These macros express version number MAJOR.MINOR.PATCH exactly
|
||||
*/
|
||||
# define OPENSSL_VERSION_MAJOR 3
|
||||
# define OPENSSL_VERSION_MINOR 0
|
||||
# define OPENSSL_VERSION_PATCH 16
|
||||
|
||||
/*
|
||||
* Additional version information
|
||||
*
|
||||
* These are also part of the new version scheme, but aren't part
|
||||
* of the version number itself.
|
||||
*/
|
||||
|
||||
/* Could be: #define OPENSSL_VERSION_PRE_RELEASE "-alpha.1" */
|
||||
# define OPENSSL_VERSION_PRE_RELEASE ""
|
||||
/* Could be: #define OPENSSL_VERSION_BUILD_METADATA "+fips" */
|
||||
/* Could be: #define OPENSSL_VERSION_BUILD_METADATA "+vendor.1" */
|
||||
# define OPENSSL_VERSION_BUILD_METADATA ""
|
||||
|
||||
/*
|
||||
* Note: The OpenSSL Project will never define OPENSSL_VERSION_BUILD_METADATA
|
||||
* to be anything but the empty string. Its use is entirely reserved for
|
||||
* others
|
||||
*/
|
||||
|
||||
/*
|
||||
* Shared library version
|
||||
*
|
||||
* This is strictly to express ABI version, which may or may not
|
||||
* be related to the API version expressed with the macros above.
|
||||
* This is defined in free form.
|
||||
*/
|
||||
# define OPENSSL_SHLIB_VERSION 3
|
||||
|
||||
/*
|
||||
* SECTION 2: USEFUL MACROS
|
||||
*/
|
||||
|
||||
/* For checking general API compatibility when preprocessing */
|
||||
# define OPENSSL_VERSION_PREREQ(maj,min) \
|
||||
((OPENSSL_VERSION_MAJOR << 16) + OPENSSL_VERSION_MINOR >= ((maj) << 16) + (min))
|
||||
|
||||
/*
|
||||
* Macros to get the version in easily digested string form, both the short
|
||||
* "MAJOR.MINOR.PATCH" variant (where MAJOR, MINOR and PATCH are replaced
|
||||
* with the values from the corresponding OPENSSL_VERSION_ macros) and the
|
||||
* longer variant with OPENSSL_VERSION_PRE_RELEASE_STR and
|
||||
* OPENSSL_VERSION_BUILD_METADATA_STR appended.
|
||||
*/
|
||||
# define OPENSSL_VERSION_STR "3.0.16"
|
||||
# define OPENSSL_FULL_VERSION_STR "3.0.16"
|
||||
|
||||
/*
|
||||
* SECTION 3: ADDITIONAL METADATA
|
||||
*
|
||||
* These strings are defined separately to allow them to be parsable.
|
||||
*/
|
||||
# define OPENSSL_RELEASE_DATE "11 Feb 2025"
|
||||
|
||||
/*
|
||||
* SECTION 4: BACKWARD COMPATIBILITY
|
||||
*/
|
||||
|
||||
# define OPENSSL_VERSION_TEXT "OpenSSL 3.0.16 11 Feb 2025"
|
||||
|
||||
/* Synthesize OPENSSL_VERSION_NUMBER with the layout 0xMNN00PPSL */
|
||||
# ifdef OPENSSL_VERSION_PRE_RELEASE
|
||||
# define _OPENSSL_VERSION_PRE_RELEASE 0x0L
|
||||
# else
|
||||
# define _OPENSSL_VERSION_PRE_RELEASE 0xfL
|
||||
# endif
|
||||
# define OPENSSL_VERSION_NUMBER \
|
||||
( (OPENSSL_VERSION_MAJOR<<28) \
|
||||
|(OPENSSL_VERSION_MINOR<<20) \
|
||||
|(OPENSSL_VERSION_PATCH<<4) \
|
||||
|_OPENSSL_VERSION_PRE_RELEASE )
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_OPENSSLV_H
|
||||
# endif
|
||||
|
||||
#endif /* OPENSSL_OPENSSLV_H */
|
||||
350
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/pkcs12.h
generated
vendored
Normal file
350
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/pkcs12.h
generated
vendored
Normal file
@@ -0,0 +1,350 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/pkcs12.h.in
|
||||
*
|
||||
* Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_PKCS12_H
|
||||
# define OPENSSL_PKCS12_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_PKCS12_H
|
||||
# endif
|
||||
|
||||
# include <openssl/bio.h>
|
||||
# include <openssl/core.h>
|
||||
# include <openssl/x509.h>
|
||||
# include <openssl/pkcs12err.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
# define PKCS12_KEY_ID 1
|
||||
# define PKCS12_IV_ID 2
|
||||
# define PKCS12_MAC_ID 3
|
||||
|
||||
/* Default iteration count */
|
||||
# ifndef PKCS12_DEFAULT_ITER
|
||||
# define PKCS12_DEFAULT_ITER PKCS5_DEFAULT_ITER
|
||||
# endif
|
||||
|
||||
# define PKCS12_MAC_KEY_LENGTH 20
|
||||
|
||||
# define PKCS12_SALT_LEN 8
|
||||
|
||||
/* It's not clear if these are actually needed... */
|
||||
# define PKCS12_key_gen PKCS12_key_gen_utf8
|
||||
# define PKCS12_add_friendlyname PKCS12_add_friendlyname_utf8
|
||||
|
||||
/* MS key usage constants */
|
||||
|
||||
# define KEY_EX 0x10
|
||||
# define KEY_SIG 0x80
|
||||
|
||||
typedef struct PKCS12_MAC_DATA_st PKCS12_MAC_DATA;
|
||||
|
||||
typedef struct PKCS12_st PKCS12;
|
||||
|
||||
typedef struct PKCS12_SAFEBAG_st PKCS12_SAFEBAG;
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(PKCS12_SAFEBAG, PKCS12_SAFEBAG, PKCS12_SAFEBAG)
|
||||
#define sk_PKCS12_SAFEBAG_num(sk) OPENSSL_sk_num(ossl_check_const_PKCS12_SAFEBAG_sk_type(sk))
|
||||
#define sk_PKCS12_SAFEBAG_value(sk, idx) ((PKCS12_SAFEBAG *)OPENSSL_sk_value(ossl_check_const_PKCS12_SAFEBAG_sk_type(sk), (idx)))
|
||||
#define sk_PKCS12_SAFEBAG_new(cmp) ((STACK_OF(PKCS12_SAFEBAG) *)OPENSSL_sk_new(ossl_check_PKCS12_SAFEBAG_compfunc_type(cmp)))
|
||||
#define sk_PKCS12_SAFEBAG_new_null() ((STACK_OF(PKCS12_SAFEBAG) *)OPENSSL_sk_new_null())
|
||||
#define sk_PKCS12_SAFEBAG_new_reserve(cmp, n) ((STACK_OF(PKCS12_SAFEBAG) *)OPENSSL_sk_new_reserve(ossl_check_PKCS12_SAFEBAG_compfunc_type(cmp), (n)))
|
||||
#define sk_PKCS12_SAFEBAG_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_PKCS12_SAFEBAG_sk_type(sk), (n))
|
||||
#define sk_PKCS12_SAFEBAG_free(sk) OPENSSL_sk_free(ossl_check_PKCS12_SAFEBAG_sk_type(sk))
|
||||
#define sk_PKCS12_SAFEBAG_zero(sk) OPENSSL_sk_zero(ossl_check_PKCS12_SAFEBAG_sk_type(sk))
|
||||
#define sk_PKCS12_SAFEBAG_delete(sk, i) ((PKCS12_SAFEBAG *)OPENSSL_sk_delete(ossl_check_PKCS12_SAFEBAG_sk_type(sk), (i)))
|
||||
#define sk_PKCS12_SAFEBAG_delete_ptr(sk, ptr) ((PKCS12_SAFEBAG *)OPENSSL_sk_delete_ptr(ossl_check_PKCS12_SAFEBAG_sk_type(sk), ossl_check_PKCS12_SAFEBAG_type(ptr)))
|
||||
#define sk_PKCS12_SAFEBAG_push(sk, ptr) OPENSSL_sk_push(ossl_check_PKCS12_SAFEBAG_sk_type(sk), ossl_check_PKCS12_SAFEBAG_type(ptr))
|
||||
#define sk_PKCS12_SAFEBAG_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_PKCS12_SAFEBAG_sk_type(sk), ossl_check_PKCS12_SAFEBAG_type(ptr))
|
||||
#define sk_PKCS12_SAFEBAG_pop(sk) ((PKCS12_SAFEBAG *)OPENSSL_sk_pop(ossl_check_PKCS12_SAFEBAG_sk_type(sk)))
|
||||
#define sk_PKCS12_SAFEBAG_shift(sk) ((PKCS12_SAFEBAG *)OPENSSL_sk_shift(ossl_check_PKCS12_SAFEBAG_sk_type(sk)))
|
||||
#define sk_PKCS12_SAFEBAG_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_PKCS12_SAFEBAG_sk_type(sk),ossl_check_PKCS12_SAFEBAG_freefunc_type(freefunc))
|
||||
#define sk_PKCS12_SAFEBAG_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_PKCS12_SAFEBAG_sk_type(sk), ossl_check_PKCS12_SAFEBAG_type(ptr), (idx))
|
||||
#define sk_PKCS12_SAFEBAG_set(sk, idx, ptr) ((PKCS12_SAFEBAG *)OPENSSL_sk_set(ossl_check_PKCS12_SAFEBAG_sk_type(sk), (idx), ossl_check_PKCS12_SAFEBAG_type(ptr)))
|
||||
#define sk_PKCS12_SAFEBAG_find(sk, ptr) OPENSSL_sk_find(ossl_check_PKCS12_SAFEBAG_sk_type(sk), ossl_check_PKCS12_SAFEBAG_type(ptr))
|
||||
#define sk_PKCS12_SAFEBAG_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_PKCS12_SAFEBAG_sk_type(sk), ossl_check_PKCS12_SAFEBAG_type(ptr))
|
||||
#define sk_PKCS12_SAFEBAG_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_PKCS12_SAFEBAG_sk_type(sk), ossl_check_PKCS12_SAFEBAG_type(ptr), pnum)
|
||||
#define sk_PKCS12_SAFEBAG_sort(sk) OPENSSL_sk_sort(ossl_check_PKCS12_SAFEBAG_sk_type(sk))
|
||||
#define sk_PKCS12_SAFEBAG_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_PKCS12_SAFEBAG_sk_type(sk))
|
||||
#define sk_PKCS12_SAFEBAG_dup(sk) ((STACK_OF(PKCS12_SAFEBAG) *)OPENSSL_sk_dup(ossl_check_const_PKCS12_SAFEBAG_sk_type(sk)))
|
||||
#define sk_PKCS12_SAFEBAG_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(PKCS12_SAFEBAG) *)OPENSSL_sk_deep_copy(ossl_check_const_PKCS12_SAFEBAG_sk_type(sk), ossl_check_PKCS12_SAFEBAG_copyfunc_type(copyfunc), ossl_check_PKCS12_SAFEBAG_freefunc_type(freefunc)))
|
||||
#define sk_PKCS12_SAFEBAG_set_cmp_func(sk, cmp) ((sk_PKCS12_SAFEBAG_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_PKCS12_SAFEBAG_sk_type(sk), ossl_check_PKCS12_SAFEBAG_compfunc_type(cmp)))
|
||||
|
||||
|
||||
typedef struct pkcs12_bag_st PKCS12_BAGS;
|
||||
|
||||
# define PKCS12_ERROR 0
|
||||
# define PKCS12_OK 1
|
||||
|
||||
/* Compatibility macros */
|
||||
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
|
||||
# define M_PKCS12_bag_type PKCS12_bag_type
|
||||
# define M_PKCS12_cert_bag_type PKCS12_cert_bag_type
|
||||
# define M_PKCS12_crl_bag_type PKCS12_cert_bag_type
|
||||
|
||||
# define PKCS12_certbag2x509 PKCS12_SAFEBAG_get1_cert
|
||||
# define PKCS12_certbag2scrl PKCS12_SAFEBAG_get1_crl
|
||||
# define PKCS12_bag_type PKCS12_SAFEBAG_get_nid
|
||||
# define PKCS12_cert_bag_type PKCS12_SAFEBAG_get_bag_nid
|
||||
# define PKCS12_x5092certbag PKCS12_SAFEBAG_create_cert
|
||||
# define PKCS12_x509crl2certbag PKCS12_SAFEBAG_create_crl
|
||||
# define PKCS12_MAKE_KEYBAG PKCS12_SAFEBAG_create0_p8inf
|
||||
# define PKCS12_MAKE_SHKEYBAG PKCS12_SAFEBAG_create_pkcs8_encrypt
|
||||
|
||||
#endif
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
OSSL_DEPRECATEDIN_1_1_0 ASN1_TYPE *PKCS12_get_attr(const PKCS12_SAFEBAG *bag,
|
||||
int attr_nid);
|
||||
#endif
|
||||
|
||||
ASN1_TYPE *PKCS8_get_attr(PKCS8_PRIV_KEY_INFO *p8, int attr_nid);
|
||||
int PKCS12_mac_present(const PKCS12 *p12);
|
||||
void PKCS12_get0_mac(const ASN1_OCTET_STRING **pmac,
|
||||
const X509_ALGOR **pmacalg,
|
||||
const ASN1_OCTET_STRING **psalt,
|
||||
const ASN1_INTEGER **piter,
|
||||
const PKCS12 *p12);
|
||||
|
||||
const ASN1_TYPE *PKCS12_SAFEBAG_get0_attr(const PKCS12_SAFEBAG *bag,
|
||||
int attr_nid);
|
||||
const ASN1_OBJECT *PKCS12_SAFEBAG_get0_type(const PKCS12_SAFEBAG *bag);
|
||||
int PKCS12_SAFEBAG_get_nid(const PKCS12_SAFEBAG *bag);
|
||||
int PKCS12_SAFEBAG_get_bag_nid(const PKCS12_SAFEBAG *bag);
|
||||
const ASN1_TYPE *PKCS12_SAFEBAG_get0_bag_obj(const PKCS12_SAFEBAG *bag);
|
||||
const ASN1_OBJECT *PKCS12_SAFEBAG_get0_bag_type(const PKCS12_SAFEBAG *bag);
|
||||
|
||||
X509 *PKCS12_SAFEBAG_get1_cert(const PKCS12_SAFEBAG *bag);
|
||||
X509_CRL *PKCS12_SAFEBAG_get1_crl(const PKCS12_SAFEBAG *bag);
|
||||
const STACK_OF(PKCS12_SAFEBAG) *
|
||||
PKCS12_SAFEBAG_get0_safes(const PKCS12_SAFEBAG *bag);
|
||||
const PKCS8_PRIV_KEY_INFO *PKCS12_SAFEBAG_get0_p8inf(const PKCS12_SAFEBAG *bag);
|
||||
const X509_SIG *PKCS12_SAFEBAG_get0_pkcs8(const PKCS12_SAFEBAG *bag);
|
||||
|
||||
PKCS12_SAFEBAG *PKCS12_SAFEBAG_create_cert(X509 *x509);
|
||||
PKCS12_SAFEBAG *PKCS12_SAFEBAG_create_crl(X509_CRL *crl);
|
||||
PKCS12_SAFEBAG *PKCS12_SAFEBAG_create_secret(int type, int vtype, const unsigned char *value, int len);
|
||||
PKCS12_SAFEBAG *PKCS12_SAFEBAG_create0_p8inf(PKCS8_PRIV_KEY_INFO *p8);
|
||||
PKCS12_SAFEBAG *PKCS12_SAFEBAG_create0_pkcs8(X509_SIG *p8);
|
||||
PKCS12_SAFEBAG *PKCS12_SAFEBAG_create_pkcs8_encrypt(int pbe_nid,
|
||||
const char *pass,
|
||||
int passlen,
|
||||
unsigned char *salt,
|
||||
int saltlen, int iter,
|
||||
PKCS8_PRIV_KEY_INFO *p8inf);
|
||||
PKCS12_SAFEBAG *PKCS12_SAFEBAG_create_pkcs8_encrypt_ex(int pbe_nid,
|
||||
const char *pass,
|
||||
int passlen,
|
||||
unsigned char *salt,
|
||||
int saltlen, int iter,
|
||||
PKCS8_PRIV_KEY_INFO *p8inf,
|
||||
OSSL_LIB_CTX *ctx,
|
||||
const char *propq);
|
||||
|
||||
PKCS12_SAFEBAG *PKCS12_item_pack_safebag(void *obj, const ASN1_ITEM *it,
|
||||
int nid1, int nid2);
|
||||
PKCS8_PRIV_KEY_INFO *PKCS8_decrypt(const X509_SIG *p8, const char *pass,
|
||||
int passlen);
|
||||
PKCS8_PRIV_KEY_INFO *PKCS8_decrypt_ex(const X509_SIG *p8, const char *pass,
|
||||
int passlen, OSSL_LIB_CTX *ctx,
|
||||
const char *propq);
|
||||
PKCS8_PRIV_KEY_INFO *PKCS12_decrypt_skey(const PKCS12_SAFEBAG *bag,
|
||||
const char *pass, int passlen);
|
||||
PKCS8_PRIV_KEY_INFO *PKCS12_decrypt_skey_ex(const PKCS12_SAFEBAG *bag,
|
||||
const char *pass, int passlen,
|
||||
OSSL_LIB_CTX *ctx,
|
||||
const char *propq);
|
||||
X509_SIG *PKCS8_encrypt(int pbe_nid, const EVP_CIPHER *cipher,
|
||||
const char *pass, int passlen, unsigned char *salt,
|
||||
int saltlen, int iter, PKCS8_PRIV_KEY_INFO *p8);
|
||||
X509_SIG *PKCS8_encrypt_ex(int pbe_nid, const EVP_CIPHER *cipher,
|
||||
const char *pass, int passlen, unsigned char *salt,
|
||||
int saltlen, int iter, PKCS8_PRIV_KEY_INFO *p8,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
X509_SIG *PKCS8_set0_pbe(const char *pass, int passlen,
|
||||
PKCS8_PRIV_KEY_INFO *p8inf, X509_ALGOR *pbe);
|
||||
X509_SIG *PKCS8_set0_pbe_ex(const char *pass, int passlen,
|
||||
PKCS8_PRIV_KEY_INFO *p8inf, X509_ALGOR *pbe,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
PKCS7 *PKCS12_pack_p7data(STACK_OF(PKCS12_SAFEBAG) *sk);
|
||||
STACK_OF(PKCS12_SAFEBAG) *PKCS12_unpack_p7data(PKCS7 *p7);
|
||||
PKCS7 *PKCS12_pack_p7encdata(int pbe_nid, const char *pass, int passlen,
|
||||
unsigned char *salt, int saltlen, int iter,
|
||||
STACK_OF(PKCS12_SAFEBAG) *bags);
|
||||
PKCS7 *PKCS12_pack_p7encdata_ex(int pbe_nid, const char *pass, int passlen,
|
||||
unsigned char *salt, int saltlen, int iter,
|
||||
STACK_OF(PKCS12_SAFEBAG) *bags,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
|
||||
STACK_OF(PKCS12_SAFEBAG) *PKCS12_unpack_p7encdata(PKCS7 *p7, const char *pass,
|
||||
int passlen);
|
||||
|
||||
int PKCS12_pack_authsafes(PKCS12 *p12, STACK_OF(PKCS7) *safes);
|
||||
STACK_OF(PKCS7) *PKCS12_unpack_authsafes(const PKCS12 *p12);
|
||||
|
||||
int PKCS12_add_localkeyid(PKCS12_SAFEBAG *bag, unsigned char *name,
|
||||
int namelen);
|
||||
int PKCS12_add_friendlyname_asc(PKCS12_SAFEBAG *bag, const char *name,
|
||||
int namelen);
|
||||
int PKCS12_add_friendlyname_utf8(PKCS12_SAFEBAG *bag, const char *name,
|
||||
int namelen);
|
||||
int PKCS12_add_CSPName_asc(PKCS12_SAFEBAG *bag, const char *name,
|
||||
int namelen);
|
||||
int PKCS12_add_friendlyname_uni(PKCS12_SAFEBAG *bag,
|
||||
const unsigned char *name, int namelen);
|
||||
int PKCS12_add1_attr_by_NID(PKCS12_SAFEBAG *bag, int nid, int type,
|
||||
const unsigned char *bytes, int len);
|
||||
int PKCS12_add1_attr_by_txt(PKCS12_SAFEBAG *bag, const char *attrname, int type,
|
||||
const unsigned char *bytes, int len);
|
||||
int PKCS8_add_keyusage(PKCS8_PRIV_KEY_INFO *p8, int usage);
|
||||
ASN1_TYPE *PKCS12_get_attr_gen(const STACK_OF(X509_ATTRIBUTE) *attrs,
|
||||
int attr_nid);
|
||||
char *PKCS12_get_friendlyname(PKCS12_SAFEBAG *bag);
|
||||
const STACK_OF(X509_ATTRIBUTE) *
|
||||
PKCS12_SAFEBAG_get0_attrs(const PKCS12_SAFEBAG *bag);
|
||||
unsigned char *PKCS12_pbe_crypt(const X509_ALGOR *algor,
|
||||
const char *pass, int passlen,
|
||||
const unsigned char *in, int inlen,
|
||||
unsigned char **data, int *datalen,
|
||||
int en_de);
|
||||
unsigned char *PKCS12_pbe_crypt_ex(const X509_ALGOR *algor,
|
||||
const char *pass, int passlen,
|
||||
const unsigned char *in, int inlen,
|
||||
unsigned char **data, int *datalen,
|
||||
int en_de, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
void *PKCS12_item_decrypt_d2i(const X509_ALGOR *algor, const ASN1_ITEM *it,
|
||||
const char *pass, int passlen,
|
||||
const ASN1_OCTET_STRING *oct, int zbuf);
|
||||
void *PKCS12_item_decrypt_d2i_ex(const X509_ALGOR *algor, const ASN1_ITEM *it,
|
||||
const char *pass, int passlen,
|
||||
const ASN1_OCTET_STRING *oct, int zbuf,
|
||||
OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
ASN1_OCTET_STRING *PKCS12_item_i2d_encrypt(X509_ALGOR *algor,
|
||||
const ASN1_ITEM *it,
|
||||
const char *pass, int passlen,
|
||||
void *obj, int zbuf);
|
||||
ASN1_OCTET_STRING *PKCS12_item_i2d_encrypt_ex(X509_ALGOR *algor,
|
||||
const ASN1_ITEM *it,
|
||||
const char *pass, int passlen,
|
||||
void *obj, int zbuf,
|
||||
OSSL_LIB_CTX *ctx,
|
||||
const char *propq);
|
||||
PKCS12 *PKCS12_init(int mode);
|
||||
PKCS12 *PKCS12_init_ex(int mode, OSSL_LIB_CTX *ctx, const char *propq);
|
||||
|
||||
int PKCS12_key_gen_asc(const char *pass, int passlen, unsigned char *salt,
|
||||
int saltlen, int id, int iter, int n,
|
||||
unsigned char *out, const EVP_MD *md_type);
|
||||
int PKCS12_key_gen_asc_ex(const char *pass, int passlen, unsigned char *salt,
|
||||
int saltlen, int id, int iter, int n,
|
||||
unsigned char *out, const EVP_MD *md_type,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
int PKCS12_key_gen_uni(unsigned char *pass, int passlen, unsigned char *salt,
|
||||
int saltlen, int id, int iter, int n,
|
||||
unsigned char *out, const EVP_MD *md_type);
|
||||
int PKCS12_key_gen_uni_ex(unsigned char *pass, int passlen, unsigned char *salt,
|
||||
int saltlen, int id, int iter, int n,
|
||||
unsigned char *out, const EVP_MD *md_type,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
int PKCS12_key_gen_utf8(const char *pass, int passlen, unsigned char *salt,
|
||||
int saltlen, int id, int iter, int n,
|
||||
unsigned char *out, const EVP_MD *md_type);
|
||||
int PKCS12_key_gen_utf8_ex(const char *pass, int passlen, unsigned char *salt,
|
||||
int saltlen, int id, int iter, int n,
|
||||
unsigned char *out, const EVP_MD *md_type,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
|
||||
int PKCS12_PBE_keyivgen(EVP_CIPHER_CTX *ctx, const char *pass, int passlen,
|
||||
ASN1_TYPE *param, const EVP_CIPHER *cipher,
|
||||
const EVP_MD *md_type, int en_de);
|
||||
int PKCS12_PBE_keyivgen_ex(EVP_CIPHER_CTX *ctx, const char *pass, int passlen,
|
||||
ASN1_TYPE *param, const EVP_CIPHER *cipher,
|
||||
const EVP_MD *md_type, int en_de,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
int PKCS12_gen_mac(PKCS12 *p12, const char *pass, int passlen,
|
||||
unsigned char *mac, unsigned int *maclen);
|
||||
int PKCS12_verify_mac(PKCS12 *p12, const char *pass, int passlen);
|
||||
int PKCS12_set_mac(PKCS12 *p12, const char *pass, int passlen,
|
||||
unsigned char *salt, int saltlen, int iter,
|
||||
const EVP_MD *md_type);
|
||||
int PKCS12_setup_mac(PKCS12 *p12, int iter, unsigned char *salt,
|
||||
int saltlen, const EVP_MD *md_type);
|
||||
unsigned char *OPENSSL_asc2uni(const char *asc, int asclen,
|
||||
unsigned char **uni, int *unilen);
|
||||
char *OPENSSL_uni2asc(const unsigned char *uni, int unilen);
|
||||
unsigned char *OPENSSL_utf82uni(const char *asc, int asclen,
|
||||
unsigned char **uni, int *unilen);
|
||||
char *OPENSSL_uni2utf8(const unsigned char *uni, int unilen);
|
||||
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS12)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS12_MAC_DATA)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS12_SAFEBAG)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS12_BAGS)
|
||||
|
||||
DECLARE_ASN1_ITEM(PKCS12_SAFEBAGS)
|
||||
DECLARE_ASN1_ITEM(PKCS12_AUTHSAFES)
|
||||
|
||||
void PKCS12_PBE_add(void);
|
||||
int PKCS12_parse(PKCS12 *p12, const char *pass, EVP_PKEY **pkey, X509 **cert,
|
||||
STACK_OF(X509) **ca);
|
||||
PKCS12 *PKCS12_create(const char *pass, const char *name, EVP_PKEY *pkey,
|
||||
X509 *cert, STACK_OF(X509) *ca, int nid_key, int nid_cert,
|
||||
int iter, int mac_iter, int keytype);
|
||||
PKCS12 *PKCS12_create_ex(const char *pass, const char *name, EVP_PKEY *pkey,
|
||||
X509 *cert, STACK_OF(X509) *ca, int nid_key, int nid_cert,
|
||||
int iter, int mac_iter, int keytype,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
|
||||
PKCS12_SAFEBAG *PKCS12_add_cert(STACK_OF(PKCS12_SAFEBAG) **pbags, X509 *cert);
|
||||
PKCS12_SAFEBAG *PKCS12_add_key(STACK_OF(PKCS12_SAFEBAG) **pbags,
|
||||
EVP_PKEY *key, int key_usage, int iter,
|
||||
int key_nid, const char *pass);
|
||||
PKCS12_SAFEBAG *PKCS12_add_key_ex(STACK_OF(PKCS12_SAFEBAG) **pbags,
|
||||
EVP_PKEY *key, int key_usage, int iter,
|
||||
int key_nid, const char *pass,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
|
||||
PKCS12_SAFEBAG *PKCS12_add_secret(STACK_OF(PKCS12_SAFEBAG) **pbags,
|
||||
int nid_type, const unsigned char *value, int len);
|
||||
int PKCS12_add_safe(STACK_OF(PKCS7) **psafes, STACK_OF(PKCS12_SAFEBAG) *bags,
|
||||
int safe_nid, int iter, const char *pass);
|
||||
int PKCS12_add_safe_ex(STACK_OF(PKCS7) **psafes, STACK_OF(PKCS12_SAFEBAG) *bags,
|
||||
int safe_nid, int iter, const char *pass,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
|
||||
PKCS12 *PKCS12_add_safes(STACK_OF(PKCS7) *safes, int p7_nid);
|
||||
PKCS12 *PKCS12_add_safes_ex(STACK_OF(PKCS7) *safes, int p7_nid,
|
||||
OSSL_LIB_CTX *ctx, const char *propq);
|
||||
|
||||
int i2d_PKCS12_bio(BIO *bp, const PKCS12 *p12);
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
int i2d_PKCS12_fp(FILE *fp, const PKCS12 *p12);
|
||||
# endif
|
||||
PKCS12 *d2i_PKCS12_bio(BIO *bp, PKCS12 **p12);
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
PKCS12 *d2i_PKCS12_fp(FILE *fp, PKCS12 **p12);
|
||||
# endif
|
||||
int PKCS12_newpass(PKCS12 *p12, const char *oldpass, const char *newpass);
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
427
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/pkcs7.h
generated
vendored
Normal file
427
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/pkcs7.h
generated
vendored
Normal file
@@ -0,0 +1,427 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/pkcs7.h.in
|
||||
*
|
||||
* Copyright 1995-2023 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_PKCS7_H
|
||||
# define OPENSSL_PKCS7_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_PKCS7_H
|
||||
# endif
|
||||
|
||||
# include <openssl/asn1.h>
|
||||
# include <openssl/bio.h>
|
||||
# include <openssl/e_os2.h>
|
||||
|
||||
# include <openssl/symhacks.h>
|
||||
# include <openssl/types.h>
|
||||
# include <openssl/pkcs7err.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
|
||||
/*-
|
||||
Encryption_ID DES-CBC
|
||||
Digest_ID MD5
|
||||
Digest_Encryption_ID rsaEncryption
|
||||
Key_Encryption_ID rsaEncryption
|
||||
*/
|
||||
|
||||
typedef struct PKCS7_CTX_st {
|
||||
OSSL_LIB_CTX *libctx;
|
||||
char *propq;
|
||||
} PKCS7_CTX;
|
||||
|
||||
typedef struct pkcs7_issuer_and_serial_st {
|
||||
X509_NAME *issuer;
|
||||
ASN1_INTEGER *serial;
|
||||
} PKCS7_ISSUER_AND_SERIAL;
|
||||
|
||||
typedef struct pkcs7_signer_info_st {
|
||||
ASN1_INTEGER *version; /* version 1 */
|
||||
PKCS7_ISSUER_AND_SERIAL *issuer_and_serial;
|
||||
X509_ALGOR *digest_alg;
|
||||
STACK_OF(X509_ATTRIBUTE) *auth_attr; /* [ 0 ] */
|
||||
X509_ALGOR *digest_enc_alg; /* confusing name, actually used for signing */
|
||||
ASN1_OCTET_STRING *enc_digest; /* confusing name, actually signature */
|
||||
STACK_OF(X509_ATTRIBUTE) *unauth_attr; /* [ 1 ] */
|
||||
/* The private key to sign with */
|
||||
EVP_PKEY *pkey;
|
||||
const PKCS7_CTX *ctx;
|
||||
} PKCS7_SIGNER_INFO;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(PKCS7_SIGNER_INFO, PKCS7_SIGNER_INFO, PKCS7_SIGNER_INFO)
|
||||
#define sk_PKCS7_SIGNER_INFO_num(sk) OPENSSL_sk_num(ossl_check_const_PKCS7_SIGNER_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_SIGNER_INFO_value(sk, idx) ((PKCS7_SIGNER_INFO *)OPENSSL_sk_value(ossl_check_const_PKCS7_SIGNER_INFO_sk_type(sk), (idx)))
|
||||
#define sk_PKCS7_SIGNER_INFO_new(cmp) ((STACK_OF(PKCS7_SIGNER_INFO) *)OPENSSL_sk_new(ossl_check_PKCS7_SIGNER_INFO_compfunc_type(cmp)))
|
||||
#define sk_PKCS7_SIGNER_INFO_new_null() ((STACK_OF(PKCS7_SIGNER_INFO) *)OPENSSL_sk_new_null())
|
||||
#define sk_PKCS7_SIGNER_INFO_new_reserve(cmp, n) ((STACK_OF(PKCS7_SIGNER_INFO) *)OPENSSL_sk_new_reserve(ossl_check_PKCS7_SIGNER_INFO_compfunc_type(cmp), (n)))
|
||||
#define sk_PKCS7_SIGNER_INFO_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), (n))
|
||||
#define sk_PKCS7_SIGNER_INFO_free(sk) OPENSSL_sk_free(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_SIGNER_INFO_zero(sk) OPENSSL_sk_zero(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_SIGNER_INFO_delete(sk, i) ((PKCS7_SIGNER_INFO *)OPENSSL_sk_delete(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), (i)))
|
||||
#define sk_PKCS7_SIGNER_INFO_delete_ptr(sk, ptr) ((PKCS7_SIGNER_INFO *)OPENSSL_sk_delete_ptr(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), ossl_check_PKCS7_SIGNER_INFO_type(ptr)))
|
||||
#define sk_PKCS7_SIGNER_INFO_push(sk, ptr) OPENSSL_sk_push(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), ossl_check_PKCS7_SIGNER_INFO_type(ptr))
|
||||
#define sk_PKCS7_SIGNER_INFO_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), ossl_check_PKCS7_SIGNER_INFO_type(ptr))
|
||||
#define sk_PKCS7_SIGNER_INFO_pop(sk) ((PKCS7_SIGNER_INFO *)OPENSSL_sk_pop(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk)))
|
||||
#define sk_PKCS7_SIGNER_INFO_shift(sk) ((PKCS7_SIGNER_INFO *)OPENSSL_sk_shift(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk)))
|
||||
#define sk_PKCS7_SIGNER_INFO_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk),ossl_check_PKCS7_SIGNER_INFO_freefunc_type(freefunc))
|
||||
#define sk_PKCS7_SIGNER_INFO_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), ossl_check_PKCS7_SIGNER_INFO_type(ptr), (idx))
|
||||
#define sk_PKCS7_SIGNER_INFO_set(sk, idx, ptr) ((PKCS7_SIGNER_INFO *)OPENSSL_sk_set(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), (idx), ossl_check_PKCS7_SIGNER_INFO_type(ptr)))
|
||||
#define sk_PKCS7_SIGNER_INFO_find(sk, ptr) OPENSSL_sk_find(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), ossl_check_PKCS7_SIGNER_INFO_type(ptr))
|
||||
#define sk_PKCS7_SIGNER_INFO_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), ossl_check_PKCS7_SIGNER_INFO_type(ptr))
|
||||
#define sk_PKCS7_SIGNER_INFO_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), ossl_check_PKCS7_SIGNER_INFO_type(ptr), pnum)
|
||||
#define sk_PKCS7_SIGNER_INFO_sort(sk) OPENSSL_sk_sort(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_SIGNER_INFO_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_PKCS7_SIGNER_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_SIGNER_INFO_dup(sk) ((STACK_OF(PKCS7_SIGNER_INFO) *)OPENSSL_sk_dup(ossl_check_const_PKCS7_SIGNER_INFO_sk_type(sk)))
|
||||
#define sk_PKCS7_SIGNER_INFO_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(PKCS7_SIGNER_INFO) *)OPENSSL_sk_deep_copy(ossl_check_const_PKCS7_SIGNER_INFO_sk_type(sk), ossl_check_PKCS7_SIGNER_INFO_copyfunc_type(copyfunc), ossl_check_PKCS7_SIGNER_INFO_freefunc_type(freefunc)))
|
||||
#define sk_PKCS7_SIGNER_INFO_set_cmp_func(sk, cmp) ((sk_PKCS7_SIGNER_INFO_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_PKCS7_SIGNER_INFO_sk_type(sk), ossl_check_PKCS7_SIGNER_INFO_compfunc_type(cmp)))
|
||||
|
||||
|
||||
typedef struct pkcs7_recip_info_st {
|
||||
ASN1_INTEGER *version; /* version 0 */
|
||||
PKCS7_ISSUER_AND_SERIAL *issuer_and_serial;
|
||||
X509_ALGOR *key_enc_algor;
|
||||
ASN1_OCTET_STRING *enc_key;
|
||||
X509 *cert; /* get the pub-key from this */
|
||||
const PKCS7_CTX *ctx;
|
||||
} PKCS7_RECIP_INFO;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(PKCS7_RECIP_INFO, PKCS7_RECIP_INFO, PKCS7_RECIP_INFO)
|
||||
#define sk_PKCS7_RECIP_INFO_num(sk) OPENSSL_sk_num(ossl_check_const_PKCS7_RECIP_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_RECIP_INFO_value(sk, idx) ((PKCS7_RECIP_INFO *)OPENSSL_sk_value(ossl_check_const_PKCS7_RECIP_INFO_sk_type(sk), (idx)))
|
||||
#define sk_PKCS7_RECIP_INFO_new(cmp) ((STACK_OF(PKCS7_RECIP_INFO) *)OPENSSL_sk_new(ossl_check_PKCS7_RECIP_INFO_compfunc_type(cmp)))
|
||||
#define sk_PKCS7_RECIP_INFO_new_null() ((STACK_OF(PKCS7_RECIP_INFO) *)OPENSSL_sk_new_null())
|
||||
#define sk_PKCS7_RECIP_INFO_new_reserve(cmp, n) ((STACK_OF(PKCS7_RECIP_INFO) *)OPENSSL_sk_new_reserve(ossl_check_PKCS7_RECIP_INFO_compfunc_type(cmp), (n)))
|
||||
#define sk_PKCS7_RECIP_INFO_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), (n))
|
||||
#define sk_PKCS7_RECIP_INFO_free(sk) OPENSSL_sk_free(ossl_check_PKCS7_RECIP_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_RECIP_INFO_zero(sk) OPENSSL_sk_zero(ossl_check_PKCS7_RECIP_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_RECIP_INFO_delete(sk, i) ((PKCS7_RECIP_INFO *)OPENSSL_sk_delete(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), (i)))
|
||||
#define sk_PKCS7_RECIP_INFO_delete_ptr(sk, ptr) ((PKCS7_RECIP_INFO *)OPENSSL_sk_delete_ptr(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), ossl_check_PKCS7_RECIP_INFO_type(ptr)))
|
||||
#define sk_PKCS7_RECIP_INFO_push(sk, ptr) OPENSSL_sk_push(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), ossl_check_PKCS7_RECIP_INFO_type(ptr))
|
||||
#define sk_PKCS7_RECIP_INFO_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), ossl_check_PKCS7_RECIP_INFO_type(ptr))
|
||||
#define sk_PKCS7_RECIP_INFO_pop(sk) ((PKCS7_RECIP_INFO *)OPENSSL_sk_pop(ossl_check_PKCS7_RECIP_INFO_sk_type(sk)))
|
||||
#define sk_PKCS7_RECIP_INFO_shift(sk) ((PKCS7_RECIP_INFO *)OPENSSL_sk_shift(ossl_check_PKCS7_RECIP_INFO_sk_type(sk)))
|
||||
#define sk_PKCS7_RECIP_INFO_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_PKCS7_RECIP_INFO_sk_type(sk),ossl_check_PKCS7_RECIP_INFO_freefunc_type(freefunc))
|
||||
#define sk_PKCS7_RECIP_INFO_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), ossl_check_PKCS7_RECIP_INFO_type(ptr), (idx))
|
||||
#define sk_PKCS7_RECIP_INFO_set(sk, idx, ptr) ((PKCS7_RECIP_INFO *)OPENSSL_sk_set(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), (idx), ossl_check_PKCS7_RECIP_INFO_type(ptr)))
|
||||
#define sk_PKCS7_RECIP_INFO_find(sk, ptr) OPENSSL_sk_find(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), ossl_check_PKCS7_RECIP_INFO_type(ptr))
|
||||
#define sk_PKCS7_RECIP_INFO_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), ossl_check_PKCS7_RECIP_INFO_type(ptr))
|
||||
#define sk_PKCS7_RECIP_INFO_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), ossl_check_PKCS7_RECIP_INFO_type(ptr), pnum)
|
||||
#define sk_PKCS7_RECIP_INFO_sort(sk) OPENSSL_sk_sort(ossl_check_PKCS7_RECIP_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_RECIP_INFO_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_PKCS7_RECIP_INFO_sk_type(sk))
|
||||
#define sk_PKCS7_RECIP_INFO_dup(sk) ((STACK_OF(PKCS7_RECIP_INFO) *)OPENSSL_sk_dup(ossl_check_const_PKCS7_RECIP_INFO_sk_type(sk)))
|
||||
#define sk_PKCS7_RECIP_INFO_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(PKCS7_RECIP_INFO) *)OPENSSL_sk_deep_copy(ossl_check_const_PKCS7_RECIP_INFO_sk_type(sk), ossl_check_PKCS7_RECIP_INFO_copyfunc_type(copyfunc), ossl_check_PKCS7_RECIP_INFO_freefunc_type(freefunc)))
|
||||
#define sk_PKCS7_RECIP_INFO_set_cmp_func(sk, cmp) ((sk_PKCS7_RECIP_INFO_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_PKCS7_RECIP_INFO_sk_type(sk), ossl_check_PKCS7_RECIP_INFO_compfunc_type(cmp)))
|
||||
|
||||
|
||||
|
||||
typedef struct pkcs7_signed_st {
|
||||
ASN1_INTEGER *version; /* version 1 */
|
||||
STACK_OF(X509_ALGOR) *md_algs; /* md used */
|
||||
STACK_OF(X509) *cert; /* [ 0 ] */
|
||||
STACK_OF(X509_CRL) *crl; /* [ 1 ] */
|
||||
STACK_OF(PKCS7_SIGNER_INFO) *signer_info;
|
||||
struct pkcs7_st *contents;
|
||||
} PKCS7_SIGNED;
|
||||
/*
|
||||
* The above structure is very very similar to PKCS7_SIGN_ENVELOPE. How about
|
||||
* merging the two
|
||||
*/
|
||||
|
||||
typedef struct pkcs7_enc_content_st {
|
||||
ASN1_OBJECT *content_type;
|
||||
X509_ALGOR *algorithm;
|
||||
ASN1_OCTET_STRING *enc_data; /* [ 0 ] */
|
||||
const EVP_CIPHER *cipher;
|
||||
const PKCS7_CTX *ctx;
|
||||
} PKCS7_ENC_CONTENT;
|
||||
|
||||
typedef struct pkcs7_enveloped_st {
|
||||
ASN1_INTEGER *version; /* version 0 */
|
||||
STACK_OF(PKCS7_RECIP_INFO) *recipientinfo;
|
||||
PKCS7_ENC_CONTENT *enc_data;
|
||||
} PKCS7_ENVELOPE;
|
||||
|
||||
typedef struct pkcs7_signedandenveloped_st {
|
||||
ASN1_INTEGER *version; /* version 1 */
|
||||
STACK_OF(X509_ALGOR) *md_algs; /* md used */
|
||||
STACK_OF(X509) *cert; /* [ 0 ] */
|
||||
STACK_OF(X509_CRL) *crl; /* [ 1 ] */
|
||||
STACK_OF(PKCS7_SIGNER_INFO) *signer_info;
|
||||
PKCS7_ENC_CONTENT *enc_data;
|
||||
STACK_OF(PKCS7_RECIP_INFO) *recipientinfo;
|
||||
} PKCS7_SIGN_ENVELOPE;
|
||||
|
||||
typedef struct pkcs7_digest_st {
|
||||
ASN1_INTEGER *version; /* version 0 */
|
||||
X509_ALGOR *md; /* md used */
|
||||
struct pkcs7_st *contents;
|
||||
ASN1_OCTET_STRING *digest;
|
||||
} PKCS7_DIGEST;
|
||||
|
||||
typedef struct pkcs7_encrypted_st {
|
||||
ASN1_INTEGER *version; /* version 0 */
|
||||
PKCS7_ENC_CONTENT *enc_data;
|
||||
} PKCS7_ENCRYPT;
|
||||
|
||||
typedef struct pkcs7_st {
|
||||
/*
|
||||
* The following is non NULL if it contains ASN1 encoding of this
|
||||
* structure
|
||||
*/
|
||||
unsigned char *asn1;
|
||||
long length;
|
||||
# define PKCS7_S_HEADER 0
|
||||
# define PKCS7_S_BODY 1
|
||||
# define PKCS7_S_TAIL 2
|
||||
int state; /* used during processing */
|
||||
int detached;
|
||||
ASN1_OBJECT *type;
|
||||
/* content as defined by the type */
|
||||
/*
|
||||
* all encryption/message digests are applied to the 'contents', leaving
|
||||
* out the 'type' field.
|
||||
*/
|
||||
union {
|
||||
char *ptr;
|
||||
/* NID_pkcs7_data */
|
||||
ASN1_OCTET_STRING *data;
|
||||
/* NID_pkcs7_signed */
|
||||
PKCS7_SIGNED *sign;
|
||||
/* NID_pkcs7_enveloped */
|
||||
PKCS7_ENVELOPE *enveloped;
|
||||
/* NID_pkcs7_signedAndEnveloped */
|
||||
PKCS7_SIGN_ENVELOPE *signed_and_enveloped;
|
||||
/* NID_pkcs7_digest */
|
||||
PKCS7_DIGEST *digest;
|
||||
/* NID_pkcs7_encrypted */
|
||||
PKCS7_ENCRYPT *encrypted;
|
||||
/* Anything else */
|
||||
ASN1_TYPE *other;
|
||||
} d;
|
||||
PKCS7_CTX ctx;
|
||||
} PKCS7;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(PKCS7, PKCS7, PKCS7)
|
||||
#define sk_PKCS7_num(sk) OPENSSL_sk_num(ossl_check_const_PKCS7_sk_type(sk))
|
||||
#define sk_PKCS7_value(sk, idx) ((PKCS7 *)OPENSSL_sk_value(ossl_check_const_PKCS7_sk_type(sk), (idx)))
|
||||
#define sk_PKCS7_new(cmp) ((STACK_OF(PKCS7) *)OPENSSL_sk_new(ossl_check_PKCS7_compfunc_type(cmp)))
|
||||
#define sk_PKCS7_new_null() ((STACK_OF(PKCS7) *)OPENSSL_sk_new_null())
|
||||
#define sk_PKCS7_new_reserve(cmp, n) ((STACK_OF(PKCS7) *)OPENSSL_sk_new_reserve(ossl_check_PKCS7_compfunc_type(cmp), (n)))
|
||||
#define sk_PKCS7_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_PKCS7_sk_type(sk), (n))
|
||||
#define sk_PKCS7_free(sk) OPENSSL_sk_free(ossl_check_PKCS7_sk_type(sk))
|
||||
#define sk_PKCS7_zero(sk) OPENSSL_sk_zero(ossl_check_PKCS7_sk_type(sk))
|
||||
#define sk_PKCS7_delete(sk, i) ((PKCS7 *)OPENSSL_sk_delete(ossl_check_PKCS7_sk_type(sk), (i)))
|
||||
#define sk_PKCS7_delete_ptr(sk, ptr) ((PKCS7 *)OPENSSL_sk_delete_ptr(ossl_check_PKCS7_sk_type(sk), ossl_check_PKCS7_type(ptr)))
|
||||
#define sk_PKCS7_push(sk, ptr) OPENSSL_sk_push(ossl_check_PKCS7_sk_type(sk), ossl_check_PKCS7_type(ptr))
|
||||
#define sk_PKCS7_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_PKCS7_sk_type(sk), ossl_check_PKCS7_type(ptr))
|
||||
#define sk_PKCS7_pop(sk) ((PKCS7 *)OPENSSL_sk_pop(ossl_check_PKCS7_sk_type(sk)))
|
||||
#define sk_PKCS7_shift(sk) ((PKCS7 *)OPENSSL_sk_shift(ossl_check_PKCS7_sk_type(sk)))
|
||||
#define sk_PKCS7_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_PKCS7_sk_type(sk),ossl_check_PKCS7_freefunc_type(freefunc))
|
||||
#define sk_PKCS7_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_PKCS7_sk_type(sk), ossl_check_PKCS7_type(ptr), (idx))
|
||||
#define sk_PKCS7_set(sk, idx, ptr) ((PKCS7 *)OPENSSL_sk_set(ossl_check_PKCS7_sk_type(sk), (idx), ossl_check_PKCS7_type(ptr)))
|
||||
#define sk_PKCS7_find(sk, ptr) OPENSSL_sk_find(ossl_check_PKCS7_sk_type(sk), ossl_check_PKCS7_type(ptr))
|
||||
#define sk_PKCS7_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_PKCS7_sk_type(sk), ossl_check_PKCS7_type(ptr))
|
||||
#define sk_PKCS7_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_PKCS7_sk_type(sk), ossl_check_PKCS7_type(ptr), pnum)
|
||||
#define sk_PKCS7_sort(sk) OPENSSL_sk_sort(ossl_check_PKCS7_sk_type(sk))
|
||||
#define sk_PKCS7_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_PKCS7_sk_type(sk))
|
||||
#define sk_PKCS7_dup(sk) ((STACK_OF(PKCS7) *)OPENSSL_sk_dup(ossl_check_const_PKCS7_sk_type(sk)))
|
||||
#define sk_PKCS7_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(PKCS7) *)OPENSSL_sk_deep_copy(ossl_check_const_PKCS7_sk_type(sk), ossl_check_PKCS7_copyfunc_type(copyfunc), ossl_check_PKCS7_freefunc_type(freefunc)))
|
||||
#define sk_PKCS7_set_cmp_func(sk, cmp) ((sk_PKCS7_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_PKCS7_sk_type(sk), ossl_check_PKCS7_compfunc_type(cmp)))
|
||||
|
||||
|
||||
|
||||
# define PKCS7_OP_SET_DETACHED_SIGNATURE 1
|
||||
# define PKCS7_OP_GET_DETACHED_SIGNATURE 2
|
||||
|
||||
# define PKCS7_get_signed_attributes(si) ((si)->auth_attr)
|
||||
# define PKCS7_get_attributes(si) ((si)->unauth_attr)
|
||||
|
||||
# define PKCS7_type_is_signed(a) (OBJ_obj2nid((a)->type) == NID_pkcs7_signed)
|
||||
# define PKCS7_type_is_encrypted(a) (OBJ_obj2nid((a)->type) == NID_pkcs7_encrypted)
|
||||
# define PKCS7_type_is_enveloped(a) (OBJ_obj2nid((a)->type) == NID_pkcs7_enveloped)
|
||||
# define PKCS7_type_is_signedAndEnveloped(a) \
|
||||
(OBJ_obj2nid((a)->type) == NID_pkcs7_signedAndEnveloped)
|
||||
# define PKCS7_type_is_data(a) (OBJ_obj2nid((a)->type) == NID_pkcs7_data)
|
||||
# define PKCS7_type_is_digest(a) (OBJ_obj2nid((a)->type) == NID_pkcs7_digest)
|
||||
|
||||
# define PKCS7_set_detached(p,v) \
|
||||
PKCS7_ctrl(p,PKCS7_OP_SET_DETACHED_SIGNATURE,v,NULL)
|
||||
# define PKCS7_get_detached(p) \
|
||||
PKCS7_ctrl(p,PKCS7_OP_GET_DETACHED_SIGNATURE,0,NULL)
|
||||
|
||||
# define PKCS7_is_detached(p7) (PKCS7_type_is_signed(p7) && PKCS7_get_detached(p7))
|
||||
|
||||
/* S/MIME related flags */
|
||||
|
||||
# define PKCS7_TEXT 0x1
|
||||
# define PKCS7_NOCERTS 0x2
|
||||
# define PKCS7_NOSIGS 0x4
|
||||
# define PKCS7_NOCHAIN 0x8
|
||||
# define PKCS7_NOINTERN 0x10
|
||||
# define PKCS7_NOVERIFY 0x20
|
||||
# define PKCS7_DETACHED 0x40
|
||||
# define PKCS7_BINARY 0x80
|
||||
# define PKCS7_NOATTR 0x100
|
||||
# define PKCS7_NOSMIMECAP 0x200
|
||||
# define PKCS7_NOOLDMIMETYPE 0x400
|
||||
# define PKCS7_CRLFEOL 0x800
|
||||
# define PKCS7_STREAM 0x1000
|
||||
# define PKCS7_NOCRL 0x2000
|
||||
# define PKCS7_PARTIAL 0x4000
|
||||
# define PKCS7_REUSE_DIGEST 0x8000
|
||||
# define PKCS7_NO_DUAL_CONTENT 0x10000
|
||||
|
||||
/* Flags: for compatibility with older code */
|
||||
|
||||
# define SMIME_TEXT PKCS7_TEXT
|
||||
# define SMIME_NOCERTS PKCS7_NOCERTS
|
||||
# define SMIME_NOSIGS PKCS7_NOSIGS
|
||||
# define SMIME_NOCHAIN PKCS7_NOCHAIN
|
||||
# define SMIME_NOINTERN PKCS7_NOINTERN
|
||||
# define SMIME_NOVERIFY PKCS7_NOVERIFY
|
||||
# define SMIME_DETACHED PKCS7_DETACHED
|
||||
# define SMIME_BINARY PKCS7_BINARY
|
||||
# define SMIME_NOATTR PKCS7_NOATTR
|
||||
|
||||
/* CRLF ASCII canonicalisation */
|
||||
# define SMIME_ASCIICRLF 0x80000
|
||||
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7_ISSUER_AND_SERIAL)
|
||||
|
||||
int PKCS7_ISSUER_AND_SERIAL_digest(PKCS7_ISSUER_AND_SERIAL *data,
|
||||
const EVP_MD *type, unsigned char *md,
|
||||
unsigned int *len);
|
||||
# ifndef OPENSSL_NO_STDIO
|
||||
PKCS7 *d2i_PKCS7_fp(FILE *fp, PKCS7 **p7);
|
||||
int i2d_PKCS7_fp(FILE *fp, const PKCS7 *p7);
|
||||
# endif
|
||||
DECLARE_ASN1_DUP_FUNCTION(PKCS7)
|
||||
PKCS7 *d2i_PKCS7_bio(BIO *bp, PKCS7 **p7);
|
||||
int i2d_PKCS7_bio(BIO *bp, const PKCS7 *p7);
|
||||
int i2d_PKCS7_bio_stream(BIO *out, PKCS7 *p7, BIO *in, int flags);
|
||||
int PEM_write_bio_PKCS7_stream(BIO *out, PKCS7 *p7, BIO *in, int flags);
|
||||
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7_SIGNER_INFO)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7_RECIP_INFO)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7_SIGNED)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7_ENC_CONTENT)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7_ENVELOPE)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7_SIGN_ENVELOPE)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7_DIGEST)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7_ENCRYPT)
|
||||
DECLARE_ASN1_FUNCTIONS(PKCS7)
|
||||
PKCS7 *PKCS7_new_ex(OSSL_LIB_CTX *libctx, const char *propq);
|
||||
|
||||
DECLARE_ASN1_ITEM(PKCS7_ATTR_SIGN)
|
||||
DECLARE_ASN1_ITEM(PKCS7_ATTR_VERIFY)
|
||||
|
||||
DECLARE_ASN1_NDEF_FUNCTION(PKCS7)
|
||||
DECLARE_ASN1_PRINT_FUNCTION(PKCS7)
|
||||
|
||||
long PKCS7_ctrl(PKCS7 *p7, int cmd, long larg, char *parg);
|
||||
|
||||
int PKCS7_type_is_other(PKCS7 *p7);
|
||||
int PKCS7_set_type(PKCS7 *p7, int type);
|
||||
int PKCS7_set0_type_other(PKCS7 *p7, int type, ASN1_TYPE *other);
|
||||
int PKCS7_set_content(PKCS7 *p7, PKCS7 *p7_data);
|
||||
int PKCS7_SIGNER_INFO_set(PKCS7_SIGNER_INFO *p7i, X509 *x509, EVP_PKEY *pkey,
|
||||
const EVP_MD *dgst);
|
||||
int PKCS7_SIGNER_INFO_sign(PKCS7_SIGNER_INFO *si);
|
||||
int PKCS7_add_signer(PKCS7 *p7, PKCS7_SIGNER_INFO *p7i);
|
||||
int PKCS7_add_certificate(PKCS7 *p7, X509 *x509);
|
||||
int PKCS7_add_crl(PKCS7 *p7, X509_CRL *x509);
|
||||
int PKCS7_content_new(PKCS7 *p7, int nid);
|
||||
int PKCS7_dataVerify(X509_STORE *cert_store, X509_STORE_CTX *ctx,
|
||||
BIO *bio, PKCS7 *p7, PKCS7_SIGNER_INFO *si);
|
||||
int PKCS7_signatureVerify(BIO *bio, PKCS7 *p7, PKCS7_SIGNER_INFO *si,
|
||||
X509 *x509);
|
||||
|
||||
BIO *PKCS7_dataInit(PKCS7 *p7, BIO *bio);
|
||||
int PKCS7_dataFinal(PKCS7 *p7, BIO *bio);
|
||||
BIO *PKCS7_dataDecode(PKCS7 *p7, EVP_PKEY *pkey, BIO *in_bio, X509 *pcert);
|
||||
|
||||
PKCS7_SIGNER_INFO *PKCS7_add_signature(PKCS7 *p7, X509 *x509,
|
||||
EVP_PKEY *pkey, const EVP_MD *dgst);
|
||||
X509 *PKCS7_cert_from_signer_info(PKCS7 *p7, PKCS7_SIGNER_INFO *si);
|
||||
int PKCS7_set_digest(PKCS7 *p7, const EVP_MD *md);
|
||||
STACK_OF(PKCS7_SIGNER_INFO) *PKCS7_get_signer_info(PKCS7 *p7);
|
||||
|
||||
PKCS7_RECIP_INFO *PKCS7_add_recipient(PKCS7 *p7, X509 *x509);
|
||||
void PKCS7_SIGNER_INFO_get0_algs(PKCS7_SIGNER_INFO *si, EVP_PKEY **pk,
|
||||
X509_ALGOR **pdig, X509_ALGOR **psig);
|
||||
void PKCS7_RECIP_INFO_get0_alg(PKCS7_RECIP_INFO *ri, X509_ALGOR **penc);
|
||||
int PKCS7_add_recipient_info(PKCS7 *p7, PKCS7_RECIP_INFO *ri);
|
||||
int PKCS7_RECIP_INFO_set(PKCS7_RECIP_INFO *p7i, X509 *x509);
|
||||
int PKCS7_set_cipher(PKCS7 *p7, const EVP_CIPHER *cipher);
|
||||
int PKCS7_stream(unsigned char ***boundary, PKCS7 *p7);
|
||||
|
||||
PKCS7_ISSUER_AND_SERIAL *PKCS7_get_issuer_and_serial(PKCS7 *p7, int idx);
|
||||
ASN1_OCTET_STRING *PKCS7_get_octet_string(PKCS7 *p7);
|
||||
ASN1_OCTET_STRING *PKCS7_digest_from_attributes(STACK_OF(X509_ATTRIBUTE) *sk);
|
||||
int PKCS7_add_signed_attribute(PKCS7_SIGNER_INFO *p7si, int nid, int type,
|
||||
void *data);
|
||||
int PKCS7_add_attribute(PKCS7_SIGNER_INFO *p7si, int nid, int atrtype,
|
||||
void *value);
|
||||
ASN1_TYPE *PKCS7_get_attribute(const PKCS7_SIGNER_INFO *si, int nid);
|
||||
ASN1_TYPE *PKCS7_get_signed_attribute(const PKCS7_SIGNER_INFO *si, int nid);
|
||||
int PKCS7_set_signed_attributes(PKCS7_SIGNER_INFO *p7si,
|
||||
STACK_OF(X509_ATTRIBUTE) *sk);
|
||||
int PKCS7_set_attributes(PKCS7_SIGNER_INFO *p7si,
|
||||
STACK_OF(X509_ATTRIBUTE) *sk);
|
||||
|
||||
PKCS7 *PKCS7_sign(X509 *signcert, EVP_PKEY *pkey, STACK_OF(X509) *certs,
|
||||
BIO *data, int flags);
|
||||
PKCS7 *PKCS7_sign_ex(X509 *signcert, EVP_PKEY *pkey, STACK_OF(X509) *certs,
|
||||
BIO *data, int flags, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
|
||||
PKCS7_SIGNER_INFO *PKCS7_sign_add_signer(PKCS7 *p7,
|
||||
X509 *signcert, EVP_PKEY *pkey,
|
||||
const EVP_MD *md, int flags);
|
||||
|
||||
int PKCS7_final(PKCS7 *p7, BIO *data, int flags);
|
||||
int PKCS7_verify(PKCS7 *p7, STACK_OF(X509) *certs, X509_STORE *store,
|
||||
BIO *indata, BIO *out, int flags);
|
||||
STACK_OF(X509) *PKCS7_get0_signers(PKCS7 *p7, STACK_OF(X509) *certs,
|
||||
int flags);
|
||||
PKCS7 *PKCS7_encrypt(STACK_OF(X509) *certs, BIO *in, const EVP_CIPHER *cipher,
|
||||
int flags);
|
||||
PKCS7 *PKCS7_encrypt_ex(STACK_OF(X509) *certs, BIO *in,
|
||||
const EVP_CIPHER *cipher, int flags,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
int PKCS7_decrypt(PKCS7 *p7, EVP_PKEY *pkey, X509 *cert, BIO *data,
|
||||
int flags);
|
||||
|
||||
int PKCS7_add_attrib_smimecap(PKCS7_SIGNER_INFO *si,
|
||||
STACK_OF(X509_ALGOR) *cap);
|
||||
STACK_OF(X509_ALGOR) *PKCS7_get_smimecap(PKCS7_SIGNER_INFO *si);
|
||||
int PKCS7_simple_smimecap(STACK_OF(X509_ALGOR) *sk, int nid, int arg);
|
||||
|
||||
int PKCS7_add_attrib_content_type(PKCS7_SIGNER_INFO *si, ASN1_OBJECT *coid);
|
||||
int PKCS7_add0_attrib_signing_time(PKCS7_SIGNER_INFO *si, ASN1_TIME *t);
|
||||
int PKCS7_add1_attrib_digest(PKCS7_SIGNER_INFO *si,
|
||||
const unsigned char *md, int mdlen);
|
||||
|
||||
int SMIME_write_PKCS7(BIO *bio, PKCS7 *p7, BIO *data, int flags);
|
||||
PKCS7 *SMIME_read_PKCS7_ex(BIO *bio, BIO **bcont, PKCS7 **p7);
|
||||
PKCS7 *SMIME_read_PKCS7(BIO *bio, BIO **bcont);
|
||||
|
||||
BIO *BIO_new_PKCS7(BIO *out, PKCS7 *p7);
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
297
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/safestack.h
generated
vendored
Normal file
297
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/safestack.h
generated
vendored
Normal file
@@ -0,0 +1,297 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/safestack.h.in
|
||||
*
|
||||
* Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_SAFESTACK_H
|
||||
# define OPENSSL_SAFESTACK_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_SAFESTACK_H
|
||||
# endif
|
||||
|
||||
# include <openssl/stack.h>
|
||||
# include <openssl/e_os2.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
# define STACK_OF(type) struct stack_st_##type
|
||||
|
||||
/* Helper macro for internal use */
|
||||
# define SKM_DEFINE_STACK_OF_INTERNAL(t1, t2, t3) \
|
||||
STACK_OF(t1); \
|
||||
typedef int (*sk_##t1##_compfunc)(const t3 * const *a, const t3 *const *b); \
|
||||
typedef void (*sk_##t1##_freefunc)(t3 *a); \
|
||||
typedef t3 * (*sk_##t1##_copyfunc)(const t3 *a); \
|
||||
static ossl_unused ossl_inline t2 *ossl_check_##t1##_type(t2 *ptr) \
|
||||
{ \
|
||||
return ptr; \
|
||||
} \
|
||||
static ossl_unused ossl_inline const OPENSSL_STACK *ossl_check_const_##t1##_sk_type(const STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
return (const OPENSSL_STACK *)sk; \
|
||||
} \
|
||||
static ossl_unused ossl_inline OPENSSL_STACK *ossl_check_##t1##_sk_type(STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
return (OPENSSL_STACK *)sk; \
|
||||
} \
|
||||
static ossl_unused ossl_inline OPENSSL_sk_compfunc ossl_check_##t1##_compfunc_type(sk_##t1##_compfunc cmp) \
|
||||
{ \
|
||||
return (OPENSSL_sk_compfunc)cmp; \
|
||||
} \
|
||||
static ossl_unused ossl_inline OPENSSL_sk_copyfunc ossl_check_##t1##_copyfunc_type(sk_##t1##_copyfunc cpy) \
|
||||
{ \
|
||||
return (OPENSSL_sk_copyfunc)cpy; \
|
||||
} \
|
||||
static ossl_unused ossl_inline OPENSSL_sk_freefunc ossl_check_##t1##_freefunc_type(sk_##t1##_freefunc fr) \
|
||||
{ \
|
||||
return (OPENSSL_sk_freefunc)fr; \
|
||||
}
|
||||
|
||||
# define SKM_DEFINE_STACK_OF(t1, t2, t3) \
|
||||
STACK_OF(t1); \
|
||||
typedef int (*sk_##t1##_compfunc)(const t3 * const *a, const t3 *const *b); \
|
||||
typedef void (*sk_##t1##_freefunc)(t3 *a); \
|
||||
typedef t3 * (*sk_##t1##_copyfunc)(const t3 *a); \
|
||||
static ossl_unused ossl_inline int sk_##t1##_num(const STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
return OPENSSL_sk_num((const OPENSSL_STACK *)sk); \
|
||||
} \
|
||||
static ossl_unused ossl_inline t2 *sk_##t1##_value(const STACK_OF(t1) *sk, int idx) \
|
||||
{ \
|
||||
return (t2 *)OPENSSL_sk_value((const OPENSSL_STACK *)sk, idx); \
|
||||
} \
|
||||
static ossl_unused ossl_inline STACK_OF(t1) *sk_##t1##_new(sk_##t1##_compfunc compare) \
|
||||
{ \
|
||||
return (STACK_OF(t1) *)OPENSSL_sk_new((OPENSSL_sk_compfunc)compare); \
|
||||
} \
|
||||
static ossl_unused ossl_inline STACK_OF(t1) *sk_##t1##_new_null(void) \
|
||||
{ \
|
||||
return (STACK_OF(t1) *)OPENSSL_sk_new_null(); \
|
||||
} \
|
||||
static ossl_unused ossl_inline STACK_OF(t1) *sk_##t1##_new_reserve(sk_##t1##_compfunc compare, int n) \
|
||||
{ \
|
||||
return (STACK_OF(t1) *)OPENSSL_sk_new_reserve((OPENSSL_sk_compfunc)compare, n); \
|
||||
} \
|
||||
static ossl_unused ossl_inline int sk_##t1##_reserve(STACK_OF(t1) *sk, int n) \
|
||||
{ \
|
||||
return OPENSSL_sk_reserve((OPENSSL_STACK *)sk, n); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void sk_##t1##_free(STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
OPENSSL_sk_free((OPENSSL_STACK *)sk); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void sk_##t1##_zero(STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
OPENSSL_sk_zero((OPENSSL_STACK *)sk); \
|
||||
} \
|
||||
static ossl_unused ossl_inline t2 *sk_##t1##_delete(STACK_OF(t1) *sk, int i) \
|
||||
{ \
|
||||
return (t2 *)OPENSSL_sk_delete((OPENSSL_STACK *)sk, i); \
|
||||
} \
|
||||
static ossl_unused ossl_inline t2 *sk_##t1##_delete_ptr(STACK_OF(t1) *sk, t2 *ptr) \
|
||||
{ \
|
||||
return (t2 *)OPENSSL_sk_delete_ptr((OPENSSL_STACK *)sk, \
|
||||
(const void *)ptr); \
|
||||
} \
|
||||
static ossl_unused ossl_inline int sk_##t1##_push(STACK_OF(t1) *sk, t2 *ptr) \
|
||||
{ \
|
||||
return OPENSSL_sk_push((OPENSSL_STACK *)sk, (const void *)ptr); \
|
||||
} \
|
||||
static ossl_unused ossl_inline int sk_##t1##_unshift(STACK_OF(t1) *sk, t2 *ptr) \
|
||||
{ \
|
||||
return OPENSSL_sk_unshift((OPENSSL_STACK *)sk, (const void *)ptr); \
|
||||
} \
|
||||
static ossl_unused ossl_inline t2 *sk_##t1##_pop(STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
return (t2 *)OPENSSL_sk_pop((OPENSSL_STACK *)sk); \
|
||||
} \
|
||||
static ossl_unused ossl_inline t2 *sk_##t1##_shift(STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
return (t2 *)OPENSSL_sk_shift((OPENSSL_STACK *)sk); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void sk_##t1##_pop_free(STACK_OF(t1) *sk, sk_##t1##_freefunc freefunc) \
|
||||
{ \
|
||||
OPENSSL_sk_pop_free((OPENSSL_STACK *)sk, (OPENSSL_sk_freefunc)freefunc); \
|
||||
} \
|
||||
static ossl_unused ossl_inline int sk_##t1##_insert(STACK_OF(t1) *sk, t2 *ptr, int idx) \
|
||||
{ \
|
||||
return OPENSSL_sk_insert((OPENSSL_STACK *)sk, (const void *)ptr, idx); \
|
||||
} \
|
||||
static ossl_unused ossl_inline t2 *sk_##t1##_set(STACK_OF(t1) *sk, int idx, t2 *ptr) \
|
||||
{ \
|
||||
return (t2 *)OPENSSL_sk_set((OPENSSL_STACK *)sk, idx, (const void *)ptr); \
|
||||
} \
|
||||
static ossl_unused ossl_inline int sk_##t1##_find(STACK_OF(t1) *sk, t2 *ptr) \
|
||||
{ \
|
||||
return OPENSSL_sk_find((OPENSSL_STACK *)sk, (const void *)ptr); \
|
||||
} \
|
||||
static ossl_unused ossl_inline int sk_##t1##_find_ex(STACK_OF(t1) *sk, t2 *ptr) \
|
||||
{ \
|
||||
return OPENSSL_sk_find_ex((OPENSSL_STACK *)sk, (const void *)ptr); \
|
||||
} \
|
||||
static ossl_unused ossl_inline int sk_##t1##_find_all(STACK_OF(t1) *sk, t2 *ptr, int *pnum) \
|
||||
{ \
|
||||
return OPENSSL_sk_find_all((OPENSSL_STACK *)sk, (const void *)ptr, pnum); \
|
||||
} \
|
||||
static ossl_unused ossl_inline void sk_##t1##_sort(STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
OPENSSL_sk_sort((OPENSSL_STACK *)sk); \
|
||||
} \
|
||||
static ossl_unused ossl_inline int sk_##t1##_is_sorted(const STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
return OPENSSL_sk_is_sorted((const OPENSSL_STACK *)sk); \
|
||||
} \
|
||||
static ossl_unused ossl_inline STACK_OF(t1) * sk_##t1##_dup(const STACK_OF(t1) *sk) \
|
||||
{ \
|
||||
return (STACK_OF(t1) *)OPENSSL_sk_dup((const OPENSSL_STACK *)sk); \
|
||||
} \
|
||||
static ossl_unused ossl_inline STACK_OF(t1) *sk_##t1##_deep_copy(const STACK_OF(t1) *sk, \
|
||||
sk_##t1##_copyfunc copyfunc, \
|
||||
sk_##t1##_freefunc freefunc) \
|
||||
{ \
|
||||
return (STACK_OF(t1) *)OPENSSL_sk_deep_copy((const OPENSSL_STACK *)sk, \
|
||||
(OPENSSL_sk_copyfunc)copyfunc, \
|
||||
(OPENSSL_sk_freefunc)freefunc); \
|
||||
} \
|
||||
static ossl_unused ossl_inline sk_##t1##_compfunc sk_##t1##_set_cmp_func(STACK_OF(t1) *sk, sk_##t1##_compfunc compare) \
|
||||
{ \
|
||||
return (sk_##t1##_compfunc)OPENSSL_sk_set_cmp_func((OPENSSL_STACK *)sk, (OPENSSL_sk_compfunc)compare); \
|
||||
}
|
||||
|
||||
# define DEFINE_STACK_OF(t) SKM_DEFINE_STACK_OF(t, t, t)
|
||||
# define DEFINE_STACK_OF_CONST(t) SKM_DEFINE_STACK_OF(t, const t, t)
|
||||
# define DEFINE_SPECIAL_STACK_OF(t1, t2) SKM_DEFINE_STACK_OF(t1, t2, t2)
|
||||
# define DEFINE_SPECIAL_STACK_OF_CONST(t1, t2) \
|
||||
SKM_DEFINE_STACK_OF(t1, const t2, t2)
|
||||
|
||||
/*-
|
||||
* Strings are special: normally an lhash entry will point to a single
|
||||
* (somewhat) mutable object. In the case of strings:
|
||||
*
|
||||
* a) Instead of a single char, there is an array of chars, NUL-terminated.
|
||||
* b) The string may have be immutable.
|
||||
*
|
||||
* So, they need their own declarations. Especially important for
|
||||
* type-checking tools, such as Deputy.
|
||||
*
|
||||
* In practice, however, it appears to be hard to have a const
|
||||
* string. For now, I'm settling for dealing with the fact it is a
|
||||
* string at all.
|
||||
*/
|
||||
typedef char *OPENSSL_STRING;
|
||||
typedef const char *OPENSSL_CSTRING;
|
||||
|
||||
/*-
|
||||
* Confusingly, LHASH_OF(STRING) deals with char ** throughout, but
|
||||
* STACK_OF(STRING) is really more like STACK_OF(char), only, as mentioned
|
||||
* above, instead of a single char each entry is a NUL-terminated array of
|
||||
* chars. So, we have to implement STRING specially for STACK_OF. This is
|
||||
* dealt with in the autogenerated macros below.
|
||||
*/
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OPENSSL_STRING, char, char)
|
||||
#define sk_OPENSSL_STRING_num(sk) OPENSSL_sk_num(ossl_check_const_OPENSSL_STRING_sk_type(sk))
|
||||
#define sk_OPENSSL_STRING_value(sk, idx) ((char *)OPENSSL_sk_value(ossl_check_const_OPENSSL_STRING_sk_type(sk), (idx)))
|
||||
#define sk_OPENSSL_STRING_new(cmp) ((STACK_OF(OPENSSL_STRING) *)OPENSSL_sk_new(ossl_check_OPENSSL_STRING_compfunc_type(cmp)))
|
||||
#define sk_OPENSSL_STRING_new_null() ((STACK_OF(OPENSSL_STRING) *)OPENSSL_sk_new_null())
|
||||
#define sk_OPENSSL_STRING_new_reserve(cmp, n) ((STACK_OF(OPENSSL_STRING) *)OPENSSL_sk_new_reserve(ossl_check_OPENSSL_STRING_compfunc_type(cmp), (n)))
|
||||
#define sk_OPENSSL_STRING_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OPENSSL_STRING_sk_type(sk), (n))
|
||||
#define sk_OPENSSL_STRING_free(sk) OPENSSL_sk_free(ossl_check_OPENSSL_STRING_sk_type(sk))
|
||||
#define sk_OPENSSL_STRING_zero(sk) OPENSSL_sk_zero(ossl_check_OPENSSL_STRING_sk_type(sk))
|
||||
#define sk_OPENSSL_STRING_delete(sk, i) ((char *)OPENSSL_sk_delete(ossl_check_OPENSSL_STRING_sk_type(sk), (i)))
|
||||
#define sk_OPENSSL_STRING_delete_ptr(sk, ptr) ((char *)OPENSSL_sk_delete_ptr(ossl_check_OPENSSL_STRING_sk_type(sk), ossl_check_OPENSSL_STRING_type(ptr)))
|
||||
#define sk_OPENSSL_STRING_push(sk, ptr) OPENSSL_sk_push(ossl_check_OPENSSL_STRING_sk_type(sk), ossl_check_OPENSSL_STRING_type(ptr))
|
||||
#define sk_OPENSSL_STRING_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OPENSSL_STRING_sk_type(sk), ossl_check_OPENSSL_STRING_type(ptr))
|
||||
#define sk_OPENSSL_STRING_pop(sk) ((char *)OPENSSL_sk_pop(ossl_check_OPENSSL_STRING_sk_type(sk)))
|
||||
#define sk_OPENSSL_STRING_shift(sk) ((char *)OPENSSL_sk_shift(ossl_check_OPENSSL_STRING_sk_type(sk)))
|
||||
#define sk_OPENSSL_STRING_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OPENSSL_STRING_sk_type(sk),ossl_check_OPENSSL_STRING_freefunc_type(freefunc))
|
||||
#define sk_OPENSSL_STRING_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OPENSSL_STRING_sk_type(sk), ossl_check_OPENSSL_STRING_type(ptr), (idx))
|
||||
#define sk_OPENSSL_STRING_set(sk, idx, ptr) ((char *)OPENSSL_sk_set(ossl_check_OPENSSL_STRING_sk_type(sk), (idx), ossl_check_OPENSSL_STRING_type(ptr)))
|
||||
#define sk_OPENSSL_STRING_find(sk, ptr) OPENSSL_sk_find(ossl_check_OPENSSL_STRING_sk_type(sk), ossl_check_OPENSSL_STRING_type(ptr))
|
||||
#define sk_OPENSSL_STRING_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OPENSSL_STRING_sk_type(sk), ossl_check_OPENSSL_STRING_type(ptr))
|
||||
#define sk_OPENSSL_STRING_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OPENSSL_STRING_sk_type(sk), ossl_check_OPENSSL_STRING_type(ptr), pnum)
|
||||
#define sk_OPENSSL_STRING_sort(sk) OPENSSL_sk_sort(ossl_check_OPENSSL_STRING_sk_type(sk))
|
||||
#define sk_OPENSSL_STRING_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OPENSSL_STRING_sk_type(sk))
|
||||
#define sk_OPENSSL_STRING_dup(sk) ((STACK_OF(OPENSSL_STRING) *)OPENSSL_sk_dup(ossl_check_const_OPENSSL_STRING_sk_type(sk)))
|
||||
#define sk_OPENSSL_STRING_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OPENSSL_STRING) *)OPENSSL_sk_deep_copy(ossl_check_const_OPENSSL_STRING_sk_type(sk), ossl_check_OPENSSL_STRING_copyfunc_type(copyfunc), ossl_check_OPENSSL_STRING_freefunc_type(freefunc)))
|
||||
#define sk_OPENSSL_STRING_set_cmp_func(sk, cmp) ((sk_OPENSSL_STRING_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OPENSSL_STRING_sk_type(sk), ossl_check_OPENSSL_STRING_compfunc_type(cmp)))
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OPENSSL_CSTRING, const char, char)
|
||||
#define sk_OPENSSL_CSTRING_num(sk) OPENSSL_sk_num(ossl_check_const_OPENSSL_CSTRING_sk_type(sk))
|
||||
#define sk_OPENSSL_CSTRING_value(sk, idx) ((const char *)OPENSSL_sk_value(ossl_check_const_OPENSSL_CSTRING_sk_type(sk), (idx)))
|
||||
#define sk_OPENSSL_CSTRING_new(cmp) ((STACK_OF(OPENSSL_CSTRING) *)OPENSSL_sk_new(ossl_check_OPENSSL_CSTRING_compfunc_type(cmp)))
|
||||
#define sk_OPENSSL_CSTRING_new_null() ((STACK_OF(OPENSSL_CSTRING) *)OPENSSL_sk_new_null())
|
||||
#define sk_OPENSSL_CSTRING_new_reserve(cmp, n) ((STACK_OF(OPENSSL_CSTRING) *)OPENSSL_sk_new_reserve(ossl_check_OPENSSL_CSTRING_compfunc_type(cmp), (n)))
|
||||
#define sk_OPENSSL_CSTRING_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OPENSSL_CSTRING_sk_type(sk), (n))
|
||||
#define sk_OPENSSL_CSTRING_free(sk) OPENSSL_sk_free(ossl_check_OPENSSL_CSTRING_sk_type(sk))
|
||||
#define sk_OPENSSL_CSTRING_zero(sk) OPENSSL_sk_zero(ossl_check_OPENSSL_CSTRING_sk_type(sk))
|
||||
#define sk_OPENSSL_CSTRING_delete(sk, i) ((const char *)OPENSSL_sk_delete(ossl_check_OPENSSL_CSTRING_sk_type(sk), (i)))
|
||||
#define sk_OPENSSL_CSTRING_delete_ptr(sk, ptr) ((const char *)OPENSSL_sk_delete_ptr(ossl_check_OPENSSL_CSTRING_sk_type(sk), ossl_check_OPENSSL_CSTRING_type(ptr)))
|
||||
#define sk_OPENSSL_CSTRING_push(sk, ptr) OPENSSL_sk_push(ossl_check_OPENSSL_CSTRING_sk_type(sk), ossl_check_OPENSSL_CSTRING_type(ptr))
|
||||
#define sk_OPENSSL_CSTRING_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OPENSSL_CSTRING_sk_type(sk), ossl_check_OPENSSL_CSTRING_type(ptr))
|
||||
#define sk_OPENSSL_CSTRING_pop(sk) ((const char *)OPENSSL_sk_pop(ossl_check_OPENSSL_CSTRING_sk_type(sk)))
|
||||
#define sk_OPENSSL_CSTRING_shift(sk) ((const char *)OPENSSL_sk_shift(ossl_check_OPENSSL_CSTRING_sk_type(sk)))
|
||||
#define sk_OPENSSL_CSTRING_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OPENSSL_CSTRING_sk_type(sk),ossl_check_OPENSSL_CSTRING_freefunc_type(freefunc))
|
||||
#define sk_OPENSSL_CSTRING_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OPENSSL_CSTRING_sk_type(sk), ossl_check_OPENSSL_CSTRING_type(ptr), (idx))
|
||||
#define sk_OPENSSL_CSTRING_set(sk, idx, ptr) ((const char *)OPENSSL_sk_set(ossl_check_OPENSSL_CSTRING_sk_type(sk), (idx), ossl_check_OPENSSL_CSTRING_type(ptr)))
|
||||
#define sk_OPENSSL_CSTRING_find(sk, ptr) OPENSSL_sk_find(ossl_check_OPENSSL_CSTRING_sk_type(sk), ossl_check_OPENSSL_CSTRING_type(ptr))
|
||||
#define sk_OPENSSL_CSTRING_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OPENSSL_CSTRING_sk_type(sk), ossl_check_OPENSSL_CSTRING_type(ptr))
|
||||
#define sk_OPENSSL_CSTRING_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OPENSSL_CSTRING_sk_type(sk), ossl_check_OPENSSL_CSTRING_type(ptr), pnum)
|
||||
#define sk_OPENSSL_CSTRING_sort(sk) OPENSSL_sk_sort(ossl_check_OPENSSL_CSTRING_sk_type(sk))
|
||||
#define sk_OPENSSL_CSTRING_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OPENSSL_CSTRING_sk_type(sk))
|
||||
#define sk_OPENSSL_CSTRING_dup(sk) ((STACK_OF(OPENSSL_CSTRING) *)OPENSSL_sk_dup(ossl_check_const_OPENSSL_CSTRING_sk_type(sk)))
|
||||
#define sk_OPENSSL_CSTRING_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OPENSSL_CSTRING) *)OPENSSL_sk_deep_copy(ossl_check_const_OPENSSL_CSTRING_sk_type(sk), ossl_check_OPENSSL_CSTRING_copyfunc_type(copyfunc), ossl_check_OPENSSL_CSTRING_freefunc_type(freefunc)))
|
||||
#define sk_OPENSSL_CSTRING_set_cmp_func(sk, cmp) ((sk_OPENSSL_CSTRING_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OPENSSL_CSTRING_sk_type(sk), ossl_check_OPENSSL_CSTRING_compfunc_type(cmp)))
|
||||
|
||||
|
||||
#if !defined(OPENSSL_NO_DEPRECATED_3_0)
|
||||
/*
|
||||
* This is not used by OpenSSL. A block of bytes, NOT nul-terminated.
|
||||
* These should also be distinguished from "normal" stacks.
|
||||
*/
|
||||
typedef void *OPENSSL_BLOCK;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(OPENSSL_BLOCK, void, void)
|
||||
#define sk_OPENSSL_BLOCK_num(sk) OPENSSL_sk_num(ossl_check_const_OPENSSL_BLOCK_sk_type(sk))
|
||||
#define sk_OPENSSL_BLOCK_value(sk, idx) ((void *)OPENSSL_sk_value(ossl_check_const_OPENSSL_BLOCK_sk_type(sk), (idx)))
|
||||
#define sk_OPENSSL_BLOCK_new(cmp) ((STACK_OF(OPENSSL_BLOCK) *)OPENSSL_sk_new(ossl_check_OPENSSL_BLOCK_compfunc_type(cmp)))
|
||||
#define sk_OPENSSL_BLOCK_new_null() ((STACK_OF(OPENSSL_BLOCK) *)OPENSSL_sk_new_null())
|
||||
#define sk_OPENSSL_BLOCK_new_reserve(cmp, n) ((STACK_OF(OPENSSL_BLOCK) *)OPENSSL_sk_new_reserve(ossl_check_OPENSSL_BLOCK_compfunc_type(cmp), (n)))
|
||||
#define sk_OPENSSL_BLOCK_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_OPENSSL_BLOCK_sk_type(sk), (n))
|
||||
#define sk_OPENSSL_BLOCK_free(sk) OPENSSL_sk_free(ossl_check_OPENSSL_BLOCK_sk_type(sk))
|
||||
#define sk_OPENSSL_BLOCK_zero(sk) OPENSSL_sk_zero(ossl_check_OPENSSL_BLOCK_sk_type(sk))
|
||||
#define sk_OPENSSL_BLOCK_delete(sk, i) ((void *)OPENSSL_sk_delete(ossl_check_OPENSSL_BLOCK_sk_type(sk), (i)))
|
||||
#define sk_OPENSSL_BLOCK_delete_ptr(sk, ptr) ((void *)OPENSSL_sk_delete_ptr(ossl_check_OPENSSL_BLOCK_sk_type(sk), ossl_check_OPENSSL_BLOCK_type(ptr)))
|
||||
#define sk_OPENSSL_BLOCK_push(sk, ptr) OPENSSL_sk_push(ossl_check_OPENSSL_BLOCK_sk_type(sk), ossl_check_OPENSSL_BLOCK_type(ptr))
|
||||
#define sk_OPENSSL_BLOCK_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_OPENSSL_BLOCK_sk_type(sk), ossl_check_OPENSSL_BLOCK_type(ptr))
|
||||
#define sk_OPENSSL_BLOCK_pop(sk) ((void *)OPENSSL_sk_pop(ossl_check_OPENSSL_BLOCK_sk_type(sk)))
|
||||
#define sk_OPENSSL_BLOCK_shift(sk) ((void *)OPENSSL_sk_shift(ossl_check_OPENSSL_BLOCK_sk_type(sk)))
|
||||
#define sk_OPENSSL_BLOCK_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_OPENSSL_BLOCK_sk_type(sk),ossl_check_OPENSSL_BLOCK_freefunc_type(freefunc))
|
||||
#define sk_OPENSSL_BLOCK_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_OPENSSL_BLOCK_sk_type(sk), ossl_check_OPENSSL_BLOCK_type(ptr), (idx))
|
||||
#define sk_OPENSSL_BLOCK_set(sk, idx, ptr) ((void *)OPENSSL_sk_set(ossl_check_OPENSSL_BLOCK_sk_type(sk), (idx), ossl_check_OPENSSL_BLOCK_type(ptr)))
|
||||
#define sk_OPENSSL_BLOCK_find(sk, ptr) OPENSSL_sk_find(ossl_check_OPENSSL_BLOCK_sk_type(sk), ossl_check_OPENSSL_BLOCK_type(ptr))
|
||||
#define sk_OPENSSL_BLOCK_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_OPENSSL_BLOCK_sk_type(sk), ossl_check_OPENSSL_BLOCK_type(ptr))
|
||||
#define sk_OPENSSL_BLOCK_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_OPENSSL_BLOCK_sk_type(sk), ossl_check_OPENSSL_BLOCK_type(ptr), pnum)
|
||||
#define sk_OPENSSL_BLOCK_sort(sk) OPENSSL_sk_sort(ossl_check_OPENSSL_BLOCK_sk_type(sk))
|
||||
#define sk_OPENSSL_BLOCK_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_OPENSSL_BLOCK_sk_type(sk))
|
||||
#define sk_OPENSSL_BLOCK_dup(sk) ((STACK_OF(OPENSSL_BLOCK) *)OPENSSL_sk_dup(ossl_check_const_OPENSSL_BLOCK_sk_type(sk)))
|
||||
#define sk_OPENSSL_BLOCK_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(OPENSSL_BLOCK) *)OPENSSL_sk_deep_copy(ossl_check_const_OPENSSL_BLOCK_sk_type(sk), ossl_check_OPENSSL_BLOCK_copyfunc_type(copyfunc), ossl_check_OPENSSL_BLOCK_freefunc_type(freefunc)))
|
||||
#define sk_OPENSSL_BLOCK_set_cmp_func(sk, cmp) ((sk_OPENSSL_BLOCK_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_OPENSSL_BLOCK_sk_type(sk), ossl_check_OPENSSL_BLOCK_compfunc_type(cmp)))
|
||||
|
||||
#endif
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
285
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/srp.h
generated
vendored
Normal file
285
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/srp.h
generated
vendored
Normal file
@@ -0,0 +1,285 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/srp.h.in
|
||||
*
|
||||
* Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
* Copyright (c) 2004, EdelKey Project. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*
|
||||
* Originally written by Christophe Renou and Peter Sylvester,
|
||||
* for the EdelKey project.
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_SRP_H
|
||||
# define OPENSSL_SRP_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_SRP_H
|
||||
# endif
|
||||
|
||||
#include <openssl/opensslconf.h>
|
||||
|
||||
#ifndef OPENSSL_NO_SRP
|
||||
# include <stdio.h>
|
||||
# include <string.h>
|
||||
# include <openssl/safestack.h>
|
||||
# include <openssl/bn.h>
|
||||
# include <openssl/crypto.h>
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
|
||||
typedef struct SRP_gN_cache_st {
|
||||
char *b64_bn;
|
||||
BIGNUM *bn;
|
||||
} SRP_gN_cache;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(SRP_gN_cache, SRP_gN_cache, SRP_gN_cache)
|
||||
#define sk_SRP_gN_cache_num(sk) OPENSSL_sk_num(ossl_check_const_SRP_gN_cache_sk_type(sk))
|
||||
#define sk_SRP_gN_cache_value(sk, idx) ((SRP_gN_cache *)OPENSSL_sk_value(ossl_check_const_SRP_gN_cache_sk_type(sk), (idx)))
|
||||
#define sk_SRP_gN_cache_new(cmp) ((STACK_OF(SRP_gN_cache) *)OPENSSL_sk_new(ossl_check_SRP_gN_cache_compfunc_type(cmp)))
|
||||
#define sk_SRP_gN_cache_new_null() ((STACK_OF(SRP_gN_cache) *)OPENSSL_sk_new_null())
|
||||
#define sk_SRP_gN_cache_new_reserve(cmp, n) ((STACK_OF(SRP_gN_cache) *)OPENSSL_sk_new_reserve(ossl_check_SRP_gN_cache_compfunc_type(cmp), (n)))
|
||||
#define sk_SRP_gN_cache_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_SRP_gN_cache_sk_type(sk), (n))
|
||||
#define sk_SRP_gN_cache_free(sk) OPENSSL_sk_free(ossl_check_SRP_gN_cache_sk_type(sk))
|
||||
#define sk_SRP_gN_cache_zero(sk) OPENSSL_sk_zero(ossl_check_SRP_gN_cache_sk_type(sk))
|
||||
#define sk_SRP_gN_cache_delete(sk, i) ((SRP_gN_cache *)OPENSSL_sk_delete(ossl_check_SRP_gN_cache_sk_type(sk), (i)))
|
||||
#define sk_SRP_gN_cache_delete_ptr(sk, ptr) ((SRP_gN_cache *)OPENSSL_sk_delete_ptr(ossl_check_SRP_gN_cache_sk_type(sk), ossl_check_SRP_gN_cache_type(ptr)))
|
||||
#define sk_SRP_gN_cache_push(sk, ptr) OPENSSL_sk_push(ossl_check_SRP_gN_cache_sk_type(sk), ossl_check_SRP_gN_cache_type(ptr))
|
||||
#define sk_SRP_gN_cache_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_SRP_gN_cache_sk_type(sk), ossl_check_SRP_gN_cache_type(ptr))
|
||||
#define sk_SRP_gN_cache_pop(sk) ((SRP_gN_cache *)OPENSSL_sk_pop(ossl_check_SRP_gN_cache_sk_type(sk)))
|
||||
#define sk_SRP_gN_cache_shift(sk) ((SRP_gN_cache *)OPENSSL_sk_shift(ossl_check_SRP_gN_cache_sk_type(sk)))
|
||||
#define sk_SRP_gN_cache_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_SRP_gN_cache_sk_type(sk),ossl_check_SRP_gN_cache_freefunc_type(freefunc))
|
||||
#define sk_SRP_gN_cache_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_SRP_gN_cache_sk_type(sk), ossl_check_SRP_gN_cache_type(ptr), (idx))
|
||||
#define sk_SRP_gN_cache_set(sk, idx, ptr) ((SRP_gN_cache *)OPENSSL_sk_set(ossl_check_SRP_gN_cache_sk_type(sk), (idx), ossl_check_SRP_gN_cache_type(ptr)))
|
||||
#define sk_SRP_gN_cache_find(sk, ptr) OPENSSL_sk_find(ossl_check_SRP_gN_cache_sk_type(sk), ossl_check_SRP_gN_cache_type(ptr))
|
||||
#define sk_SRP_gN_cache_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_SRP_gN_cache_sk_type(sk), ossl_check_SRP_gN_cache_type(ptr))
|
||||
#define sk_SRP_gN_cache_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_SRP_gN_cache_sk_type(sk), ossl_check_SRP_gN_cache_type(ptr), pnum)
|
||||
#define sk_SRP_gN_cache_sort(sk) OPENSSL_sk_sort(ossl_check_SRP_gN_cache_sk_type(sk))
|
||||
#define sk_SRP_gN_cache_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_SRP_gN_cache_sk_type(sk))
|
||||
#define sk_SRP_gN_cache_dup(sk) ((STACK_OF(SRP_gN_cache) *)OPENSSL_sk_dup(ossl_check_const_SRP_gN_cache_sk_type(sk)))
|
||||
#define sk_SRP_gN_cache_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(SRP_gN_cache) *)OPENSSL_sk_deep_copy(ossl_check_const_SRP_gN_cache_sk_type(sk), ossl_check_SRP_gN_cache_copyfunc_type(copyfunc), ossl_check_SRP_gN_cache_freefunc_type(freefunc)))
|
||||
#define sk_SRP_gN_cache_set_cmp_func(sk, cmp) ((sk_SRP_gN_cache_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_SRP_gN_cache_sk_type(sk), ossl_check_SRP_gN_cache_compfunc_type(cmp)))
|
||||
|
||||
|
||||
|
||||
typedef struct SRP_user_pwd_st {
|
||||
/* Owned by us. */
|
||||
char *id;
|
||||
BIGNUM *s;
|
||||
BIGNUM *v;
|
||||
/* Not owned by us. */
|
||||
const BIGNUM *g;
|
||||
const BIGNUM *N;
|
||||
/* Owned by us. */
|
||||
char *info;
|
||||
} SRP_user_pwd;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(SRP_user_pwd, SRP_user_pwd, SRP_user_pwd)
|
||||
#define sk_SRP_user_pwd_num(sk) OPENSSL_sk_num(ossl_check_const_SRP_user_pwd_sk_type(sk))
|
||||
#define sk_SRP_user_pwd_value(sk, idx) ((SRP_user_pwd *)OPENSSL_sk_value(ossl_check_const_SRP_user_pwd_sk_type(sk), (idx)))
|
||||
#define sk_SRP_user_pwd_new(cmp) ((STACK_OF(SRP_user_pwd) *)OPENSSL_sk_new(ossl_check_SRP_user_pwd_compfunc_type(cmp)))
|
||||
#define sk_SRP_user_pwd_new_null() ((STACK_OF(SRP_user_pwd) *)OPENSSL_sk_new_null())
|
||||
#define sk_SRP_user_pwd_new_reserve(cmp, n) ((STACK_OF(SRP_user_pwd) *)OPENSSL_sk_new_reserve(ossl_check_SRP_user_pwd_compfunc_type(cmp), (n)))
|
||||
#define sk_SRP_user_pwd_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_SRP_user_pwd_sk_type(sk), (n))
|
||||
#define sk_SRP_user_pwd_free(sk) OPENSSL_sk_free(ossl_check_SRP_user_pwd_sk_type(sk))
|
||||
#define sk_SRP_user_pwd_zero(sk) OPENSSL_sk_zero(ossl_check_SRP_user_pwd_sk_type(sk))
|
||||
#define sk_SRP_user_pwd_delete(sk, i) ((SRP_user_pwd *)OPENSSL_sk_delete(ossl_check_SRP_user_pwd_sk_type(sk), (i)))
|
||||
#define sk_SRP_user_pwd_delete_ptr(sk, ptr) ((SRP_user_pwd *)OPENSSL_sk_delete_ptr(ossl_check_SRP_user_pwd_sk_type(sk), ossl_check_SRP_user_pwd_type(ptr)))
|
||||
#define sk_SRP_user_pwd_push(sk, ptr) OPENSSL_sk_push(ossl_check_SRP_user_pwd_sk_type(sk), ossl_check_SRP_user_pwd_type(ptr))
|
||||
#define sk_SRP_user_pwd_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_SRP_user_pwd_sk_type(sk), ossl_check_SRP_user_pwd_type(ptr))
|
||||
#define sk_SRP_user_pwd_pop(sk) ((SRP_user_pwd *)OPENSSL_sk_pop(ossl_check_SRP_user_pwd_sk_type(sk)))
|
||||
#define sk_SRP_user_pwd_shift(sk) ((SRP_user_pwd *)OPENSSL_sk_shift(ossl_check_SRP_user_pwd_sk_type(sk)))
|
||||
#define sk_SRP_user_pwd_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_SRP_user_pwd_sk_type(sk),ossl_check_SRP_user_pwd_freefunc_type(freefunc))
|
||||
#define sk_SRP_user_pwd_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_SRP_user_pwd_sk_type(sk), ossl_check_SRP_user_pwd_type(ptr), (idx))
|
||||
#define sk_SRP_user_pwd_set(sk, idx, ptr) ((SRP_user_pwd *)OPENSSL_sk_set(ossl_check_SRP_user_pwd_sk_type(sk), (idx), ossl_check_SRP_user_pwd_type(ptr)))
|
||||
#define sk_SRP_user_pwd_find(sk, ptr) OPENSSL_sk_find(ossl_check_SRP_user_pwd_sk_type(sk), ossl_check_SRP_user_pwd_type(ptr))
|
||||
#define sk_SRP_user_pwd_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_SRP_user_pwd_sk_type(sk), ossl_check_SRP_user_pwd_type(ptr))
|
||||
#define sk_SRP_user_pwd_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_SRP_user_pwd_sk_type(sk), ossl_check_SRP_user_pwd_type(ptr), pnum)
|
||||
#define sk_SRP_user_pwd_sort(sk) OPENSSL_sk_sort(ossl_check_SRP_user_pwd_sk_type(sk))
|
||||
#define sk_SRP_user_pwd_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_SRP_user_pwd_sk_type(sk))
|
||||
#define sk_SRP_user_pwd_dup(sk) ((STACK_OF(SRP_user_pwd) *)OPENSSL_sk_dup(ossl_check_const_SRP_user_pwd_sk_type(sk)))
|
||||
#define sk_SRP_user_pwd_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(SRP_user_pwd) *)OPENSSL_sk_deep_copy(ossl_check_const_SRP_user_pwd_sk_type(sk), ossl_check_SRP_user_pwd_copyfunc_type(copyfunc), ossl_check_SRP_user_pwd_freefunc_type(freefunc)))
|
||||
#define sk_SRP_user_pwd_set_cmp_func(sk, cmp) ((sk_SRP_user_pwd_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_SRP_user_pwd_sk_type(sk), ossl_check_SRP_user_pwd_compfunc_type(cmp)))
|
||||
|
||||
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
SRP_user_pwd *SRP_user_pwd_new(void);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void SRP_user_pwd_free(SRP_user_pwd *user_pwd);
|
||||
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void SRP_user_pwd_set_gN(SRP_user_pwd *user_pwd, const BIGNUM *g,
|
||||
const BIGNUM *N);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int SRP_user_pwd_set1_ids(SRP_user_pwd *user_pwd, const char *id,
|
||||
const char *info);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int SRP_user_pwd_set0_sv(SRP_user_pwd *user_pwd, BIGNUM *s, BIGNUM *v);
|
||||
|
||||
typedef struct SRP_VBASE_st {
|
||||
STACK_OF(SRP_user_pwd) *users_pwd;
|
||||
STACK_OF(SRP_gN_cache) *gN_cache;
|
||||
/* to simulate a user */
|
||||
char *seed_key;
|
||||
const BIGNUM *default_g;
|
||||
const BIGNUM *default_N;
|
||||
} SRP_VBASE;
|
||||
|
||||
/*
|
||||
* Internal structure storing N and g pair
|
||||
*/
|
||||
typedef struct SRP_gN_st {
|
||||
char *id;
|
||||
const BIGNUM *g;
|
||||
const BIGNUM *N;
|
||||
} SRP_gN;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(SRP_gN, SRP_gN, SRP_gN)
|
||||
#define sk_SRP_gN_num(sk) OPENSSL_sk_num(ossl_check_const_SRP_gN_sk_type(sk))
|
||||
#define sk_SRP_gN_value(sk, idx) ((SRP_gN *)OPENSSL_sk_value(ossl_check_const_SRP_gN_sk_type(sk), (idx)))
|
||||
#define sk_SRP_gN_new(cmp) ((STACK_OF(SRP_gN) *)OPENSSL_sk_new(ossl_check_SRP_gN_compfunc_type(cmp)))
|
||||
#define sk_SRP_gN_new_null() ((STACK_OF(SRP_gN) *)OPENSSL_sk_new_null())
|
||||
#define sk_SRP_gN_new_reserve(cmp, n) ((STACK_OF(SRP_gN) *)OPENSSL_sk_new_reserve(ossl_check_SRP_gN_compfunc_type(cmp), (n)))
|
||||
#define sk_SRP_gN_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_SRP_gN_sk_type(sk), (n))
|
||||
#define sk_SRP_gN_free(sk) OPENSSL_sk_free(ossl_check_SRP_gN_sk_type(sk))
|
||||
#define sk_SRP_gN_zero(sk) OPENSSL_sk_zero(ossl_check_SRP_gN_sk_type(sk))
|
||||
#define sk_SRP_gN_delete(sk, i) ((SRP_gN *)OPENSSL_sk_delete(ossl_check_SRP_gN_sk_type(sk), (i)))
|
||||
#define sk_SRP_gN_delete_ptr(sk, ptr) ((SRP_gN *)OPENSSL_sk_delete_ptr(ossl_check_SRP_gN_sk_type(sk), ossl_check_SRP_gN_type(ptr)))
|
||||
#define sk_SRP_gN_push(sk, ptr) OPENSSL_sk_push(ossl_check_SRP_gN_sk_type(sk), ossl_check_SRP_gN_type(ptr))
|
||||
#define sk_SRP_gN_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_SRP_gN_sk_type(sk), ossl_check_SRP_gN_type(ptr))
|
||||
#define sk_SRP_gN_pop(sk) ((SRP_gN *)OPENSSL_sk_pop(ossl_check_SRP_gN_sk_type(sk)))
|
||||
#define sk_SRP_gN_shift(sk) ((SRP_gN *)OPENSSL_sk_shift(ossl_check_SRP_gN_sk_type(sk)))
|
||||
#define sk_SRP_gN_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_SRP_gN_sk_type(sk),ossl_check_SRP_gN_freefunc_type(freefunc))
|
||||
#define sk_SRP_gN_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_SRP_gN_sk_type(sk), ossl_check_SRP_gN_type(ptr), (idx))
|
||||
#define sk_SRP_gN_set(sk, idx, ptr) ((SRP_gN *)OPENSSL_sk_set(ossl_check_SRP_gN_sk_type(sk), (idx), ossl_check_SRP_gN_type(ptr)))
|
||||
#define sk_SRP_gN_find(sk, ptr) OPENSSL_sk_find(ossl_check_SRP_gN_sk_type(sk), ossl_check_SRP_gN_type(ptr))
|
||||
#define sk_SRP_gN_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_SRP_gN_sk_type(sk), ossl_check_SRP_gN_type(ptr))
|
||||
#define sk_SRP_gN_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_SRP_gN_sk_type(sk), ossl_check_SRP_gN_type(ptr), pnum)
|
||||
#define sk_SRP_gN_sort(sk) OPENSSL_sk_sort(ossl_check_SRP_gN_sk_type(sk))
|
||||
#define sk_SRP_gN_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_SRP_gN_sk_type(sk))
|
||||
#define sk_SRP_gN_dup(sk) ((STACK_OF(SRP_gN) *)OPENSSL_sk_dup(ossl_check_const_SRP_gN_sk_type(sk)))
|
||||
#define sk_SRP_gN_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(SRP_gN) *)OPENSSL_sk_deep_copy(ossl_check_const_SRP_gN_sk_type(sk), ossl_check_SRP_gN_copyfunc_type(copyfunc), ossl_check_SRP_gN_freefunc_type(freefunc)))
|
||||
#define sk_SRP_gN_set_cmp_func(sk, cmp) ((sk_SRP_gN_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_SRP_gN_sk_type(sk), ossl_check_SRP_gN_compfunc_type(cmp)))
|
||||
|
||||
|
||||
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
SRP_VBASE *SRP_VBASE_new(char *seed_key);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
void SRP_VBASE_free(SRP_VBASE *vb);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int SRP_VBASE_init(SRP_VBASE *vb, char *verifier_file);
|
||||
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int SRP_VBASE_add0_user(SRP_VBASE *vb, SRP_user_pwd *user_pwd);
|
||||
|
||||
/* NOTE: unlike in SRP_VBASE_get_by_user, caller owns the returned pointer.*/
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
SRP_user_pwd *SRP_VBASE_get1_by_user(SRP_VBASE *vb, char *username);
|
||||
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
char *SRP_create_verifier_ex(const char *user, const char *pass, char **salt,
|
||||
char **verifier, const char *N, const char *g,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
char *SRP_create_verifier(const char *user, const char *pass, char **salt,
|
||||
char **verifier, const char *N, const char *g);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int SRP_create_verifier_BN_ex(const char *user, const char *pass, BIGNUM **salt,
|
||||
BIGNUM **verifier, const BIGNUM *N,
|
||||
const BIGNUM *g, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int SRP_create_verifier_BN(const char *user, const char *pass, BIGNUM **salt,
|
||||
BIGNUM **verifier, const BIGNUM *N,
|
||||
const BIGNUM *g);
|
||||
|
||||
# define SRP_NO_ERROR 0
|
||||
# define SRP_ERR_VBASE_INCOMPLETE_FILE 1
|
||||
# define SRP_ERR_VBASE_BN_LIB 2
|
||||
# define SRP_ERR_OPEN_FILE 3
|
||||
# define SRP_ERR_MEMORY 4
|
||||
|
||||
# define DB_srptype 0
|
||||
# define DB_srpverifier 1
|
||||
# define DB_srpsalt 2
|
||||
# define DB_srpid 3
|
||||
# define DB_srpgN 4
|
||||
# define DB_srpinfo 5
|
||||
# undef DB_NUMBER
|
||||
# define DB_NUMBER 6
|
||||
|
||||
# define DB_SRP_INDEX 'I'
|
||||
# define DB_SRP_VALID 'V'
|
||||
# define DB_SRP_REVOKED 'R'
|
||||
# define DB_SRP_MODIF 'v'
|
||||
|
||||
/* see srp.c */
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
char *SRP_check_known_gN_param(const BIGNUM *g, const BIGNUM *N);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
SRP_gN *SRP_get_default_gN(const char *id);
|
||||
|
||||
/* server side .... */
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_server_key(const BIGNUM *A, const BIGNUM *v, const BIGNUM *u,
|
||||
const BIGNUM *b, const BIGNUM *N);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_B_ex(const BIGNUM *b, const BIGNUM *N, const BIGNUM *g,
|
||||
const BIGNUM *v, OSSL_LIB_CTX *libctx, const char *propq);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_B(const BIGNUM *b, const BIGNUM *N, const BIGNUM *g,
|
||||
const BIGNUM *v);
|
||||
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int SRP_Verify_A_mod_N(const BIGNUM *A, const BIGNUM *N);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_u_ex(const BIGNUM *A, const BIGNUM *B, const BIGNUM *N,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_u(const BIGNUM *A, const BIGNUM *B, const BIGNUM *N);
|
||||
|
||||
/* client side .... */
|
||||
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_x_ex(const BIGNUM *s, const char *user, const char *pass,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_x(const BIGNUM *s, const char *user, const char *pass);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_A(const BIGNUM *a, const BIGNUM *N, const BIGNUM *g);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_client_key_ex(const BIGNUM *N, const BIGNUM *B, const BIGNUM *g,
|
||||
const BIGNUM *x, const BIGNUM *a, const BIGNUM *u,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
BIGNUM *SRP_Calc_client_key(const BIGNUM *N, const BIGNUM *B, const BIGNUM *g,
|
||||
const BIGNUM *x, const BIGNUM *a, const BIGNUM *u);
|
||||
OSSL_DEPRECATEDIN_3_0
|
||||
int SRP_Verify_B_mod_N(const BIGNUM *B, const BIGNUM *N);
|
||||
|
||||
# define SRP_MINIMAL_N 1024
|
||||
|
||||
# endif /* OPENSSL_NO_DEPRECATED_3_0 */
|
||||
|
||||
/* This method ignores the configured seed and fails for an unknown user. */
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
OSSL_DEPRECATEDIN_1_1_0
|
||||
SRP_user_pwd *SRP_VBASE_get_by_user(SRP_VBASE *vb, char *username);
|
||||
# endif
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
# endif
|
||||
|
||||
#endif
|
||||
2599
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ssl.h
generated
vendored
Normal file
2599
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ssl.h
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
407
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ui.h
generated
vendored
Normal file
407
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/ui.h
generated
vendored
Normal file
@@ -0,0 +1,407 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/ui.h.in
|
||||
*
|
||||
* Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_UI_H
|
||||
# define OPENSSL_UI_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_UI_H
|
||||
# endif
|
||||
|
||||
# include <openssl/opensslconf.h>
|
||||
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# include <openssl/crypto.h>
|
||||
# endif
|
||||
# include <openssl/safestack.h>
|
||||
# include <openssl/pem.h>
|
||||
# include <openssl/types.h>
|
||||
# include <openssl/uierr.h>
|
||||
|
||||
/* For compatibility reasons, the macro OPENSSL_NO_UI is currently retained */
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# ifdef OPENSSL_NO_UI_CONSOLE
|
||||
# define OPENSSL_NO_UI
|
||||
# endif
|
||||
# endif
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
/*
|
||||
* All the following functions return -1 or NULL on error and in some cases
|
||||
* (UI_process()) -2 if interrupted or in some other way cancelled. When
|
||||
* everything is fine, they return 0, a positive value or a non-NULL pointer,
|
||||
* all depending on their purpose.
|
||||
*/
|
||||
|
||||
/* Creators and destructor. */
|
||||
UI *UI_new(void);
|
||||
UI *UI_new_method(const UI_METHOD *method);
|
||||
void UI_free(UI *ui);
|
||||
|
||||
/*-
|
||||
The following functions are used to add strings to be printed and prompt
|
||||
strings to prompt for data. The names are UI_{add,dup}_<function>_string
|
||||
and UI_{add,dup}_input_boolean.
|
||||
|
||||
UI_{add,dup}_<function>_string have the following meanings:
|
||||
add add a text or prompt string. The pointers given to these
|
||||
functions are used verbatim, no copying is done.
|
||||
dup make a copy of the text or prompt string, then add the copy
|
||||
to the collection of strings in the user interface.
|
||||
<function>
|
||||
The function is a name for the functionality that the given
|
||||
string shall be used for. It can be one of:
|
||||
input use the string as data prompt.
|
||||
verify use the string as verification prompt. This
|
||||
is used to verify a previous input.
|
||||
info use the string for informational output.
|
||||
error use the string for error output.
|
||||
Honestly, there's currently no difference between info and error for the
|
||||
moment.
|
||||
|
||||
UI_{add,dup}_input_boolean have the same semantics for "add" and "dup",
|
||||
and are typically used when one wants to prompt for a yes/no response.
|
||||
|
||||
All of the functions in this group take a UI and a prompt string.
|
||||
The string input and verify addition functions also take a flag argument,
|
||||
a buffer for the result to end up with, a minimum input size and a maximum
|
||||
input size (the result buffer MUST be large enough to be able to contain
|
||||
the maximum number of characters). Additionally, the verify addition
|
||||
functions takes another buffer to compare the result against.
|
||||
The boolean input functions take an action description string (which should
|
||||
be safe to ignore if the expected user action is obvious, for example with
|
||||
a dialog box with an OK button and a Cancel button), a string of acceptable
|
||||
characters to mean OK and to mean Cancel. The two last strings are checked
|
||||
to make sure they don't have common characters. Additionally, the same
|
||||
flag argument as for the string input is taken, as well as a result buffer.
|
||||
The result buffer is required to be at least one byte long. Depending on
|
||||
the answer, the first character from the OK or the Cancel character strings
|
||||
will be stored in the first byte of the result buffer. No NUL will be
|
||||
added, so the result is *not* a string.
|
||||
|
||||
On success, the all return an index of the added information. That index
|
||||
is useful when retrieving results with UI_get0_result(). */
|
||||
int UI_add_input_string(UI *ui, const char *prompt, int flags,
|
||||
char *result_buf, int minsize, int maxsize);
|
||||
int UI_dup_input_string(UI *ui, const char *prompt, int flags,
|
||||
char *result_buf, int minsize, int maxsize);
|
||||
int UI_add_verify_string(UI *ui, const char *prompt, int flags,
|
||||
char *result_buf, int minsize, int maxsize,
|
||||
const char *test_buf);
|
||||
int UI_dup_verify_string(UI *ui, const char *prompt, int flags,
|
||||
char *result_buf, int minsize, int maxsize,
|
||||
const char *test_buf);
|
||||
int UI_add_input_boolean(UI *ui, const char *prompt, const char *action_desc,
|
||||
const char *ok_chars, const char *cancel_chars,
|
||||
int flags, char *result_buf);
|
||||
int UI_dup_input_boolean(UI *ui, const char *prompt, const char *action_desc,
|
||||
const char *ok_chars, const char *cancel_chars,
|
||||
int flags, char *result_buf);
|
||||
int UI_add_info_string(UI *ui, const char *text);
|
||||
int UI_dup_info_string(UI *ui, const char *text);
|
||||
int UI_add_error_string(UI *ui, const char *text);
|
||||
int UI_dup_error_string(UI *ui, const char *text);
|
||||
|
||||
/* These are the possible flags. They can be or'ed together. */
|
||||
/* Use to have echoing of input */
|
||||
# define UI_INPUT_FLAG_ECHO 0x01
|
||||
/*
|
||||
* Use a default password. Where that password is found is completely up to
|
||||
* the application, it might for example be in the user data set with
|
||||
* UI_add_user_data(). It is not recommended to have more than one input in
|
||||
* each UI being marked with this flag, or the application might get
|
||||
* confused.
|
||||
*/
|
||||
# define UI_INPUT_FLAG_DEFAULT_PWD 0x02
|
||||
|
||||
/*-
|
||||
* The user of these routines may want to define flags of their own. The core
|
||||
* UI won't look at those, but will pass them on to the method routines. They
|
||||
* must use higher bits so they don't get confused with the UI bits above.
|
||||
* UI_INPUT_FLAG_USER_BASE tells which is the lowest bit to use. A good
|
||||
* example of use is this:
|
||||
*
|
||||
* #define MY_UI_FLAG1 (0x01 << UI_INPUT_FLAG_USER_BASE)
|
||||
*
|
||||
*/
|
||||
# define UI_INPUT_FLAG_USER_BASE 16
|
||||
|
||||
/*-
|
||||
* The following function helps construct a prompt.
|
||||
* phrase_desc is a textual short description of the phrase to enter,
|
||||
* for example "pass phrase", and
|
||||
* object_name is the name of the object
|
||||
* (which might be a card name or a file name) or NULL.
|
||||
* The returned string shall always be allocated on the heap with
|
||||
* OPENSSL_malloc(), and need to be free'd with OPENSSL_free().
|
||||
*
|
||||
* If the ui_method doesn't contain a pointer to a user-defined prompt
|
||||
* constructor, a default string is built, looking like this:
|
||||
*
|
||||
* "Enter {phrase_desc} for {object_name}:"
|
||||
*
|
||||
* So, if phrase_desc has the value "pass phrase" and object_name has
|
||||
* the value "foo.key", the resulting string is:
|
||||
*
|
||||
* "Enter pass phrase for foo.key:"
|
||||
*/
|
||||
char *UI_construct_prompt(UI *ui_method,
|
||||
const char *phrase_desc, const char *object_name);
|
||||
|
||||
/*
|
||||
* The following function is used to store a pointer to user-specific data.
|
||||
* Any previous such pointer will be returned and replaced.
|
||||
*
|
||||
* For callback purposes, this function makes a lot more sense than using
|
||||
* ex_data, since the latter requires that different parts of OpenSSL or
|
||||
* applications share the same ex_data index.
|
||||
*
|
||||
* Note that the UI_OpenSSL() method completely ignores the user data. Other
|
||||
* methods may not, however.
|
||||
*/
|
||||
void *UI_add_user_data(UI *ui, void *user_data);
|
||||
/*
|
||||
* Alternatively, this function is used to duplicate the user data.
|
||||
* This uses the duplicator method function. The destroy function will
|
||||
* be used to free the user data in this case.
|
||||
*/
|
||||
int UI_dup_user_data(UI *ui, void *user_data);
|
||||
/* We need a user data retrieving function as well. */
|
||||
void *UI_get0_user_data(UI *ui);
|
||||
|
||||
/* Return the result associated with a prompt given with the index i. */
|
||||
const char *UI_get0_result(UI *ui, int i);
|
||||
int UI_get_result_length(UI *ui, int i);
|
||||
|
||||
/* When all strings have been added, process the whole thing. */
|
||||
int UI_process(UI *ui);
|
||||
|
||||
/*
|
||||
* Give a user interface parameterised control commands. This can be used to
|
||||
* send down an integer, a data pointer or a function pointer, as well as be
|
||||
* used to get information from a UI.
|
||||
*/
|
||||
int UI_ctrl(UI *ui, int cmd, long i, void *p, void (*f) (void));
|
||||
|
||||
/* The commands */
|
||||
/*
|
||||
* Use UI_CONTROL_PRINT_ERRORS with the value 1 to have UI_process print the
|
||||
* OpenSSL error stack before printing any info or added error messages and
|
||||
* before any prompting.
|
||||
*/
|
||||
# define UI_CTRL_PRINT_ERRORS 1
|
||||
/*
|
||||
* Check if a UI_process() is possible to do again with the same instance of
|
||||
* a user interface. This makes UI_ctrl() return 1 if it is redoable, and 0
|
||||
* if not.
|
||||
*/
|
||||
# define UI_CTRL_IS_REDOABLE 2
|
||||
|
||||
/* Some methods may use extra data */
|
||||
# define UI_set_app_data(s,arg) UI_set_ex_data(s,0,arg)
|
||||
# define UI_get_app_data(s) UI_get_ex_data(s,0)
|
||||
|
||||
# define UI_get_ex_new_index(l, p, newf, dupf, freef) \
|
||||
CRYPTO_get_ex_new_index(CRYPTO_EX_INDEX_UI, l, p, newf, dupf, freef)
|
||||
int UI_set_ex_data(UI *r, int idx, void *arg);
|
||||
void *UI_get_ex_data(const UI *r, int idx);
|
||||
|
||||
/* Use specific methods instead of the built-in one */
|
||||
void UI_set_default_method(const UI_METHOD *meth);
|
||||
const UI_METHOD *UI_get_default_method(void);
|
||||
const UI_METHOD *UI_get_method(UI *ui);
|
||||
const UI_METHOD *UI_set_method(UI *ui, const UI_METHOD *meth);
|
||||
|
||||
# ifndef OPENSSL_NO_UI_CONSOLE
|
||||
|
||||
/* The method with all the built-in thingies */
|
||||
UI_METHOD *UI_OpenSSL(void);
|
||||
|
||||
# endif
|
||||
|
||||
/*
|
||||
* NULL method. Literally does nothing, but may serve as a placeholder
|
||||
* to avoid internal default.
|
||||
*/
|
||||
const UI_METHOD *UI_null(void);
|
||||
|
||||
/* ---------- For method writers ---------- */
|
||||
/*-
|
||||
A method contains a number of functions that implement the low level
|
||||
of the User Interface. The functions are:
|
||||
|
||||
an opener This function starts a session, maybe by opening
|
||||
a channel to a tty, or by opening a window.
|
||||
a writer This function is called to write a given string,
|
||||
maybe to the tty, maybe as a field label in a
|
||||
window.
|
||||
a flusher This function is called to flush everything that
|
||||
has been output so far. It can be used to actually
|
||||
display a dialog box after it has been built.
|
||||
a reader This function is called to read a given prompt,
|
||||
maybe from the tty, maybe from a field in a
|
||||
window. Note that it's called with all string
|
||||
structures, not only the prompt ones, so it must
|
||||
check such things itself.
|
||||
a closer This function closes the session, maybe by closing
|
||||
the channel to the tty, or closing the window.
|
||||
|
||||
All these functions are expected to return:
|
||||
|
||||
0 on error.
|
||||
1 on success.
|
||||
-1 on out-of-band events, for example if some prompting has
|
||||
been canceled (by pressing Ctrl-C, for example). This is
|
||||
only checked when returned by the flusher or the reader.
|
||||
|
||||
The way this is used, the opener is first called, then the writer for all
|
||||
strings, then the flusher, then the reader for all strings and finally the
|
||||
closer. Note that if you want to prompt from a terminal or other command
|
||||
line interface, the best is to have the reader also write the prompts
|
||||
instead of having the writer do it. If you want to prompt from a dialog
|
||||
box, the writer can be used to build up the contents of the box, and the
|
||||
flusher to actually display the box and run the event loop until all data
|
||||
has been given, after which the reader only grabs the given data and puts
|
||||
them back into the UI strings.
|
||||
|
||||
All method functions take a UI as argument. Additionally, the writer and
|
||||
the reader take a UI_STRING.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The UI_STRING type is the data structure that contains all the needed info
|
||||
* about a string or a prompt, including test data for a verification prompt.
|
||||
*/
|
||||
typedef struct ui_string_st UI_STRING;
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(UI_STRING, UI_STRING, UI_STRING)
|
||||
#define sk_UI_STRING_num(sk) OPENSSL_sk_num(ossl_check_const_UI_STRING_sk_type(sk))
|
||||
#define sk_UI_STRING_value(sk, idx) ((UI_STRING *)OPENSSL_sk_value(ossl_check_const_UI_STRING_sk_type(sk), (idx)))
|
||||
#define sk_UI_STRING_new(cmp) ((STACK_OF(UI_STRING) *)OPENSSL_sk_new(ossl_check_UI_STRING_compfunc_type(cmp)))
|
||||
#define sk_UI_STRING_new_null() ((STACK_OF(UI_STRING) *)OPENSSL_sk_new_null())
|
||||
#define sk_UI_STRING_new_reserve(cmp, n) ((STACK_OF(UI_STRING) *)OPENSSL_sk_new_reserve(ossl_check_UI_STRING_compfunc_type(cmp), (n)))
|
||||
#define sk_UI_STRING_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_UI_STRING_sk_type(sk), (n))
|
||||
#define sk_UI_STRING_free(sk) OPENSSL_sk_free(ossl_check_UI_STRING_sk_type(sk))
|
||||
#define sk_UI_STRING_zero(sk) OPENSSL_sk_zero(ossl_check_UI_STRING_sk_type(sk))
|
||||
#define sk_UI_STRING_delete(sk, i) ((UI_STRING *)OPENSSL_sk_delete(ossl_check_UI_STRING_sk_type(sk), (i)))
|
||||
#define sk_UI_STRING_delete_ptr(sk, ptr) ((UI_STRING *)OPENSSL_sk_delete_ptr(ossl_check_UI_STRING_sk_type(sk), ossl_check_UI_STRING_type(ptr)))
|
||||
#define sk_UI_STRING_push(sk, ptr) OPENSSL_sk_push(ossl_check_UI_STRING_sk_type(sk), ossl_check_UI_STRING_type(ptr))
|
||||
#define sk_UI_STRING_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_UI_STRING_sk_type(sk), ossl_check_UI_STRING_type(ptr))
|
||||
#define sk_UI_STRING_pop(sk) ((UI_STRING *)OPENSSL_sk_pop(ossl_check_UI_STRING_sk_type(sk)))
|
||||
#define sk_UI_STRING_shift(sk) ((UI_STRING *)OPENSSL_sk_shift(ossl_check_UI_STRING_sk_type(sk)))
|
||||
#define sk_UI_STRING_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_UI_STRING_sk_type(sk),ossl_check_UI_STRING_freefunc_type(freefunc))
|
||||
#define sk_UI_STRING_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_UI_STRING_sk_type(sk), ossl_check_UI_STRING_type(ptr), (idx))
|
||||
#define sk_UI_STRING_set(sk, idx, ptr) ((UI_STRING *)OPENSSL_sk_set(ossl_check_UI_STRING_sk_type(sk), (idx), ossl_check_UI_STRING_type(ptr)))
|
||||
#define sk_UI_STRING_find(sk, ptr) OPENSSL_sk_find(ossl_check_UI_STRING_sk_type(sk), ossl_check_UI_STRING_type(ptr))
|
||||
#define sk_UI_STRING_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_UI_STRING_sk_type(sk), ossl_check_UI_STRING_type(ptr))
|
||||
#define sk_UI_STRING_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_UI_STRING_sk_type(sk), ossl_check_UI_STRING_type(ptr), pnum)
|
||||
#define sk_UI_STRING_sort(sk) OPENSSL_sk_sort(ossl_check_UI_STRING_sk_type(sk))
|
||||
#define sk_UI_STRING_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_UI_STRING_sk_type(sk))
|
||||
#define sk_UI_STRING_dup(sk) ((STACK_OF(UI_STRING) *)OPENSSL_sk_dup(ossl_check_const_UI_STRING_sk_type(sk)))
|
||||
#define sk_UI_STRING_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(UI_STRING) *)OPENSSL_sk_deep_copy(ossl_check_const_UI_STRING_sk_type(sk), ossl_check_UI_STRING_copyfunc_type(copyfunc), ossl_check_UI_STRING_freefunc_type(freefunc)))
|
||||
#define sk_UI_STRING_set_cmp_func(sk, cmp) ((sk_UI_STRING_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_UI_STRING_sk_type(sk), ossl_check_UI_STRING_compfunc_type(cmp)))
|
||||
|
||||
|
||||
/*
|
||||
* The different types of strings that are currently supported. This is only
|
||||
* needed by method authors.
|
||||
*/
|
||||
enum UI_string_types {
|
||||
UIT_NONE = 0,
|
||||
UIT_PROMPT, /* Prompt for a string */
|
||||
UIT_VERIFY, /* Prompt for a string and verify */
|
||||
UIT_BOOLEAN, /* Prompt for a yes/no response */
|
||||
UIT_INFO, /* Send info to the user */
|
||||
UIT_ERROR /* Send an error message to the user */
|
||||
};
|
||||
|
||||
/* Create and manipulate methods */
|
||||
UI_METHOD *UI_create_method(const char *name);
|
||||
void UI_destroy_method(UI_METHOD *ui_method);
|
||||
int UI_method_set_opener(UI_METHOD *method, int (*opener) (UI *ui));
|
||||
int UI_method_set_writer(UI_METHOD *method,
|
||||
int (*writer) (UI *ui, UI_STRING *uis));
|
||||
int UI_method_set_flusher(UI_METHOD *method, int (*flusher) (UI *ui));
|
||||
int UI_method_set_reader(UI_METHOD *method,
|
||||
int (*reader) (UI *ui, UI_STRING *uis));
|
||||
int UI_method_set_closer(UI_METHOD *method, int (*closer) (UI *ui));
|
||||
int UI_method_set_data_duplicator(UI_METHOD *method,
|
||||
void *(*duplicator) (UI *ui, void *ui_data),
|
||||
void (*destructor)(UI *ui, void *ui_data));
|
||||
int UI_method_set_prompt_constructor(UI_METHOD *method,
|
||||
char *(*prompt_constructor) (UI *ui,
|
||||
const char
|
||||
*phrase_desc,
|
||||
const char
|
||||
*object_name));
|
||||
int UI_method_set_ex_data(UI_METHOD *method, int idx, void *data);
|
||||
int (*UI_method_get_opener(const UI_METHOD *method)) (UI *);
|
||||
int (*UI_method_get_writer(const UI_METHOD *method)) (UI *, UI_STRING *);
|
||||
int (*UI_method_get_flusher(const UI_METHOD *method)) (UI *);
|
||||
int (*UI_method_get_reader(const UI_METHOD *method)) (UI *, UI_STRING *);
|
||||
int (*UI_method_get_closer(const UI_METHOD *method)) (UI *);
|
||||
char *(*UI_method_get_prompt_constructor(const UI_METHOD *method))
|
||||
(UI *, const char *, const char *);
|
||||
void *(*UI_method_get_data_duplicator(const UI_METHOD *method)) (UI *, void *);
|
||||
void (*UI_method_get_data_destructor(const UI_METHOD *method)) (UI *, void *);
|
||||
const void *UI_method_get_ex_data(const UI_METHOD *method, int idx);
|
||||
|
||||
/*
|
||||
* The following functions are helpers for method writers to access relevant
|
||||
* data from a UI_STRING.
|
||||
*/
|
||||
|
||||
/* Return type of the UI_STRING */
|
||||
enum UI_string_types UI_get_string_type(UI_STRING *uis);
|
||||
/* Return input flags of the UI_STRING */
|
||||
int UI_get_input_flags(UI_STRING *uis);
|
||||
/* Return the actual string to output (the prompt, info or error) */
|
||||
const char *UI_get0_output_string(UI_STRING *uis);
|
||||
/*
|
||||
* Return the optional action string to output (the boolean prompt
|
||||
* instruction)
|
||||
*/
|
||||
const char *UI_get0_action_string(UI_STRING *uis);
|
||||
/* Return the result of a prompt */
|
||||
const char *UI_get0_result_string(UI_STRING *uis);
|
||||
int UI_get_result_string_length(UI_STRING *uis);
|
||||
/*
|
||||
* Return the string to test the result against. Only useful with verifies.
|
||||
*/
|
||||
const char *UI_get0_test_string(UI_STRING *uis);
|
||||
/* Return the required minimum size of the result */
|
||||
int UI_get_result_minsize(UI_STRING *uis);
|
||||
/* Return the required maximum size of the result */
|
||||
int UI_get_result_maxsize(UI_STRING *uis);
|
||||
/* Set the result of a UI_STRING. */
|
||||
int UI_set_result(UI *ui, UI_STRING *uis, const char *result);
|
||||
int UI_set_result_ex(UI *ui, UI_STRING *uis, const char *result, int len);
|
||||
|
||||
/* A couple of popular utility functions */
|
||||
int UI_UTIL_read_pw_string(char *buf, int length, const char *prompt,
|
||||
int verify);
|
||||
int UI_UTIL_read_pw(char *buf, char *buff, int size, const char *prompt,
|
||||
int verify);
|
||||
UI_METHOD *UI_UTIL_wrap_read_pem_callback(pem_password_cb *cb, int rwflag);
|
||||
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
1276
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/x509.h
generated
vendored
Normal file
1276
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/x509.h
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
894
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/x509_vfy.h
generated
vendored
Normal file
894
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/x509_vfy.h
generated
vendored
Normal file
@@ -0,0 +1,894 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from include/openssl/x509_vfy.h.in
|
||||
*
|
||||
* Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#ifndef OPENSSL_X509_VFY_H
|
||||
# define OPENSSL_X509_VFY_H
|
||||
# pragma once
|
||||
|
||||
# include <openssl/macros.h>
|
||||
# ifndef OPENSSL_NO_DEPRECATED_3_0
|
||||
# define HEADER_X509_VFY_H
|
||||
# endif
|
||||
|
||||
/*
|
||||
* Protect against recursion, x509.h and x509_vfy.h each include the other.
|
||||
*/
|
||||
# ifndef OPENSSL_X509_H
|
||||
# include <openssl/x509.h>
|
||||
# endif
|
||||
|
||||
# include <openssl/opensslconf.h>
|
||||
# include <openssl/lhash.h>
|
||||
# include <openssl/bio.h>
|
||||
# include <openssl/crypto.h>
|
||||
# include <openssl/symhacks.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*-
|
||||
SSL_CTX -> X509_STORE
|
||||
-> X509_LOOKUP
|
||||
->X509_LOOKUP_METHOD
|
||||
-> X509_LOOKUP
|
||||
->X509_LOOKUP_METHOD
|
||||
|
||||
SSL -> X509_STORE_CTX
|
||||
->X509_STORE
|
||||
|
||||
The X509_STORE holds the tables etc for verification stuff.
|
||||
A X509_STORE_CTX is used while validating a single certificate.
|
||||
The X509_STORE has X509_LOOKUPs for looking up certs.
|
||||
The X509_STORE then calls a function to actually verify the
|
||||
certificate chain.
|
||||
*/
|
||||
|
||||
typedef enum {
|
||||
X509_LU_NONE = 0,
|
||||
X509_LU_X509, X509_LU_CRL
|
||||
} X509_LOOKUP_TYPE;
|
||||
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
#define X509_LU_RETRY -1
|
||||
#define X509_LU_FAIL 0
|
||||
#endif
|
||||
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(X509_LOOKUP, X509_LOOKUP, X509_LOOKUP)
|
||||
#define sk_X509_LOOKUP_num(sk) OPENSSL_sk_num(ossl_check_const_X509_LOOKUP_sk_type(sk))
|
||||
#define sk_X509_LOOKUP_value(sk, idx) ((X509_LOOKUP *)OPENSSL_sk_value(ossl_check_const_X509_LOOKUP_sk_type(sk), (idx)))
|
||||
#define sk_X509_LOOKUP_new(cmp) ((STACK_OF(X509_LOOKUP) *)OPENSSL_sk_new(ossl_check_X509_LOOKUP_compfunc_type(cmp)))
|
||||
#define sk_X509_LOOKUP_new_null() ((STACK_OF(X509_LOOKUP) *)OPENSSL_sk_new_null())
|
||||
#define sk_X509_LOOKUP_new_reserve(cmp, n) ((STACK_OF(X509_LOOKUP) *)OPENSSL_sk_new_reserve(ossl_check_X509_LOOKUP_compfunc_type(cmp), (n)))
|
||||
#define sk_X509_LOOKUP_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_X509_LOOKUP_sk_type(sk), (n))
|
||||
#define sk_X509_LOOKUP_free(sk) OPENSSL_sk_free(ossl_check_X509_LOOKUP_sk_type(sk))
|
||||
#define sk_X509_LOOKUP_zero(sk) OPENSSL_sk_zero(ossl_check_X509_LOOKUP_sk_type(sk))
|
||||
#define sk_X509_LOOKUP_delete(sk, i) ((X509_LOOKUP *)OPENSSL_sk_delete(ossl_check_X509_LOOKUP_sk_type(sk), (i)))
|
||||
#define sk_X509_LOOKUP_delete_ptr(sk, ptr) ((X509_LOOKUP *)OPENSSL_sk_delete_ptr(ossl_check_X509_LOOKUP_sk_type(sk), ossl_check_X509_LOOKUP_type(ptr)))
|
||||
#define sk_X509_LOOKUP_push(sk, ptr) OPENSSL_sk_push(ossl_check_X509_LOOKUP_sk_type(sk), ossl_check_X509_LOOKUP_type(ptr))
|
||||
#define sk_X509_LOOKUP_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_X509_LOOKUP_sk_type(sk), ossl_check_X509_LOOKUP_type(ptr))
|
||||
#define sk_X509_LOOKUP_pop(sk) ((X509_LOOKUP *)OPENSSL_sk_pop(ossl_check_X509_LOOKUP_sk_type(sk)))
|
||||
#define sk_X509_LOOKUP_shift(sk) ((X509_LOOKUP *)OPENSSL_sk_shift(ossl_check_X509_LOOKUP_sk_type(sk)))
|
||||
#define sk_X509_LOOKUP_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_X509_LOOKUP_sk_type(sk),ossl_check_X509_LOOKUP_freefunc_type(freefunc))
|
||||
#define sk_X509_LOOKUP_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_X509_LOOKUP_sk_type(sk), ossl_check_X509_LOOKUP_type(ptr), (idx))
|
||||
#define sk_X509_LOOKUP_set(sk, idx, ptr) ((X509_LOOKUP *)OPENSSL_sk_set(ossl_check_X509_LOOKUP_sk_type(sk), (idx), ossl_check_X509_LOOKUP_type(ptr)))
|
||||
#define sk_X509_LOOKUP_find(sk, ptr) OPENSSL_sk_find(ossl_check_X509_LOOKUP_sk_type(sk), ossl_check_X509_LOOKUP_type(ptr))
|
||||
#define sk_X509_LOOKUP_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_X509_LOOKUP_sk_type(sk), ossl_check_X509_LOOKUP_type(ptr))
|
||||
#define sk_X509_LOOKUP_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_X509_LOOKUP_sk_type(sk), ossl_check_X509_LOOKUP_type(ptr), pnum)
|
||||
#define sk_X509_LOOKUP_sort(sk) OPENSSL_sk_sort(ossl_check_X509_LOOKUP_sk_type(sk))
|
||||
#define sk_X509_LOOKUP_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_X509_LOOKUP_sk_type(sk))
|
||||
#define sk_X509_LOOKUP_dup(sk) ((STACK_OF(X509_LOOKUP) *)OPENSSL_sk_dup(ossl_check_const_X509_LOOKUP_sk_type(sk)))
|
||||
#define sk_X509_LOOKUP_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(X509_LOOKUP) *)OPENSSL_sk_deep_copy(ossl_check_const_X509_LOOKUP_sk_type(sk), ossl_check_X509_LOOKUP_copyfunc_type(copyfunc), ossl_check_X509_LOOKUP_freefunc_type(freefunc)))
|
||||
#define sk_X509_LOOKUP_set_cmp_func(sk, cmp) ((sk_X509_LOOKUP_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_X509_LOOKUP_sk_type(sk), ossl_check_X509_LOOKUP_compfunc_type(cmp)))
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(X509_OBJECT, X509_OBJECT, X509_OBJECT)
|
||||
#define sk_X509_OBJECT_num(sk) OPENSSL_sk_num(ossl_check_const_X509_OBJECT_sk_type(sk))
|
||||
#define sk_X509_OBJECT_value(sk, idx) ((X509_OBJECT *)OPENSSL_sk_value(ossl_check_const_X509_OBJECT_sk_type(sk), (idx)))
|
||||
#define sk_X509_OBJECT_new(cmp) ((STACK_OF(X509_OBJECT) *)OPENSSL_sk_new(ossl_check_X509_OBJECT_compfunc_type(cmp)))
|
||||
#define sk_X509_OBJECT_new_null() ((STACK_OF(X509_OBJECT) *)OPENSSL_sk_new_null())
|
||||
#define sk_X509_OBJECT_new_reserve(cmp, n) ((STACK_OF(X509_OBJECT) *)OPENSSL_sk_new_reserve(ossl_check_X509_OBJECT_compfunc_type(cmp), (n)))
|
||||
#define sk_X509_OBJECT_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_X509_OBJECT_sk_type(sk), (n))
|
||||
#define sk_X509_OBJECT_free(sk) OPENSSL_sk_free(ossl_check_X509_OBJECT_sk_type(sk))
|
||||
#define sk_X509_OBJECT_zero(sk) OPENSSL_sk_zero(ossl_check_X509_OBJECT_sk_type(sk))
|
||||
#define sk_X509_OBJECT_delete(sk, i) ((X509_OBJECT *)OPENSSL_sk_delete(ossl_check_X509_OBJECT_sk_type(sk), (i)))
|
||||
#define sk_X509_OBJECT_delete_ptr(sk, ptr) ((X509_OBJECT *)OPENSSL_sk_delete_ptr(ossl_check_X509_OBJECT_sk_type(sk), ossl_check_X509_OBJECT_type(ptr)))
|
||||
#define sk_X509_OBJECT_push(sk, ptr) OPENSSL_sk_push(ossl_check_X509_OBJECT_sk_type(sk), ossl_check_X509_OBJECT_type(ptr))
|
||||
#define sk_X509_OBJECT_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_X509_OBJECT_sk_type(sk), ossl_check_X509_OBJECT_type(ptr))
|
||||
#define sk_X509_OBJECT_pop(sk) ((X509_OBJECT *)OPENSSL_sk_pop(ossl_check_X509_OBJECT_sk_type(sk)))
|
||||
#define sk_X509_OBJECT_shift(sk) ((X509_OBJECT *)OPENSSL_sk_shift(ossl_check_X509_OBJECT_sk_type(sk)))
|
||||
#define sk_X509_OBJECT_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_X509_OBJECT_sk_type(sk),ossl_check_X509_OBJECT_freefunc_type(freefunc))
|
||||
#define sk_X509_OBJECT_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_X509_OBJECT_sk_type(sk), ossl_check_X509_OBJECT_type(ptr), (idx))
|
||||
#define sk_X509_OBJECT_set(sk, idx, ptr) ((X509_OBJECT *)OPENSSL_sk_set(ossl_check_X509_OBJECT_sk_type(sk), (idx), ossl_check_X509_OBJECT_type(ptr)))
|
||||
#define sk_X509_OBJECT_find(sk, ptr) OPENSSL_sk_find(ossl_check_X509_OBJECT_sk_type(sk), ossl_check_X509_OBJECT_type(ptr))
|
||||
#define sk_X509_OBJECT_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_X509_OBJECT_sk_type(sk), ossl_check_X509_OBJECT_type(ptr))
|
||||
#define sk_X509_OBJECT_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_X509_OBJECT_sk_type(sk), ossl_check_X509_OBJECT_type(ptr), pnum)
|
||||
#define sk_X509_OBJECT_sort(sk) OPENSSL_sk_sort(ossl_check_X509_OBJECT_sk_type(sk))
|
||||
#define sk_X509_OBJECT_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_X509_OBJECT_sk_type(sk))
|
||||
#define sk_X509_OBJECT_dup(sk) ((STACK_OF(X509_OBJECT) *)OPENSSL_sk_dup(ossl_check_const_X509_OBJECT_sk_type(sk)))
|
||||
#define sk_X509_OBJECT_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(X509_OBJECT) *)OPENSSL_sk_deep_copy(ossl_check_const_X509_OBJECT_sk_type(sk), ossl_check_X509_OBJECT_copyfunc_type(copyfunc), ossl_check_X509_OBJECT_freefunc_type(freefunc)))
|
||||
#define sk_X509_OBJECT_set_cmp_func(sk, cmp) ((sk_X509_OBJECT_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_X509_OBJECT_sk_type(sk), ossl_check_X509_OBJECT_compfunc_type(cmp)))
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(X509_VERIFY_PARAM, X509_VERIFY_PARAM, X509_VERIFY_PARAM)
|
||||
#define sk_X509_VERIFY_PARAM_num(sk) OPENSSL_sk_num(ossl_check_const_X509_VERIFY_PARAM_sk_type(sk))
|
||||
#define sk_X509_VERIFY_PARAM_value(sk, idx) ((X509_VERIFY_PARAM *)OPENSSL_sk_value(ossl_check_const_X509_VERIFY_PARAM_sk_type(sk), (idx)))
|
||||
#define sk_X509_VERIFY_PARAM_new(cmp) ((STACK_OF(X509_VERIFY_PARAM) *)OPENSSL_sk_new(ossl_check_X509_VERIFY_PARAM_compfunc_type(cmp)))
|
||||
#define sk_X509_VERIFY_PARAM_new_null() ((STACK_OF(X509_VERIFY_PARAM) *)OPENSSL_sk_new_null())
|
||||
#define sk_X509_VERIFY_PARAM_new_reserve(cmp, n) ((STACK_OF(X509_VERIFY_PARAM) *)OPENSSL_sk_new_reserve(ossl_check_X509_VERIFY_PARAM_compfunc_type(cmp), (n)))
|
||||
#define sk_X509_VERIFY_PARAM_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_X509_VERIFY_PARAM_sk_type(sk), (n))
|
||||
#define sk_X509_VERIFY_PARAM_free(sk) OPENSSL_sk_free(ossl_check_X509_VERIFY_PARAM_sk_type(sk))
|
||||
#define sk_X509_VERIFY_PARAM_zero(sk) OPENSSL_sk_zero(ossl_check_X509_VERIFY_PARAM_sk_type(sk))
|
||||
#define sk_X509_VERIFY_PARAM_delete(sk, i) ((X509_VERIFY_PARAM *)OPENSSL_sk_delete(ossl_check_X509_VERIFY_PARAM_sk_type(sk), (i)))
|
||||
#define sk_X509_VERIFY_PARAM_delete_ptr(sk, ptr) ((X509_VERIFY_PARAM *)OPENSSL_sk_delete_ptr(ossl_check_X509_VERIFY_PARAM_sk_type(sk), ossl_check_X509_VERIFY_PARAM_type(ptr)))
|
||||
#define sk_X509_VERIFY_PARAM_push(sk, ptr) OPENSSL_sk_push(ossl_check_X509_VERIFY_PARAM_sk_type(sk), ossl_check_X509_VERIFY_PARAM_type(ptr))
|
||||
#define sk_X509_VERIFY_PARAM_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_X509_VERIFY_PARAM_sk_type(sk), ossl_check_X509_VERIFY_PARAM_type(ptr))
|
||||
#define sk_X509_VERIFY_PARAM_pop(sk) ((X509_VERIFY_PARAM *)OPENSSL_sk_pop(ossl_check_X509_VERIFY_PARAM_sk_type(sk)))
|
||||
#define sk_X509_VERIFY_PARAM_shift(sk) ((X509_VERIFY_PARAM *)OPENSSL_sk_shift(ossl_check_X509_VERIFY_PARAM_sk_type(sk)))
|
||||
#define sk_X509_VERIFY_PARAM_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_X509_VERIFY_PARAM_sk_type(sk),ossl_check_X509_VERIFY_PARAM_freefunc_type(freefunc))
|
||||
#define sk_X509_VERIFY_PARAM_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_X509_VERIFY_PARAM_sk_type(sk), ossl_check_X509_VERIFY_PARAM_type(ptr), (idx))
|
||||
#define sk_X509_VERIFY_PARAM_set(sk, idx, ptr) ((X509_VERIFY_PARAM *)OPENSSL_sk_set(ossl_check_X509_VERIFY_PARAM_sk_type(sk), (idx), ossl_check_X509_VERIFY_PARAM_type(ptr)))
|
||||
#define sk_X509_VERIFY_PARAM_find(sk, ptr) OPENSSL_sk_find(ossl_check_X509_VERIFY_PARAM_sk_type(sk), ossl_check_X509_VERIFY_PARAM_type(ptr))
|
||||
#define sk_X509_VERIFY_PARAM_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_X509_VERIFY_PARAM_sk_type(sk), ossl_check_X509_VERIFY_PARAM_type(ptr))
|
||||
#define sk_X509_VERIFY_PARAM_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_X509_VERIFY_PARAM_sk_type(sk), ossl_check_X509_VERIFY_PARAM_type(ptr), pnum)
|
||||
#define sk_X509_VERIFY_PARAM_sort(sk) OPENSSL_sk_sort(ossl_check_X509_VERIFY_PARAM_sk_type(sk))
|
||||
#define sk_X509_VERIFY_PARAM_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_X509_VERIFY_PARAM_sk_type(sk))
|
||||
#define sk_X509_VERIFY_PARAM_dup(sk) ((STACK_OF(X509_VERIFY_PARAM) *)OPENSSL_sk_dup(ossl_check_const_X509_VERIFY_PARAM_sk_type(sk)))
|
||||
#define sk_X509_VERIFY_PARAM_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(X509_VERIFY_PARAM) *)OPENSSL_sk_deep_copy(ossl_check_const_X509_VERIFY_PARAM_sk_type(sk), ossl_check_X509_VERIFY_PARAM_copyfunc_type(copyfunc), ossl_check_X509_VERIFY_PARAM_freefunc_type(freefunc)))
|
||||
#define sk_X509_VERIFY_PARAM_set_cmp_func(sk, cmp) ((sk_X509_VERIFY_PARAM_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_X509_VERIFY_PARAM_sk_type(sk), ossl_check_X509_VERIFY_PARAM_compfunc_type(cmp)))
|
||||
|
||||
|
||||
/* This is used for a table of trust checking functions */
|
||||
typedef struct x509_trust_st {
|
||||
int trust;
|
||||
int flags;
|
||||
int (*check_trust) (struct x509_trust_st *, X509 *, int);
|
||||
char *name;
|
||||
int arg1;
|
||||
void *arg2;
|
||||
} X509_TRUST;
|
||||
SKM_DEFINE_STACK_OF_INTERNAL(X509_TRUST, X509_TRUST, X509_TRUST)
|
||||
#define sk_X509_TRUST_num(sk) OPENSSL_sk_num(ossl_check_const_X509_TRUST_sk_type(sk))
|
||||
#define sk_X509_TRUST_value(sk, idx) ((X509_TRUST *)OPENSSL_sk_value(ossl_check_const_X509_TRUST_sk_type(sk), (idx)))
|
||||
#define sk_X509_TRUST_new(cmp) ((STACK_OF(X509_TRUST) *)OPENSSL_sk_new(ossl_check_X509_TRUST_compfunc_type(cmp)))
|
||||
#define sk_X509_TRUST_new_null() ((STACK_OF(X509_TRUST) *)OPENSSL_sk_new_null())
|
||||
#define sk_X509_TRUST_new_reserve(cmp, n) ((STACK_OF(X509_TRUST) *)OPENSSL_sk_new_reserve(ossl_check_X509_TRUST_compfunc_type(cmp), (n)))
|
||||
#define sk_X509_TRUST_reserve(sk, n) OPENSSL_sk_reserve(ossl_check_X509_TRUST_sk_type(sk), (n))
|
||||
#define sk_X509_TRUST_free(sk) OPENSSL_sk_free(ossl_check_X509_TRUST_sk_type(sk))
|
||||
#define sk_X509_TRUST_zero(sk) OPENSSL_sk_zero(ossl_check_X509_TRUST_sk_type(sk))
|
||||
#define sk_X509_TRUST_delete(sk, i) ((X509_TRUST *)OPENSSL_sk_delete(ossl_check_X509_TRUST_sk_type(sk), (i)))
|
||||
#define sk_X509_TRUST_delete_ptr(sk, ptr) ((X509_TRUST *)OPENSSL_sk_delete_ptr(ossl_check_X509_TRUST_sk_type(sk), ossl_check_X509_TRUST_type(ptr)))
|
||||
#define sk_X509_TRUST_push(sk, ptr) OPENSSL_sk_push(ossl_check_X509_TRUST_sk_type(sk), ossl_check_X509_TRUST_type(ptr))
|
||||
#define sk_X509_TRUST_unshift(sk, ptr) OPENSSL_sk_unshift(ossl_check_X509_TRUST_sk_type(sk), ossl_check_X509_TRUST_type(ptr))
|
||||
#define sk_X509_TRUST_pop(sk) ((X509_TRUST *)OPENSSL_sk_pop(ossl_check_X509_TRUST_sk_type(sk)))
|
||||
#define sk_X509_TRUST_shift(sk) ((X509_TRUST *)OPENSSL_sk_shift(ossl_check_X509_TRUST_sk_type(sk)))
|
||||
#define sk_X509_TRUST_pop_free(sk, freefunc) OPENSSL_sk_pop_free(ossl_check_X509_TRUST_sk_type(sk),ossl_check_X509_TRUST_freefunc_type(freefunc))
|
||||
#define sk_X509_TRUST_insert(sk, ptr, idx) OPENSSL_sk_insert(ossl_check_X509_TRUST_sk_type(sk), ossl_check_X509_TRUST_type(ptr), (idx))
|
||||
#define sk_X509_TRUST_set(sk, idx, ptr) ((X509_TRUST *)OPENSSL_sk_set(ossl_check_X509_TRUST_sk_type(sk), (idx), ossl_check_X509_TRUST_type(ptr)))
|
||||
#define sk_X509_TRUST_find(sk, ptr) OPENSSL_sk_find(ossl_check_X509_TRUST_sk_type(sk), ossl_check_X509_TRUST_type(ptr))
|
||||
#define sk_X509_TRUST_find_ex(sk, ptr) OPENSSL_sk_find_ex(ossl_check_X509_TRUST_sk_type(sk), ossl_check_X509_TRUST_type(ptr))
|
||||
#define sk_X509_TRUST_find_all(sk, ptr, pnum) OPENSSL_sk_find_all(ossl_check_X509_TRUST_sk_type(sk), ossl_check_X509_TRUST_type(ptr), pnum)
|
||||
#define sk_X509_TRUST_sort(sk) OPENSSL_sk_sort(ossl_check_X509_TRUST_sk_type(sk))
|
||||
#define sk_X509_TRUST_is_sorted(sk) OPENSSL_sk_is_sorted(ossl_check_const_X509_TRUST_sk_type(sk))
|
||||
#define sk_X509_TRUST_dup(sk) ((STACK_OF(X509_TRUST) *)OPENSSL_sk_dup(ossl_check_const_X509_TRUST_sk_type(sk)))
|
||||
#define sk_X509_TRUST_deep_copy(sk, copyfunc, freefunc) ((STACK_OF(X509_TRUST) *)OPENSSL_sk_deep_copy(ossl_check_const_X509_TRUST_sk_type(sk), ossl_check_X509_TRUST_copyfunc_type(copyfunc), ossl_check_X509_TRUST_freefunc_type(freefunc)))
|
||||
#define sk_X509_TRUST_set_cmp_func(sk, cmp) ((sk_X509_TRUST_compfunc)OPENSSL_sk_set_cmp_func(ossl_check_X509_TRUST_sk_type(sk), ossl_check_X509_TRUST_compfunc_type(cmp)))
|
||||
|
||||
|
||||
/* standard trust ids */
|
||||
# define X509_TRUST_DEFAULT 0 /* Only valid in purpose settings */
|
||||
# define X509_TRUST_COMPAT 1
|
||||
# define X509_TRUST_SSL_CLIENT 2
|
||||
# define X509_TRUST_SSL_SERVER 3
|
||||
# define X509_TRUST_EMAIL 4
|
||||
# define X509_TRUST_OBJECT_SIGN 5
|
||||
# define X509_TRUST_OCSP_SIGN 6
|
||||
# define X509_TRUST_OCSP_REQUEST 7
|
||||
# define X509_TRUST_TSA 8
|
||||
/* Keep these up to date! */
|
||||
# define X509_TRUST_MIN 1
|
||||
# define X509_TRUST_MAX 8
|
||||
|
||||
/* trust_flags values */
|
||||
# define X509_TRUST_DYNAMIC (1U << 0)
|
||||
# define X509_TRUST_DYNAMIC_NAME (1U << 1)
|
||||
/* No compat trust if self-signed, preempts "DO_SS" */
|
||||
# define X509_TRUST_NO_SS_COMPAT (1U << 2)
|
||||
/* Compat trust if no explicit accepted trust EKUs */
|
||||
# define X509_TRUST_DO_SS_COMPAT (1U << 3)
|
||||
/* Accept "anyEKU" as a wildcard rejection OID and as a wildcard trust OID */
|
||||
# define X509_TRUST_OK_ANY_EKU (1U << 4)
|
||||
|
||||
/* check_trust return codes */
|
||||
# define X509_TRUST_TRUSTED 1
|
||||
# define X509_TRUST_REJECTED 2
|
||||
# define X509_TRUST_UNTRUSTED 3
|
||||
|
||||
int X509_TRUST_set(int *t, int trust);
|
||||
int X509_TRUST_get_count(void);
|
||||
X509_TRUST *X509_TRUST_get0(int idx);
|
||||
int X509_TRUST_get_by_id(int id);
|
||||
int X509_TRUST_add(int id, int flags, int (*ck) (X509_TRUST *, X509 *, int),
|
||||
const char *name, int arg1, void *arg2);
|
||||
void X509_TRUST_cleanup(void);
|
||||
int X509_TRUST_get_flags(const X509_TRUST *xp);
|
||||
char *X509_TRUST_get0_name(const X509_TRUST *xp);
|
||||
int X509_TRUST_get_trust(const X509_TRUST *xp);
|
||||
|
||||
int X509_trusted(const X509 *x);
|
||||
int X509_add1_trust_object(X509 *x, const ASN1_OBJECT *obj);
|
||||
int X509_add1_reject_object(X509 *x, const ASN1_OBJECT *obj);
|
||||
void X509_trust_clear(X509 *x);
|
||||
void X509_reject_clear(X509 *x);
|
||||
STACK_OF(ASN1_OBJECT) *X509_get0_trust_objects(X509 *x);
|
||||
STACK_OF(ASN1_OBJECT) *X509_get0_reject_objects(X509 *x);
|
||||
|
||||
int (*X509_TRUST_set_default(int (*trust) (int, X509 *, int))) (int, X509 *,
|
||||
int);
|
||||
int X509_check_trust(X509 *x, int id, int flags);
|
||||
|
||||
int X509_verify_cert(X509_STORE_CTX *ctx);
|
||||
int X509_STORE_CTX_verify(X509_STORE_CTX *ctx);
|
||||
STACK_OF(X509) *X509_build_chain(X509 *target, STACK_OF(X509) *certs,
|
||||
X509_STORE *store, int with_self_signed,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
|
||||
int X509_STORE_set_depth(X509_STORE *store, int depth);
|
||||
|
||||
typedef int (*X509_STORE_CTX_verify_cb)(int, X509_STORE_CTX *);
|
||||
int X509_STORE_CTX_print_verify_cb(int ok, X509_STORE_CTX *ctx);
|
||||
typedef int (*X509_STORE_CTX_verify_fn)(X509_STORE_CTX *);
|
||||
typedef int (*X509_STORE_CTX_get_issuer_fn)(X509 **issuer,
|
||||
X509_STORE_CTX *ctx, X509 *x);
|
||||
typedef int (*X509_STORE_CTX_check_issued_fn)(X509_STORE_CTX *ctx,
|
||||
X509 *x, X509 *issuer);
|
||||
typedef int (*X509_STORE_CTX_check_revocation_fn)(X509_STORE_CTX *ctx);
|
||||
typedef int (*X509_STORE_CTX_get_crl_fn)(X509_STORE_CTX *ctx,
|
||||
X509_CRL **crl, X509 *x);
|
||||
typedef int (*X509_STORE_CTX_check_crl_fn)(X509_STORE_CTX *ctx, X509_CRL *crl);
|
||||
typedef int (*X509_STORE_CTX_cert_crl_fn)(X509_STORE_CTX *ctx,
|
||||
X509_CRL *crl, X509 *x);
|
||||
typedef int (*X509_STORE_CTX_check_policy_fn)(X509_STORE_CTX *ctx);
|
||||
typedef STACK_OF(X509)
|
||||
*(*X509_STORE_CTX_lookup_certs_fn)(X509_STORE_CTX *ctx,
|
||||
const X509_NAME *nm);
|
||||
typedef STACK_OF(X509_CRL)
|
||||
*(*X509_STORE_CTX_lookup_crls_fn)(const X509_STORE_CTX *ctx,
|
||||
const X509_NAME *nm);
|
||||
typedef int (*X509_STORE_CTX_cleanup_fn)(X509_STORE_CTX *ctx);
|
||||
|
||||
void X509_STORE_CTX_set_depth(X509_STORE_CTX *ctx, int depth);
|
||||
|
||||
# define X509_STORE_CTX_set_app_data(ctx,data) \
|
||||
X509_STORE_CTX_set_ex_data(ctx,0,data)
|
||||
# define X509_STORE_CTX_get_app_data(ctx) \
|
||||
X509_STORE_CTX_get_ex_data(ctx,0)
|
||||
|
||||
# define X509_L_FILE_LOAD 1
|
||||
# define X509_L_ADD_DIR 2
|
||||
# define X509_L_ADD_STORE 3
|
||||
# define X509_L_LOAD_STORE 4
|
||||
|
||||
# define X509_LOOKUP_load_file(x,name,type) \
|
||||
X509_LOOKUP_ctrl((x),X509_L_FILE_LOAD,(name),(long)(type),NULL)
|
||||
|
||||
# define X509_LOOKUP_add_dir(x,name,type) \
|
||||
X509_LOOKUP_ctrl((x),X509_L_ADD_DIR,(name),(long)(type),NULL)
|
||||
|
||||
# define X509_LOOKUP_add_store(x,name) \
|
||||
X509_LOOKUP_ctrl((x),X509_L_ADD_STORE,(name),0,NULL)
|
||||
|
||||
# define X509_LOOKUP_load_store(x,name) \
|
||||
X509_LOOKUP_ctrl((x),X509_L_LOAD_STORE,(name),0,NULL)
|
||||
|
||||
# define X509_LOOKUP_load_file_ex(x, name, type, libctx, propq) \
|
||||
X509_LOOKUP_ctrl_ex((x), X509_L_FILE_LOAD, (name), (long)(type), NULL,\
|
||||
(libctx), (propq))
|
||||
|
||||
# define X509_LOOKUP_load_store_ex(x, name, libctx, propq) \
|
||||
X509_LOOKUP_ctrl_ex((x), X509_L_LOAD_STORE, (name), 0, NULL, \
|
||||
(libctx), (propq))
|
||||
|
||||
# define X509_LOOKUP_add_store_ex(x, name, libctx, propq) \
|
||||
X509_LOOKUP_ctrl_ex((x), X509_L_ADD_STORE, (name), 0, NULL, \
|
||||
(libctx), (propq))
|
||||
|
||||
# define X509_V_OK 0
|
||||
# define X509_V_ERR_UNSPECIFIED 1
|
||||
# define X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT 2
|
||||
# define X509_V_ERR_UNABLE_TO_GET_CRL 3
|
||||
# define X509_V_ERR_UNABLE_TO_DECRYPT_CERT_SIGNATURE 4
|
||||
# define X509_V_ERR_UNABLE_TO_DECRYPT_CRL_SIGNATURE 5
|
||||
# define X509_V_ERR_UNABLE_TO_DECODE_ISSUER_PUBLIC_KEY 6
|
||||
# define X509_V_ERR_CERT_SIGNATURE_FAILURE 7
|
||||
# define X509_V_ERR_CRL_SIGNATURE_FAILURE 8
|
||||
# define X509_V_ERR_CERT_NOT_YET_VALID 9
|
||||
# define X509_V_ERR_CERT_HAS_EXPIRED 10
|
||||
# define X509_V_ERR_CRL_NOT_YET_VALID 11
|
||||
# define X509_V_ERR_CRL_HAS_EXPIRED 12
|
||||
# define X509_V_ERR_ERROR_IN_CERT_NOT_BEFORE_FIELD 13
|
||||
# define X509_V_ERR_ERROR_IN_CERT_NOT_AFTER_FIELD 14
|
||||
# define X509_V_ERR_ERROR_IN_CRL_LAST_UPDATE_FIELD 15
|
||||
# define X509_V_ERR_ERROR_IN_CRL_NEXT_UPDATE_FIELD 16
|
||||
# define X509_V_ERR_OUT_OF_MEM 17
|
||||
# define X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT 18
|
||||
# define X509_V_ERR_SELF_SIGNED_CERT_IN_CHAIN 19
|
||||
# define X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT_LOCALLY 20
|
||||
# define X509_V_ERR_UNABLE_TO_VERIFY_LEAF_SIGNATURE 21
|
||||
# define X509_V_ERR_CERT_CHAIN_TOO_LONG 22
|
||||
# define X509_V_ERR_CERT_REVOKED 23
|
||||
# define X509_V_ERR_NO_ISSUER_PUBLIC_KEY 24
|
||||
# define X509_V_ERR_PATH_LENGTH_EXCEEDED 25
|
||||
# define X509_V_ERR_INVALID_PURPOSE 26
|
||||
# define X509_V_ERR_CERT_UNTRUSTED 27
|
||||
# define X509_V_ERR_CERT_REJECTED 28
|
||||
|
||||
/* These are 'informational' when looking for issuer cert */
|
||||
# define X509_V_ERR_SUBJECT_ISSUER_MISMATCH 29
|
||||
# define X509_V_ERR_AKID_SKID_MISMATCH 30
|
||||
# define X509_V_ERR_AKID_ISSUER_SERIAL_MISMATCH 31
|
||||
# define X509_V_ERR_KEYUSAGE_NO_CERTSIGN 32
|
||||
# define X509_V_ERR_UNABLE_TO_GET_CRL_ISSUER 33
|
||||
# define X509_V_ERR_UNHANDLED_CRITICAL_EXTENSION 34
|
||||
# define X509_V_ERR_KEYUSAGE_NO_CRL_SIGN 35
|
||||
# define X509_V_ERR_UNHANDLED_CRITICAL_CRL_EXTENSION 36
|
||||
# define X509_V_ERR_INVALID_NON_CA 37
|
||||
# define X509_V_ERR_PROXY_PATH_LENGTH_EXCEEDED 38
|
||||
# define X509_V_ERR_KEYUSAGE_NO_DIGITAL_SIGNATURE 39
|
||||
# define X509_V_ERR_PROXY_CERTIFICATES_NOT_ALLOWED 40
|
||||
# define X509_V_ERR_INVALID_EXTENSION 41
|
||||
# define X509_V_ERR_INVALID_POLICY_EXTENSION 42
|
||||
# define X509_V_ERR_NO_EXPLICIT_POLICY 43
|
||||
# define X509_V_ERR_DIFFERENT_CRL_SCOPE 44
|
||||
# define X509_V_ERR_UNSUPPORTED_EXTENSION_FEATURE 45
|
||||
# define X509_V_ERR_UNNESTED_RESOURCE 46
|
||||
# define X509_V_ERR_PERMITTED_VIOLATION 47
|
||||
# define X509_V_ERR_EXCLUDED_VIOLATION 48
|
||||
# define X509_V_ERR_SUBTREE_MINMAX 49
|
||||
/* The application is not happy */
|
||||
# define X509_V_ERR_APPLICATION_VERIFICATION 50
|
||||
# define X509_V_ERR_UNSUPPORTED_CONSTRAINT_TYPE 51
|
||||
# define X509_V_ERR_UNSUPPORTED_CONSTRAINT_SYNTAX 52
|
||||
# define X509_V_ERR_UNSUPPORTED_NAME_SYNTAX 53
|
||||
# define X509_V_ERR_CRL_PATH_VALIDATION_ERROR 54
|
||||
/* Another issuer check debug option */
|
||||
# define X509_V_ERR_PATH_LOOP 55
|
||||
/* Suite B mode algorithm violation */
|
||||
# define X509_V_ERR_SUITE_B_INVALID_VERSION 56
|
||||
# define X509_V_ERR_SUITE_B_INVALID_ALGORITHM 57
|
||||
# define X509_V_ERR_SUITE_B_INVALID_CURVE 58
|
||||
# define X509_V_ERR_SUITE_B_INVALID_SIGNATURE_ALGORITHM 59
|
||||
# define X509_V_ERR_SUITE_B_LOS_NOT_ALLOWED 60
|
||||
# define X509_V_ERR_SUITE_B_CANNOT_SIGN_P_384_WITH_P_256 61
|
||||
/* Host, email and IP check errors */
|
||||
# define X509_V_ERR_HOSTNAME_MISMATCH 62
|
||||
# define X509_V_ERR_EMAIL_MISMATCH 63
|
||||
# define X509_V_ERR_IP_ADDRESS_MISMATCH 64
|
||||
/* DANE TLSA errors */
|
||||
# define X509_V_ERR_DANE_NO_MATCH 65
|
||||
/* security level errors */
|
||||
# define X509_V_ERR_EE_KEY_TOO_SMALL 66
|
||||
# define X509_V_ERR_CA_KEY_TOO_SMALL 67
|
||||
# define X509_V_ERR_CA_MD_TOO_WEAK 68
|
||||
/* Caller error */
|
||||
# define X509_V_ERR_INVALID_CALL 69
|
||||
/* Issuer lookup error */
|
||||
# define X509_V_ERR_STORE_LOOKUP 70
|
||||
/* Certificate transparency */
|
||||
# define X509_V_ERR_NO_VALID_SCTS 71
|
||||
|
||||
# define X509_V_ERR_PROXY_SUBJECT_NAME_VIOLATION 72
|
||||
/* OCSP status errors */
|
||||
# define X509_V_ERR_OCSP_VERIFY_NEEDED 73 /* Need OCSP verification */
|
||||
# define X509_V_ERR_OCSP_VERIFY_FAILED 74 /* Couldn't verify cert through OCSP */
|
||||
# define X509_V_ERR_OCSP_CERT_UNKNOWN 75 /* Certificate wasn't recognized by the OCSP responder */
|
||||
|
||||
# define X509_V_ERR_UNSUPPORTED_SIGNATURE_ALGORITHM 76
|
||||
# define X509_V_ERR_SIGNATURE_ALGORITHM_MISMATCH 77
|
||||
|
||||
/* Errors in case a check in X509_V_FLAG_X509_STRICT mode fails */
|
||||
# define X509_V_ERR_SIGNATURE_ALGORITHM_INCONSISTENCY 78
|
||||
# define X509_V_ERR_INVALID_CA 79
|
||||
# define X509_V_ERR_PATHLEN_INVALID_FOR_NON_CA 80
|
||||
# define X509_V_ERR_PATHLEN_WITHOUT_KU_KEY_CERT_SIGN 81
|
||||
# define X509_V_ERR_KU_KEY_CERT_SIGN_INVALID_FOR_NON_CA 82
|
||||
# define X509_V_ERR_ISSUER_NAME_EMPTY 83
|
||||
# define X509_V_ERR_SUBJECT_NAME_EMPTY 84
|
||||
# define X509_V_ERR_MISSING_AUTHORITY_KEY_IDENTIFIER 85
|
||||
# define X509_V_ERR_MISSING_SUBJECT_KEY_IDENTIFIER 86
|
||||
# define X509_V_ERR_EMPTY_SUBJECT_ALT_NAME 87
|
||||
# define X509_V_ERR_EMPTY_SUBJECT_SAN_NOT_CRITICAL 88
|
||||
# define X509_V_ERR_CA_BCONS_NOT_CRITICAL 89
|
||||
# define X509_V_ERR_AUTHORITY_KEY_IDENTIFIER_CRITICAL 90
|
||||
# define X509_V_ERR_SUBJECT_KEY_IDENTIFIER_CRITICAL 91
|
||||
# define X509_V_ERR_CA_CERT_MISSING_KEY_USAGE 92
|
||||
# define X509_V_ERR_EXTENSIONS_REQUIRE_VERSION_3 93
|
||||
# define X509_V_ERR_EC_KEY_EXPLICIT_PARAMS 94
|
||||
|
||||
/* Certificate verify flags */
|
||||
# ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# define X509_V_FLAG_CB_ISSUER_CHECK 0x0 /* Deprecated */
|
||||
# endif
|
||||
/* Use check time instead of current time */
|
||||
# define X509_V_FLAG_USE_CHECK_TIME 0x2
|
||||
/* Lookup CRLs */
|
||||
# define X509_V_FLAG_CRL_CHECK 0x4
|
||||
/* Lookup CRLs for whole chain */
|
||||
# define X509_V_FLAG_CRL_CHECK_ALL 0x8
|
||||
/* Ignore unhandled critical extensions */
|
||||
# define X509_V_FLAG_IGNORE_CRITICAL 0x10
|
||||
/* Disable workarounds for broken certificates */
|
||||
# define X509_V_FLAG_X509_STRICT 0x20
|
||||
/* Enable proxy certificate validation */
|
||||
# define X509_V_FLAG_ALLOW_PROXY_CERTS 0x40
|
||||
/* Enable policy checking */
|
||||
# define X509_V_FLAG_POLICY_CHECK 0x80
|
||||
/* Policy variable require-explicit-policy */
|
||||
# define X509_V_FLAG_EXPLICIT_POLICY 0x100
|
||||
/* Policy variable inhibit-any-policy */
|
||||
# define X509_V_FLAG_INHIBIT_ANY 0x200
|
||||
/* Policy variable inhibit-policy-mapping */
|
||||
# define X509_V_FLAG_INHIBIT_MAP 0x400
|
||||
/* Notify callback that policy is OK */
|
||||
# define X509_V_FLAG_NOTIFY_POLICY 0x800
|
||||
/* Extended CRL features such as indirect CRLs, alternate CRL signing keys */
|
||||
# define X509_V_FLAG_EXTENDED_CRL_SUPPORT 0x1000
|
||||
/* Delta CRL support */
|
||||
# define X509_V_FLAG_USE_DELTAS 0x2000
|
||||
/* Check self-signed CA signature */
|
||||
# define X509_V_FLAG_CHECK_SS_SIGNATURE 0x4000
|
||||
/* Use trusted store first */
|
||||
# define X509_V_FLAG_TRUSTED_FIRST 0x8000
|
||||
/* Suite B 128 bit only mode: not normally used */
|
||||
# define X509_V_FLAG_SUITEB_128_LOS_ONLY 0x10000
|
||||
/* Suite B 192 bit only mode */
|
||||
# define X509_V_FLAG_SUITEB_192_LOS 0x20000
|
||||
/* Suite B 128 bit mode allowing 192 bit algorithms */
|
||||
# define X509_V_FLAG_SUITEB_128_LOS 0x30000
|
||||
/* Allow partial chains if at least one certificate is in trusted store */
|
||||
# define X509_V_FLAG_PARTIAL_CHAIN 0x80000
|
||||
/*
|
||||
* If the initial chain is not trusted, do not attempt to build an alternative
|
||||
* chain. Alternate chain checking was introduced in 1.1.0. Setting this flag
|
||||
* will force the behaviour to match that of previous versions.
|
||||
*/
|
||||
# define X509_V_FLAG_NO_ALT_CHAINS 0x100000
|
||||
/* Do not check certificate/CRL validity against current time */
|
||||
# define X509_V_FLAG_NO_CHECK_TIME 0x200000
|
||||
|
||||
# define X509_VP_FLAG_DEFAULT 0x1
|
||||
# define X509_VP_FLAG_OVERWRITE 0x2
|
||||
# define X509_VP_FLAG_RESET_FLAGS 0x4
|
||||
# define X509_VP_FLAG_LOCKED 0x8
|
||||
# define X509_VP_FLAG_ONCE 0x10
|
||||
|
||||
/* Internal use: mask of policy related options */
|
||||
# define X509_V_FLAG_POLICY_MASK (X509_V_FLAG_POLICY_CHECK \
|
||||
| X509_V_FLAG_EXPLICIT_POLICY \
|
||||
| X509_V_FLAG_INHIBIT_ANY \
|
||||
| X509_V_FLAG_INHIBIT_MAP)
|
||||
|
||||
int X509_OBJECT_idx_by_subject(STACK_OF(X509_OBJECT) *h, X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name);
|
||||
X509_OBJECT *X509_OBJECT_retrieve_by_subject(STACK_OF(X509_OBJECT) *h,
|
||||
X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name);
|
||||
X509_OBJECT *X509_OBJECT_retrieve_match(STACK_OF(X509_OBJECT) *h,
|
||||
X509_OBJECT *x);
|
||||
int X509_OBJECT_up_ref_count(X509_OBJECT *a);
|
||||
X509_OBJECT *X509_OBJECT_new(void);
|
||||
void X509_OBJECT_free(X509_OBJECT *a);
|
||||
X509_LOOKUP_TYPE X509_OBJECT_get_type(const X509_OBJECT *a);
|
||||
X509 *X509_OBJECT_get0_X509(const X509_OBJECT *a);
|
||||
int X509_OBJECT_set1_X509(X509_OBJECT *a, X509 *obj);
|
||||
X509_CRL *X509_OBJECT_get0_X509_CRL(const X509_OBJECT *a);
|
||||
int X509_OBJECT_set1_X509_CRL(X509_OBJECT *a, X509_CRL *obj);
|
||||
X509_STORE *X509_STORE_new(void);
|
||||
void X509_STORE_free(X509_STORE *v);
|
||||
int X509_STORE_lock(X509_STORE *ctx);
|
||||
int X509_STORE_unlock(X509_STORE *ctx);
|
||||
int X509_STORE_up_ref(X509_STORE *v);
|
||||
STACK_OF(X509_OBJECT) *X509_STORE_get0_objects(const X509_STORE *v);
|
||||
STACK_OF(X509) *X509_STORE_get1_all_certs(X509_STORE *st);
|
||||
STACK_OF(X509) *X509_STORE_CTX_get1_certs(X509_STORE_CTX *st,
|
||||
const X509_NAME *nm);
|
||||
STACK_OF(X509_CRL) *X509_STORE_CTX_get1_crls(const X509_STORE_CTX *st,
|
||||
const X509_NAME *nm);
|
||||
int X509_STORE_set_flags(X509_STORE *ctx, unsigned long flags);
|
||||
int X509_STORE_set_purpose(X509_STORE *ctx, int purpose);
|
||||
int X509_STORE_set_trust(X509_STORE *ctx, int trust);
|
||||
int X509_STORE_set1_param(X509_STORE *ctx, const X509_VERIFY_PARAM *pm);
|
||||
X509_VERIFY_PARAM *X509_STORE_get0_param(const X509_STORE *ctx);
|
||||
|
||||
void X509_STORE_set_verify(X509_STORE *ctx, X509_STORE_CTX_verify_fn verify);
|
||||
#define X509_STORE_set_verify_func(ctx, func) \
|
||||
X509_STORE_set_verify((ctx),(func))
|
||||
void X509_STORE_CTX_set_verify(X509_STORE_CTX *ctx,
|
||||
X509_STORE_CTX_verify_fn verify);
|
||||
X509_STORE_CTX_verify_fn X509_STORE_get_verify(const X509_STORE *ctx);
|
||||
void X509_STORE_set_verify_cb(X509_STORE *ctx,
|
||||
X509_STORE_CTX_verify_cb verify_cb);
|
||||
# define X509_STORE_set_verify_cb_func(ctx,func) \
|
||||
X509_STORE_set_verify_cb((ctx),(func))
|
||||
X509_STORE_CTX_verify_cb X509_STORE_get_verify_cb(const X509_STORE *ctx);
|
||||
void X509_STORE_set_get_issuer(X509_STORE *ctx,
|
||||
X509_STORE_CTX_get_issuer_fn get_issuer);
|
||||
X509_STORE_CTX_get_issuer_fn X509_STORE_get_get_issuer(const X509_STORE *ctx);
|
||||
void X509_STORE_set_check_issued(X509_STORE *ctx,
|
||||
X509_STORE_CTX_check_issued_fn check_issued);
|
||||
X509_STORE_CTX_check_issued_fn X509_STORE_get_check_issued(const X509_STORE *ctx);
|
||||
void X509_STORE_set_check_revocation(X509_STORE *ctx,
|
||||
X509_STORE_CTX_check_revocation_fn check_revocation);
|
||||
X509_STORE_CTX_check_revocation_fn
|
||||
X509_STORE_get_check_revocation(const X509_STORE *ctx);
|
||||
void X509_STORE_set_get_crl(X509_STORE *ctx,
|
||||
X509_STORE_CTX_get_crl_fn get_crl);
|
||||
X509_STORE_CTX_get_crl_fn X509_STORE_get_get_crl(const X509_STORE *ctx);
|
||||
void X509_STORE_set_check_crl(X509_STORE *ctx,
|
||||
X509_STORE_CTX_check_crl_fn check_crl);
|
||||
X509_STORE_CTX_check_crl_fn X509_STORE_get_check_crl(const X509_STORE *ctx);
|
||||
void X509_STORE_set_cert_crl(X509_STORE *ctx,
|
||||
X509_STORE_CTX_cert_crl_fn cert_crl);
|
||||
X509_STORE_CTX_cert_crl_fn X509_STORE_get_cert_crl(const X509_STORE *ctx);
|
||||
void X509_STORE_set_check_policy(X509_STORE *ctx,
|
||||
X509_STORE_CTX_check_policy_fn check_policy);
|
||||
X509_STORE_CTX_check_policy_fn X509_STORE_get_check_policy(const X509_STORE *ctx);
|
||||
void X509_STORE_set_lookup_certs(X509_STORE *ctx,
|
||||
X509_STORE_CTX_lookup_certs_fn lookup_certs);
|
||||
X509_STORE_CTX_lookup_certs_fn X509_STORE_get_lookup_certs(const X509_STORE *ctx);
|
||||
void X509_STORE_set_lookup_crls(X509_STORE *ctx,
|
||||
X509_STORE_CTX_lookup_crls_fn lookup_crls);
|
||||
#define X509_STORE_set_lookup_crls_cb(ctx, func) \
|
||||
X509_STORE_set_lookup_crls((ctx), (func))
|
||||
X509_STORE_CTX_lookup_crls_fn X509_STORE_get_lookup_crls(const X509_STORE *ctx);
|
||||
void X509_STORE_set_cleanup(X509_STORE *ctx,
|
||||
X509_STORE_CTX_cleanup_fn cleanup);
|
||||
X509_STORE_CTX_cleanup_fn X509_STORE_get_cleanup(const X509_STORE *ctx);
|
||||
|
||||
#define X509_STORE_get_ex_new_index(l, p, newf, dupf, freef) \
|
||||
CRYPTO_get_ex_new_index(CRYPTO_EX_INDEX_X509_STORE, l, p, newf, dupf, freef)
|
||||
int X509_STORE_set_ex_data(X509_STORE *ctx, int idx, void *data);
|
||||
void *X509_STORE_get_ex_data(const X509_STORE *ctx, int idx);
|
||||
|
||||
X509_STORE_CTX *X509_STORE_CTX_new_ex(OSSL_LIB_CTX *libctx, const char *propq);
|
||||
X509_STORE_CTX *X509_STORE_CTX_new(void);
|
||||
|
||||
int X509_STORE_CTX_get1_issuer(X509 **issuer, X509_STORE_CTX *ctx, X509 *x);
|
||||
|
||||
void X509_STORE_CTX_free(X509_STORE_CTX *ctx);
|
||||
int X509_STORE_CTX_init(X509_STORE_CTX *ctx, X509_STORE *trust_store,
|
||||
X509 *target, STACK_OF(X509) *untrusted);
|
||||
void X509_STORE_CTX_set0_trusted_stack(X509_STORE_CTX *ctx, STACK_OF(X509) *sk);
|
||||
void X509_STORE_CTX_cleanup(X509_STORE_CTX *ctx);
|
||||
|
||||
X509_STORE *X509_STORE_CTX_get0_store(const X509_STORE_CTX *ctx);
|
||||
X509 *X509_STORE_CTX_get0_cert(const X509_STORE_CTX *ctx);
|
||||
STACK_OF(X509)* X509_STORE_CTX_get0_untrusted(const X509_STORE_CTX *ctx);
|
||||
void X509_STORE_CTX_set0_untrusted(X509_STORE_CTX *ctx, STACK_OF(X509) *sk);
|
||||
void X509_STORE_CTX_set_verify_cb(X509_STORE_CTX *ctx,
|
||||
X509_STORE_CTX_verify_cb verify);
|
||||
X509_STORE_CTX_verify_cb X509_STORE_CTX_get_verify_cb(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_verify_fn X509_STORE_CTX_get_verify(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_get_issuer_fn X509_STORE_CTX_get_get_issuer(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_check_issued_fn X509_STORE_CTX_get_check_issued(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_check_revocation_fn X509_STORE_CTX_get_check_revocation(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_get_crl_fn X509_STORE_CTX_get_get_crl(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_check_crl_fn X509_STORE_CTX_get_check_crl(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_cert_crl_fn X509_STORE_CTX_get_cert_crl(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_check_policy_fn X509_STORE_CTX_get_check_policy(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_lookup_certs_fn X509_STORE_CTX_get_lookup_certs(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_lookup_crls_fn X509_STORE_CTX_get_lookup_crls(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX_cleanup_fn X509_STORE_CTX_get_cleanup(const X509_STORE_CTX *ctx);
|
||||
|
||||
#ifndef OPENSSL_NO_DEPRECATED_1_1_0
|
||||
# define X509_STORE_CTX_get_chain X509_STORE_CTX_get0_chain
|
||||
# define X509_STORE_CTX_set_chain X509_STORE_CTX_set0_untrusted
|
||||
# define X509_STORE_CTX_trusted_stack X509_STORE_CTX_set0_trusted_stack
|
||||
# define X509_STORE_get_by_subject X509_STORE_CTX_get_by_subject
|
||||
# define X509_STORE_get1_certs X509_STORE_CTX_get1_certs
|
||||
# define X509_STORE_get1_crls X509_STORE_CTX_get1_crls
|
||||
/* the following macro is misspelled; use X509_STORE_get1_certs instead */
|
||||
# define X509_STORE_get1_cert X509_STORE_CTX_get1_certs
|
||||
/* the following macro is misspelled; use X509_STORE_get1_crls instead */
|
||||
# define X509_STORE_get1_crl X509_STORE_CTX_get1_crls
|
||||
#endif
|
||||
|
||||
X509_LOOKUP *X509_STORE_add_lookup(X509_STORE *v, X509_LOOKUP_METHOD *m);
|
||||
X509_LOOKUP_METHOD *X509_LOOKUP_hash_dir(void);
|
||||
X509_LOOKUP_METHOD *X509_LOOKUP_file(void);
|
||||
X509_LOOKUP_METHOD *X509_LOOKUP_store(void);
|
||||
|
||||
typedef int (*X509_LOOKUP_ctrl_fn)(X509_LOOKUP *ctx, int cmd, const char *argc,
|
||||
long argl, char **ret);
|
||||
typedef int (*X509_LOOKUP_ctrl_ex_fn)(
|
||||
X509_LOOKUP *ctx, int cmd, const char *argc, long argl, char **ret,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
|
||||
typedef int (*X509_LOOKUP_get_by_subject_fn)(X509_LOOKUP *ctx,
|
||||
X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name,
|
||||
X509_OBJECT *ret);
|
||||
typedef int (*X509_LOOKUP_get_by_subject_ex_fn)(X509_LOOKUP *ctx,
|
||||
X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name,
|
||||
X509_OBJECT *ret,
|
||||
OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
typedef int (*X509_LOOKUP_get_by_issuer_serial_fn)(X509_LOOKUP *ctx,
|
||||
X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name,
|
||||
const ASN1_INTEGER *serial,
|
||||
X509_OBJECT *ret);
|
||||
typedef int (*X509_LOOKUP_get_by_fingerprint_fn)(X509_LOOKUP *ctx,
|
||||
X509_LOOKUP_TYPE type,
|
||||
const unsigned char* bytes,
|
||||
int len,
|
||||
X509_OBJECT *ret);
|
||||
typedef int (*X509_LOOKUP_get_by_alias_fn)(X509_LOOKUP *ctx,
|
||||
X509_LOOKUP_TYPE type,
|
||||
const char *str,
|
||||
int len,
|
||||
X509_OBJECT *ret);
|
||||
|
||||
X509_LOOKUP_METHOD *X509_LOOKUP_meth_new(const char *name);
|
||||
void X509_LOOKUP_meth_free(X509_LOOKUP_METHOD *method);
|
||||
|
||||
int X509_LOOKUP_meth_set_new_item(X509_LOOKUP_METHOD *method,
|
||||
int (*new_item) (X509_LOOKUP *ctx));
|
||||
int (*X509_LOOKUP_meth_get_new_item(const X509_LOOKUP_METHOD* method))
|
||||
(X509_LOOKUP *ctx);
|
||||
|
||||
int X509_LOOKUP_meth_set_free(X509_LOOKUP_METHOD *method,
|
||||
void (*free_fn) (X509_LOOKUP *ctx));
|
||||
void (*X509_LOOKUP_meth_get_free(const X509_LOOKUP_METHOD* method))
|
||||
(X509_LOOKUP *ctx);
|
||||
|
||||
int X509_LOOKUP_meth_set_init(X509_LOOKUP_METHOD *method,
|
||||
int (*init) (X509_LOOKUP *ctx));
|
||||
int (*X509_LOOKUP_meth_get_init(const X509_LOOKUP_METHOD* method))
|
||||
(X509_LOOKUP *ctx);
|
||||
|
||||
int X509_LOOKUP_meth_set_shutdown(X509_LOOKUP_METHOD *method,
|
||||
int (*shutdown) (X509_LOOKUP *ctx));
|
||||
int (*X509_LOOKUP_meth_get_shutdown(const X509_LOOKUP_METHOD* method))
|
||||
(X509_LOOKUP *ctx);
|
||||
|
||||
int X509_LOOKUP_meth_set_ctrl(X509_LOOKUP_METHOD *method,
|
||||
X509_LOOKUP_ctrl_fn ctrl_fn);
|
||||
X509_LOOKUP_ctrl_fn X509_LOOKUP_meth_get_ctrl(const X509_LOOKUP_METHOD *method);
|
||||
|
||||
int X509_LOOKUP_meth_set_get_by_subject(X509_LOOKUP_METHOD *method,
|
||||
X509_LOOKUP_get_by_subject_fn fn);
|
||||
X509_LOOKUP_get_by_subject_fn X509_LOOKUP_meth_get_get_by_subject(
|
||||
const X509_LOOKUP_METHOD *method);
|
||||
|
||||
int X509_LOOKUP_meth_set_get_by_issuer_serial(X509_LOOKUP_METHOD *method,
|
||||
X509_LOOKUP_get_by_issuer_serial_fn fn);
|
||||
X509_LOOKUP_get_by_issuer_serial_fn X509_LOOKUP_meth_get_get_by_issuer_serial(
|
||||
const X509_LOOKUP_METHOD *method);
|
||||
|
||||
int X509_LOOKUP_meth_set_get_by_fingerprint(X509_LOOKUP_METHOD *method,
|
||||
X509_LOOKUP_get_by_fingerprint_fn fn);
|
||||
X509_LOOKUP_get_by_fingerprint_fn X509_LOOKUP_meth_get_get_by_fingerprint(
|
||||
const X509_LOOKUP_METHOD *method);
|
||||
|
||||
int X509_LOOKUP_meth_set_get_by_alias(X509_LOOKUP_METHOD *method,
|
||||
X509_LOOKUP_get_by_alias_fn fn);
|
||||
X509_LOOKUP_get_by_alias_fn X509_LOOKUP_meth_get_get_by_alias(
|
||||
const X509_LOOKUP_METHOD *method);
|
||||
|
||||
|
||||
int X509_STORE_add_cert(X509_STORE *ctx, X509 *x);
|
||||
int X509_STORE_add_crl(X509_STORE *ctx, X509_CRL *x);
|
||||
|
||||
int X509_STORE_CTX_get_by_subject(const X509_STORE_CTX *vs,
|
||||
X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name, X509_OBJECT *ret);
|
||||
X509_OBJECT *X509_STORE_CTX_get_obj_by_subject(X509_STORE_CTX *vs,
|
||||
X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name);
|
||||
|
||||
int X509_LOOKUP_ctrl(X509_LOOKUP *ctx, int cmd, const char *argc,
|
||||
long argl, char **ret);
|
||||
int X509_LOOKUP_ctrl_ex(X509_LOOKUP *ctx, int cmd, const char *argc, long argl,
|
||||
char **ret, OSSL_LIB_CTX *libctx, const char *propq);
|
||||
|
||||
int X509_load_cert_file(X509_LOOKUP *ctx, const char *file, int type);
|
||||
int X509_load_cert_file_ex(X509_LOOKUP *ctx, const char *file, int type,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
int X509_load_crl_file(X509_LOOKUP *ctx, const char *file, int type);
|
||||
int X509_load_cert_crl_file(X509_LOOKUP *ctx, const char *file, int type);
|
||||
int X509_load_cert_crl_file_ex(X509_LOOKUP *ctx, const char *file, int type,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
|
||||
X509_LOOKUP *X509_LOOKUP_new(X509_LOOKUP_METHOD *method);
|
||||
void X509_LOOKUP_free(X509_LOOKUP *ctx);
|
||||
int X509_LOOKUP_init(X509_LOOKUP *ctx);
|
||||
int X509_LOOKUP_by_subject(X509_LOOKUP *ctx, X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name, X509_OBJECT *ret);
|
||||
int X509_LOOKUP_by_subject_ex(X509_LOOKUP *ctx, X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name, X509_OBJECT *ret,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
int X509_LOOKUP_by_issuer_serial(X509_LOOKUP *ctx, X509_LOOKUP_TYPE type,
|
||||
const X509_NAME *name,
|
||||
const ASN1_INTEGER *serial,
|
||||
X509_OBJECT *ret);
|
||||
int X509_LOOKUP_by_fingerprint(X509_LOOKUP *ctx, X509_LOOKUP_TYPE type,
|
||||
const unsigned char *bytes, int len,
|
||||
X509_OBJECT *ret);
|
||||
int X509_LOOKUP_by_alias(X509_LOOKUP *ctx, X509_LOOKUP_TYPE type,
|
||||
const char *str, int len, X509_OBJECT *ret);
|
||||
int X509_LOOKUP_set_method_data(X509_LOOKUP *ctx, void *data);
|
||||
void *X509_LOOKUP_get_method_data(const X509_LOOKUP *ctx);
|
||||
X509_STORE *X509_LOOKUP_get_store(const X509_LOOKUP *ctx);
|
||||
int X509_LOOKUP_shutdown(X509_LOOKUP *ctx);
|
||||
|
||||
int X509_STORE_load_file(X509_STORE *ctx, const char *file);
|
||||
int X509_STORE_load_path(X509_STORE *ctx, const char *path);
|
||||
int X509_STORE_load_store(X509_STORE *ctx, const char *store);
|
||||
int X509_STORE_load_locations(X509_STORE *ctx,
|
||||
const char *file,
|
||||
const char *dir);
|
||||
int X509_STORE_set_default_paths(X509_STORE *ctx);
|
||||
|
||||
int X509_STORE_load_file_ex(X509_STORE *ctx, const char *file,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
int X509_STORE_load_store_ex(X509_STORE *ctx, const char *store,
|
||||
OSSL_LIB_CTX *libctx, const char *propq);
|
||||
int X509_STORE_load_locations_ex(X509_STORE *ctx, const char *file,
|
||||
const char *dir, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
int X509_STORE_set_default_paths_ex(X509_STORE *ctx, OSSL_LIB_CTX *libctx,
|
||||
const char *propq);
|
||||
|
||||
#define X509_STORE_CTX_get_ex_new_index(l, p, newf, dupf, freef) \
|
||||
CRYPTO_get_ex_new_index(CRYPTO_EX_INDEX_X509_STORE_CTX, l, p, newf, dupf, freef)
|
||||
int X509_STORE_CTX_set_ex_data(X509_STORE_CTX *ctx, int idx, void *data);
|
||||
void *X509_STORE_CTX_get_ex_data(const X509_STORE_CTX *ctx, int idx);
|
||||
int X509_STORE_CTX_get_error(const X509_STORE_CTX *ctx);
|
||||
void X509_STORE_CTX_set_error(X509_STORE_CTX *ctx, int s);
|
||||
int X509_STORE_CTX_get_error_depth(const X509_STORE_CTX *ctx);
|
||||
void X509_STORE_CTX_set_error_depth(X509_STORE_CTX *ctx, int depth);
|
||||
X509 *X509_STORE_CTX_get_current_cert(const X509_STORE_CTX *ctx);
|
||||
void X509_STORE_CTX_set_current_cert(X509_STORE_CTX *ctx, X509 *x);
|
||||
X509 *X509_STORE_CTX_get0_current_issuer(const X509_STORE_CTX *ctx);
|
||||
X509_CRL *X509_STORE_CTX_get0_current_crl(const X509_STORE_CTX *ctx);
|
||||
X509_STORE_CTX *X509_STORE_CTX_get0_parent_ctx(const X509_STORE_CTX *ctx);
|
||||
STACK_OF(X509) *X509_STORE_CTX_get0_chain(const X509_STORE_CTX *ctx);
|
||||
STACK_OF(X509) *X509_STORE_CTX_get1_chain(const X509_STORE_CTX *ctx);
|
||||
void X509_STORE_CTX_set_cert(X509_STORE_CTX *ctx, X509 *target);
|
||||
void X509_STORE_CTX_set0_verified_chain(X509_STORE_CTX *c, STACK_OF(X509) *sk);
|
||||
void X509_STORE_CTX_set0_crls(X509_STORE_CTX *ctx, STACK_OF(X509_CRL) *sk);
|
||||
int X509_STORE_CTX_set_purpose(X509_STORE_CTX *ctx, int purpose);
|
||||
int X509_STORE_CTX_set_trust(X509_STORE_CTX *ctx, int trust);
|
||||
int X509_STORE_CTX_purpose_inherit(X509_STORE_CTX *ctx, int def_purpose,
|
||||
int purpose, int trust);
|
||||
void X509_STORE_CTX_set_flags(X509_STORE_CTX *ctx, unsigned long flags);
|
||||
void X509_STORE_CTX_set_time(X509_STORE_CTX *ctx, unsigned long flags,
|
||||
time_t t);
|
||||
|
||||
X509_POLICY_TREE *X509_STORE_CTX_get0_policy_tree(const X509_STORE_CTX *ctx);
|
||||
int X509_STORE_CTX_get_explicit_policy(const X509_STORE_CTX *ctx);
|
||||
int X509_STORE_CTX_get_num_untrusted(const X509_STORE_CTX *ctx);
|
||||
|
||||
X509_VERIFY_PARAM *X509_STORE_CTX_get0_param(const X509_STORE_CTX *ctx);
|
||||
void X509_STORE_CTX_set0_param(X509_STORE_CTX *ctx, X509_VERIFY_PARAM *param);
|
||||
int X509_STORE_CTX_set_default(X509_STORE_CTX *ctx, const char *name);
|
||||
|
||||
/*
|
||||
* Bridge opacity barrier between libcrypt and libssl, also needed to support
|
||||
* offline testing in test/danetest.c
|
||||
*/
|
||||
void X509_STORE_CTX_set0_dane(X509_STORE_CTX *ctx, SSL_DANE *dane);
|
||||
#define DANE_FLAG_NO_DANE_EE_NAMECHECKS (1L << 0)
|
||||
|
||||
/* X509_VERIFY_PARAM functions */
|
||||
|
||||
X509_VERIFY_PARAM *X509_VERIFY_PARAM_new(void);
|
||||
void X509_VERIFY_PARAM_free(X509_VERIFY_PARAM *param);
|
||||
int X509_VERIFY_PARAM_inherit(X509_VERIFY_PARAM *to,
|
||||
const X509_VERIFY_PARAM *from);
|
||||
int X509_VERIFY_PARAM_set1(X509_VERIFY_PARAM *to,
|
||||
const X509_VERIFY_PARAM *from);
|
||||
int X509_VERIFY_PARAM_set1_name(X509_VERIFY_PARAM *param, const char *name);
|
||||
int X509_VERIFY_PARAM_set_flags(X509_VERIFY_PARAM *param,
|
||||
unsigned long flags);
|
||||
int X509_VERIFY_PARAM_clear_flags(X509_VERIFY_PARAM *param,
|
||||
unsigned long flags);
|
||||
unsigned long X509_VERIFY_PARAM_get_flags(const X509_VERIFY_PARAM *param);
|
||||
int X509_VERIFY_PARAM_set_purpose(X509_VERIFY_PARAM *param, int purpose);
|
||||
int X509_VERIFY_PARAM_set_trust(X509_VERIFY_PARAM *param, int trust);
|
||||
void X509_VERIFY_PARAM_set_depth(X509_VERIFY_PARAM *param, int depth);
|
||||
void X509_VERIFY_PARAM_set_auth_level(X509_VERIFY_PARAM *param, int auth_level);
|
||||
time_t X509_VERIFY_PARAM_get_time(const X509_VERIFY_PARAM *param);
|
||||
void X509_VERIFY_PARAM_set_time(X509_VERIFY_PARAM *param, time_t t);
|
||||
int X509_VERIFY_PARAM_add0_policy(X509_VERIFY_PARAM *param,
|
||||
ASN1_OBJECT *policy);
|
||||
int X509_VERIFY_PARAM_set1_policies(X509_VERIFY_PARAM *param,
|
||||
STACK_OF(ASN1_OBJECT) *policies);
|
||||
|
||||
int X509_VERIFY_PARAM_set_inh_flags(X509_VERIFY_PARAM *param,
|
||||
uint32_t flags);
|
||||
uint32_t X509_VERIFY_PARAM_get_inh_flags(const X509_VERIFY_PARAM *param);
|
||||
|
||||
char *X509_VERIFY_PARAM_get0_host(X509_VERIFY_PARAM *param, int idx);
|
||||
int X509_VERIFY_PARAM_set1_host(X509_VERIFY_PARAM *param,
|
||||
const char *name, size_t namelen);
|
||||
int X509_VERIFY_PARAM_add1_host(X509_VERIFY_PARAM *param,
|
||||
const char *name, size_t namelen);
|
||||
void X509_VERIFY_PARAM_set_hostflags(X509_VERIFY_PARAM *param,
|
||||
unsigned int flags);
|
||||
unsigned int X509_VERIFY_PARAM_get_hostflags(const X509_VERIFY_PARAM *param);
|
||||
char *X509_VERIFY_PARAM_get0_peername(const X509_VERIFY_PARAM *param);
|
||||
void X509_VERIFY_PARAM_move_peername(X509_VERIFY_PARAM *, X509_VERIFY_PARAM *);
|
||||
char *X509_VERIFY_PARAM_get0_email(X509_VERIFY_PARAM *param);
|
||||
int X509_VERIFY_PARAM_set1_email(X509_VERIFY_PARAM *param,
|
||||
const char *email, size_t emaillen);
|
||||
char *X509_VERIFY_PARAM_get1_ip_asc(X509_VERIFY_PARAM *param);
|
||||
int X509_VERIFY_PARAM_set1_ip(X509_VERIFY_PARAM *param,
|
||||
const unsigned char *ip, size_t iplen);
|
||||
int X509_VERIFY_PARAM_set1_ip_asc(X509_VERIFY_PARAM *param,
|
||||
const char *ipasc);
|
||||
|
||||
int X509_VERIFY_PARAM_get_depth(const X509_VERIFY_PARAM *param);
|
||||
int X509_VERIFY_PARAM_get_auth_level(const X509_VERIFY_PARAM *param);
|
||||
const char *X509_VERIFY_PARAM_get0_name(const X509_VERIFY_PARAM *param);
|
||||
|
||||
int X509_VERIFY_PARAM_add0_table(X509_VERIFY_PARAM *param);
|
||||
int X509_VERIFY_PARAM_get_count(void);
|
||||
const X509_VERIFY_PARAM *X509_VERIFY_PARAM_get0(int id);
|
||||
const X509_VERIFY_PARAM *X509_VERIFY_PARAM_lookup(const char *name);
|
||||
void X509_VERIFY_PARAM_table_cleanup(void);
|
||||
|
||||
/* Non positive return values are errors */
|
||||
#define X509_PCY_TREE_FAILURE -2 /* Failure to satisfy explicit policy */
|
||||
#define X509_PCY_TREE_INVALID -1 /* Inconsistent or invalid extensions */
|
||||
#define X509_PCY_TREE_INTERNAL 0 /* Internal error, most likely malloc */
|
||||
|
||||
/*
|
||||
* Positive return values form a bit mask, all but the first are internal to
|
||||
* the library and don't appear in results from X509_policy_check().
|
||||
*/
|
||||
#define X509_PCY_TREE_VALID 1 /* The policy tree is valid */
|
||||
#define X509_PCY_TREE_EMPTY 2 /* The policy tree is empty */
|
||||
#define X509_PCY_TREE_EXPLICIT 4 /* Explicit policy required */
|
||||
|
||||
int X509_policy_check(X509_POLICY_TREE **ptree, int *pexplicit_policy,
|
||||
STACK_OF(X509) *certs,
|
||||
STACK_OF(ASN1_OBJECT) *policy_oids, unsigned int flags);
|
||||
|
||||
void X509_policy_tree_free(X509_POLICY_TREE *tree);
|
||||
|
||||
int X509_policy_tree_level_count(const X509_POLICY_TREE *tree);
|
||||
X509_POLICY_LEVEL *X509_policy_tree_get0_level(const X509_POLICY_TREE *tree,
|
||||
int i);
|
||||
|
||||
STACK_OF(X509_POLICY_NODE)
|
||||
*X509_policy_tree_get0_policies(const X509_POLICY_TREE *tree);
|
||||
|
||||
STACK_OF(X509_POLICY_NODE)
|
||||
*X509_policy_tree_get0_user_policies(const X509_POLICY_TREE *tree);
|
||||
|
||||
int X509_policy_level_node_count(X509_POLICY_LEVEL *level);
|
||||
|
||||
X509_POLICY_NODE *X509_policy_level_get0_node(const X509_POLICY_LEVEL *level,
|
||||
int i);
|
||||
|
||||
const ASN1_OBJECT *X509_policy_node_get0_policy(const X509_POLICY_NODE *node);
|
||||
|
||||
STACK_OF(POLICYQUALINFO)
|
||||
*X509_policy_node_get0_qualifiers(const X509_POLICY_NODE *node);
|
||||
const X509_POLICY_NODE
|
||||
*X509_policy_node_get0_parent(const X509_POLICY_NODE *node);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
1450
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/x509v3.h
generated
vendored
Normal file
1450
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/openssl/x509v3.h
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
123
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/progs.h
generated
vendored
Normal file
123
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm/include/progs.h
generated
vendored
Normal file
@@ -0,0 +1,123 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by apps/progs.pl
|
||||
*
|
||||
* Copyright 1995-2025 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#include "function.h"
|
||||
|
||||
extern int asn1parse_main(int argc, char *argv[]);
|
||||
extern int ca_main(int argc, char *argv[]);
|
||||
extern int ciphers_main(int argc, char *argv[]);
|
||||
extern int cmp_main(int argc, char *argv[]);
|
||||
extern int cms_main(int argc, char *argv[]);
|
||||
extern int crl_main(int argc, char *argv[]);
|
||||
extern int crl2pkcs7_main(int argc, char *argv[]);
|
||||
extern int dgst_main(int argc, char *argv[]);
|
||||
extern int dhparam_main(int argc, char *argv[]);
|
||||
extern int dsa_main(int argc, char *argv[]);
|
||||
extern int dsaparam_main(int argc, char *argv[]);
|
||||
extern int ec_main(int argc, char *argv[]);
|
||||
extern int ecparam_main(int argc, char *argv[]);
|
||||
extern int enc_main(int argc, char *argv[]);
|
||||
extern int engine_main(int argc, char *argv[]);
|
||||
extern int errstr_main(int argc, char *argv[]);
|
||||
extern int fipsinstall_main(int argc, char *argv[]);
|
||||
extern int gendsa_main(int argc, char *argv[]);
|
||||
extern int genpkey_main(int argc, char *argv[]);
|
||||
extern int genrsa_main(int argc, char *argv[]);
|
||||
extern int help_main(int argc, char *argv[]);
|
||||
extern int info_main(int argc, char *argv[]);
|
||||
extern int kdf_main(int argc, char *argv[]);
|
||||
extern int list_main(int argc, char *argv[]);
|
||||
extern int mac_main(int argc, char *argv[]);
|
||||
extern int nseq_main(int argc, char *argv[]);
|
||||
extern int ocsp_main(int argc, char *argv[]);
|
||||
extern int passwd_main(int argc, char *argv[]);
|
||||
extern int pkcs12_main(int argc, char *argv[]);
|
||||
extern int pkcs7_main(int argc, char *argv[]);
|
||||
extern int pkcs8_main(int argc, char *argv[]);
|
||||
extern int pkey_main(int argc, char *argv[]);
|
||||
extern int pkeyparam_main(int argc, char *argv[]);
|
||||
extern int pkeyutl_main(int argc, char *argv[]);
|
||||
extern int prime_main(int argc, char *argv[]);
|
||||
extern int rand_main(int argc, char *argv[]);
|
||||
extern int rehash_main(int argc, char *argv[]);
|
||||
extern int req_main(int argc, char *argv[]);
|
||||
extern int rsa_main(int argc, char *argv[]);
|
||||
extern int rsautl_main(int argc, char *argv[]);
|
||||
extern int s_client_main(int argc, char *argv[]);
|
||||
extern int s_server_main(int argc, char *argv[]);
|
||||
extern int s_time_main(int argc, char *argv[]);
|
||||
extern int sess_id_main(int argc, char *argv[]);
|
||||
extern int smime_main(int argc, char *argv[]);
|
||||
extern int speed_main(int argc, char *argv[]);
|
||||
extern int spkac_main(int argc, char *argv[]);
|
||||
extern int srp_main(int argc, char *argv[]);
|
||||
extern int storeutl_main(int argc, char *argv[]);
|
||||
extern int ts_main(int argc, char *argv[]);
|
||||
extern int verify_main(int argc, char *argv[]);
|
||||
extern int version_main(int argc, char *argv[]);
|
||||
extern int x509_main(int argc, char *argv[]);
|
||||
|
||||
extern const OPTIONS asn1parse_options[];
|
||||
extern const OPTIONS ca_options[];
|
||||
extern const OPTIONS ciphers_options[];
|
||||
extern const OPTIONS cmp_options[];
|
||||
extern const OPTIONS cms_options[];
|
||||
extern const OPTIONS crl_options[];
|
||||
extern const OPTIONS crl2pkcs7_options[];
|
||||
extern const OPTIONS dgst_options[];
|
||||
extern const OPTIONS dhparam_options[];
|
||||
extern const OPTIONS dsa_options[];
|
||||
extern const OPTIONS dsaparam_options[];
|
||||
extern const OPTIONS ec_options[];
|
||||
extern const OPTIONS ecparam_options[];
|
||||
extern const OPTIONS enc_options[];
|
||||
extern const OPTIONS engine_options[];
|
||||
extern const OPTIONS errstr_options[];
|
||||
extern const OPTIONS fipsinstall_options[];
|
||||
extern const OPTIONS gendsa_options[];
|
||||
extern const OPTIONS genpkey_options[];
|
||||
extern const OPTIONS genrsa_options[];
|
||||
extern const OPTIONS help_options[];
|
||||
extern const OPTIONS info_options[];
|
||||
extern const OPTIONS kdf_options[];
|
||||
extern const OPTIONS list_options[];
|
||||
extern const OPTIONS mac_options[];
|
||||
extern const OPTIONS nseq_options[];
|
||||
extern const OPTIONS ocsp_options[];
|
||||
extern const OPTIONS passwd_options[];
|
||||
extern const OPTIONS pkcs12_options[];
|
||||
extern const OPTIONS pkcs7_options[];
|
||||
extern const OPTIONS pkcs8_options[];
|
||||
extern const OPTIONS pkey_options[];
|
||||
extern const OPTIONS pkeyparam_options[];
|
||||
extern const OPTIONS pkeyutl_options[];
|
||||
extern const OPTIONS prime_options[];
|
||||
extern const OPTIONS rand_options[];
|
||||
extern const OPTIONS rehash_options[];
|
||||
extern const OPTIONS req_options[];
|
||||
extern const OPTIONS rsa_options[];
|
||||
extern const OPTIONS rsautl_options[];
|
||||
extern const OPTIONS s_client_options[];
|
||||
extern const OPTIONS s_server_options[];
|
||||
extern const OPTIONS s_time_options[];
|
||||
extern const OPTIONS sess_id_options[];
|
||||
extern const OPTIONS smime_options[];
|
||||
extern const OPTIONS speed_options[];
|
||||
extern const OPTIONS spkac_options[];
|
||||
extern const OPTIONS srp_options[];
|
||||
extern const OPTIONS storeutl_options[];
|
||||
extern const OPTIONS ts_options[];
|
||||
extern const OPTIONS verify_options[];
|
||||
extern const OPTIONS version_options[];
|
||||
extern const OPTIONS x509_options[];
|
||||
|
||||
extern FUNCTION functions[];
|
||||
@@ -0,0 +1,160 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from providers/common/include/prov/der_digests.h.in
|
||||
*
|
||||
* Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#include "internal/der.h"
|
||||
|
||||
/* Well known OIDs precompiled */
|
||||
|
||||
/*
|
||||
* sigAlgs OBJECT IDENTIFIER ::= { nistAlgorithms 3 }
|
||||
*/
|
||||
#define DER_OID_V_sigAlgs DER_P_OBJECT, 8, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03
|
||||
#define DER_OID_SZ_sigAlgs 10
|
||||
extern const unsigned char ossl_der_oid_sigAlgs[DER_OID_SZ_sigAlgs];
|
||||
|
||||
/*
|
||||
* id-sha1 OBJECT IDENTIFIER ::= { iso(1)
|
||||
* identified-organization(3) oiw(14)
|
||||
* secsig(3) algorithms(2) 26 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha1 DER_P_OBJECT, 5, 0x2B, 0x0E, 0x03, 0x02, 0x1A
|
||||
#define DER_OID_SZ_id_sha1 7
|
||||
extern const unsigned char ossl_der_oid_id_sha1[DER_OID_SZ_id_sha1];
|
||||
|
||||
/*
|
||||
* id-md2 OBJECT IDENTIFIER ::= {
|
||||
* iso(1) member-body(2) us(840) rsadsi(113549) digestAlgorithm(2) 2 }
|
||||
*/
|
||||
#define DER_OID_V_id_md2 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x02, 0x02
|
||||
#define DER_OID_SZ_id_md2 10
|
||||
extern const unsigned char ossl_der_oid_id_md2[DER_OID_SZ_id_md2];
|
||||
|
||||
/*
|
||||
* id-md5 OBJECT IDENTIFIER ::= {
|
||||
* iso(1) member-body(2) us(840) rsadsi(113549) digestAlgorithm(2) 5 }
|
||||
*/
|
||||
#define DER_OID_V_id_md5 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x02, 0x05
|
||||
#define DER_OID_SZ_id_md5 10
|
||||
extern const unsigned char ossl_der_oid_id_md5[DER_OID_SZ_id_md5];
|
||||
|
||||
/*
|
||||
* id-sha256 OBJECT IDENTIFIER ::= { hashAlgs 1 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha256 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01
|
||||
#define DER_OID_SZ_id_sha256 11
|
||||
extern const unsigned char ossl_der_oid_id_sha256[DER_OID_SZ_id_sha256];
|
||||
|
||||
/*
|
||||
* id-sha384 OBJECT IDENTIFIER ::= { hashAlgs 2 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha384 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x02
|
||||
#define DER_OID_SZ_id_sha384 11
|
||||
extern const unsigned char ossl_der_oid_id_sha384[DER_OID_SZ_id_sha384];
|
||||
|
||||
/*
|
||||
* id-sha512 OBJECT IDENTIFIER ::= { hashAlgs 3 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha512 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x03
|
||||
#define DER_OID_SZ_id_sha512 11
|
||||
extern const unsigned char ossl_der_oid_id_sha512[DER_OID_SZ_id_sha512];
|
||||
|
||||
/*
|
||||
* id-sha224 OBJECT IDENTIFIER ::= { hashAlgs 4 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha224 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x04
|
||||
#define DER_OID_SZ_id_sha224 11
|
||||
extern const unsigned char ossl_der_oid_id_sha224[DER_OID_SZ_id_sha224];
|
||||
|
||||
/*
|
||||
* id-sha512-224 OBJECT IDENTIFIER ::= { hashAlgs 5 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha512_224 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x05
|
||||
#define DER_OID_SZ_id_sha512_224 11
|
||||
extern const unsigned char ossl_der_oid_id_sha512_224[DER_OID_SZ_id_sha512_224];
|
||||
|
||||
/*
|
||||
* id-sha512-256 OBJECT IDENTIFIER ::= { hashAlgs 6 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha512_256 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x06
|
||||
#define DER_OID_SZ_id_sha512_256 11
|
||||
extern const unsigned char ossl_der_oid_id_sha512_256[DER_OID_SZ_id_sha512_256];
|
||||
|
||||
/*
|
||||
* id-sha3-224 OBJECT IDENTIFIER ::= { hashAlgs 7 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha3_224 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x07
|
||||
#define DER_OID_SZ_id_sha3_224 11
|
||||
extern const unsigned char ossl_der_oid_id_sha3_224[DER_OID_SZ_id_sha3_224];
|
||||
|
||||
/*
|
||||
* id-sha3-256 OBJECT IDENTIFIER ::= { hashAlgs 8 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha3_256 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x08
|
||||
#define DER_OID_SZ_id_sha3_256 11
|
||||
extern const unsigned char ossl_der_oid_id_sha3_256[DER_OID_SZ_id_sha3_256];
|
||||
|
||||
/*
|
||||
* id-sha3-384 OBJECT IDENTIFIER ::= { hashAlgs 9 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha3_384 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x09
|
||||
#define DER_OID_SZ_id_sha3_384 11
|
||||
extern const unsigned char ossl_der_oid_id_sha3_384[DER_OID_SZ_id_sha3_384];
|
||||
|
||||
/*
|
||||
* id-sha3-512 OBJECT IDENTIFIER ::= { hashAlgs 10 }
|
||||
*/
|
||||
#define DER_OID_V_id_sha3_512 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x0A
|
||||
#define DER_OID_SZ_id_sha3_512 11
|
||||
extern const unsigned char ossl_der_oid_id_sha3_512[DER_OID_SZ_id_sha3_512];
|
||||
|
||||
/*
|
||||
* id-shake128 OBJECT IDENTIFIER ::= { hashAlgs 11 }
|
||||
*/
|
||||
#define DER_OID_V_id_shake128 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x0B
|
||||
#define DER_OID_SZ_id_shake128 11
|
||||
extern const unsigned char ossl_der_oid_id_shake128[DER_OID_SZ_id_shake128];
|
||||
|
||||
/*
|
||||
* id-shake256 OBJECT IDENTIFIER ::= { hashAlgs 12 }
|
||||
*/
|
||||
#define DER_OID_V_id_shake256 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x0C
|
||||
#define DER_OID_SZ_id_shake256 11
|
||||
extern const unsigned char ossl_der_oid_id_shake256[DER_OID_SZ_id_shake256];
|
||||
|
||||
/*
|
||||
* id-shake128-len OBJECT IDENTIFIER ::= { hashAlgs 17 }
|
||||
*/
|
||||
#define DER_OID_V_id_shake128_len DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x11
|
||||
#define DER_OID_SZ_id_shake128_len 11
|
||||
extern const unsigned char ossl_der_oid_id_shake128_len[DER_OID_SZ_id_shake128_len];
|
||||
|
||||
/*
|
||||
* id-shake256-len OBJECT IDENTIFIER ::= { hashAlgs 18 }
|
||||
*/
|
||||
#define DER_OID_V_id_shake256_len DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x12
|
||||
#define DER_OID_SZ_id_shake256_len 11
|
||||
extern const unsigned char ossl_der_oid_id_shake256_len[DER_OID_SZ_id_shake256_len];
|
||||
|
||||
/*
|
||||
* id-KMACWithSHAKE128 OBJECT IDENTIFIER ::={hashAlgs 19}
|
||||
*/
|
||||
#define DER_OID_V_id_KMACWithSHAKE128 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x13
|
||||
#define DER_OID_SZ_id_KMACWithSHAKE128 11
|
||||
extern const unsigned char ossl_der_oid_id_KMACWithSHAKE128[DER_OID_SZ_id_KMACWithSHAKE128];
|
||||
|
||||
/*
|
||||
* id-KMACWithSHAKE256 OBJECT IDENTIFIER ::={ hashAlgs 20}
|
||||
*/
|
||||
#define DER_OID_V_id_KMACWithSHAKE256 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x14
|
||||
#define DER_OID_SZ_id_KMACWithSHAKE256 11
|
||||
extern const unsigned char ossl_der_oid_id_KMACWithSHAKE256[DER_OID_SZ_id_KMACWithSHAKE256];
|
||||
|
||||
@@ -0,0 +1,94 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from providers/common/include/prov/der_dsa.h.in
|
||||
*
|
||||
* Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#include "internal/der.h"
|
||||
|
||||
/* Well known OIDs precompiled */
|
||||
|
||||
/*
|
||||
* id-dsa OBJECT IDENTIFIER ::= {
|
||||
* iso(1) member-body(2) us(840) x9-57(10040) x9algorithm(4) 1 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa DER_P_OBJECT, 7, 0x2A, 0x86, 0x48, 0xCE, 0x38, 0x04, 0x01
|
||||
#define DER_OID_SZ_id_dsa 9
|
||||
extern const unsigned char ossl_der_oid_id_dsa[DER_OID_SZ_id_dsa];
|
||||
|
||||
/*
|
||||
* id-dsa-with-sha1 OBJECT IDENTIFIER ::= {
|
||||
* iso(1) member-body(2) us(840) x9-57 (10040) x9algorithm(4) 3 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa_with_sha1 DER_P_OBJECT, 7, 0x2A, 0x86, 0x48, 0xCE, 0x38, 0x04, 0x03
|
||||
#define DER_OID_SZ_id_dsa_with_sha1 9
|
||||
extern const unsigned char ossl_der_oid_id_dsa_with_sha1[DER_OID_SZ_id_dsa_with_sha1];
|
||||
|
||||
/*
|
||||
* id-dsa-with-sha224 OBJECT IDENTIFIER ::= { sigAlgs 1 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa_with_sha224 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x01
|
||||
#define DER_OID_SZ_id_dsa_with_sha224 11
|
||||
extern const unsigned char ossl_der_oid_id_dsa_with_sha224[DER_OID_SZ_id_dsa_with_sha224];
|
||||
|
||||
/*
|
||||
* id-dsa-with-sha256 OBJECT IDENTIFIER ::= { sigAlgs 2 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa_with_sha256 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x02
|
||||
#define DER_OID_SZ_id_dsa_with_sha256 11
|
||||
extern const unsigned char ossl_der_oid_id_dsa_with_sha256[DER_OID_SZ_id_dsa_with_sha256];
|
||||
|
||||
/*
|
||||
* id-dsa-with-sha384 OBJECT IDENTIFIER ::= { sigAlgs 3 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa_with_sha384 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x03
|
||||
#define DER_OID_SZ_id_dsa_with_sha384 11
|
||||
extern const unsigned char ossl_der_oid_id_dsa_with_sha384[DER_OID_SZ_id_dsa_with_sha384];
|
||||
|
||||
/*
|
||||
* id-dsa-with-sha512 OBJECT IDENTIFIER ::= { sigAlgs 4 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa_with_sha512 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x04
|
||||
#define DER_OID_SZ_id_dsa_with_sha512 11
|
||||
extern const unsigned char ossl_der_oid_id_dsa_with_sha512[DER_OID_SZ_id_dsa_with_sha512];
|
||||
|
||||
/*
|
||||
* id-dsa-with-sha3-224 OBJECT IDENTIFIER ::= { sigAlgs 5 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa_with_sha3_224 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x05
|
||||
#define DER_OID_SZ_id_dsa_with_sha3_224 11
|
||||
extern const unsigned char ossl_der_oid_id_dsa_with_sha3_224[DER_OID_SZ_id_dsa_with_sha3_224];
|
||||
|
||||
/*
|
||||
* id-dsa-with-sha3-256 OBJECT IDENTIFIER ::= { sigAlgs 6 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa_with_sha3_256 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x06
|
||||
#define DER_OID_SZ_id_dsa_with_sha3_256 11
|
||||
extern const unsigned char ossl_der_oid_id_dsa_with_sha3_256[DER_OID_SZ_id_dsa_with_sha3_256];
|
||||
|
||||
/*
|
||||
* id-dsa-with-sha3-384 OBJECT IDENTIFIER ::= { sigAlgs 7 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa_with_sha3_384 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x07
|
||||
#define DER_OID_SZ_id_dsa_with_sha3_384 11
|
||||
extern const unsigned char ossl_der_oid_id_dsa_with_sha3_384[DER_OID_SZ_id_dsa_with_sha3_384];
|
||||
|
||||
/*
|
||||
* id-dsa-with-sha3-512 OBJECT IDENTIFIER ::= { sigAlgs 8 }
|
||||
*/
|
||||
#define DER_OID_V_id_dsa_with_sha3_512 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x08
|
||||
#define DER_OID_SZ_id_dsa_with_sha3_512 11
|
||||
extern const unsigned char ossl_der_oid_id_dsa_with_sha3_512[DER_OID_SZ_id_dsa_with_sha3_512];
|
||||
|
||||
|
||||
/* Subject Public Key Info */
|
||||
int ossl_DER_w_algorithmIdentifier_DSA(WPACKET *pkt, int tag, DSA *dsa);
|
||||
/* Signature */
|
||||
int ossl_DER_w_algorithmIdentifier_DSA_with_MD(WPACKET *pkt, int tag,
|
||||
DSA *dsa, int mdnid);
|
||||
@@ -0,0 +1,286 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from providers/common/include/prov/der_ec.h.in
|
||||
*
|
||||
* Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#include "crypto/ec.h"
|
||||
#include "internal/der.h"
|
||||
|
||||
/* Well known OIDs precompiled */
|
||||
|
||||
/*
|
||||
* ecdsa-with-SHA1 OBJECT IDENTIFIER ::= { id-ecSigType 1 }
|
||||
*/
|
||||
#define DER_OID_V_ecdsa_with_SHA1 DER_P_OBJECT, 7, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x04, 0x01
|
||||
#define DER_OID_SZ_ecdsa_with_SHA1 9
|
||||
extern const unsigned char ossl_der_oid_ecdsa_with_SHA1[DER_OID_SZ_ecdsa_with_SHA1];
|
||||
|
||||
/*
|
||||
* id-ecPublicKey OBJECT IDENTIFIER ::= { id-publicKeyType 1 }
|
||||
*/
|
||||
#define DER_OID_V_id_ecPublicKey DER_P_OBJECT, 7, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x02, 0x01
|
||||
#define DER_OID_SZ_id_ecPublicKey 9
|
||||
extern const unsigned char ossl_der_oid_id_ecPublicKey[DER_OID_SZ_id_ecPublicKey];
|
||||
|
||||
/*
|
||||
* c2pnb163v1 OBJECT IDENTIFIER ::= { c-TwoCurve 1 }
|
||||
*/
|
||||
#define DER_OID_V_c2pnb163v1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x01
|
||||
#define DER_OID_SZ_c2pnb163v1 10
|
||||
extern const unsigned char ossl_der_oid_c2pnb163v1[DER_OID_SZ_c2pnb163v1];
|
||||
|
||||
/*
|
||||
* c2pnb163v2 OBJECT IDENTIFIER ::= { c-TwoCurve 2 }
|
||||
*/
|
||||
#define DER_OID_V_c2pnb163v2 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x02
|
||||
#define DER_OID_SZ_c2pnb163v2 10
|
||||
extern const unsigned char ossl_der_oid_c2pnb163v2[DER_OID_SZ_c2pnb163v2];
|
||||
|
||||
/*
|
||||
* c2pnb163v3 OBJECT IDENTIFIER ::= { c-TwoCurve 3 }
|
||||
*/
|
||||
#define DER_OID_V_c2pnb163v3 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x03
|
||||
#define DER_OID_SZ_c2pnb163v3 10
|
||||
extern const unsigned char ossl_der_oid_c2pnb163v3[DER_OID_SZ_c2pnb163v3];
|
||||
|
||||
/*
|
||||
* c2pnb176w1 OBJECT IDENTIFIER ::= { c-TwoCurve 4 }
|
||||
*/
|
||||
#define DER_OID_V_c2pnb176w1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x04
|
||||
#define DER_OID_SZ_c2pnb176w1 10
|
||||
extern const unsigned char ossl_der_oid_c2pnb176w1[DER_OID_SZ_c2pnb176w1];
|
||||
|
||||
/*
|
||||
* c2tnb191v1 OBJECT IDENTIFIER ::= { c-TwoCurve 5 }
|
||||
*/
|
||||
#define DER_OID_V_c2tnb191v1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x05
|
||||
#define DER_OID_SZ_c2tnb191v1 10
|
||||
extern const unsigned char ossl_der_oid_c2tnb191v1[DER_OID_SZ_c2tnb191v1];
|
||||
|
||||
/*
|
||||
* c2tnb191v2 OBJECT IDENTIFIER ::= { c-TwoCurve 6 }
|
||||
*/
|
||||
#define DER_OID_V_c2tnb191v2 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x06
|
||||
#define DER_OID_SZ_c2tnb191v2 10
|
||||
extern const unsigned char ossl_der_oid_c2tnb191v2[DER_OID_SZ_c2tnb191v2];
|
||||
|
||||
/*
|
||||
* c2tnb191v3 OBJECT IDENTIFIER ::= { c-TwoCurve 7 }
|
||||
*/
|
||||
#define DER_OID_V_c2tnb191v3 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x07
|
||||
#define DER_OID_SZ_c2tnb191v3 10
|
||||
extern const unsigned char ossl_der_oid_c2tnb191v3[DER_OID_SZ_c2tnb191v3];
|
||||
|
||||
/*
|
||||
* c2onb191v4 OBJECT IDENTIFIER ::= { c-TwoCurve 8 }
|
||||
*/
|
||||
#define DER_OID_V_c2onb191v4 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x08
|
||||
#define DER_OID_SZ_c2onb191v4 10
|
||||
extern const unsigned char ossl_der_oid_c2onb191v4[DER_OID_SZ_c2onb191v4];
|
||||
|
||||
/*
|
||||
* c2onb191v5 OBJECT IDENTIFIER ::= { c-TwoCurve 9 }
|
||||
*/
|
||||
#define DER_OID_V_c2onb191v5 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x09
|
||||
#define DER_OID_SZ_c2onb191v5 10
|
||||
extern const unsigned char ossl_der_oid_c2onb191v5[DER_OID_SZ_c2onb191v5];
|
||||
|
||||
/*
|
||||
* c2pnb208w1 OBJECT IDENTIFIER ::= { c-TwoCurve 10 }
|
||||
*/
|
||||
#define DER_OID_V_c2pnb208w1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x0A
|
||||
#define DER_OID_SZ_c2pnb208w1 10
|
||||
extern const unsigned char ossl_der_oid_c2pnb208w1[DER_OID_SZ_c2pnb208w1];
|
||||
|
||||
/*
|
||||
* c2tnb239v1 OBJECT IDENTIFIER ::= { c-TwoCurve 11 }
|
||||
*/
|
||||
#define DER_OID_V_c2tnb239v1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x0B
|
||||
#define DER_OID_SZ_c2tnb239v1 10
|
||||
extern const unsigned char ossl_der_oid_c2tnb239v1[DER_OID_SZ_c2tnb239v1];
|
||||
|
||||
/*
|
||||
* c2tnb239v2 OBJECT IDENTIFIER ::= { c-TwoCurve 12 }
|
||||
*/
|
||||
#define DER_OID_V_c2tnb239v2 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x0C
|
||||
#define DER_OID_SZ_c2tnb239v2 10
|
||||
extern const unsigned char ossl_der_oid_c2tnb239v2[DER_OID_SZ_c2tnb239v2];
|
||||
|
||||
/*
|
||||
* c2tnb239v3 OBJECT IDENTIFIER ::= { c-TwoCurve 13 }
|
||||
*/
|
||||
#define DER_OID_V_c2tnb239v3 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x0D
|
||||
#define DER_OID_SZ_c2tnb239v3 10
|
||||
extern const unsigned char ossl_der_oid_c2tnb239v3[DER_OID_SZ_c2tnb239v3];
|
||||
|
||||
/*
|
||||
* c2onb239v4 OBJECT IDENTIFIER ::= { c-TwoCurve 14 }
|
||||
*/
|
||||
#define DER_OID_V_c2onb239v4 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x0E
|
||||
#define DER_OID_SZ_c2onb239v4 10
|
||||
extern const unsigned char ossl_der_oid_c2onb239v4[DER_OID_SZ_c2onb239v4];
|
||||
|
||||
/*
|
||||
* c2onb239v5 OBJECT IDENTIFIER ::= { c-TwoCurve 15 }
|
||||
*/
|
||||
#define DER_OID_V_c2onb239v5 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x0F
|
||||
#define DER_OID_SZ_c2onb239v5 10
|
||||
extern const unsigned char ossl_der_oid_c2onb239v5[DER_OID_SZ_c2onb239v5];
|
||||
|
||||
/*
|
||||
* c2pnb272w1 OBJECT IDENTIFIER ::= { c-TwoCurve 16 }
|
||||
*/
|
||||
#define DER_OID_V_c2pnb272w1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x10
|
||||
#define DER_OID_SZ_c2pnb272w1 10
|
||||
extern const unsigned char ossl_der_oid_c2pnb272w1[DER_OID_SZ_c2pnb272w1];
|
||||
|
||||
/*
|
||||
* c2pnb304w1 OBJECT IDENTIFIER ::= { c-TwoCurve 17 }
|
||||
*/
|
||||
#define DER_OID_V_c2pnb304w1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x11
|
||||
#define DER_OID_SZ_c2pnb304w1 10
|
||||
extern const unsigned char ossl_der_oid_c2pnb304w1[DER_OID_SZ_c2pnb304w1];
|
||||
|
||||
/*
|
||||
* c2tnb359v1 OBJECT IDENTIFIER ::= { c-TwoCurve 18 }
|
||||
*/
|
||||
#define DER_OID_V_c2tnb359v1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x12
|
||||
#define DER_OID_SZ_c2tnb359v1 10
|
||||
extern const unsigned char ossl_der_oid_c2tnb359v1[DER_OID_SZ_c2tnb359v1];
|
||||
|
||||
/*
|
||||
* c2pnb368w1 OBJECT IDENTIFIER ::= { c-TwoCurve 19 }
|
||||
*/
|
||||
#define DER_OID_V_c2pnb368w1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x13
|
||||
#define DER_OID_SZ_c2pnb368w1 10
|
||||
extern const unsigned char ossl_der_oid_c2pnb368w1[DER_OID_SZ_c2pnb368w1];
|
||||
|
||||
/*
|
||||
* c2tnb431r1 OBJECT IDENTIFIER ::= { c-TwoCurve 20 }
|
||||
*/
|
||||
#define DER_OID_V_c2tnb431r1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x00, 0x14
|
||||
#define DER_OID_SZ_c2tnb431r1 10
|
||||
extern const unsigned char ossl_der_oid_c2tnb431r1[DER_OID_SZ_c2tnb431r1];
|
||||
|
||||
/*
|
||||
* prime192v1 OBJECT IDENTIFIER ::= { primeCurve 1 }
|
||||
*/
|
||||
#define DER_OID_V_prime192v1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x01, 0x01
|
||||
#define DER_OID_SZ_prime192v1 10
|
||||
extern const unsigned char ossl_der_oid_prime192v1[DER_OID_SZ_prime192v1];
|
||||
|
||||
/*
|
||||
* prime192v2 OBJECT IDENTIFIER ::= { primeCurve 2 }
|
||||
*/
|
||||
#define DER_OID_V_prime192v2 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x01, 0x02
|
||||
#define DER_OID_SZ_prime192v2 10
|
||||
extern const unsigned char ossl_der_oid_prime192v2[DER_OID_SZ_prime192v2];
|
||||
|
||||
/*
|
||||
* prime192v3 OBJECT IDENTIFIER ::= { primeCurve 3 }
|
||||
*/
|
||||
#define DER_OID_V_prime192v3 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x01, 0x03
|
||||
#define DER_OID_SZ_prime192v3 10
|
||||
extern const unsigned char ossl_der_oid_prime192v3[DER_OID_SZ_prime192v3];
|
||||
|
||||
/*
|
||||
* prime239v1 OBJECT IDENTIFIER ::= { primeCurve 4 }
|
||||
*/
|
||||
#define DER_OID_V_prime239v1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x01, 0x04
|
||||
#define DER_OID_SZ_prime239v1 10
|
||||
extern const unsigned char ossl_der_oid_prime239v1[DER_OID_SZ_prime239v1];
|
||||
|
||||
/*
|
||||
* prime239v2 OBJECT IDENTIFIER ::= { primeCurve 5 }
|
||||
*/
|
||||
#define DER_OID_V_prime239v2 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x01, 0x05
|
||||
#define DER_OID_SZ_prime239v2 10
|
||||
extern const unsigned char ossl_der_oid_prime239v2[DER_OID_SZ_prime239v2];
|
||||
|
||||
/*
|
||||
* prime239v3 OBJECT IDENTIFIER ::= { primeCurve 6 }
|
||||
*/
|
||||
#define DER_OID_V_prime239v3 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x01, 0x06
|
||||
#define DER_OID_SZ_prime239v3 10
|
||||
extern const unsigned char ossl_der_oid_prime239v3[DER_OID_SZ_prime239v3];
|
||||
|
||||
/*
|
||||
* prime256v1 OBJECT IDENTIFIER ::= { primeCurve 7 }
|
||||
*/
|
||||
#define DER_OID_V_prime256v1 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x03, 0x01, 0x07
|
||||
#define DER_OID_SZ_prime256v1 10
|
||||
extern const unsigned char ossl_der_oid_prime256v1[DER_OID_SZ_prime256v1];
|
||||
|
||||
/*
|
||||
* ecdsa-with-SHA224 OBJECT IDENTIFIER ::= { iso(1) member-body(2)
|
||||
* us(840) ansi-X9-62(10045) signatures(4) ecdsa-with-SHA2(3) 1 }
|
||||
*/
|
||||
#define DER_OID_V_ecdsa_with_SHA224 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x04, 0x03, 0x01
|
||||
#define DER_OID_SZ_ecdsa_with_SHA224 10
|
||||
extern const unsigned char ossl_der_oid_ecdsa_with_SHA224[DER_OID_SZ_ecdsa_with_SHA224];
|
||||
|
||||
/*
|
||||
* ecdsa-with-SHA256 OBJECT IDENTIFIER ::= { iso(1) member-body(2)
|
||||
* us(840) ansi-X9-62(10045) signatures(4) ecdsa-with-SHA2(3) 2 }
|
||||
*/
|
||||
#define DER_OID_V_ecdsa_with_SHA256 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x04, 0x03, 0x02
|
||||
#define DER_OID_SZ_ecdsa_with_SHA256 10
|
||||
extern const unsigned char ossl_der_oid_ecdsa_with_SHA256[DER_OID_SZ_ecdsa_with_SHA256];
|
||||
|
||||
/*
|
||||
* ecdsa-with-SHA384 OBJECT IDENTIFIER ::= { iso(1) member-body(2)
|
||||
* us(840) ansi-X9-62(10045) signatures(4) ecdsa-with-SHA2(3) 3 }
|
||||
*/
|
||||
#define DER_OID_V_ecdsa_with_SHA384 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x04, 0x03, 0x03
|
||||
#define DER_OID_SZ_ecdsa_with_SHA384 10
|
||||
extern const unsigned char ossl_der_oid_ecdsa_with_SHA384[DER_OID_SZ_ecdsa_with_SHA384];
|
||||
|
||||
/*
|
||||
* ecdsa-with-SHA512 OBJECT IDENTIFIER ::= { iso(1) member-body(2)
|
||||
* us(840) ansi-X9-62(10045) signatures(4) ecdsa-with-SHA2(3) 4 }
|
||||
*/
|
||||
#define DER_OID_V_ecdsa_with_SHA512 DER_P_OBJECT, 8, 0x2A, 0x86, 0x48, 0xCE, 0x3D, 0x04, 0x03, 0x04
|
||||
#define DER_OID_SZ_ecdsa_with_SHA512 10
|
||||
extern const unsigned char ossl_der_oid_ecdsa_with_SHA512[DER_OID_SZ_ecdsa_with_SHA512];
|
||||
|
||||
/*
|
||||
* id-ecdsa-with-sha3-224 OBJECT IDENTIFIER ::= { sigAlgs 9 }
|
||||
*/
|
||||
#define DER_OID_V_id_ecdsa_with_sha3_224 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x09
|
||||
#define DER_OID_SZ_id_ecdsa_with_sha3_224 11
|
||||
extern const unsigned char ossl_der_oid_id_ecdsa_with_sha3_224[DER_OID_SZ_id_ecdsa_with_sha3_224];
|
||||
|
||||
/*
|
||||
* id-ecdsa-with-sha3-256 OBJECT IDENTIFIER ::= { sigAlgs 10 }
|
||||
*/
|
||||
#define DER_OID_V_id_ecdsa_with_sha3_256 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x0A
|
||||
#define DER_OID_SZ_id_ecdsa_with_sha3_256 11
|
||||
extern const unsigned char ossl_der_oid_id_ecdsa_with_sha3_256[DER_OID_SZ_id_ecdsa_with_sha3_256];
|
||||
|
||||
/*
|
||||
* id-ecdsa-with-sha3-384 OBJECT IDENTIFIER ::= { sigAlgs 11 }
|
||||
*/
|
||||
#define DER_OID_V_id_ecdsa_with_sha3_384 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x0B
|
||||
#define DER_OID_SZ_id_ecdsa_with_sha3_384 11
|
||||
extern const unsigned char ossl_der_oid_id_ecdsa_with_sha3_384[DER_OID_SZ_id_ecdsa_with_sha3_384];
|
||||
|
||||
/*
|
||||
* id-ecdsa-with-sha3-512 OBJECT IDENTIFIER ::= { sigAlgs 12 }
|
||||
*/
|
||||
#define DER_OID_V_id_ecdsa_with_sha3_512 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x0C
|
||||
#define DER_OID_SZ_id_ecdsa_with_sha3_512 11
|
||||
extern const unsigned char ossl_der_oid_id_ecdsa_with_sha3_512[DER_OID_SZ_id_ecdsa_with_sha3_512];
|
||||
|
||||
|
||||
/* Subject Public Key Info */
|
||||
int ossl_DER_w_algorithmIdentifier_EC(WPACKET *pkt, int cont, EC_KEY *ec);
|
||||
/* Signature */
|
||||
int ossl_DER_w_algorithmIdentifier_ECDSA_with_MD(WPACKET *pkt, int cont,
|
||||
EC_KEY *ec, int mdnid);
|
||||
@@ -0,0 +1,50 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from providers/common/include/prov/der_ecx.h.in
|
||||
*
|
||||
* Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#include "internal/der.h"
|
||||
#include "crypto/ecx.h"
|
||||
|
||||
/* Well known OIDs precompiled */
|
||||
|
||||
/*
|
||||
* id-X25519 OBJECT IDENTIFIER ::= { id-edwards-curve-algs 110 }
|
||||
*/
|
||||
#define DER_OID_V_id_X25519 DER_P_OBJECT, 3, 0x2B, 0x65, 0x6E
|
||||
#define DER_OID_SZ_id_X25519 5
|
||||
extern const unsigned char ossl_der_oid_id_X25519[DER_OID_SZ_id_X25519];
|
||||
|
||||
/*
|
||||
* id-X448 OBJECT IDENTIFIER ::= { id-edwards-curve-algs 111 }
|
||||
*/
|
||||
#define DER_OID_V_id_X448 DER_P_OBJECT, 3, 0x2B, 0x65, 0x6F
|
||||
#define DER_OID_SZ_id_X448 5
|
||||
extern const unsigned char ossl_der_oid_id_X448[DER_OID_SZ_id_X448];
|
||||
|
||||
/*
|
||||
* id-Ed25519 OBJECT IDENTIFIER ::= { id-edwards-curve-algs 112 }
|
||||
*/
|
||||
#define DER_OID_V_id_Ed25519 DER_P_OBJECT, 3, 0x2B, 0x65, 0x70
|
||||
#define DER_OID_SZ_id_Ed25519 5
|
||||
extern const unsigned char ossl_der_oid_id_Ed25519[DER_OID_SZ_id_Ed25519];
|
||||
|
||||
/*
|
||||
* id-Ed448 OBJECT IDENTIFIER ::= { id-edwards-curve-algs 113 }
|
||||
*/
|
||||
#define DER_OID_V_id_Ed448 DER_P_OBJECT, 3, 0x2B, 0x65, 0x71
|
||||
#define DER_OID_SZ_id_Ed448 5
|
||||
extern const unsigned char ossl_der_oid_id_Ed448[DER_OID_SZ_id_Ed448];
|
||||
|
||||
|
||||
int ossl_DER_w_algorithmIdentifier_ED25519(WPACKET *pkt, int cont, ECX_KEY *ec);
|
||||
int ossl_DER_w_algorithmIdentifier_ED448(WPACKET *pkt, int cont, ECX_KEY *ec);
|
||||
int ossl_DER_w_algorithmIdentifier_X25519(WPACKET *pkt, int cont, ECX_KEY *ec);
|
||||
int ossl_DER_w_algorithmIdentifier_X448(WPACKET *pkt, int cont, ECX_KEY *ec);
|
||||
@@ -0,0 +1,187 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from providers/common/include/prov/der_rsa.h.in
|
||||
*
|
||||
* Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#include "crypto/rsa.h"
|
||||
#include "internal/der.h"
|
||||
|
||||
/* Well known OIDs precompiled */
|
||||
|
||||
/*
|
||||
* hashAlgs OBJECT IDENTIFIER ::= { nistAlgorithms 2 }
|
||||
*/
|
||||
#define DER_OID_V_hashAlgs DER_P_OBJECT, 8, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02
|
||||
#define DER_OID_SZ_hashAlgs 10
|
||||
extern const unsigned char ossl_der_oid_hashAlgs[DER_OID_SZ_hashAlgs];
|
||||
|
||||
/*
|
||||
* rsaEncryption OBJECT IDENTIFIER ::= { pkcs-1 1 }
|
||||
*/
|
||||
#define DER_OID_V_rsaEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x01
|
||||
#define DER_OID_SZ_rsaEncryption 11
|
||||
extern const unsigned char ossl_der_oid_rsaEncryption[DER_OID_SZ_rsaEncryption];
|
||||
|
||||
/*
|
||||
* id-RSAES-OAEP OBJECT IDENTIFIER ::= { pkcs-1 7 }
|
||||
*/
|
||||
#define DER_OID_V_id_RSAES_OAEP DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x07
|
||||
#define DER_OID_SZ_id_RSAES_OAEP 11
|
||||
extern const unsigned char ossl_der_oid_id_RSAES_OAEP[DER_OID_SZ_id_RSAES_OAEP];
|
||||
|
||||
/*
|
||||
* id-pSpecified OBJECT IDENTIFIER ::= { pkcs-1 9 }
|
||||
*/
|
||||
#define DER_OID_V_id_pSpecified DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x09
|
||||
#define DER_OID_SZ_id_pSpecified 11
|
||||
extern const unsigned char ossl_der_oid_id_pSpecified[DER_OID_SZ_id_pSpecified];
|
||||
|
||||
/*
|
||||
* id-RSASSA-PSS OBJECT IDENTIFIER ::= { pkcs-1 10 }
|
||||
*/
|
||||
#define DER_OID_V_id_RSASSA_PSS DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x0A
|
||||
#define DER_OID_SZ_id_RSASSA_PSS 11
|
||||
extern const unsigned char ossl_der_oid_id_RSASSA_PSS[DER_OID_SZ_id_RSASSA_PSS];
|
||||
|
||||
/*
|
||||
* md2WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 2 }
|
||||
*/
|
||||
#define DER_OID_V_md2WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x02
|
||||
#define DER_OID_SZ_md2WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_md2WithRSAEncryption[DER_OID_SZ_md2WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* md5WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 4 }
|
||||
*/
|
||||
#define DER_OID_V_md5WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x04
|
||||
#define DER_OID_SZ_md5WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_md5WithRSAEncryption[DER_OID_SZ_md5WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* sha1WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 5 }
|
||||
*/
|
||||
#define DER_OID_V_sha1WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x05
|
||||
#define DER_OID_SZ_sha1WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_sha1WithRSAEncryption[DER_OID_SZ_sha1WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* sha224WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 14 }
|
||||
*/
|
||||
#define DER_OID_V_sha224WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x0E
|
||||
#define DER_OID_SZ_sha224WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_sha224WithRSAEncryption[DER_OID_SZ_sha224WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* sha256WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 11 }
|
||||
*/
|
||||
#define DER_OID_V_sha256WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x0B
|
||||
#define DER_OID_SZ_sha256WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_sha256WithRSAEncryption[DER_OID_SZ_sha256WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* sha384WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 12 }
|
||||
*/
|
||||
#define DER_OID_V_sha384WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x0C
|
||||
#define DER_OID_SZ_sha384WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_sha384WithRSAEncryption[DER_OID_SZ_sha384WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* sha512WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 13 }
|
||||
*/
|
||||
#define DER_OID_V_sha512WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x0D
|
||||
#define DER_OID_SZ_sha512WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_sha512WithRSAEncryption[DER_OID_SZ_sha512WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* sha512-224WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 15 }
|
||||
*/
|
||||
#define DER_OID_V_sha512_224WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x0F
|
||||
#define DER_OID_SZ_sha512_224WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_sha512_224WithRSAEncryption[DER_OID_SZ_sha512_224WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* sha512-256WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 16 }
|
||||
*/
|
||||
#define DER_OID_V_sha512_256WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x10
|
||||
#define DER_OID_SZ_sha512_256WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_sha512_256WithRSAEncryption[DER_OID_SZ_sha512_256WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* id-mgf1 OBJECT IDENTIFIER ::= { pkcs-1 8 }
|
||||
*/
|
||||
#define DER_OID_V_id_mgf1 DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x08
|
||||
#define DER_OID_SZ_id_mgf1 11
|
||||
extern const unsigned char ossl_der_oid_id_mgf1[DER_OID_SZ_id_mgf1];
|
||||
|
||||
/*
|
||||
* id-rsassa-pkcs1-v1_5-with-sha3-224 OBJECT IDENTIFIER ::= { sigAlgs 13 }
|
||||
*/
|
||||
#define DER_OID_V_id_rsassa_pkcs1_v1_5_with_sha3_224 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x0D
|
||||
#define DER_OID_SZ_id_rsassa_pkcs1_v1_5_with_sha3_224 11
|
||||
extern const unsigned char ossl_der_oid_id_rsassa_pkcs1_v1_5_with_sha3_224[DER_OID_SZ_id_rsassa_pkcs1_v1_5_with_sha3_224];
|
||||
|
||||
/*
|
||||
* id-rsassa-pkcs1-v1_5-with-sha3-256 OBJECT IDENTIFIER ::= { sigAlgs 14 }
|
||||
*/
|
||||
#define DER_OID_V_id_rsassa_pkcs1_v1_5_with_sha3_256 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x0E
|
||||
#define DER_OID_SZ_id_rsassa_pkcs1_v1_5_with_sha3_256 11
|
||||
extern const unsigned char ossl_der_oid_id_rsassa_pkcs1_v1_5_with_sha3_256[DER_OID_SZ_id_rsassa_pkcs1_v1_5_with_sha3_256];
|
||||
|
||||
/*
|
||||
* id-rsassa-pkcs1-v1_5-with-sha3-384 OBJECT IDENTIFIER ::= { sigAlgs 15 }
|
||||
*/
|
||||
#define DER_OID_V_id_rsassa_pkcs1_v1_5_with_sha3_384 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x0F
|
||||
#define DER_OID_SZ_id_rsassa_pkcs1_v1_5_with_sha3_384 11
|
||||
extern const unsigned char ossl_der_oid_id_rsassa_pkcs1_v1_5_with_sha3_384[DER_OID_SZ_id_rsassa_pkcs1_v1_5_with_sha3_384];
|
||||
|
||||
/*
|
||||
* id-rsassa-pkcs1-v1_5-with-sha3-512 OBJECT IDENTIFIER ::= { sigAlgs 16 }
|
||||
*/
|
||||
#define DER_OID_V_id_rsassa_pkcs1_v1_5_with_sha3_512 DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x03, 0x10
|
||||
#define DER_OID_SZ_id_rsassa_pkcs1_v1_5_with_sha3_512 11
|
||||
extern const unsigned char ossl_der_oid_id_rsassa_pkcs1_v1_5_with_sha3_512[DER_OID_SZ_id_rsassa_pkcs1_v1_5_with_sha3_512];
|
||||
|
||||
/*
|
||||
* md4WithRSAEncryption OBJECT IDENTIFIER ::= { pkcs-1 3 }
|
||||
*/
|
||||
#define DER_OID_V_md4WithRSAEncryption DER_P_OBJECT, 9, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x03
|
||||
#define DER_OID_SZ_md4WithRSAEncryption 11
|
||||
extern const unsigned char ossl_der_oid_md4WithRSAEncryption[DER_OID_SZ_md4WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* ripemd160WithRSAEncryption OBJECT IDENTIFIER ::= {
|
||||
* iso(1) identified-organization(3) teletrust(36) algorithm(3) signatureAlgorithm(3) rsaSignature(1) 2
|
||||
* }
|
||||
*/
|
||||
#define DER_OID_V_ripemd160WithRSAEncryption DER_P_OBJECT, 6, 0x2B, 0x24, 0x03, 0x03, 0x01, 0x02
|
||||
#define DER_OID_SZ_ripemd160WithRSAEncryption 8
|
||||
extern const unsigned char ossl_der_oid_ripemd160WithRSAEncryption[DER_OID_SZ_ripemd160WithRSAEncryption];
|
||||
|
||||
/*
|
||||
* mdc2WithRSASignature OBJECT IDENTIFIER ::= {
|
||||
* iso(1) identified-organization(3) oiw(14) secsig(3) algorithms(2) mdc2WithRSASignature(14)
|
||||
* }
|
||||
*/
|
||||
#define DER_OID_V_mdc2WithRSASignature DER_P_OBJECT, 5, 0x2B, 0x0E, 0x03, 0x02, 0x0E
|
||||
#define DER_OID_SZ_mdc2WithRSASignature 7
|
||||
extern const unsigned char ossl_der_oid_mdc2WithRSASignature[DER_OID_SZ_mdc2WithRSASignature];
|
||||
|
||||
|
||||
/* PSS parameters */
|
||||
int ossl_DER_w_RSASSA_PSS_params(WPACKET *pkt, int tag,
|
||||
const RSA_PSS_PARAMS_30 *pss);
|
||||
/* Subject Public Key Info */
|
||||
int ossl_DER_w_algorithmIdentifier_RSA(WPACKET *pkt, int tag, RSA *rsa);
|
||||
int ossl_DER_w_algorithmIdentifier_RSA_PSS(WPACKET *pkt, int tag,
|
||||
int rsa_type,
|
||||
const RSA_PSS_PARAMS_30 *pss);
|
||||
/* Signature */
|
||||
int ossl_DER_w_algorithmIdentifier_MDWithRSAEncryption(WPACKET *pkt, int tag,
|
||||
int mdnid);
|
||||
@@ -0,0 +1,37 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from providers/common/include/prov/der_sm2.h.in
|
||||
*
|
||||
* Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#include "crypto/ec.h"
|
||||
#include "internal/der.h"
|
||||
|
||||
/* Well known OIDs precompiled */
|
||||
|
||||
/*
|
||||
* sm2-with-SM3 OBJECT IDENTIFIER ::= { sm-scheme 501 }
|
||||
*/
|
||||
#define DER_OID_V_sm2_with_SM3 DER_P_OBJECT, 8, 0x2A, 0x81, 0x1C, 0xCF, 0x55, 0x01, 0x83, 0x75
|
||||
#define DER_OID_SZ_sm2_with_SM3 10
|
||||
extern const unsigned char ossl_der_oid_sm2_with_SM3[DER_OID_SZ_sm2_with_SM3];
|
||||
|
||||
/*
|
||||
* curveSM2 OBJECT IDENTIFIER ::= { sm-scheme 301 }
|
||||
*/
|
||||
#define DER_OID_V_curveSM2 DER_P_OBJECT, 8, 0x2A, 0x81, 0x1C, 0xCF, 0x55, 0x01, 0x82, 0x2D
|
||||
#define DER_OID_SZ_curveSM2 10
|
||||
extern const unsigned char ossl_der_oid_curveSM2[DER_OID_SZ_curveSM2];
|
||||
|
||||
|
||||
/* Subject Public Key Info */
|
||||
int ossl_DER_w_algorithmIdentifier_SM2(WPACKET *pkt, int cont, EC_KEY *ec);
|
||||
/* Signature */
|
||||
int ossl_DER_w_algorithmIdentifier_SM2_with_MD(WPACKET *pkt, int cont,
|
||||
EC_KEY *ec, int mdnid);
|
||||
@@ -0,0 +1,46 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by Makefile from providers/common/include/prov/der_wrap.h.in
|
||||
*
|
||||
* Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#include "internal/der.h"
|
||||
|
||||
/* Well known OIDs precompiled */
|
||||
|
||||
/*
|
||||
* id-alg-CMS3DESwrap OBJECT IDENTIFIER ::= {
|
||||
* iso(1) member-body(2) us(840) rsadsi(113549) pkcs(1) pkcs-9(9) smime(16) alg(3) 6
|
||||
* }
|
||||
*/
|
||||
#define DER_OID_V_id_alg_CMS3DESwrap DER_P_OBJECT, 11, 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x09, 0x10, 0x03, 0x06
|
||||
#define DER_OID_SZ_id_alg_CMS3DESwrap 13
|
||||
extern const unsigned char ossl_der_oid_id_alg_CMS3DESwrap[DER_OID_SZ_id_alg_CMS3DESwrap];
|
||||
|
||||
/*
|
||||
* id-aes128-wrap OBJECT IDENTIFIER ::= { aes 5 }
|
||||
*/
|
||||
#define DER_OID_V_id_aes128_wrap DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x01, 0x05
|
||||
#define DER_OID_SZ_id_aes128_wrap 11
|
||||
extern const unsigned char ossl_der_oid_id_aes128_wrap[DER_OID_SZ_id_aes128_wrap];
|
||||
|
||||
/*
|
||||
* id-aes192-wrap OBJECT IDENTIFIER ::= { aes 25 }
|
||||
*/
|
||||
#define DER_OID_V_id_aes192_wrap DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x01, 0x19
|
||||
#define DER_OID_SZ_id_aes192_wrap 11
|
||||
extern const unsigned char ossl_der_oid_id_aes192_wrap[DER_OID_SZ_id_aes192_wrap];
|
||||
|
||||
/*
|
||||
* id-aes256-wrap OBJECT IDENTIFIER ::= { aes 45 }
|
||||
*/
|
||||
#define DER_OID_V_id_aes256_wrap DER_P_OBJECT, 9, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x01, 0x2D
|
||||
#define DER_OID_SZ_id_aes256_wrap 11
|
||||
extern const unsigned char ossl_der_oid_id_aes256_wrap[DER_OID_SZ_id_aes256_wrap];
|
||||
|
||||
34
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm_avx2/crypto/buildinf.h
generated
vendored
Normal file
34
panel-mgmt_backend/node_modules/node/node_modules/node-bin-darwin-arm64/include/node/openssl/archs/BSD-x86/asm_avx2/crypto/buildinf.h
generated
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
/*
|
||||
* WARNING: do not edit!
|
||||
* Generated by util/mkbuildinf.pl
|
||||
*
|
||||
* Copyright 2014-2025 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#define PLATFORM "platform: BSD-x86"
|
||||
#define DATE "built on: Wed Mar 5 20:59:15 2025 UTC"
|
||||
|
||||
/*
|
||||
* Generate compiler_flags as an array of individual characters. This is a
|
||||
* workaround for the situation where CFLAGS gets too long for a C90 string
|
||||
* literal
|
||||
*/
|
||||
static const char compiler_flags[] = {
|
||||
'c','o','m','p','i','l','e','r',':',' ','.','.','/','c','o','n',
|
||||
'f','i','g','/','f','a','k','e','_','g','c','c','.','p','l',' ',
|
||||
'-','f','P','I','C',' ','-','p','t','h','r','e','a','d',' ','-',
|
||||
'W','a',',','-','-','n','o','e','x','e','c','s','t','a','c','k',
|
||||
' ','-','W','a','l','l',' ','-','O','3',' ','-','f','o','m','i',
|
||||
't','-','f','r','a','m','e','-','p','o','i','n','t','e','r',' ',
|
||||
'-','D','L','_','E','N','D','I','A','N',' ','-','D','O','P','E',
|
||||
'N','S','S','L','_','P','I','C',' ','-','D','_','T','H','R','E',
|
||||
'A','D','_','S','A','F','E',' ','-','D','_','R','E','E','N','T',
|
||||
'R','A','N','T',' ','-','D','O','P','E','N','S','S','L','_','B',
|
||||
'U','I','L','D','I','N','G','_','O','P','E','N','S','S','L',' ',
|
||||
'-','D','N','D','E','B','U','G','\0'
|
||||
};
|
||||
@@ -0,0 +1,29 @@
|
||||
/* WARNING: do not edit! */
|
||||
/* Generated by Makefile from include/crypto/bn_conf.h.in */
|
||||
/*
|
||||
* Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#ifndef OSSL_CRYPTO_BN_CONF_H
|
||||
# define OSSL_CRYPTO_BN_CONF_H
|
||||
# pragma once
|
||||
|
||||
/*
|
||||
* The contents of this file are not used in the UEFI build, as
|
||||
* both 32-bit and 64-bit builds are supported from a single run
|
||||
* of the Configure script.
|
||||
*/
|
||||
|
||||
/* Should we define BN_DIV2W here? */
|
||||
|
||||
/* Only one for the following should be defined */
|
||||
#undef SIXTY_FOUR_BIT_LONG
|
||||
#undef SIXTY_FOUR_BIT
|
||||
#define THIRTY_TWO_BIT
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,19 @@
|
||||
/* WARNING: do not edit! */
|
||||
/* Generated by Makefile from include/crypto/dso_conf.h.in */
|
||||
/*
|
||||
* Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#ifndef OSSL_CRYPTO_DSO_CONF_H
|
||||
# define OSSL_CRYPTO_DSO_CONF_H
|
||||
# pragma once
|
||||
|
||||
# define DSO_DLFCN
|
||||
# define HAVE_DLFCN_H
|
||||
# define DSO_EXTENSION ".so"
|
||||
#endif
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user