

10:35, EEST

February 14, 2020

Hello Prosys Team.
We use a prosysopc:ua-client-server-sdk:5.1.0-116.
We create a certificate for ApplicationIdentity:
identity = ApplicationIdentity.loadOrCreateCertificate(
appDesc,
“Name”,
“name”,
new File(certStore.getBaseDir(), “private”),
null,
null,
true
);
How long is it valid for?
How can I create a certificate that is valid for 100 years?
Thanks in advance.
Regards Oleksandr
11:04, EEST

Moderators
February 11, 2020

Hello,
By default, certificates created by calling ApplicationIdentity.loadOrCreateCertificate are valid for 3650 days, which is approximately 10 years.
You can call ApplicationIdentity.setDefaultCertificateDays to set the default to another value, e.g. 36500 for approximately 100 years. You must call this before creating new certificates with ApplicationIdentity.loadOrCreateCertificate. Calling ApplicationIdentity.setDefaultCertificateDays and then loading an existing certificate with ApplicationIdentity.loadOrCreateCertificate does not affect its validity period.
Most Users Ever Online: 1919
Currently Online:
37 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Heikki Tahvanainen: 402
hbrackel: 144
rocket science: 90
pramanj: 86
Francesco Zambon: 83
Ibrahim: 78
Sabari: 62
kapsl: 57
gjevremovic: 49
Xavier: 43
Member Stats:
Guest Posters: 0
Members: 786
Moderators: 8
Admins: 1
Forum Stats:
Groups: 3
Forums: 15
Topics: 1543
Posts: 6506
Newest Members:
Olpsom, shastaappleton, hildred39i, Adam, tammara49z, vktwaylon2, pilarstorkey83, Dwightsache, MollyAlori, somnath.kalaneModerators: Jouni Aro: 1029, Pyry: 1, Petri: 0, Bjarne Boström: 1040, Jimmy Ni: 26, Matti Siponen: 353, Lusetti: 0, Elias: 0
Administrators: admin: 1