Comments (6)
Thank you for your message.
Microsoft support referred me to your script in-fact...
Hahaha, I don't if I like this or not...
Overall, I am currently not running Ubuntu, but Arch Linux. So I need to setup a VM to test this. I currently have limited time to spend, but will see if I can do something the next days.
Regarding Chromium and Brave, please check the paths in common.sh if they match your system.
from create-dotnet-devcert.
I actually tested it right now, and I am not able to reproduce this issue.
Could you please try the script from the branch 12-cert-not-trusted.
If the issue still persists, please paste the OpenSSL Version (openssl version
) and the output of the script.
from create-dotnet-devcert.
Hi Boris,
Thank you for your time....
Tried and getting same behaviour....
Am I right to assume that after running your script that running an openssl verify
on the cert (as above) should work?
Anyhow, here's the output of openssl version
OpenSSL 3.0.2 15 Mar 2022 (Library: OpenSSL 3.0.2 15 Mar 2022)
from create-dotnet-devcert.
Yes, openssl verify
should work, and it does that for me in my Ubuntu VM. Your openssl version also matches mine, so I am not sure what the issue is.
Please pull the latest version of the script in this branch, run with -d
arguments (e.g. ./ubuntu-create-dotnet-devcert.sh -d
) and copy & paste the output here.
from create-dotnet-devcert.
I am having the same problem as @athoma13 when I run openssl verify
. Below is the result when I run the script with -d
:
+ DEPENDENCIES=dotnet certutil openssl
+ check_command dotnet
+ echo Checking if dotnet exists
Checking if dotnet exists
+ command -v dotnet
+ check_command certutil
+ echo Checking if certutil exists
Checking if certutil exists
+ command -v certutil
+ check_command openssl
+ echo Checking if openssl exists
Checking if openssl exists
+ command -v openssl
+ TMP_PATH=/var/tmp/localhost-dev-cert
+ [ ! -d /var/tmp/localhost-dev-cert ]
+ mkdir /var/tmp/localhost-dev-cert
+ KEYFILE=/var/tmp/localhost-dev-cert/dotnet-devcert.key
+ CRTFILE=/var/tmp/localhost-dev-cert/dotnet-devcert.crt
+ PFXFILE=/var/tmp/localhost-dev-cert/dotnet-devcert.pfx
+ NSSDB_PATHS=/home/tester/.pki/nssdb /home/tester/snap/chromium/current/.pki/nssdb /home/tester/snap/postman/current/.pki/nssdb /home/tester/snap/brave/current/.pki/nssdb
+ CONF_PATH=/var/tmp/localhost-dev-cert/localhost.conf
+ cat
+ openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /var/tmp/localhost-dev-cert/dotnet-devcert.key -out /var/tmp/localhost-dev-cert/dotnet-devcert.crt -config /var/tmp/localhost-dev-cert/localhost.conf --passout pass:
.........+......+.......+++++++++++++++++++++++++++++++++++++++*.+++++++++++++++++++++++++++++++++++++++*............+...........+.........+......+.+...+......+...........+....+..+....+........+...+...+.+...+...........+......+.+...+..+....+.....+..............................++++++
....+......+......+.....+.+..+......+++++++++++++++++++++++++++++++++++++++*.+.........+..........+......+......+..+.+.....+++++++++++++++++++++++++++++++++++++++*...........+...+..+..........+.....+.+..+.......+.....+.......+.....+.+..................+..+...+.+......+.........+.........+..+...+......+.+..+.+....................+.+......+..................+......+.....+...+...+...+....+........+..........+.....+...................+.........+.....+....+...+.........+......+.........+....................+...+.............+..................+..+............+.+.........+......+......+...+..+....+...........+...+......+.......+..+..........+..+....+............+...+..............+...+............+......+....+......+.....+.........+.+.........+...+............+..+.........+....+......+.........+........+....+...+...........+.+...+...+.........+......+...+..+.......+...+..+.....................+....+...+.....+.........+...+.............+...+.....+.........+.+.....+.......+...+......+......+.....+...+.+.........+.....+......+....+..+....+...+......+.....+.+...+...+.....+...+.........+......+.........+...+......................+..+......+...............+....+...+......+......+......+.....+.......+...+..............+..........+...+..+.+.....+.......+..+..................+..........+..+...+......+.+......+..+.+.........++++++
-----
+ openssl pkcs12 -export -out /var/tmp/localhost-dev-cert/dotnet-devcert.pfx -inkey /var/tmp/localhost-dev-cert/dotnet-devcert.key -in /var/tmp/localhost-dev-cert/dotnet-devcert.crt --passout pass:
+ [ -d /home/tester/.pki/nssdb ]
+ configure_nssdb /home/tester/.pki/nssdb
+ echo Configuring nssdb for /home/tester/.pki/nssdb
Configuring nssdb for /home/tester/.pki/nssdb
+ certutil -d sql:/home/tester/.pki/nssdb -D -n dotnet-devcert
+ certutil -d sql:/home/tester/.pki/nssdb -A -t CP,, -n dotnet-devcert -i /var/tmp/localhost-dev-cert/dotnet-devcert.crt
+ [ -d /home/tester/snap/chromium/current/.pki/nssdb ]
+ [ -d /home/tester/snap/postman/current/.pki/nssdb ]
+ [ -d /home/tester/snap/brave/current/.pki/nssdb ]
+ id -u
+ [ 1000 -ne 0 ]
+ SUDO=sudo
+ dotnet dev-certs https --clean --import /var/tmp/localhost-dev-cert/dotnet-devcert.pfx -p
HTTPS development certificates successfully removed from the machine.
The certificate was successfully imported.
+ [ 0 = 1 ]
+ sudo rm /etc/ssl/certs/dotnet-devcert.pem
+ sudo cp /var/tmp/localhost-dev-cert/dotnet-devcert.crt /usr/local/share/ca-certificates
+ sudo update-ca-certificates
Updating certificates in /etc/ssl/certs...
1 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d...
done.
+ cleanup
+ rm -R /var/tmp/localhost-dev-cert
from create-dotnet-devcert.
Related Issues (14)
- Great job.
- I am working with Microsoft Tye on Ubuntu it seem to help development on microservices. I am also working with the abp framework they have an example project called eShopOnAbp
- ipv6 devcert
- Work well before but error when upgrading to 22.04 from 20.04
- certutil: could not find certificate named "dotnet-devcert": SEC_ERROR_INVALID_ARGS: security library: invalid arguments. HOT 1
- Great Job!
- OpenSuse TW
- Requires dotnet 5. HOT 11
- IdentityServer4 service-to-service communication Error UntrustedRoot HOT 9
- Received an unexpected EOF or 0 bytes from the transport stream HOT 3
- Help required for running in Docker (Ubuntu) HOT 4
- The server mode SSL must use a certificate with the associated private key HOT 1
- Running command from outside scripts folder fails HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from create-dotnet-devcert.