1
0
mirror of https://github.com/JKorf/CryptoExchange.Net synced 2026-04-13 00:22:22 +00:00
This commit is contained in:
JKorf 2026-03-16 21:36:59 +01:00
parent 0611848da8
commit f56853030e
2 changed files with 1 additions and 58 deletions

View File

@ -339,7 +339,7 @@ namespace CryptoExchange.Net.UnitTests
public class STJDecimalObject
{
[JsonConverter(typeof(NullableDecimalConverter))]
[JsonConverter(typeof(DecimalConverter))]
[JsonPropertyName("test")]
public decimal? Test { get; set; }
}

View File

@ -1,8 +1,6 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
namespace CryptoExchange.Net.Authentication
{
@ -140,61 +138,6 @@ namespace CryptoExchange.Net.Authentication
return CredentialPairs.OfType<T>().SingleOrDefault();
}
///// <summary>
///// Create API credentials using an API key and secret generated by the server
///// </summary>
//public static ApiCredentials HmacCredentials(string apiKey, string apiSecret, string? pass = null)
//{
// return new ApiCredentials(new HMACCredential(apiKey, apiSecret, pass));
//}
//#if NETSTANDARD2_1_OR_GREATER || NET7_0_OR_GREATER
// /// <summary>
// /// Create API credentials using an API key and an RSA private key in PEM format
// /// </summary>
// public static ApiCredentials RsaPemCredentials(string publicKey, string privateKey)
// {
// return new ApiCredentials(new RSAPemCredential(publicKey, privateKey));
// }
//#endif
// /// <summary>
// /// Create API credentials using an API key and an RSA private key in XML format
// /// </summary>
// public static ApiCredentials RsaXmlCredentials(string publicKey, string privateKey)
// {
// return new ApiCredentials(new RSAXmlCredential(publicKey, privateKey));
// }
//#if NET8_0_OR_GREATER
// /// <summary>
// /// Create API credentials using an API key and an Ed25519 private key
// /// </summary>
// public static ApiCredentials Ed25519Credentials(string publicKey, string privateKey)
// {
// return new ApiCredentials(new ED25519Credential(publicKey, privateKey));
// }
//#endif
// /// <summary>
// /// Create API credentials using an API key and an Ecdsa private key
// /// </summary>
// public static ApiCredentials EcdsaCredentials(string publicKey, string privateKey)
// {
// return new ApiCredentials(new ECDSACredential(publicKey, privateKey));
// }
/// <summary>
/// Load a key from a file
/// </summary>
#warning check
public static string ReadFromFile(string path)
{
using var fileStream = File.OpenRead(path);
using var streamReader = new StreamReader(fileStream);
return streamReader.ReadToEnd();
}
/// <summary>
/// Copy the credentials
/// </summary>