Merge pull request 'main' (#33) from main into working
Reviewed-on: #33
This commit was merged in pull request #33.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
.center-frame {
|
||||
margin: 0 200px;
|
||||
width: calc(100% - 400px);
|
||||
margin: 0 auto;
|
||||
max-width: 1400px;
|
||||
}
|
||||
|
||||
.center-text {
|
||||
|
||||
@@ -46,13 +46,12 @@ h1 {
|
||||
}
|
||||
|
||||
.resume-section {
|
||||
break-inside: avoid;
|
||||
background-color: #DDDDDD;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.resume-sub-section {
|
||||
border: 1px solid #666666;
|
||||
break-inside: avoid;
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
|
||||
@@ -91,6 +91,7 @@ if (IPayment._PaymentType == PaymentType.StripeIntent) {
|
||||
RsaSecurityKey? PublicKey = null;
|
||||
using (HttpClient client = new HttpClient()) {
|
||||
while (PublicKey == null) {
|
||||
try {
|
||||
HttpResponseMessage PublicKeyResponse = await client.GetAsync("https://auth.mistox.com/api/auth/publickey");
|
||||
if (PublicKeyResponse.IsSuccessStatusCode) {
|
||||
string publicKey = await PublicKeyResponse.Content.ReadAsStringAsync();
|
||||
@@ -99,8 +100,14 @@ using (HttpClient client = new HttpClient()) {
|
||||
PublicKey = new RsaSecurityKey(rsa);
|
||||
} else {
|
||||
await Task.Delay(2000); // sleep the main thread for 2 seconds before sending another request. Prevent DDOS of my own equiptment
|
||||
Console.WriteLine("auth.mistox.com returned error code: " + PublicKeyResponse.StatusCode);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
await Task.Delay(2000); // sleep the main thread for 2 seconds before sending another request. Prevent DDOS of my own equiptment
|
||||
Console.WriteLine("Error loading public key: " + e.InnerException?.Message);
|
||||
}
|
||||
}
|
||||
Console.WriteLine("PublicKey loaded");
|
||||
}
|
||||
|
||||
builder.Services.AddAuthentication(options => {
|
||||
|
||||
Reference in New Issue
Block a user