Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/daliborgogic/nemid
Experimental Node.js Danish NemId integration for authenticating a user.
https://github.com/daliborgogic/nemid
crypto nemid nodejs
Last synced: 17 days ago
JSON representation
Experimental Node.js Danish NemId integration for authenticating a user.
- Host: GitHub
- URL: https://github.com/daliborgogic/nemid
- Owner: daliborgogic
- License: mit
- Created: 2019-06-29T18:09:21.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-01-04T08:50:28.000Z (almost 2 years ago)
- Last Synced: 2024-10-17T19:19:08.007Z (27 days ago)
- Topics: crypto, nemid, nodejs
- Language: JavaScript
- Homepage:
- Size: 2.1 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 21
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# [POC] nemid
Download the file DanID Test (gyldig) under [Virksomhedscertifikater](https://www.nets.eu/dk-da/kundeservice/nemid-tjenesteudbyder/NemID-tjenesteudbyderpakken/Pages/OCES-II-certifikat-eksempler.aspx)
You got your `p12` certificate now generate `*.pem` files, use following commands:
Convert it to `public.pem`, use the password `Test1234`.
```bash
# public
openssl pkcs12 \
-in certs/VOCES_gyldig.p12 \
-out certs/public.pem \
-clcerts \
-nokeys
```NOTE: Remove the initial lines with Bag Attributes if present.
Only the `-----BEGIN CERTIFICATE-----`, the `base64` encoded certificate and `-----END CERTIFICATE-----` are relevant.
```bash
# private
openssl pkcs12 \
-in certs/VOCES_gyldig.p12 \
-clcerts \
-out certs/private.pem
```### Environment Variables
```bash
$ cat > .env << EOL
export PASS_PHRASE=
export ORIGIN=
EOL
```### NemID (DK) Test Users
There are two available types of NemID test users.
- [NemID til Private (POCES)](https://www.nets.eu/developer/e-ident/eids/Pages/testusers.aspx#poces)
- [NemID Medarbejdersignatur (MOCES)](https://www.nets.eu/developer/e-ident/eids/Pages/testusers.aspx#moces)