first real commit

This commit is contained in:
Doug Macintosh
2026-03-08 17:05:59 -04:00
parent d5bc62a4f2
commit 336b0dbb7e
945 changed files with 1083090 additions and 0 deletions

1
.consulo/.name Normal file
View File

@@ -0,0 +1 @@
hydro-cdr

11
.consulo/compiler.xml Normal file
View File

@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<project>
<component name="CompilerManager">
<module name="hydro-cdr">
<output url="file://$PROJECT_DIR$/bin/Debug" type="PRODUCTION" />
<output url="file://$PROJECT_DIR$/bin/Debug" type="PRODUCTION_RESOURCE" />
<output url="file://$PROJECT_DIR$/bin/Debug" type="TEST" />
<output url="file://$PROJECT_DIR$/bin/Debug" type="TEST_RESOURCE" />
</module>
</component>
</project>

View File

@@ -0,0 +1,5 @@
<component name="CopyrightManager">
<settings default="">
<module2copyright />
</settings>
</component>

91
.consulo/modules.xml Normal file
View File

@@ -0,0 +1,91 @@
<?xml version="1.0" encoding="UTF-8"?>
<project>
<component name="ModuleManager">
<modules>
<module name="hydro_cdr (Root)" dirurl="file://$PROJECT_DIR$" current-layer="Default">
<module-layer name="Default">
<extension id="msbuild-mono" sdk="Mono MSBuild 15.1 (predefined)" solution-url="file://$MODULE_DIR$/hydro-cdr.sln" provider-id="mono" />
<content url="file://$MODULE_DIR$" />
<orderEntry type="sourceFolder" />
</module-layer>
</module>
<module name="hydro-cdr" current-layer="Default">
<module-layer name="Default">
<extension id="csharp-mono-by-msbuild" unsafe-code="false" optimize-code="false" platform="ANY_CPU" />
<extension id="dotnet-mono-by-msbuild" sdk-module-name="" sdk-name="Mono 4.0-api (predefined)" target="EXECUTABLE" debug="true" allow-source-roots="false" file-name="cdr-tool.$TargetFileExt$" output-dir="$USER_HOME$/Downloads/hydro_cdr/bin/Debug/" namespace-prefix="">
<define>DEBUG</define>
<define>TRACE</define>
</extension>
<content url="file://$USER_HOME$/Downloads/hydro_cdr/Arguments.cs" />
<content url="file://$USER_HOME$/Downloads/hydro_cdr/Logger.cs" />
<content url="file://$USER_HOME$/Downloads/hydro_cdr/Properties/AssemblyInfo.cs" />
<content url="file://$USER_HOME$/Downloads/hydro_cdr/Web.cs" />
<content url="file://$USER_HOME$/Downloads/hydro_cdr/WebRoutines.cs" />
<content url="file://$USER_HOME$/Downloads/hydro_cdr/_Main.cs" />
<content url="file://$USER_HOME$/Downloads/hydro_cdr/app.config" />
<content url="file://$USER_HOME$/Downloads/hydro_cdr/bin/Debug">
<content-folder type="EXCLUDED" url="file://$USER_HOME$/Downloads/hydro_cdr/bin/Debug" />
</content>
<content url="file://$USER_HOME$/Downloads/hydro_cdr/hydro-cdr.csproj" />
<orderEntry type="sourceFolder" />
<orderEntry type="module-library">
<library>
<binaries>
<root url="netdll:///Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/Microsoft.CSharp.dll!/" />
</binaries>
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<binaries>
<root url="netdll:///Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/mscorlib.dll!/" />
</binaries>
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<binaries>
<root url="netdll:///Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Core.dll!/" />
</binaries>
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<binaries>
<root url="netdll:///Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Data.DataSetExtensions.dll!/" />
</binaries>
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<binaries>
<root url="netdll:///Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Data.dll!/" />
</binaries>
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<binaries>
<root url="netdll:///Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.dll!/" />
</binaries>
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<binaries>
<root url="netdll:///Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Xml.dll!/" />
</binaries>
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<binaries>
<root url="netdll:///Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Xml.Linq.dll!/" />
</binaries>
</library>
</orderEntry>
</module-layer>
</module>
</modules>
</component>
</project>

1031
.consulo/workspace.xml Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,36 @@
<Properties StartupConfiguration="{6166EEDD-31E3-44EB-978A-5EAF9C2992F9}|Default" BuildWithMSBuildOnMono="True">
<AuthorInfo Name="Doug Macintosh" Email="support@sommetconsulting.ca" Copyright="Sommet Consulting" Company="Sommet Consulting" Trademark="" />
<MultiItemStartupConfigurations />
<MonoDevelop.Ide.ItemProperties.cdrtool PreferredExecutionTarget="MonoDevelop.Default" />
<MonoDevelop.Ide.Workbench ActiveDocument="_Main.cs">
<Files>
<File FileName="License.cs" />
<File FileName="WebRoutines.cs" Line="469" Column="17" />
<File FileName="Web.cs" />
<File FileName="LicenseFile.cs" />
<File FileName="Gmail.cs" />
<File FileName="SSH.cs" Line="372" Column="2" />
<File FileName="_Main.cs" Line="526" Column="33" />
<File FileName="app.config" />
<File FileName="packages.config" />
</Files>
<Pads>
<Pad Id="ProjectPad">
<State name="__root__">
<Node name="cdrtool" expanded="True">
<Node name="cdrtool" expanded="True">
<Node name="Properties" expanded="True" />
<Node name="_Main.cs" selected="True" />
</Node>
</Node>
</State>
</Pad>
</Pads>
</MonoDevelop.Ide.Workbench>
<Debugger.DebugSourceFolders />
<MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" />
<MonoDevelop.Ide.DebuggingService.Breakpoints>
<BreakpointStore />
</MonoDevelop.Ide.DebuggingService.Breakpoints>
<MonoDevelop.Ide.DebuggingService.PinnedWatches />
</Properties>

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1 @@
{"Format":1,"ProjectReferences":[],"MetadataReferences":[{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/Microsoft.CSharp.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/mscorlib.dll","Aliases":[],"Framework":null},{"FilePath":"/Users/doug/Documents/Projects/cdrtool/Embedded/Newtonsoft.Json.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.ComponentModel.Composition.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.Configuration.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.Core.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.Data.DataSetExtensions.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.Data.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.IO.Compression.FileSystem.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.Numerics.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.Runtime.Serialization.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.Xaml.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.Xml.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.8-api/System.Xml.Linq.dll","Aliases":[],"Framework":null}],"Files":["/Users/doug/Documents/Projects/cdrtool/Arguments.cs","/Users/doug/Documents/Projects/cdrtool/Logger.cs","/Users/doug/Documents/Projects/cdrtool/Properties/AssemblyInfo.cs","/Users/doug/Documents/Projects/cdrtool/Web.cs","/Users/doug/Documents/Projects/cdrtool/WebRoutines.cs","/Users/doug/Documents/Projects/cdrtool/_Main.cs","/Users/doug/Documents/Projects/cdrtool/License.cs","/Users/doug/Documents/Projects/cdrtool/obj/Release/.NETFramework,Version=v4.8.AssemblyAttributes.cs","/Users/doug/Documents/Projects/cdrtool/app.config","/Users/doug/Documents/Projects/cdrtool/packages.config","/Users/doug/Documents/Projects/cdrtool/LicenseFile.cs","/Users/doug/Documents/Projects/cdrtool/Embedded/Newtonsoft.Json.dll"],"BuildActions":["Compile","Compile","Compile","Compile","Compile","Compile","Compile","Compile","None","None","None","EmbeddedResource"],"Analyzers":[],"AdditionalFiles":[],"EditorConfigFiles":[],"DefineConstants":["TRACE"],"IntermediateAssembly":"/Users/doug/Documents/Projects/cdrtool/obj/Release/cdr-tool.exe"}

View File

@@ -0,0 +1,28 @@
<Properties StartupConfiguration="{6166EEDD-31E3-44EB-978A-5EAF9C2992F9}|Default">
<MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" />
<MonoDevelop.Ide.DebuggingService.Breakpoints>
<BreakpointStore />
</MonoDevelop.Ide.DebuggingService.Breakpoints>
<MonoDevelop.Ide.Workbench ActiveDocument="WebRoutines.cs">
<Files>
<File FileName="_Main.cs" Line="38" Column="78" />
<File FileName="WebRoutines.cs" Line="325" Column="45" />
<File FileName="Web.cs" Line="138" Column="17" />
</Files>
<Pads>
<Pad Id="ProjectPad">
<State name="__root__">
<Node name="hydro-cdr" expanded="True">
<Node name="hydro-cdr" expanded="True">
<Node name="References" expanded="True" />
<Node name="Web.cs" selected="True" />
</Node>
</Node>
</State>
</Pad>
</Pads>
</MonoDevelop.Ide.Workbench>
<MonoDevelop.Ide.ItemProperties.hydro-cdr PreferredExecutionTarget="MonoDevelop.Default" />
<MonoDevelop.Ide.DebuggingService.PinnedWatches />
<MultiItemStartupConfigurations />
</Properties>

View File

@@ -0,0 +1 @@
{"Format":1,"ProjectReferences":[],"MetadataReferences":[{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/Microsoft.CSharp.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/mscorlib.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Core.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Data.DataSetExtensions.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Data.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Runtime.Serialization.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Xml.dll","Aliases":[],"Framework":null},{"FilePath":"/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/4.0-api/System.Xml.Linq.dll","Aliases":[],"Framework":null}],"Files":["/Users/doug/Documents/Projects/hydro_cdr/Arguments.cs","/Users/doug/Documents/Projects/hydro_cdr/Logger.cs","/Users/doug/Documents/Projects/hydro_cdr/Properties/AssemblyInfo.cs","/Users/doug/Documents/Projects/hydro_cdr/Web.cs","/Users/doug/Documents/Projects/hydro_cdr/WebRoutines.cs","/Users/doug/Documents/Projects/hydro_cdr/_Main.cs","/Users/doug/Documents/Projects/hydro_cdr/obj/Debug/.NETFramework,Version=v4.0.AssemblyAttributes.cs","/Users/doug/Documents/Projects/hydro_cdr/app.config"],"BuildActions":["Compile","Compile","Compile","Compile","Compile","Compile","Compile","None"],"Analyzers":[],"AdditionalFiles":[],"EditorConfigFiles":[],"DefineConstants":["DEBUG","TRACE"],"IntermediateAssembly":"/Users/doug/Documents/Projects/hydro_cdr/obj/Debug/cdr-tool.exe"}

7
1time.sh Executable file
View File

@@ -0,0 +1,7 @@
touch README.md
git init
git checkout -b main
git add README.md
git commit -m "first commit"
git remote add origin http://10.0.0.3:8418/gituser/cdrtool.git
git push -u origin main

292
Arguments.cs Normal file
View File

@@ -0,0 +1,292 @@
/*
* Created by SharpDevelop.
* User: User
* Date: 1/19/2012
* Time: 6:41 PM
Example Usage
There are two ways you can start using this class, I have created a SplitCommandLine function which ignores escaped quotes, this is needed for path support, the trailing \ on the path causes the quote to be taken literally.
Using SplitCommandLine:
var commandLine = Environment.CommandLine;
var splitCommandLine = Arguments.SplitCommandLine(commandLine);
var arguments = new Arguments(splitCommandLine);
Letting windows do it:
static int Main(string[] args)
{
_args = new Arguments(args);
}
Example Arguments
Argument: flag
Usage: args.IsTrue("flag");
Result: true
Argument: arg:MyValue
Usage: args.Single("arg");
Result: MyValue
Argument: arg "My Value"
Usage: args.Single("arg");
Result: My Value
Argument: /arg=Value /arg=Value2
Usage: args["arg"]
Result: new string[] {"Value", "Value2"}
Argument: /arg="Value,Value2"
Usage: args["arg"]
Result: new string[] {"Value", "Value2"}
As you can see it is very flexible, it support [/]arg[:=]value and with the list support it makes it really useful and adaptable.
*/
using System;
using System.Collections.ObjectModel;
using System.Collections.Generic;
//using System.Collections.Specialized;
using System.Text;
using System.Text.RegularExpressions;
namespace cdrtool
{
/// <summary>
/// Arguments class
/// Example Arguments
/// </summary>
public class Arguments
{
/// <summary>
/// Splits the command line. When main(string[] args) is used escaped quotes (ie a path "c:\folder\")
/// Will consume all the following command line arguments as the one argument.
/// This function ignores escaped quotes making handling paths much easier.
/// </summary>
/// <param name="commandLine">The command line.</param>
/// <returns></returns>
public static string[] SplitCommandLine(string commandLine)
{
var translatedArguments = new StringBuilder(commandLine);
var escaped = false;
for (var i = 0; i < translatedArguments.Length; i++)
{
if (translatedArguments[i] == '"')
{
escaped = !escaped;
}
if (translatedArguments[i] == ' ' && !escaped)
{
translatedArguments[i] = '\n';
}
}
var toReturn = translatedArguments.ToString().Split(new[] { '\n' }, StringSplitOptions.RemoveEmptyEntries);
for (var i = 0; i < toReturn.Length; i++)
{
toReturn[i] = RemoveMatchingQuotes(toReturn[i]);
}
return toReturn;
}
public static string RemoveMatchingQuotes(string stringToTrim)
{
var firstQuoteIndex = stringToTrim.IndexOf('"');
var lastQuoteIndex = stringToTrim.LastIndexOf('"');
while (firstQuoteIndex != lastQuoteIndex)
{
stringToTrim = stringToTrim.Remove(firstQuoteIndex, 1);
stringToTrim = stringToTrim.Remove(lastQuoteIndex - 1, 1); //-1 because we've shifted the indicies left by one
firstQuoteIndex = stringToTrim.IndexOf('"');
lastQuoteIndex = stringToTrim.LastIndexOf('"');
}
return stringToTrim;
}
private readonly Dictionary<string, Collection<string>> _parameters;
private string _waitingParameter;
public Arguments(IEnumerable<string> arguments) : this(arguments, false)
{
}
public Arguments(IEnumerable<string> arguments, bool ignoreCase)
{
//_parameters = new Dictionary<string, Collection<string>>();
Regex argumentSplitter;
if (ignoreCase)
{
//_parameters = new Dictionary<string, Collection<string>>(StringComparer.OrdinalIgnoreCase);
argumentSplitter = new Regex(@"^-{1,2}|^/|=", RegexOptions.Compiled);
_parameters = new Dictionary<string, Collection<string>>(StringComparer.Ordinal);
}
else
{
//_parameters = new Dictionary<string, Collection<string>>();
//Regex argumentSplitter = new Regex(@"^-{1}|^/", RegexOptions.IgnoreCase | RegexOptions.Compiled);
argumentSplitter = new Regex(@"^-{1,2}|^/|=", RegexOptions.IgnoreCase | RegexOptions.Compiled);
_parameters = new Dictionary<string, Collection<string>>(StringComparer.InvariantCultureIgnoreCase);
}
string[] parts;
//Splits on beginning of arguments ( - and -- and / )
//And on assignment operators ( = and : )
//Regex argumentSplitter = new Regex(@"^-{1,2}|^/|=|:",RegexOptions.IgnoreCase | RegexOptions.Compiled);
foreach (string argument in arguments)
{
parts = argumentSplitter.Split(argument, 3);
switch (parts.Length)
{
case 1:
AddValueToWaitingArgument(parts[0]);
break;
case 2:
AddWaitingArgumentAsFlag();
//Because of the split index 0 will be a empty string
_waitingParameter = parts[1];
break;
case 3:
AddWaitingArgumentAsFlag();
//Because of the split index 0 will be a empty string
string valuesWithoutQuotes = RemoveMatchingQuotes(parts[2]);
AddListValues(parts[1], valuesWithoutQuotes.Split(','));
break;
}
}
AddWaitingArgumentAsFlag();
}
private void AddListValues(string argument, IEnumerable<string> values)
{
foreach (var listValue in values)
{
Add(argument, listValue);
}
}
private void AddWaitingArgumentAsFlag()
{
if (_waitingParameter == null) return;
AddSingle(_waitingParameter, "true");
_waitingParameter = null;
}
private void AddValueToWaitingArgument(string value)
{
if (_waitingParameter == null) return;
value = RemoveMatchingQuotes(value);
Add(_waitingParameter, value);
_waitingParameter = null;
}
/// <summary>
/// Gets the count.
/// </summary>
/// <value>The count.</value>
public int Count
{
get
{
return _parameters.Count;
}
}
/// <summary>
/// Adds the specified argument.
/// </summary>
/// <param name="argument">The argument.</param>
/// <param name="value">The value.</param>
public void Add(string argument, string value)
{
if (!_parameters.ContainsKey(argument))
_parameters.Add(argument, new Collection<string>());
_parameters[argument].Add(value);
}
public void AddSingle(string argument, string value)
{
if (!_parameters.ContainsKey(argument))
_parameters.Add(argument, new Collection<string>());
else
throw new ArgumentException(string.Format("Argument {0} has already been defined", argument));
_parameters[argument].Add(value);
}
public void Remove(string argument)
{
if (_parameters.ContainsKey(argument))
_parameters.Remove(argument);
}
/// <summary>
/// Determines whether the specified argument is true.
/// </summary>
/// <param name="argument">The argument.</param>
/// <returns>
/// <c>true</c> if the specified argument is true; otherwise, <c>false</c>.
/// </returns>
public bool IsTrue(string argument)
{
AssertSingle(argument);
var arg = this[argument];
return arg != null && arg[0].Equals("true", StringComparison.OrdinalIgnoreCase);
}
private void AssertSingle(string argument)
{
if (this[argument] != null && this[argument].Count > 1)
throw new ArgumentException(string.Format("{0} has been specified more than once, expecting single value", argument));
}
public string Single(string argument)
{
AssertSingle(argument);
//only return value if its NOT true, there is only a single item for that argument
//and the argument is defined
if (this[argument] != null && !IsTrue(argument))
return this[argument][0];
return null;
}
public bool Exists(string argument)
{
return (this[argument] != null && this[argument].Count > 0);
}
/// <summary>
/// Gets the <see cref="System.Collections.ObjectModel.Collection&lt;T&gt;"/> with the specified parameter.
/// </summary>
/// <value></value>
public Collection<string> this[string parameter]
{
get
{
return _parameters.ContainsKey(parameter) ? _parameters[parameter] : null;
}
}
}
}

Binary file not shown.

BIN
Embedded/Google.Apis.Auth.dll Executable file

Binary file not shown.

BIN
Embedded/Google.Apis.Core.dll Executable file

Binary file not shown.

BIN
Embedded/Google.Apis.Gmail.v1.dll Executable file

Binary file not shown.

BIN
Embedded/Google.Apis.dll Executable file

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
Embedded/Newtonsoft.Json.dll Executable file

Binary file not shown.

BIN
Embedded/Renci.SshNet.dll Executable file

Binary file not shown.

BIN
Embedded/System.Buffers.dll Executable file

Binary file not shown.

BIN
Embedded/System.CodeDom.dll Executable file

Binary file not shown.

Binary file not shown.

BIN
Embedded/System.Formats.Asn1.dll Executable file

Binary file not shown.

BIN
Embedded/System.Memory.dll Executable file

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
Embedded/System.ValueTuple.dll Executable file

Binary file not shown.

159
Gmail.cs Normal file
View File

@@ -0,0 +1,159 @@
using System;
using Google.Apis.Auth.OAuth2;
using Google.Apis.Gmail.v1;
using Google.Apis.Gmail.v1.Data;
using Google.Apis.Services;
using Google.Apis.Util.Store;
using System.Collections.Generic;
using System.IO;
using System.Threading;
using System.Threading.Tasks;
using System.Linq;
using System.Text.RegularExpressions;
using System.Runtime.Remoting.Messaging;
namespace cdrtool
{
class Gmail
{
static string[] Scopes = { GmailService.Scope.GmailReadonly };
static string ApplicationName = "Gmail API .NET Quickstart";
public static async Task<string> GetMail()
{
UserCredential credential;
string mfa_code = "";
using (var stream = new FileStream("credentials.json", FileMode.Open, FileAccess.Read))
{
string credPath = "token.json";
credential = await GoogleWebAuthorizationBroker.AuthorizeAsync(
GoogleClientSecrets.FromStream(stream).Secrets,
Scopes,
"user",
CancellationToken.None,
new FileDataStore(credPath, true));
//Console.WriteLine("Credential file saved to: " + credPath);
}
// Create Gmail API service.
var service = new GmailService(new BaseClientService.Initializer()
{
HttpClientInitializer = credential,
ApplicationName = ApplicationName,
});
// Define the timestamp after which we want to find emails (in Unix time format).
DateTime afterTimestamp = new DateTime(2024, 01, 01); // Use this when you cannot generate a new mfs email to test with
afterTimestamp = DateTime.Now; // We do this to ensure we get the latest auth email, usually 2-3 seconds after this fires
long afterUnixTimestamp = ((DateTimeOffset)afterTimestamp).ToUnixTimeSeconds();
Logger.Log(1,"Awaiting MFA email (max {0}s)", cdrtool.mfa_delay);
bool repeat = false;
int count = cdrtool.mfa_delay;
do
{
// Fetch emails received after the given timestamp
var request = service.Users.Messages.List("me");
request.Q = $"after:{afterUnixTimestamp} from:\"Rogers SIP Portal\" "; //refinement added Sep16 2024
ListMessagesResponse response = await request.ExecuteAsync();
var messages = response.Messages?.OrderByDescending(m => m.InternalDate).ToList();
repeat = (messages == null);
//Console.WriteLine("Messages count: {0}", (messages != null) ? messages.Count : 0 );
if (messages != null && messages.Any())
{
//Console.WriteLine("Messages count: {0}",messages.Count);
var mostRecentMessage = messages.First();
Message message = await service.Users.Messages.Get("me", mostRecentMessage.Id).ExecuteAsync();
try
{
Regex word = new Regex(@".*Your Portal.+([0-9]{6})"); // MFA looking for 6 digit code //refinement added Sep16 2024
Match m = word.Match(message.Snippet); // .Snippet easily grabs enough plain text to find the MFA code
if (m.Success)
{
Group g = m.Groups[1];
//Capture c = g.Captures[0];
Logger.Log(6, "Regex Match {0} / Group Count {1} / Captures Count {2} / result={3}", m.Success, m.Groups.Count, m.Captures.Count, g.Value);
int code = Convert.ToInt32(g.Value);
if ((code >= 0) && (code <= 999999))
Logger.Log(5, "Code found successfully {0}", code);
mfa_code = g.Value;
repeat = false;
}
else
{
Logger.Log(1, "No code found in email.");
}
}
catch (Exception e)
{
Logger.Log(0, "Error parsing Gmail. {0}", e.Message);
}
}
else
{
int incr = 1;
if (count <= (cdrtool.mfa_delay - 5) ) incr = 5;
count-= incr;
System.Threading.Thread.Sleep(1000 * incr);
Logger.Log(1, "No message found for {0}s", cdrtool.mfa_delay - count);
}
}
while (repeat && (count > 0) );
Logger.Log(0, "Emailed MFA Code : {0}", mfa_code);
return mfa_code;
}
static string GetPlainTextFromMessageParts(IList<MessagePart> parts)
{
if (parts == null)
return string.Empty;
foreach (var part in parts)
{
//Console.WriteLine("email: type:{0}\nbody:\n{1}", part.MimeType, part.Body.Data);
if (part.MimeType == "text/plain" && part.Body != null && part.Body.Data != null)
{
return Base64UrlDecode(part.Body.Data);
}
else if (part.Parts != null)
{
string text = GetPlainTextFromMessageParts(part.Parts);
if (!string.IsNullOrEmpty(text))
return text;
}
}
return string.Empty;
}
static string Base64UrlDecode(string input)
{
string s = input.Replace('-', '+').Replace('_', '/');
switch (s.Length % 4)
{
case 2: s += "=="; break;
case 3: s += "="; break;
}
var bytes = Convert.FromBase64String(s);
return System.Text.Encoding.UTF8.GetString(bytes);
}
}
}

86
License.cs Normal file
View File

@@ -0,0 +1,86 @@
/*
* Created by SharpDevelop.
* User: Doug.Macintosh
* Date: 2023-02-05
* Time: 9:52 AM
*
* To change this template use Tools | Options | Coding | Edit Standard Headers.
*/
using System;
using System.Collections.Generic;
using System.IO;
using System.IO.Compression;
using System.Runtime.ConstrainedExecution;
using System.Security.Cryptography;
using System.Text;
using Newtonsoft.Json;
namespace cdrtool
{
class License
{
public static string validate(string filename)
{
string license;
if ( (!File.Exists(filename)) || ( new FileInfo(filename).Length == 0))
throw new FileNotFoundException("License file missing or corrupt.");
if (cdrtool.company.Length < 6)
throw new InvalidDataException("User account missing or corrupt.");
try
{
license = License.getLicense(filename, makeHash(cdrtool.company + cdrtool.product + cdrtool.version.Substring(0, 3)).Substring(0, 32));
Logger.Log(5, "Decrypted License Key: {0}", license);
}
catch (Exception)
{
throw new InvalidDataException("Unable to decrypt license file, please contact Support.");
}
return license;
}
private static string getLicense(string filename, string secretKey)
{
return Decrypt(File.ReadAllText(filename), secretKey);
}
private static string Decrypt(string encryptedText, string secretKey)
{
byte[] encryptedTextBytes = Convert.FromBase64String(encryptedText);
using (Aes aes = Aes.Create())
{
aes.Key = Encoding.UTF8.GetBytes(secretKey);
byte[] iv = new byte[aes.BlockSize / 8];
byte[] encrypted = new byte[encryptedTextBytes.Length - iv.Length];
Array.Copy(encryptedTextBytes, 0, iv, 0, iv.Length);
Array.Copy(encryptedTextBytes, iv.Length, encrypted, 0, encrypted.Length);
aes.IV = iv;
using (ICryptoTransform decryptor = aes.CreateDecryptor(aes.Key, aes.IV))
{
byte[] decryptedBytes = decryptor.TransformFinalBlock(encrypted, 0, encrypted.Length);
return Encoding.UTF8.GetString(decryptedBytes);
}
}
}
private static string makeHash(string InputString)
{
using (SHA256 sha256Hash = SHA256.Create())
{
byte[] bytes = sha256Hash.ComputeHash(System.Text.Encoding.UTF8.GetBytes(InputString));
return Convert.ToBase64String(bytes);
}
}
}
}

159
LicenseFile.cs Normal file
View File

@@ -0,0 +1,159 @@
#define PROD_
/*
* Created by SharpDevelop.
* User: Doug.Macintosh
* Date: 2023-02-05
* Time: 9:52 AM
*
* To change this template use Tools | Options | Coding | Edit Standard Headers.
*/
using System;
using System.Collections.Generic;
using System.IO;
using System.IO.Compression;
using System.Runtime.ConstrainedExecution;
using System.Security.Cryptography;
using System.Text;
using Newtonsoft.Json;
namespace cdrtool
{
class LicenseFile
{
private class Lic
{
public string Company { get; set; }
public string Product { get; set; }
public string Version { get; set; }
public string Type { get; set; }
public string ValidTo { get; set; }
public bool Perpetual { get; set; }
}
#if !PROD_
//LicenseFile.makeLicenseFile(licfile, "Support", 5, false);
public static void makeLicenseFile(string filename, string lictype, int licyears, bool eoy)
{
string secretKey;
string KeyExpiration;
if (eoy)
{
//KeyExpiration = String.Format("{0}-12-31", DateTime.Now.Year + licyears - 1);
//KeyExpiration = String.Format("{0}-12-31", DateTime.Now.Year); // MFA beta 1
KeyExpiration = String.Format("2030-12-31"); // MFA beta 1
}
else
{
KeyExpiration = DateTime.Now.AddYears(licyears).ToString("yyyy-MM-dd");
}
cdrtool.company = "Hydro Ottawa Limited 4596";
Lic mylicense = new Lic
{
Company = cdrtool.company,
Product = cdrtool.product,
Version = cdrtool.version.Substring(0, 3),
Type = lictype,
ValidTo = KeyExpiration,
Perpetual = (licyears >= 5)
//Perpetual = true
};
Console.WriteLine("c:{0} p:{1} v:{2}", cdrtool.company, cdrtool.product, cdrtool.version);
secretKey = _makeHash(cdrtool.company + cdrtool.product + cdrtool.version.Substring(0, 3)).Substring(0, 32);
Console.WriteLine("sk:{0}", secretKey);
string clearText = JsonConvert.SerializeObject(mylicense, Formatting.Indented);
Console.WriteLine(clearText);
string encryptedKey = Encrypt(clearText, secretKey);
File.WriteAllText(filename, encryptedKey);
}
private static string Encrypt(string clearText, string secretKey)
{
byte[] clearTextBytes = Encoding.UTF8.GetBytes(clearText);
using (Aes aes = Aes.Create())
{
aes.Key = Encoding.UTF8.GetBytes(secretKey);
aes.GenerateIV();
using (ICryptoTransform encryptor = aes.CreateEncryptor(aes.Key, aes.IV))
{
byte[] encryptedBytes = encryptor.TransformFinalBlock(clearTextBytes, 0, clearTextBytes.Length);
byte[] combinedBytes = new byte[aes.IV.Length + encryptedBytes.Length];
aes.IV.CopyTo(combinedBytes, 0);
encryptedBytes.CopyTo(combinedBytes, aes.IV.Length);
return Convert.ToBase64String(combinedBytes);
}
}
}
#endif
public static string validate(string filename)
{
string license;
if ((!File.Exists(filename)) || (new FileInfo(filename).Length == 0))
throw new FileNotFoundException("License file missing or corrupt.");
if (cdrtool.company.Length < 6)
throw new InvalidDataException("User account missing or corrupt.");
try
{
license = _getLicense(filename, _makeHash(cdrtool.company + cdrtool.product + cdrtool.version.Substring(0, 3)).Substring(0, 32));
Logger.Log(5, "Decrypted License Key: {0}", license);
}
catch (Exception)
{
throw new InvalidDataException("Unable to decrypt license file, please contact Support.");
}
return license;
}
private static string _getLicense(string filename, string secretKey)
{
return _Decrypt(File.ReadAllText(filename), secretKey);
}
private static string _Decrypt(string encryptedText, string secretKey)
{
byte[] encryptedTextBytes = Convert.FromBase64String(encryptedText);
using (Aes aes = Aes.Create())
{
aes.Key = Encoding.UTF8.GetBytes(secretKey);
byte[] iv = new byte[aes.BlockSize / 8];
byte[] encrypted = new byte[encryptedTextBytes.Length - iv.Length];
Array.Copy(encryptedTextBytes, 0, iv, 0, iv.Length);
Array.Copy(encryptedTextBytes, iv.Length, encrypted, 0, encrypted.Length);
aes.IV = iv;
using (ICryptoTransform decryptor = aes.CreateDecryptor(aes.Key, aes.IV))
{
byte[] decryptedBytes = decryptor.TransformFinalBlock(encrypted, 0, encrypted.Length);
return Encoding.UTF8.GetString(decryptedBytes);
}
}
}
private static string _makeHash(string InputString)
{
using (SHA256 sha256Hash = SHA256.Create())
{
byte[] bytes = sha256Hash.ComputeHash(System.Text.Encoding.UTF8.GetBytes(InputString));
return Convert.ToBase64String(bytes);
}
}
}
}

86
Logger.cs Normal file
View File

@@ -0,0 +1,86 @@
namespace cdrtool
{
using System;
using System.Text;
internal static class Logger
{
public static void Log(uint level, string format, params object[] objs)
{
StringBuilder sb = new StringBuilder();
sb.AppendFormat("[{0}] ", DateTime.Now);
sb.AppendFormat(format, objs);
if (level <= cdrtool.debug )
{
Console.WriteLine(sb.ToString());
cdrtool.outfile.WriteLine(sb.ToString());
}
if (level <= cdrtool.adlvl )
{
cdrtool.adminLog.AppendLine(sb.ToString());
}
}
public static void Log(uint level, string format, string s1, string s2)
{
StringBuilder sb = new StringBuilder();
sb.AppendFormat("[{0}] ", DateTime.Now);
sb.AppendFormat(format, s1, s2);
if (level <= cdrtool.debug )
{
Console.WriteLine(sb.ToString());
cdrtool.outfile.WriteLine(sb.ToString());
}
if (level <= cdrtool.adlvl )
{
cdrtool.adminLog.AppendLine(sb.ToString());
}
}
public static void Log(uint level, string format, string s1)
{
StringBuilder sb = new StringBuilder();
sb.AppendFormat("[{0}] ", DateTime.Now);
sb.AppendFormat(format, s1);
if (level <= cdrtool.debug )
{
Console.WriteLine(sb.ToString());
cdrtool.outfile.WriteLine(sb.ToString());
}
if (level <= cdrtool.adlvl )
{
cdrtool.adminLog.AppendLine(sb.ToString());
}
}
public static void Log(uint level, string message)
{
StringBuilder sb = new StringBuilder();
sb.AppendFormat("[{0}] {1}", DateTime.Now, message);
if (level <= cdrtool.debug )
{
Console.WriteLine(sb.ToString());
cdrtool.outfile.WriteLine(sb.ToString());
}
if (level <= cdrtool.adlvl )
{
cdrtool.adminLog.AppendLine(sb.ToString());
}
}
public static void Log(string message)
{
StringBuilder sb = new StringBuilder();
sb.AppendFormat("[{0}] {1}", DateTime.Now, message);
Console.WriteLine(sb.ToString());
cdrtool.outfile.WriteLine(sb.ToString());
cdrtool.adminLog.AppendLine(sb.ToString());
}
}
}

View File

@@ -0,0 +1,31 @@
#region Using directives
using System;
using System.Reflection;
using System.Runtime.InteropServices;
#endregion
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("CDR-Tool")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Sommet Consulting Inc.")]
[assembly: AssemblyProduct("CDR Tool")]
[assembly: AssemblyCopyright("Copyright 2022-26")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// This sets the default COM visibility of types in the assembly to invisible.
// If you need to expose a type to COM, use [ComVisible(true)] on that type.
[assembly: ComVisible(false)]
// The assembly version has following format :
//
// Major.Minor.Build.Revision
//
// You can specify all the values or you can use the default the Revision and
// Build Numbers by using the '*' as shown below:
[assembly: AssemblyVersion("1.6.*")]

372
SSH.cs Normal file
View File

@@ -0,0 +1,372 @@
using System;
using System.IO;
using System.Threading;
using Renci.SshNet;
namespace cdrtool
{
public class sftp
{
private static SftpClient CreateClient(
string host,
int port,
string username,
string password)
{
var client = new SftpClient(host, port, username, password);
client.ConnectionInfo.Timeout = System.TimeSpan.FromSeconds(15);
client.OperationTimeout = System.TimeSpan.FromSeconds(30);
client.KeepAliveInterval = System.TimeSpan.FromSeconds(10);
return client;
}
public static Renci.SshNet.ConnectionInfo BuildConnectionInfo(
string host,
int port,
string username,
string password,
Renci.SshNet.PrivateKeyFile privateKeyFile = null)
{
var auth = new System.Collections.Generic.List<Renci.SshNet.AuthenticationMethod>();
if (privateKeyFile != null)
auth.Add(new Renci.SshNet.PrivateKeyAuthenticationMethod(username, privateKeyFile));
if (!string.IsNullOrEmpty(password))
{
var kb = new Renci.SshNet.KeyboardInteractiveAuthenticationMethod(username);
kb.AuthenticationPrompt += (s, e) =>
{
foreach (var p in e.Prompts)
p.Response = password;
};
auth.Add(kb);
auth.Add(new Renci.SshNet.PasswordAuthenticationMethod(username, password));
}
return new Renci.SshNet.ConnectionInfo(host, port, username, auth.ToArray())
{
Timeout = System.TimeSpan.FromSeconds(30),
RetryAttempts = 1
};
}
/*
public static bool ConnectWithRetries(
Renci.SshNet.ConnectionInfo info,
int maxAttempts,
int timeoutSeconds)
{
for (int i = 0; i < maxAttempts; i++)
{
if (TrySftpConnectWithHardTimeout(info, timeoutSeconds))
return true;
System.Threading.Thread.Sleep(5000);
}
return false;
}
*/
public static Renci.SshNet.SftpClient TrySftpConnectWithHardTimeout(
Renci.SshNet.ConnectionInfo connectionInfo,
int maxAttempts,
int timeoutSeconds)
{
for (int i = 0; i < maxAttempts; i++)
{
Renci.SshNet.SftpClient client = null;
try
{
var task = System.Threading.Tasks.Task.Run(() =>
{
client = new Renci.SshNet.SftpClient(connectionInfo);
// These are still useful, but not sufficient alone
client.ConnectionInfo.Timeout =
System.TimeSpan.FromSeconds(30);
client.KeepAliveInterval =
System.TimeSpan.FromSeconds(15);
client.Connect();
});
bool completed =
task.Wait(System.TimeSpan.FromSeconds(timeoutSeconds));
if (!completed)
{
// HARD TIMEOUT
try
{
client?.Dispose();
}
catch { }
//return null;
}
else
{
return client;
}
}
catch
{
try
{
client?.Dispose();
}
catch { }
//return null;
}
System.Threading.Thread.Sleep(5000);
}
return null;
}
public static void Upload_stream(MemoryStream ms, string filename, string host, int port, string username, string password)
{
int maxAttempts = 5;
int timeout = 120; //seconds
try
{
//using (var sftpClient = CreateClient(host, port, username, password))
var sftpInfo = BuildConnectionInfo(host, port, username, password);
Renci.SshNet.SftpClient sftpClient = null;
try
{
sftpClient = TrySftpConnectWithHardTimeout(sftpInfo, maxAttempts, timeout);
}
catch (Renci.SshNet.Common.SshConnectionException e)
{
Logger.Log(1, " connection exception ({0}) : {1}", "", e.Message);
}
if ( sftpClient == null)
{
Logger.Log(1, " null connection exception. Transfer failed.");
return;
}
try
{
sftpClient.UploadFile(
ms,
filename,
uploaded =>
{
Logger.Log(5, $"Uploaded {(double)uploaded / ms.Length * 100}% of the file.");
});
}
catch (Renci.SshNet.Common.SshException e)
{
Logger.Log(0, " SSH upload Exception {0}:{1}", e.Message, e.InnerException.Message);
}
Logger.Log(1, " -- uploaded: {0} ({3}KB) to {1}:{2}", filename, host, port, (ms.Length / 1024));
sftpClient.Disconnect();
Logger.Log(" SSH Disconnected");
try
{
sftpClient?.Dispose();
}
catch { }
return; // success
}
catch (Exception e)
{
Logger.Log(0, "SFTP exception {0}:{1}", e.Message, e.InnerException.Message);
}
}
public static void Upload_stream_linear(MemoryStream ms, string filename, string host, int port, string username, string password)
{
int attempts = 0;
int maxAttempts = 5;
while (true)
{
try
{
using (var sftpClient = CreateClient(host, port, username, password))
{
attempts++;
try
{
sftpClient.Connect();
}
catch (Renci.SshNet.Common.SshConnectionException e)
{
Logger.Log(1, " connection exception ({0}) : {1}", attempts, e.Message);
}
//------------
if (!sftpClient.IsConnected)
{
Logger.Log(1, " connection failure {0}", attempts);
if (attempts < 10) { Thread.Sleep(TimeSpan.FromSeconds(5)); continue; } else { break; };
}
try
{
sftpClient.UploadFile(
ms,
filename,
uploaded =>
{
Logger.Log(5, $"Uploaded {(double)uploaded / ms.Length * 100}% of the file.");
});
}
catch (Renci.SshNet.Common.SshException e)
{
Logger.Log(0, " SSH upload Exception {0}:{1}", e.Message, e.InnerException.Message);
}
Logger.Log(1, " -- uploaded: {0} ({3}KB) to {1}:{2}", filename, host, port, (ms.Length / 1024));
sftpClient.Disconnect();
Logger.Log(" SSH Disconnected");
return; // success
}
}
catch (Exception e)
{
Logger.Log(0, "SFTP exception {0}:{1}", e.Message, e.InnerException.Message);
}
attempts++;
if (attempts >= maxAttempts)
{
Logger.Log(0, ("Failed to Connect after 10 attempts."));
return;
}
Logger.Log(1, " ...retrying ({0})", attempts);
Thread.Sleep(TimeSpan.FromSeconds(5));
} // end of while true/do forever
}
public static void Upload_stream_old( MemoryStream ms, string filename, string host, int port, string username, string password)
{
try
{
using (var sftpClient = new SftpClient(host, port, username, password))
//using (var fs = new FileStream(fileToUpload, FileMode.Open))
{
sftpClient.OperationTimeout = TimeSpan.FromSeconds(30);
sftpClient.ConnectionInfo.Timeout = TimeSpan.FromSeconds(30);
int attempts = 0;
do
{
attempts++;
try
{
sftpClient.Connect();
}
catch (Renci.SshNet.Common.SshConnectionException e)
{
Logger.Log(1," retrying ({0}) : {1}",attempts, e.Message);
Thread.Sleep(TimeSpan.FromSeconds(5));
}
}
while (attempts < 10 && !sftpClient.IsConnected);
if (attempts >= 10)
{
throw new Exception("Failed to Connect after 10 attempts.");
}
else
{
Logger.Log(" SSH Connected");
try
{
sftpClient.UploadFile(
ms,
filename,
uploaded =>
{
Logger.Log(5, $"Uploaded {(double)uploaded / ms.Length * 100}% of the file.");
});
}
catch (Renci.SshNet.Common.SshException e)
{
Logger.Log(0, " SSH upload Exception {0}:{1}", e.Message, e.InnerException.Message);
}
Logger.Log(" SSH Disconnected");
sftpClient.Disconnect();
}
}
Logger.Log(1, " -- uploaded: {0} ({3}KB) to {1}:{2}", filename, host, port, ( ms.Length/1024) );
}
catch (Exception e)
{
Logger.Log(e.Message);
}
}
public static void Upload_file(string fileToUpload, string host, int port, string username, string password)
{
try
{
using (var sftpClient = new SftpClient(host, port, username, password))
using (var fs = new FileStream(fileToUpload, FileMode.Open))
{
sftpClient.OperationTimeout = TimeSpan.FromSeconds(30);
int attempts = 0;
do
{
try
{
attempts += 1;
sftpClient.Connect();
}
catch (Renci.SshNet.Common.SshConnectionException e)
{
Logger.Log(1, " retrying in 5s ({0}) : {1}", attempts, e.Message);
Thread.Sleep(TimeSpan.FromSeconds(5));
}
} while (attempts < 10 && !sftpClient.IsConnected);
Logger.Log(" SSH Connected");
try
{
sftpClient.UploadFile(
fs,
"/Doug/" + Path.GetFileName(fileToUpload),
uploaded =>
{
Logger.Log(5,$"Uploaded {(double)uploaded / fs.Length * 100}% of the file.");
});
}
catch (Renci.SshNet.Common.SshException e)
{
Logger.Log(0, " SSH Exception {0}:{1}", e.Message, e.InnerException.Message);
}
sftpClient.Disconnect();
}
Logger.Log(1," uploaded: {0}", fileToUpload);
}
catch (Exception e)
{
Console.WriteLine(e.Message);
}
}
}
}

458
Web.cs Normal file
View File

@@ -0,0 +1,458 @@
/*
* Created by SharpDevelop.
* User: dmacinto
* Date: 10/05/11
* Time: 3:04 PM
*
* To change this template use Tools | Options | Coding | Edit Standard Headers.
*/
using System;
using System.Collections.Generic;
using System.Net;
using System.IO;
using System.Text;
using System.Text.RegularExpressions;
using System.Configuration;
using System.Security.Cryptography.X509Certificates;
using System.Net.Security;
//using Newtonsoft.Json;
namespace cdrtool
{
/// <summary>
/// Provides wrapper around HttpWebRequest, handling 302 redir, binary and certificate issues
/// </summary>
public class Web
{
public Web()
{
}
//Login1 (used to acquire token for auth)
public static bool MakeRequest(string method, string uri, bool json, ref string token, ref byte[] webdata, ref CookieContainer cookie)
{
bool redir = true;
string vars = "";
//string token = cdrtool.token;
WebProxy proxy = null;
return MakeByteRequest(method, redir, uri, vars, ref webdata, json, ref token, ref cookie, proxy);
}
// as above but with RO token option
public static bool MakeRequest(string method, string uri, bool json, string token, ref byte[] webdata, ref CookieContainer cookie)
{
bool redir = true;
string vars = "";
WebProxy proxy = null;
return MakeByteRequest(method, redir, uri, vars, ref webdata, json, ref token, ref cookie, proxy);
}
//Login2
public static bool MakeRequest(string method, string uri, string vars, bool json, ref byte[] webdata, ref CookieContainer cookie)
{
bool redir = true;
string token = cdrtool.token;
WebProxy proxy = null;
return MakeByteRequest(method, redir, uri, vars, ref webdata, json, ref token, ref cookie, proxy);
}
//as above with RO token
public static bool MakeRequest(string method, string uri, string vars, bool json, string token, ref byte[] webdata, ref CookieContainer cookie)
{
bool redir = true;
WebProxy proxy = null;
return MakeByteRequest(method, redir, uri, vars, ref webdata, json, ref token, ref cookie, proxy);
}
/* public static bool MakeRequest(string method, string uri, ref byte[] webdata, ref CookieContainer cookie )
{
//byte[] webdata = null;
bool redir = true;
string vars = "";
string token = cdrtool.token;
bool json = (token != "");
WebProxy proxy = null;
bool success = MakeByteRequest(method, redir, uri, vars, ref webdata, json, token, ref cookie, proxy);
//string respstr = "";
//if (webdata != null) { respstr = Encoding.ASCII.GetString(webdata); }
return success;
}
*/
// old school object call
public static object[] MakeRequest(string method, bool redir, string uri, string vars, ref CookieContainer cookie, WebProxy proxy)
{
byte[] webdata = null;
string token = cdrtool.token;
bool json = true;
bool success = MakeByteRequest( method, redir, uri, vars, ref webdata, json, ref token, ref cookie, proxy);
string respstr = "";
if ( webdata != null ) { respstr = Encoding.ASCII.GetString(webdata); }
//Console.WriteLine("{0}",respstr);
return new object[]{ success, respstr };
}
/* public static object[] MakeRequest(string method, bool redir, string uri, string vars, ref CookieContainer cookie, WebProxy proxy)
{
object[] r = MakeByteRequest(method, redir, uri, vars, ref cookie, proxy);
string respstr = "";
if ((byte[])r[1] != null) { respstr = Encoding.ASCII.GetString((byte[])r[1]); }
return new object[] { r[0], respstr };
}
*/
// full feature set call
public static bool MakeByteRequest(string method, bool redir, string uri, string vars, ref byte[] data, bool json, ref string token, ref CookieContainer cookie, WebProxy proxy)
{
bool success = false;
HttpWebRequest webRequest = null;
// Consider setting webRequest.KeepAlive = false; for the logout call to shut down the TCP resources.
// Set the 'Timeout' property in Milliseconds.
//webRequest.Timeout = 1000 * 60 * 3; // 3min
if (method == "GET")
{
webRequest = (HttpWebRequest)WebRequest.Create(string.Format("{0}{1}", uri, vars));
webRequest.Method = "GET";
webRequest.UserAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.93 Safari/537.36 OPR/76.0.4017.123";
if (token != "")
{
webRequest.PreAuthenticate = true;
webRequest.Headers.Add("Authorization", "Bearer " + token);
//webRequest.Headers.Add("Origin", uri); //Feb2023
}
if (json)
{
webRequest.Accept = "application/json";
}
webRequest.AllowAutoRedirect = redir;
webRequest.Method = method;
webRequest.CookieContainer = cookie;
//webRequest.Timeout = 180000; // 3min
webRequest.Timeout = cdrtool.webMaxWait * 60 * 1000; // convert minutes of wait into milliseconds
if (proxy != null)
{
webRequest.Proxy = proxy;
}
}
else if (method == "POST")
{
byte[] buffer = Encoding.ASCII.GetBytes(vars);
webRequest = (HttpWebRequest)WebRequest.Create(uri);
if (proxy != null)
{
webRequest.Proxy = proxy;
}
webRequest.Method = "POST";
webRequest.UserAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.93 Safari/537.36 OPR/76.0.4017.123";
if (token != "") // basically is this a JSON request
{
webRequest.PreAuthenticate = true;
webRequest.Headers.Add("Authorization", "Bearer " + token);
}
if (json)
{
webRequest.Accept = "application/json";
webRequest.ContentType = "application/json";
}
else
{
webRequest.ContentType = "application/x-www-form-urlencoded";
}
webRequest.ContentLength = buffer.Length;
webRequest.AllowAutoRedirect = redir;
webRequest.Method = method;
webRequest.CookieContainer = cookie;
webRequest.Timeout = cdrtool.webMaxWait * 60 * 1000; // convert minutes of wait into milliseconds
if (proxy != null)
{
webRequest.Proxy = proxy;
}
//We open a stream for writing the postvars
Stream PostData = webRequest.GetRequestStream();
//Now we write, and afterwards, we close. Closing is always important!
PostData.Write(buffer, 0, buffer.Length);
PostData.Close();
}
else
{
Logger.Log("Request not understood");
Logger.Log(3,"FAIL - UNKNOWN METHOD" );
return false;
}
// allows for validation of SSL conversations
ServicePointManager.ServerCertificateValidationCallback += new RemoteCertificateValidationCallback(
ValidateRemoteCertificate
);
HttpWebResponse response = null;
try
{
//ServicePointManager.SecurityProtocol = (SecurityProtocolType)3072 | (SecurityProtocolType)768 | (SecurityProtocolType)192; //3072
//ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls | System.Net.SecurityProtocolType.Tls11 | System.Net.SecurityProtocolType.Tls12;
response = (HttpWebResponse)webRequest.GetResponse();
//Let's show some information about the response
Logger.Log(6, "{0}", response.StatusCode);
Logger.Log(6, "{0}", response.GetResponseHeader("error"));
foreach (Cookie cook in response.Cookies)
{
cookie.Add(cook);
}
//DumpCookies(response.Cookies);
if ((response.StatusCode == HttpStatusCode.Found) ||
(response.StatusCode == HttpStatusCode.OK))
{
success = true;
}
using (Stream s = response.GetResponseStream())
{
//byte[] data = ReadStreamFully(s);
data = ReadStreamFully(s);
s.Close();
//System.IO.StreamWriter file = new System.IO.StreamWriter("webcs.txt"); file.BaseStream.Write(data,0,data.Length); file.Close();
//object[] ret = { success, Encoding.ASCII.GetString(data) , data };
//object[] ret = { success, data };
//return true;
}
return success;
}
catch (Exception ex)
{
Logger.Log(0, "WebRequest error: {0}", ex.Message);
//object[] ret = { false, null };
return false;
}
finally
{
if (response != null)
response.Close();
}
}
/*
public static object[] zMakeByteRequest(string method, bool redir, string uri, string vars, ref CookieContainer cookie, WebProxy proxy)
{
bool success = false;
HttpWebRequest webRequest = null;
// Set the 'Timeout' property in Milliseconds.
//webRequest.Timeout = 1000 * 60 * 3; // 3min
if ( method == "GET" )
{
webRequest = (HttpWebRequest)WebRequest.Create(string.Format("{0}{1}", uri, vars));
webRequest.Method = "GET";
webRequest.UserAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.93 Safari/537.36 OPR/76.0.4017.123";
if ( cdrtool.token != "" )
{
webRequest.PreAuthenticate = true;
webRequest.Headers.Add("Authorization", "Bearer " + cdrtool.token );
webRequest.Accept = "application/json";
}
webRequest.AllowAutoRedirect = redir;
webRequest.Method = method;
webRequest.CookieContainer = cookie;
//webRequest.Timeout = 180000; // 3min
webRequest.Timeout = cdrtool.webMaxWait * 60 * 1000; // convert minutes of wait into milliseconds
if (proxy != null)
{
webRequest.Proxy = proxy;
}
}
else if ( method == "POST" )
{
byte[] buffer = Encoding.ASCII.GetBytes(vars);
webRequest = (HttpWebRequest)WebRequest.Create(uri);
if (proxy != null)
{
webRequest.Proxy = proxy;
}
webRequest.Method = "POST";
webRequest.UserAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.93 Safari/537.36 OPR/76.0.4017.123";
if ( cdrtool.token != "" ) // basically is this a JSON request
{
webRequest.PreAuthenticate = true;
webRequest.Headers.Add("Authorization", "Bearer " + cdrtool.token );
webRequest.Accept = "application/json";
webRequest.ContentType = "application/json";
}
else
{
webRequest.ContentType = "application/x-www-form-urlencoded";
webRequest.ContentType = "application/json"; // all cdrtool requests are json
}
webRequest.ContentLength = buffer.Length;
webRequest.AllowAutoRedirect = redir;
webRequest.Method = method;
webRequest.CookieContainer = cookie;
webRequest.Timeout = cdrtool.webMaxWait * 60 * 1000; // convert minutes of wait into milliseconds
if (proxy != null)
{
webRequest.Proxy = proxy;
}
//We open a stream for writing the postvars
Stream PostData = webRequest.GetRequestStream();
//Now we write, and afterwards, we close. Closing is always important!
PostData.Write(buffer, 0, buffer.Length);
PostData.Close();
}
else
{
Logger.Log("Request not understood");
object[] ret = { false, "FAIL - UNKNOWN METHOD" };
return ret;
}
// allows for validation of SSL conversations
ServicePointManager.ServerCertificateValidationCallback += new RemoteCertificateValidationCallback(
ValidateRemoteCertificate
);
HttpWebResponse response = null;
try
{
//ServicePointManager.SecurityProtocol = (SecurityProtocolType)3072 | (SecurityProtocolType)768 | (SecurityProtocolType)192; //3072
//ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls | System.Net.SecurityProtocolType.Tls11 | System.Net.SecurityProtocolType.Tls12;
response = (HttpWebResponse)webRequest.GetResponse();
//Let's show some information about the response
Logger.Log(6,"{0}",response.StatusCode);
foreach (Cookie cook in response.Cookies)
{
cookie.Add(cook);
}
//DumpCookies(response.Cookies);
if ( ( response.StatusCode == HttpStatusCode.Found ) ||
( response.StatusCode == HttpStatusCode.OK ) )
{
success = true;
}
using (Stream s = response.GetResponseStream() )
{
byte[] data = ReadStreamFully(s);
s.Close();
//System.IO.StreamWriter file = new System.IO.StreamWriter("webcs.txt"); file.BaseStream.Write(data,0,data.Length); file.Close();
//object[] ret = { success, Encoding.ASCII.GetString(data) , data };
object[] ret = { success, data };
return ret;
}
}
catch (Exception ex)
{
Logger.Log(0,"WebRequest error: {0}",ex.Message);
object[] ret = { false, null };
return ret;
}
finally
{
if (response != null)
response.Close();
}
}
*/
public static byte[] ReadStreamFully (Stream stream)
{
byte[] buffer = new byte[32768];
using (MemoryStream ms = new MemoryStream())
{
while (true)
{
int read = stream.Read (buffer, 0, buffer.Length);
if (read <= 0)
//return ms;
return ms.ToArray();
ms.Write (buffer, 0, read);
}
}
}
// callback used to validate the certificate in an SSL conversation
private static bool ValidateRemoteCertificate(
object sender,
X509Certificate certificate,
X509Chain chain,
SslPolicyErrors policyErrors
)
{
/*if (Convert.ToBoolean(ConfigurationManager.AppSettings["IgnoreSslErrors"]))
{
// allow any old dodgy certificate...
return true;
}
else
{
return policyErrors == SslPolicyErrors.None;
}
*/
return true; //policyErrors == SslPolicyErrors.None;
}
private static void DumpCookies ( System.Net.CookieCollection ckjar )
{
foreach (Cookie cook in ckjar)
//foreach (Cookie cook in cookie)
{
Logger.Log("Cookie:");
Logger.Log(0, "{0} = {1}", cook.Name, cook.Value);
Logger.Log(0, "Domain: {0}", cook.Domain);
Logger.Log(0, "Path: {0}", cook.Path);
Logger.Log(0, "Port: {0}", cook.Port);
Logger.Log(0, "Secure: {0}", cook.Secure);
Logger.Log(0, "When issued: {0}", cook.TimeStamp);
Logger.Log(0, "Expires: {0} (expired? {1})",
cook.Expires, cook.Expired);
Logger.Log(0, "Don't save: {0}", cook.Discard);
Logger.Log(0, "Comment: {0}", cook.Comment);
Logger.Log(0, "Uri for comments: {0}", cook.CommentUri);
Logger.Log(0, "Version: RFC {0}" , cook.Version == 1 ? "2109" : "2965");
// Show the string representation of the cookie.
Logger.Log (0, "String: {0}", cook.ToString());
}
}
}
}

1191
WebRoutines.cs Normal file

File diff suppressed because it is too large Load Diff

619
_Main.cs Normal file
View File

@@ -0,0 +1,619 @@
#define PROD_ // also change in LicenseFile.cs too, prevents compilation of the licensekey making bits
/*
* Created by SharpDevelop.
* User: D Macintosh
* Date: 10/25/2022
* Time: 9:32 PM
*
* To change this template use Tools | Options | Coding | Edit Standard Headers.
*/
using System;
using System.Collections.Generic;
using System.Net;
using System.IO;
using System.Text;
using Newtonsoft.Json.Linq;
using System.Threading;
using System.Reflection;
namespace cdrtool
{
class cdrtool
{
public static string product = "CDR-Tool";
public static string version = "1.6.7";
public static int debug = 1;
public static int mode = 1;
public static int major_errs = 0;
public static int MAX_RETRY = 3;
public static int MIN_INT = 10; // minimum interval for timer in minutes
public static int MAX_INT = 360; // maximum interval for timer
public static int webMaxWait = 20; //max wait time in minutes for webaccess
public static bool logappend = true;
public static string logname = "logfile.txt";
public static string licfile = "license.txt";
public static StreamWriter outfile;
public static string username;
public static string password;
public static string company;
public static bool licensed;
public static string dirpath = "";
public static string token = "";
public static int begin = 8;
public static int end = 20;
public static int interval = 0;
public static bool checkPrevMonth = true;
public static int prevMonOffset = 1;
public static string mfa = ""; // 6-digit MFA code
public static int mfa_delay = 120; // wait time for email to arrive in seconds
public static string ssh_user;
public static string ssh_pass;
public static string ssh_host;
public static string ssh_path = "." + Path.DirectorySeparatorChar ;
public static int ssh_port = 22;
public static bool sftp = false;
public static StringBuilder adminLog = new StringBuilder();
public static StringBuilder auditLog = new StringBuilder();
public static int adlvl = 2;
/* see https://denhamcoder.net/2018/08/25/embedding-net-assemblies-inside-net-assemblies/ */ // still needs external copy during compilation!
// Loads NewtonsoftJson lib into memory as .dll
public static Assembly CurrentDomain_AssemblyResolve(object sender, ResolveEventArgs args)
{
string name = new AssemblyName(args.Name).Name;
string embname = "other";
if (name == "BouncyCastle.Cryptography")
{
embname = "CDRTool.Embedded.BouncyCastle.Cryptography.dll";
}
else if (name == "Google.Apis")
{
embname = "CDRTool.Embedded.Google.Apis.dll";
}
else if (name == "Google.Apis.Auth")
{
embname = "CDRTool.Embedded.Google.Apis.Auth.dll";
}
else if (name == "Google.Apis.Core")
{
embname = "CDRTool.Embedded.Google.Apis.Core.dll";
}
else if (name == "Google.Apis.Gmail.v1")
{
embname = "CDRTool.Embedded.Google.Apis.Gmail.v1.dll";
}
else if (name == "Microsoft.Bcl.AsyncInterfaces")
{
embname = "CDRTool.Embedded.Microsoft.Bcl.AsyncInterfaces.dll";
}
else if (name == "Microsoft.Extensions.DependencyInjection.Abstractions")
{
embname = "CDRTool.Embedded.Microsoft.Extensions.DependencyInjection.Abstractions.dll";
}
else if (name == "Microsoft.Extensions.Logging.Abstractions")
{
embname = "CDRTool.Embedded.Microsoft.Extensions.Logging.Abstractions.dll";
}
else if (name == "Newtonsoft.Json")
{
embname = "CDRTool.Embedded.Newtonsoft.Json.dll";
}
else if (name == "Renci.SshNet")
{
embname = "CDRTool.Embedded.Renci.SshNet.dll";
}
else if (name == "System.Buffers")
{
embname = "CDRTool.Embedded.System.Buffers.dll";
}
else if (name == "System.CodeDom")
{
embname = "CDRTool.Embedded.System.CodeDom.dll";
}
else if (name == "System.Diagnostics.DiagnosticSource")
{
embname = "CDRTool.Embedded.System.Diagnostics.DiagnosticSource.dll";
}
else if (name == "System.Formats.Asn1")
{
embname = "CDRTool.Embedded.System.Formats.Asn1.dll";
}
else if (name == "System.Memory")
{
embname = "CDRTool.Embedded.System.Memory.dll";
}
else if (name == "System.Numerics.Vectors")
{
embname = "CDRTool.Embedded.System.Numerics.Vectors.dll";
}
else if (name == "System.Runtime.CompilerServices.Unsafe")
{
embname = "CDRTool.Embedded.System.Runtime.CompilerServices.Unsafe.dll";
}
else if (name == "System.Threading.Tasks.Extensions")
{
embname = "CDRTool.Embedded.System.Threading.Tasks.Extensions.dll";
}
else if (name == "System.ValueTuple")
{
embname = "CDRTool.Embedded.System.ValueTuple.dll";
}
else
{
embname = "something_bad";
}
//Console.WriteLine("returning assy: " + name);
using (var stream = Assembly.GetExecutingAssembly().GetManifestResourceStream(embname))
{
var assemblyData = new Byte[stream.Length];
stream.Read(assemblyData, 0, assemblyData.Length);
return Assembly.Load(assemblyData);
}
}
public static void Main(string[] args)
{
// Load Embedded Resources
AppDomain.CurrentDomain.AssemblyResolve += CurrentDomain_AssemblyResolve;
//foreach (var resource in Assembly.GetExecutingAssembly().GetManifestResourceNames()) Console.WriteLine("Resource: " + resource);
Main2(args);
}
public static async void Main2(string[] args)
{
#if !PROD_
// LicenseFile.makeLicenseFile(licfile, "Support", 5, false);
LicenseFile.makeLicenseFile("license.txt", "Support", 1, true);
Console.WriteLine(LicenseFile.validate("license.txt"));
return;
#endif
// Clears 'async' compiler error
await System.Threading.Tasks.Task.CompletedTask;
// Enforce TLS1.2 Sep2017
ServicePointManager.SecurityProtocol = (SecurityProtocolType)3072 | (SecurityProtocolType)768 | (SecurityProtocolType)192;
// Logging file
outfile = new StreamWriter(@""+logname,logappend);
outfile.AutoFlush = true;
string ban2 = product+" v"+version+" (c) 2022-2026 Sommet Consulting Inc.";
ban2 = "\u2551 " + ban2 + " \u2551";
string ban1 = "\u2554";
for ( int i = 2; i < ban2.Length; i++) { ban1 += "\u2550"; }
ban1 += "\u2557";
string ban3 = "\u255a";
for ( int i = 2; i < ban2.Length; i++) { ban3 += "\u2550"; }
ban3 += "\u255d";
Logger.Log(ban1); Logger.Log(ban2); Logger.Log(ban3);
//Logger.Log("--- UNLICENSED, FOR EVALUATION USE ONLY ---");
dynamic license;
Arguments myargs = new Arguments(args);
CookieContainer cookiejar = new CookieContainer();
if ( (myargs.Count < 1 ) || myargs.Exists("help") || myargs.Exists("h") )
{
Logger.Log(" usage: " + System.Diagnostics.Process.GetCurrentProcess().ProcessName + " [-options]");
//Console.WriteLine("retry: -retries n");
//Logger.Log("--- UNLICENSED, FOR EVALUATION USE ONLY ---");
Logger.Log(" login: -u user -p passwd");
Logger.Log(" time: -begin 8 -end 20 -interval 60");
Logger.Log(" path: -path " + ( Path.DirectorySeparatorChar.ToString()=="\\" ? "C:" : "") + "/directory/subdir");
Logger.Log(" sftp: -sh sftp.server -su user -sp passwd -sport 22 -spath CustomPath");
//Logger.Log(" debug: -debug n");
//Console.WriteLine("-fiddler"); // not needed with Fiddler v5.x
return;
}
WebProxy proxyObject = null;
#if !PROD_
{
//cdrtool Creds
if (myargs.Exists("dm"))
{
username = "Doug.Macintosh@rci.rogers.com";
password = "Rogers1!";
//clientInfo = "logging in as Doug Macintosh";
}
if (myargs.IsTrue("fiddler"))
{
Logger.Log("Enabling Fiddler Proxy");
proxyObject = new WebProxy("http://127.0.0.1:8888/"); // Fiddler proxy
//System.Net.WebRequest.DefaultWebProxy = new System.Net.WebProxy("127.0.0.1", 8888);
}
//}
#endif
if (myargs.Exists("debug"))
{
debug = int.Parse(myargs.Single("debug"));
Logger.Log(5, "Setting debug level to {0}", debug);
}
//}
if (myargs.Exists("path"))
{
dirpath = myargs.Single("path");
}
else
{
dirpath = "." + Path.DirectorySeparatorChar.ToString();
}
if (dirpath.EndsWith(Path.DirectorySeparatorChar.ToString())) { } else { dirpath += Path.DirectorySeparatorChar.ToString();}
Logger.Log(0,"Setting filestore path to {0}", dirpath);
int b = begin;
int e = end;
if (myargs.Exists("begin"))
{
b = int.Parse(myargs.Single("begin"));
}
if (myargs.Exists("end"))
{
e = int.Parse(myargs.Single("end"));
}
if ( ( e > b) && ( ( e > 0) && ( e <= 24 )) )
{
end = e;
}
else
{
Logger.Log(0,"Invalid parameter for end hour. Must be 0-24h and greater than begin hour.");
return;
}
if ( ( b < e ) && ( ( b >= 0 ) && ( b < 24 ) ) )
{
begin = b;
}
else
{
Logger.Log(0,"Invalid parameter for start hour. Must be 0-24h and less than end hour.");
return;
}
if (myargs.Exists("interval"))
{
int i = int.Parse(myargs.Single("interval"));
if ( ( i >= MIN_INT ) && ( i <= MAX_INT ) )
{
interval = i;
}
else
{
Logger.Log(0,"Invalid parameter for interval in minutes. Must be 10-360min");
return;
}
}
if (interval > 0)
{
Logger.Log(0,"Setting Timer Period {0}h to {1}h, {2}min interval", begin, end, interval);
}
else
{
Logger.Log(0,"Single Shot Mode. (set time: parameters to enable repetition).");
}
if (myargs.Exists("offset"))
{
prevMonOffset = int.Parse(myargs.Single("offset"));
Logger.Log(0, "Setting History File offset to -{0}", prevMonOffset);
}
if ((myargs.Exists("sh")) && (myargs.Exists("su")) && (myargs.Exists("sp")) )
{
ssh_host = myargs.Single("sh");
ssh_user = myargs.Single("su");
ssh_pass = myargs.Single("sp");
if (myargs.Exists("sport"))
{
ssh_port = int.Parse(myargs.Single("sport"));
}
if (myargs.Exists("spath"))
{
ssh_path = (myargs.Single("spath"));
}
sftp = true;
Logger.Log(0, "Uploading files as {3} to server: {0}:{1}{4}{2}", ssh_host, ssh_port, ssh_path, ssh_user, Path.DirectorySeparatorChar);
}
if ((myargs.Exists("u")) && (myargs.Exists("p")))
{
username = myargs.Single("u");
password = myargs.Single("p");
Logger.Log(0, "Setting authorized account to: {0}", username);
}
#if !PROD_
else if (myargs.Exists("dm"))
{
//already done
}
#endif
else
{
Logger.Log(0,"No valid login credentials found. Exiting.");
return;
}
// ***MAIN
//sftp.Upload_file("./CURRENT.csv", "10.0.0.3", 2222, "doug", "D4t4Guru");
//return;
do {
var now = DateTime.Now;
var start = new DateTime(now.Year, now.Month, now.Day, begin, 0, 0, now.Kind);
// Logger.Log(5," day of week: {0}", now.DayOfWeek);
TimeSpan span = now - start; // - TimeSpan.FromSeconds(1);
int m = (interval>0) ? interval - ((( span.Hours * 60 ) + span.Minutes ) % interval) : 0; //minutes to next logical interval
var nextTrigger = now + TimeSpan.FromMinutes(m>0 ? m:interval) - TimeSpan.FromSeconds(span.Seconds); // sync to next logical interval
Logger.Log(5," next event at: {0}",nextTrigger);
if( ( interval == 0 ) || ( now.Hour >= begin && now.Hour <= end))
{
// Work loop
bool LoggedIn = false;
int tries = 1;
//Login
do
{
Logger.Log(0,"Initiating connection...");
tries++;
try
{
LoggedIn = WebRoutines.Login( username, password, ref token, ref cookiejar, proxyObject );
if (!LoggedIn) { Logger.Log(1," retrying {0}",tries); }
}
catch (Exception)
{
Logger.Log("Error attempting to login to SIP Portal website");
if (!LoggedIn) { Logger.Log(1," retrying {0}",tries); }
}
}
while (!LoggedIn && (tries <= MAX_RETRY) );
if ( !LoggedIn )
{
Logger.Log("Aborting due to inability to login to SIP Portal website");
break; // DWMM Jan26
}
else
{
try
{
#if !PROD_
LicenseFile.makeLicenseFile(licfile, "Support", 5, false);
#endif
license = JObject.Parse(LicenseFile.validate(licfile));
}
catch (Exception ex)
{
Logger.Log("ERROR: Invalid License File!");
Logger.Log(5,ex.Message);
Logger.Log("Exiting.");
return;
}
string validity = (
((bool)license.Perpetual ? "Perpetual License: " : "License: ") + product + " has " +
((DateTime.Now <= (DateTime)license.ValidTo) ? (license.Type + " valid through " + license.ValidTo) :
((bool)license.Perpetual ? "Right to Use only." : "Expired on " + license.ValidTo)));
if (checkPrevMonth) Logger.Log(validity);
licensed = !validity.Contains("Expire");
if (licensed && checkPrevMonth) Logger.Log("For assistance please contact support@sommetconsulting.ca");
}
// Get Parameters
string wfr_guid = "";
string ch_guid = "";
string act_guid = "";
string co_guid = "";
string did_guid = "";
string year = "";
string mtd = "";
bool gotParams = false;
tries = 1;
do
{
try
{
if (licensed)
{
Logger.Log("Setting up...");
gotParams = WebRoutines.GetGUIDs(token, ref wfr_guid, ref ch_guid, ref act_guid, ref co_guid, ref did_guid,
ref year, ref mtd, ref cookiejar, proxyObject);
}
}
catch (Exception ex)
{
Logger.Log("Error navigating SIP Portal");
Logger.Log(5, ex.Message);
if (!gotParams) { tries++; Logger.Log(0, " retrying {0}", tries); }
}
}
while (!gotParams && (tries < MAX_RETRY));
if (!gotParams)
{
Logger.Log("Aborting due to inability to navigate SIP Portal.");
break; //return;
}
// Get files
string filename = "CURRENT.csv";
//filename = ""; // use system filename
bool gotMTDFile = false;
tries = 1;
do
{
try
{
if (licensed)
{
gotMTDFile = WebRoutines.GetMTDFile(dirpath, filename, token, ref act_guid, ref co_guid, ref did_guid,
ref year, ref mtd, ref cookiejar, proxyObject);
}
}
catch (Exception ex)
{
Logger.Log("Error attempting to download MTD File.");
Logger.Log(5, ex.Message);
if (!gotMTDFile) { tries++; Logger.Log(0, " retrying {0}", tries); }
}
}
while (!gotMTDFile && (tries < MAX_RETRY));
if (!gotMTDFile)
{
Logger.Log("Exiting due to inability to download Month-to-Date file.");
break; // return;
}
bool gotCDRHistoryFile = false;
tries = 1;
do
{
try
{
if (checkPrevMonth && licensed)
{
filename = ""; // use system filename
gotCDRHistoryFile = WebRoutines.GetCDRHistoryFile(dirpath, filename, prevMonOffset, token, ref act_guid, ref co_guid, ref did_guid,
ref year, ref mtd, ref cookiejar, proxyObject);
}
else
{
gotCDRHistoryFile = true;
}
}
catch (Exception ex)
{
Logger.Log("Error attempting to download History File.");
Logger.Log(5, ex.Message);
if (!gotCDRHistoryFile) { tries++; Logger.Log(0, " retrying {0}", tries); }
}
}
while (!gotCDRHistoryFile && (tries < MAX_RETRY));
if (!gotCDRHistoryFile)
{
Logger.Log("Aborting due to inability to download CDR Monthly History file.");
break; // return;
}
checkPrevMonth = false;
Logger.Log(3,"Trigger hour {0} Now hour {1}", nextTrigger.Hour, now.Hour);
//if (( interval > 0) && ( nextTrigger.Hour <= ( now.Hour + 1)) ) // NEED TO HANDLE MIDNIGHT ROLLOVER STILL
if ( (interval > 0) ) // NEED TO HANDLE MIDNIGHT ROLLOVER STILL
{
Logger.Log(0,"Completed CDR processing. Next event at {0:00}h{1:00}", nextTrigger.Hour, nextTrigger.Minute);
}
else
{
Logger.Log(0,"Completed CDR processing.");
}
// LOG OUT
bool LoggedOut = WebRoutines.Logout(token, ref cookiejar, ref proxyObject);
//break; // exit while() loop we are using as in 'IF'
} //END OF WORK LOOP
now = DateTime.Now; // reset and clean up in case we started just before the next cycle was to start
// Moved stuff
span = now - start; // - TimeSpan.FromSeconds(1);
m = (interval > 0) ? interval - (((span.Hours * 60) + span.Minutes) % interval) : 0; //minutes to next logical interval
nextTrigger = now + TimeSpan.FromMinutes(m > 0 ? m : interval) - TimeSpan.FromSeconds(span.Seconds); // sync to next logical interval
//Logger.Log(0, " span {0} m:{1} next trigger {2})", span, m, nextTrigger);
if ( ( now.Hour < begin || now.Hour > end || nextTrigger.Hour < begin || nextTrigger.Hour > end) && ( interval > 0 ) )
{
nextTrigger = new DateTime(now.Year, now.Month, now.Day, now.Hour, 0, 0, now.Kind) ;
nextTrigger += TimeSpan.FromHours( (24 - now.Hour + begin) % 24 );
Logger.Log(0,"Going to sleep until {0:00}h{1:00}", nextTrigger.Hour, nextTrigger.Minute); // begin is always less than end in any given 24h cycle
checkPrevMonth = true;
}
if (interval > 0)
{
//now = DateTime.Now;
// if ((nextTrigger - now) < TimeSpan.FromSeconds(1)) now -= TimeSpan.FromSeconds(1);
//nextTrigger += TimeSpan.FromMinutes(interval);
//Logger.Log(3,"values adjusted: trig:{0} now:{1}", nextTrigger, now);
//Logger.Log(3, " thread sleeping {0}", (nextTrigger - now));
Logger.Log(5, " thread sleeping {0} ({1} - {2})", (nextTrigger - now), (nextTrigger), (now.ToString("HH:mm:ss.fff")));
token = ""; // reset auth token for session
Thread.Sleep(nextTrigger - now + TimeSpan.FromSeconds(0.5));
}
}
while ( ( licensed || checkPrevMonth) && (interval > 0));
} // end of MAIN()
} // cdrtool class
public static class IDictionaryExtensions
{
public static TKey FindKeyByValue<TKey, TValue>(this IDictionary<TKey, TValue> dictionary, TValue value)
{
if (dictionary == null)
throw new ArgumentNullException("dictionary");
foreach (KeyValuePair<TKey, TValue> pair in dictionary)
if (value.Equals(pair.Value)) return pair.Key;
throw new Exception("the value is not found in the dictionary");
}
}
}

6
app.config Normal file
View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup>
<supportedRuntime version="v4.8" sku=".NETFramework,Version=v4.0" />
</startup>
</configuration>

Binary file not shown.

File diff suppressed because it is too large Load Diff

38537
bin/Debug/CURRENT.csv Normal file

File diff suppressed because it is too large Load Diff

BIN
bin/Debug/Google.Apis.Auth.dll Executable file

Binary file not shown.

BIN
bin/Debug/Google.Apis.Auth.pdb Executable file

Binary file not shown.

5100
bin/Debug/Google.Apis.Auth.xml Executable file

File diff suppressed because it is too large Load Diff

BIN
bin/Debug/Google.Apis.Core.dll Executable file

Binary file not shown.

BIN
bin/Debug/Google.Apis.Core.pdb Executable file

Binary file not shown.

2062
bin/Debug/Google.Apis.Core.xml Executable file

File diff suppressed because it is too large Load Diff

Binary file not shown.

Binary file not shown.

5758
bin/Debug/Google.Apis.Gmail.v1.xml Executable file

File diff suppressed because it is too large Load Diff

BIN
bin/Debug/Google.Apis.dll Executable file

Binary file not shown.

BIN
bin/Debug/Google.Apis.pdb Executable file

Binary file not shown.

1840
bin/Debug/Google.Apis.xml Executable file

File diff suppressed because it is too large Load Diff

Binary file not shown.

View File

@@ -0,0 +1,420 @@
<?xml version="1.0"?>
<doc>
<assembly>
<name>Microsoft.Bcl.AsyncInterfaces</name>
</assembly>
<members>
<member name="T:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1">
<summary>Provides the core logic for implementing a manual-reset <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/> or <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/>.</summary>
<typeparam name="TResult"></typeparam>
</member>
<member name="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._continuation">
<summary>
The callback to invoke when the operation completes if <see cref="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.OnCompleted(System.Action{System.Object},System.Object,System.Int16,System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags)"/> was called before the operation completed,
or <see cref="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCoreShared.s_sentinel"/> if the operation completed before a callback was supplied,
or null if a callback hasn't yet been provided and the operation hasn't yet completed.
</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._continuationState">
<summary>State to pass to <see cref="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._continuation"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._executionContext">
<summary><see cref="T:System.Threading.ExecutionContext"/> to flow to the callback, or null if no flowing is required.</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._capturedContext">
<summary>
A "captured" <see cref="T:System.Threading.SynchronizationContext"/> or <see cref="T:System.Threading.Tasks.TaskScheduler"/> with which to invoke the callback,
or null if no special context is required.
</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._completed">
<summary>Whether the current operation has completed.</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._result">
<summary>The result with which the operation succeeded, or the default value if it hasn't yet completed or failed.</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._error">
<summary>The exception with which the operation failed, or null if it hasn't yet completed or completed successfully.</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._version">
<summary>The current version of this value, used to help prevent misuse.</summary>
</member>
<member name="P:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.RunContinuationsAsynchronously">
<summary>Gets or sets whether to force continuations to run asynchronously.</summary>
<remarks>Continuations may run asynchronously if this is false, but they'll never run synchronously if this is true.</remarks>
</member>
<member name="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.Reset">
<summary>Resets to prepare for the next operation.</summary>
</member>
<member name="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.SetResult(`0)">
<summary>Completes with a successful result.</summary>
<param name="result">The result.</param>
</member>
<member name="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.SetException(System.Exception)">
<summary>Complets with an error.</summary>
<param name="error"></param>
</member>
<member name="P:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.Version">
<summary>Gets the operation version.</summary>
</member>
<member name="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.GetStatus(System.Int16)">
<summary>Gets the status of the operation.</summary>
<param name="token">Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask"/>'s constructor.</param>
</member>
<member name="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.GetResult(System.Int16)">
<summary>Gets the result of the operation.</summary>
<param name="token">Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask"/>'s constructor.</param>
</member>
<member name="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.OnCompleted(System.Action{System.Object},System.Object,System.Int16,System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags)">
<summary>Schedules the continuation action for this operation.</summary>
<param name="continuation">The continuation to invoke when the operation has completed.</param>
<param name="state">The state object to pass to <paramref name="continuation"/> when it's invoked.</param>
<param name="token">Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask"/>'s constructor.</param>
<param name="flags">The flags describing the behavior of the continuation.</param>
</member>
<member name="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.ValidateToken(System.Int16)">
<summary>Ensures that the specified token matches the current version.</summary>
<param name="token">The token supplied by <see cref="T:System.Threading.Tasks.ValueTask"/>.</param>
</member>
<member name="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.SignalCompletion">
<summary>Signals that the operation has completed. Invoked after the result or error has been set.</summary>
</member>
<member name="M:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.InvokeContinuation">
<summary>
Invokes the continuation with the appropriate captured context / scheduler.
This assumes that if <see cref="F:System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1._executionContext"/> is not null we're already
running within that <see cref="T:System.Threading.ExecutionContext"/>.
</summary>
</member>
<member name="T:System.Threading.Tasks.TaskAsyncEnumerableExtensions">
<summary>Provides a set of static methods for configuring <see cref="T:System.Threading.Tasks.Task"/>-related behaviors on asynchronous enumerables and disposables.</summary>
</member>
<member name="M:System.Threading.Tasks.TaskAsyncEnumerableExtensions.ConfigureAwait(System.IAsyncDisposable,System.Boolean)">
<summary>Configures how awaits on the tasks returned from an async disposable will be performed.</summary>
<param name="source">The source async disposable.</param>
<param name="continueOnCapturedContext"><see langword="true" /> to capture and marshal back to the current context; otherwise, <see langword="false" />.</param>
<returns>The configured async disposable.</returns>
</member>
<member name="M:System.Threading.Tasks.TaskAsyncEnumerableExtensions.ConfigureAwait``1(System.Collections.Generic.IAsyncEnumerable{``0},System.Boolean)">
<summary>Configures how awaits on the tasks returned from an async iteration will be performed.</summary>
<typeparam name="T">The type of the objects being iterated.</typeparam>
<param name="source">The source enumerable being iterated.</param>
<param name="continueOnCapturedContext"><see langword="true" /> to capture and marshal back to the current context; otherwise, <see langword="false" />.</param>
<returns>The configured enumerable.</returns>
</member>
<member name="M:System.Threading.Tasks.TaskAsyncEnumerableExtensions.WithCancellation``1(System.Collections.Generic.IAsyncEnumerable{``0},System.Threading.CancellationToken)">
<summary>Sets the <see cref="T:System.Threading.CancellationToken"/> to be passed to <see cref="M:System.Collections.Generic.IAsyncEnumerable`1.GetAsyncEnumerator(System.Threading.CancellationToken)"/> when iterating.</summary>
<typeparam name="T">The type of the objects being iterated.</typeparam>
<param name="source">The source enumerable being iterated.</param>
<param name="cancellationToken">The <see cref="T:System.Threading.CancellationToken"/> to use.</param>
<returns>The configured enumerable.</returns>
</member>
<member name="T:System.Runtime.CompilerServices.AsyncIteratorMethodBuilder">
<summary>Represents a builder for asynchronous iterators.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncIteratorMethodBuilder.Create">
<summary>Creates an instance of the <see cref="T:System.Runtime.CompilerServices.AsyncIteratorMethodBuilder"/> struct.</summary>
<returns>The initialized instance.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncIteratorMethodBuilder.MoveNext``1(``0@)">
<summary>Invokes <see cref="M:System.Runtime.CompilerServices.IAsyncStateMachine.MoveNext"/> on the state machine while guarding the <see cref="T:System.Threading.ExecutionContext"/>.</summary>
<typeparam name="TStateMachine">The type of the state machine.</typeparam>
<param name="stateMachine">The state machine instance, passed by reference.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncIteratorMethodBuilder.AwaitOnCompleted``2(``0@,``1@)">
<summary>Schedules the state machine to proceed to the next action when the specified awaiter completes.</summary>
<typeparam name="TAwaiter">The type of the awaiter.</typeparam>
<typeparam name="TStateMachine">The type of the state machine.</typeparam>
<param name="awaiter">The awaiter.</param>
<param name="stateMachine">The state machine.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncIteratorMethodBuilder.AwaitUnsafeOnCompleted``2(``0@,``1@)">
<summary>Schedules the state machine to proceed to the next action when the specified awaiter completes.</summary>
<typeparam name="TAwaiter">The type of the awaiter.</typeparam>
<typeparam name="TStateMachine">The type of the state machine.</typeparam>
<param name="awaiter">The awaiter.</param>
<param name="stateMachine">The state machine.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncIteratorMethodBuilder.Complete">
<summary>Marks iteration as being completed, whether successfully or otherwise.</summary>
</member>
<member name="P:System.Runtime.CompilerServices.AsyncIteratorMethodBuilder.ObjectIdForDebugger">
<summary>Gets an object that may be used to uniquely identify this builder to the debugger.</summary>
</member>
<member name="T:System.Runtime.CompilerServices.AsyncIteratorStateMachineAttribute">
<summary>Indicates whether a method is an asynchronous iterator.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncIteratorStateMachineAttribute.#ctor(System.Type)">
<summary>Initializes a new instance of the <see cref="T:System.Runtime.CompilerServices.AsyncIteratorStateMachineAttribute"/> class.</summary>
<param name="stateMachineType">The type object for the underlying state machine type that's used to implement a state machine method.</param>
</member>
<member name="T:System.Runtime.CompilerServices.ConfiguredAsyncDisposable">
<summary>Provides a type that can be used to configure how awaits on an <see cref="T:System.IAsyncDisposable"/> are performed.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredAsyncDisposable.DisposeAsync">
<summary>Asynchronously releases the unmanaged resources used by the <see cref="T:System.Runtime.CompilerServices.ConfiguredAsyncDisposable" />.</summary>
<returns>A task that represents the asynchronous dispose operation.</returns>
</member>
<member name="T:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1">
<summary>Provides an awaitable async enumerable that enables cancelable iteration and configured awaits.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1.ConfigureAwait(System.Boolean)">
<summary>Configures how awaits on the tasks returned from an async iteration will be performed.</summary>
<param name="continueOnCapturedContext"><see langword="true" /> to capture and marshal back to the current context; otherwise, <see langword="false" />.</param>
<returns>The configured enumerable.</returns>
<remarks>This will replace any previous value set by <see cref="M:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1.ConfigureAwait(System.Boolean)"/> for this iteration.</remarks>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1.WithCancellation(System.Threading.CancellationToken)">
<summary>Sets the <see cref="T:System.Threading.CancellationToken"/> to be passed to <see cref="M:System.Collections.Generic.IAsyncEnumerable`1.GetAsyncEnumerator(System.Threading.CancellationToken)"/> when iterating.</summary>
<param name="cancellationToken">The <see cref="T:System.Threading.CancellationToken"/> to use.</param>
<returns>The configured enumerable.</returns>
<remarks>This will replace any previous <see cref="T:System.Threading.CancellationToken"/> set by <see cref="M:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1.WithCancellation(System.Threading.CancellationToken)"/> for this iteration.</remarks>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1.GetAsyncEnumerator">
<summary>Returns an enumerator that iterates asynchronously through collections that enables cancelable iteration and configured awaits.</summary>
<returns>An enumerator for the <see cref="T:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1" /> class.</returns>
</member>
<member name="T:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1.Enumerator">
<summary>Provides an awaitable async enumerator that enables cancelable iteration and configured awaits.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1.Enumerator.MoveNextAsync">
<summary>Advances the enumerator asynchronously to the next element of the collection.</summary>
<returns>
A <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1"/> that will complete with a result of <c>true</c>
if the enumerator was successfully advanced to the next element, or <c>false</c> if the enumerator has
passed the end of the collection.
</returns>
</member>
<member name="P:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1.Enumerator.Current">
<summary>Gets the element in the collection at the current position of the enumerator.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable`1.Enumerator.DisposeAsync">
<summary>
Performs application-defined tasks associated with freeing, releasing, or
resetting unmanaged resources asynchronously.
</summary>
</member>
<member name="T:System.Runtime.CompilerServices.EnumeratorCancellationAttribute">
<summary>Allows users of async-enumerable methods to mark the parameter that should receive the cancellation token value from <see cref="M:System.Collections.Generic.IAsyncEnumerable`1.GetAsyncEnumerator(System.Threading.CancellationToken)" />.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.EnumeratorCancellationAttribute.#ctor">
<summary>Initializes a new instance of the <see cref="T:System.Runtime.CompilerServices.EnumeratorCancellationAttribute" /> class.</summary>
</member>
<member name="T:System.Runtime.InteropServices.LibraryImportAttribute">
<summary>
Attribute used to indicate a source generator should create a function for marshalling
arguments instead of relying on the runtime to generate an equivalent marshalling function at run-time.
</summary>
<remarks>
This attribute is meaningless if the source generator associated with it is not enabled.
The current built-in source generator only supports C# and only supplies an implementation when
applied to static, partial, non-generic methods.
</remarks>
</member>
<member name="M:System.Runtime.InteropServices.LibraryImportAttribute.#ctor(System.String)">
<summary>
Initializes a new instance of the <see cref="T:System.Runtime.InteropServices.LibraryImportAttribute"/>.
</summary>
<param name="libraryName">Name of the library containing the import.</param>
</member>
<member name="P:System.Runtime.InteropServices.LibraryImportAttribute.LibraryName">
<summary>
Gets the name of the library containing the import.
</summary>
</member>
<member name="P:System.Runtime.InteropServices.LibraryImportAttribute.EntryPoint">
<summary>
Gets or sets the name of the entry point to be called.
</summary>
</member>
<member name="P:System.Runtime.InteropServices.LibraryImportAttribute.StringMarshalling">
<summary>
Gets or sets how to marshal string arguments to the method.
</summary>
<remarks>
If this field is set to a value other than <see cref="F:System.Runtime.InteropServices.StringMarshalling.Custom" />,
<see cref="P:System.Runtime.InteropServices.LibraryImportAttribute.StringMarshallingCustomType" /> must not be specified.
</remarks>
</member>
<member name="P:System.Runtime.InteropServices.LibraryImportAttribute.StringMarshallingCustomType">
<summary>
Gets or sets the <see cref="T:System.Type"/> used to control how string arguments to the method are marshalled.
</summary>
<remarks>
If this field is specified, <see cref="P:System.Runtime.InteropServices.LibraryImportAttribute.StringMarshalling" /> must not be specified
or must be set to <see cref="F:System.Runtime.InteropServices.StringMarshalling.Custom" />.
</remarks>
</member>
<member name="P:System.Runtime.InteropServices.LibraryImportAttribute.SetLastError">
<summary>
Gets or sets whether the callee sets an error (SetLastError on Windows or errno
on other platforms) before returning from the attributed method.
</summary>
</member>
<member name="T:System.Runtime.InteropServices.StringMarshalling">
<summary>
Specifies how strings should be marshalled for generated p/invokes
</summary>
</member>
<member name="F:System.Runtime.InteropServices.StringMarshalling.Custom">
<summary>
Indicates the user is supplying a specific marshaller in <see cref="P:System.Runtime.InteropServices.LibraryImportAttribute.StringMarshallingCustomType"/>.
</summary>
</member>
<member name="F:System.Runtime.InteropServices.StringMarshalling.Utf8">
<summary>
Use the platform-provided UTF-8 marshaller.
</summary>
</member>
<member name="F:System.Runtime.InteropServices.StringMarshalling.Utf16">
<summary>
Use the platform-provided UTF-16 marshaller.
</summary>
</member>
<member name="T:System.Collections.Generic.IAsyncEnumerable`1">
<summary>Exposes an enumerator that provides asynchronous iteration over values of a specified type.</summary>
<typeparam name="T">The type of values to enumerate.</typeparam>
</member>
<member name="M:System.Collections.Generic.IAsyncEnumerable`1.GetAsyncEnumerator(System.Threading.CancellationToken)">
<summary>Returns an enumerator that iterates asynchronously through the collection.</summary>
<param name="cancellationToken">A <see cref="T:System.Threading.CancellationToken"/> that may be used to cancel the asynchronous iteration.</param>
<returns>An enumerator that can be used to iterate asynchronously through the collection.</returns>
</member>
<member name="T:System.Collections.Generic.IAsyncEnumerator`1">
<summary>Supports a simple asynchronous iteration over a generic collection.</summary>
<typeparam name="T">The type of objects to enumerate.</typeparam>
</member>
<member name="M:System.Collections.Generic.IAsyncEnumerator`1.MoveNextAsync">
<summary>Advances the enumerator asynchronously to the next element of the collection.</summary>
<returns>
A <see cref="T:System.Threading.Tasks.ValueTask`1"/> that will complete with a result of <c>true</c> if the enumerator
was successfully advanced to the next element, or <c>false</c> if the enumerator has passed the end
of the collection.
</returns>
</member>
<member name="P:System.Collections.Generic.IAsyncEnumerator`1.Current">
<summary>Gets the element in the collection at the current position of the enumerator.</summary>
</member>
<member name="T:System.IAsyncDisposable">
<summary>Provides a mechanism for releasing unmanaged resources asynchronously.</summary>
</member>
<member name="M:System.IAsyncDisposable.DisposeAsync">
<summary>
Performs application-defined tasks associated with freeing, releasing, or
resetting unmanaged resources asynchronously.
</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.AllowNullAttribute">
<summary>Specifies that null is allowed as an input even if the corresponding type disallows it.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.DisallowNullAttribute">
<summary>Specifies that null is disallowed as an input even if the corresponding type allows it.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.MaybeNullAttribute">
<summary>Specifies that an output may be null even if the corresponding type disallows it.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.NotNullAttribute">
<summary>Specifies that an output will not be null even if the corresponding type allows it. Specifies that an input argument was not null when the call returns.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute">
<summary>Specifies that when a method returns <see cref="P:System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute.ReturnValue"/>, the parameter may be null even if the corresponding type disallows it.</summary>
</member>
<member name="M:System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute.#ctor(System.Boolean)">
<summary>Initializes the attribute with the specified return value condition.</summary>
<param name="returnValue">
The return value condition. If the method returns this value, the associated parameter may be null.
</param>
</member>
<member name="P:System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute.ReturnValue">
<summary>Gets the return value condition.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.NotNullWhenAttribute">
<summary>Specifies that when a method returns <see cref="P:System.Diagnostics.CodeAnalysis.NotNullWhenAttribute.ReturnValue"/>, the parameter will not be null even if the corresponding type allows it.</summary>
</member>
<member name="M:System.Diagnostics.CodeAnalysis.NotNullWhenAttribute.#ctor(System.Boolean)">
<summary>Initializes the attribute with the specified return value condition.</summary>
<param name="returnValue">
The return value condition. If the method returns this value, the associated parameter will not be null.
</param>
</member>
<member name="P:System.Diagnostics.CodeAnalysis.NotNullWhenAttribute.ReturnValue">
<summary>Gets the return value condition.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.NotNullIfNotNullAttribute">
<summary>Specifies that the output will be non-null if the named parameter is non-null.</summary>
</member>
<member name="M:System.Diagnostics.CodeAnalysis.NotNullIfNotNullAttribute.#ctor(System.String)">
<summary>Initializes the attribute with the associated parameter name.</summary>
<param name="parameterName">
The associated parameter name. The output will be non-null if the argument to the parameter specified is non-null.
</param>
</member>
<member name="P:System.Diagnostics.CodeAnalysis.NotNullIfNotNullAttribute.ParameterName">
<summary>Gets the associated parameter name.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.DoesNotReturnAttribute">
<summary>Applied to a method that will never return under any circumstance.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.DoesNotReturnIfAttribute">
<summary>Specifies that the method will not return if the associated Boolean parameter is passed the specified value.</summary>
</member>
<member name="M:System.Diagnostics.CodeAnalysis.DoesNotReturnIfAttribute.#ctor(System.Boolean)">
<summary>Initializes the attribute with the specified parameter value.</summary>
<param name="parameterValue">
The condition parameter value. Code after the method will be considered unreachable by diagnostics if the argument to
the associated parameter matches this value.
</param>
</member>
<member name="P:System.Diagnostics.CodeAnalysis.DoesNotReturnIfAttribute.ParameterValue">
<summary>Gets the condition parameter value.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.MemberNotNullAttribute">
<summary>Specifies that the method or property will ensure that the listed field and property members have not-null values.</summary>
</member>
<member name="M:System.Diagnostics.CodeAnalysis.MemberNotNullAttribute.#ctor(System.String)">
<summary>Initializes the attribute with a field or property member.</summary>
<param name="member">
The field or property member that is promised to be not-null.
</param>
</member>
<member name="M:System.Diagnostics.CodeAnalysis.MemberNotNullAttribute.#ctor(System.String[])">
<summary>Initializes the attribute with the list of field and property members.</summary>
<param name="members">
The list of field and property members that are promised to be not-null.
</param>
</member>
<member name="P:System.Diagnostics.CodeAnalysis.MemberNotNullAttribute.Members">
<summary>Gets field or property member names.</summary>
</member>
<member name="T:System.Diagnostics.CodeAnalysis.MemberNotNullWhenAttribute">
<summary>Specifies that the method or property will ensure that the listed field and property members have not-null values when returning with the specified return value condition.</summary>
</member>
<member name="M:System.Diagnostics.CodeAnalysis.MemberNotNullWhenAttribute.#ctor(System.Boolean,System.String)">
<summary>Initializes the attribute with the specified return value condition and a field or property member.</summary>
<param name="returnValue">
The return value condition. If the method returns this value, the associated field or property member will not be null.
</param>
<param name="member">
The field or property member that is promised to be not-null.
</param>
</member>
<member name="M:System.Diagnostics.CodeAnalysis.MemberNotNullWhenAttribute.#ctor(System.Boolean,System.String[])">
<summary>Initializes the attribute with the specified return value condition and list of field and property members.</summary>
<param name="returnValue">
The return value condition. If the method returns this value, the associated field and property members will not be null.
</param>
<param name="members">
The list of field and property members that are promised to be not-null.
</param>
</member>
<member name="P:System.Diagnostics.CodeAnalysis.MemberNotNullWhenAttribute.ReturnValue">
<summary>Gets the return value condition.</summary>
</member>
<member name="P:System.Diagnostics.CodeAnalysis.MemberNotNullWhenAttribute.Members">
<summary>Gets field or property member names.</summary>
</member>
<member name="T:System.ExceptionPolyfills">
<summary>Provides downlevel polyfills for static methods on Exception-derived types.</summary>
</member>
</members>
</doc>

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

BIN
bin/Debug/Newtonsoft.Json.dll Executable file

Binary file not shown.

11698
bin/Debug/Newtonsoft.Json.xml Executable file

File diff suppressed because it is too large Load Diff

BIN
bin/Debug/Renci.SshNet.dll Executable file

Binary file not shown.

20969
bin/Debug/Renci.SshNet.xml Executable file

File diff suppressed because it is too large Load Diff

BIN
bin/Debug/System.Buffers.dll Executable file

Binary file not shown.

173
bin/Debug/System.Buffers.xml Executable file
View File

@@ -0,0 +1,173 @@
<?xml version="1.0"?>
<doc>
<assembly>
<name>System.Buffers</name>
</assembly>
<members>
<member name="T:System.Buffers.ArrayPool`1">
<summary>
Provides a resource pool that enables reusing instances of type <see cref="T:T[]"/>.
</summary>
<remarks>
<para>
Renting and returning buffers with an <see cref="T:System.Buffers.ArrayPool`1"/> can increase performance
in situations where arrays are created and destroyed frequently, resulting in significant
memory pressure on the garbage collector.
</para>
<para>
This class is thread-safe. All members may be used by multiple threads concurrently.
</para>
</remarks>
</member>
<member name="F:System.Buffers.ArrayPool`1.s_sharedInstance">
<summary>The lazily-initialized shared pool instance.</summary>
</member>
<member name="P:System.Buffers.ArrayPool`1.Shared">
<summary>
Retrieves a shared <see cref="T:System.Buffers.ArrayPool`1"/> instance.
</summary>
<remarks>
The shared pool provides a default implementation of <see cref="T:System.Buffers.ArrayPool`1"/>
that's intended for general applicability. It maintains arrays of multiple sizes, and
may hand back a larger array than was actually requested, but will never hand back a smaller
array than was requested. Renting a buffer from it with <see cref="M:System.Buffers.ArrayPool`1.Rent(System.Int32)"/> will result in an
existing buffer being taken from the pool if an appropriate buffer is available or in a new
buffer being allocated if one is not available.
</remarks>
</member>
<member name="M:System.Buffers.ArrayPool`1.EnsureSharedCreated">
<summary>Ensures that <see cref="F:System.Buffers.ArrayPool`1.s_sharedInstance"/> has been initialized to a pool and returns it.</summary>
</member>
<member name="M:System.Buffers.ArrayPool`1.Create">
<summary>
Creates a new <see cref="T:System.Buffers.ArrayPool`1"/> instance using default configuration options.
</summary>
<returns>A new <see cref="T:System.Buffers.ArrayPool`1"/> instance.</returns>
</member>
<member name="M:System.Buffers.ArrayPool`1.Create(System.Int32,System.Int32)">
<summary>
Creates a new <see cref="T:System.Buffers.ArrayPool`1"/> instance using custom configuration options.
</summary>
<param name="maxArrayLength">The maximum length of array instances that may be stored in the pool.</param>
<param name="maxArraysPerBucket">
The maximum number of array instances that may be stored in each bucket in the pool. The pool
groups arrays of similar lengths into buckets for faster access.
</param>
<returns>A new <see cref="T:System.Buffers.ArrayPool`1"/> instance with the specified configuration options.</returns>
<remarks>
The created pool will group arrays into buckets, with no more than <paramref name="maxArraysPerBucket"/>
in each bucket and with those arrays not exceeding <paramref name="maxArrayLength"/> in length.
</remarks>
</member>
<member name="M:System.Buffers.ArrayPool`1.Rent(System.Int32)">
<summary>
Retrieves a buffer that is at least the requested length.
</summary>
<param name="minimumLength">The minimum length of the array needed.</param>
<returns>
An <see cref="T:T[]"/> that is at least <paramref name="minimumLength"/> in length.
</returns>
<remarks>
This buffer is loaned to the caller and should be returned to the same pool via
<see cref="M:System.Buffers.ArrayPool`1.Return(`0[],System.Boolean)"/> so that it may be reused in subsequent usage of <see cref="M:System.Buffers.ArrayPool`1.Rent(System.Int32)"/>.
It is not a fatal error to not return a rented buffer, but failure to do so may lead to
decreased application performance, as the pool may need to create a new buffer to replace
the one lost.
</remarks>
</member>
<member name="M:System.Buffers.ArrayPool`1.Return(`0[],System.Boolean)">
<summary>
Returns to the pool an array that was previously obtained via <see cref="M:System.Buffers.ArrayPool`1.Rent(System.Int32)"/> on the same
<see cref="T:System.Buffers.ArrayPool`1"/> instance.
</summary>
<param name="array">
The buffer previously obtained from <see cref="M:System.Buffers.ArrayPool`1.Rent(System.Int32)"/> to return to the pool.
</param>
<param name="clearArray">
If <c>true</c> and if the pool will store the buffer to enable subsequent reuse, <see cref="M:System.Buffers.ArrayPool`1.Return(`0[],System.Boolean)"/>
will clear <paramref name="array"/> of its contents so that a subsequent consumer via <see cref="M:System.Buffers.ArrayPool`1.Rent(System.Int32)"/>
will not see the previous consumer's content. If <c>false</c> or if the pool will release the buffer,
the array's contents are left unchanged.
</param>
<remarks>
Once a buffer has been returned to the pool, the caller gives up all ownership of the buffer
and must not use it. The reference returned from a given call to <see cref="M:System.Buffers.ArrayPool`1.Rent(System.Int32)"/> must only be
returned via <see cref="M:System.Buffers.ArrayPool`1.Return(`0[],System.Boolean)"/> once. The default <see cref="T:System.Buffers.ArrayPool`1"/>
may hold onto the returned buffer in order to rent it again, or it may release the returned buffer
if it's determined that the pool already has enough buffers stored.
</remarks>
</member>
<member name="T:System.Buffers.ArrayPoolEventSource.BufferAllocatedReason">
<summary>The reason for a BufferAllocated event.</summary>
</member>
<member name="F:System.Buffers.ArrayPoolEventSource.BufferAllocatedReason.Pooled">
<summary>The pool is allocating a buffer to be pooled in a bucket.</summary>
</member>
<member name="F:System.Buffers.ArrayPoolEventSource.BufferAllocatedReason.OverMaximumSize">
<summary>The requested buffer size was too large to be pooled.</summary>
</member>
<member name="F:System.Buffers.ArrayPoolEventSource.BufferAllocatedReason.PoolExhausted">
<summary>The pool has already allocated for pooling as many buffers of a particular size as it's allowed.</summary>
</member>
<member name="M:System.Buffers.ArrayPoolEventSource.BufferRented(System.Int32,System.Int32,System.Int32,System.Int32)">
<summary>
Event for when a buffer is rented. This is invoked once for every successful call to Rent,
regardless of whether a buffer is allocated or a buffer is taken from the pool. In a
perfect situation where all rented buffers are returned, we expect to see the number
of BufferRented events exactly match the number of BuferReturned events, with the number
of BufferAllocated events being less than or equal to those numbers (ideally significantly
less than).
</summary>
</member>
<member name="M:System.Buffers.ArrayPoolEventSource.BufferAllocated(System.Int32,System.Int32,System.Int32,System.Int32,System.Buffers.ArrayPoolEventSource.BufferAllocatedReason)">
<summary>
Event for when a buffer is allocated by the pool. In an ideal situation, the number
of BufferAllocated events is significantly smaller than the number of BufferRented and
BufferReturned events.
</summary>
</member>
<member name="M:System.Buffers.ArrayPoolEventSource.BufferReturned(System.Int32,System.Int32,System.Int32)">
<summary>
Event raised when a buffer is returned to the pool. This event is raised regardless of whether
the returned buffer is stored or dropped. In an ideal situation, the number of BufferReturned
events exactly matches the number of BufferRented events.
</summary>
</member>
<member name="F:System.Buffers.DefaultArrayPool`1.DefaultMaxArrayLength">
<summary>The default maximum length of each array in the pool (2^20).</summary>
</member>
<member name="F:System.Buffers.DefaultArrayPool`1.DefaultMaxNumberOfArraysPerBucket">
<summary>The default maximum number of arrays per bucket that are available for rent.</summary>
</member>
<member name="F:System.Buffers.DefaultArrayPool`1.s_emptyArray">
<summary>Lazily-allocated empty array used when arrays of length 0 are requested.</summary>
</member>
<member name="P:System.Buffers.DefaultArrayPool`1.Id">
<summary>Gets an ID for the pool to use with events.</summary>
</member>
<member name="T:System.Buffers.DefaultArrayPool`1.Bucket">
<summary>Provides a thread-safe bucket containing buffers that can be Rent'd and Return'd.</summary>
</member>
<member name="M:System.Buffers.DefaultArrayPool`1.Bucket.#ctor(System.Int32,System.Int32,System.Int32)">
<summary>
Creates the pool with numberOfBuffers arrays where each buffer is of bufferLength length.
</summary>
</member>
<member name="P:System.Buffers.DefaultArrayPool`1.Bucket.Id">
<summary>Gets an ID for the bucket to use with events.</summary>
</member>
<member name="M:System.Buffers.DefaultArrayPool`1.Bucket.Rent">
<summary>Takes an array from the bucket. If the bucket is empty, returns null.</summary>
</member>
<member name="M:System.Buffers.DefaultArrayPool`1.Bucket.Return(`0[])">
<summary>
Attempts to return the buffer to the bucket. If successful, the buffer will be stored
in the bucket and true will be returned; otherwise, the buffer won't be stored, and false
will be returned.
</summary>
</member>
<member name="P:System.SR.ArgumentException_BufferNotFromPool">
<summary>The buffer is not associated with this pool and may not be returned to it.</summary>
</member>
</members>
</doc>

BIN
bin/Debug/System.CodeDom.dll Executable file

Binary file not shown.

4454
bin/Debug/System.CodeDom.xml Executable file

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

BIN
bin/Debug/System.Formats.Asn1.dll Executable file

Binary file not shown.

4472
bin/Debug/System.Formats.Asn1.xml Executable file

File diff suppressed because it is too large Load Diff

BIN
bin/Debug/System.Memory.dll Executable file

Binary file not shown.

3489
bin/Debug/System.Memory.xml Executable file

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

View File

@@ -0,0 +1,353 @@
<?xml version="1.0"?>
<doc>
<assembly>
<name>System.Runtime.CompilerServices.Unsafe</name>
</assembly>
<members>
<member name="T:System.Runtime.CompilerServices.Unsafe">
<summary>
Contains generic, low-level functionality for manipulating pointers.
</summary>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Read``1(System.Void*)">
<summary>
Reads a value of type <typeparamref name="T"/> from the given location.
</summary>
<typeparam name="T">The type to read.</typeparam>
<param name="source">The location to read from.</param>
<returns>An object of type <typeparamref name="T"/> read from the given location.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.ReadUnaligned``1(System.Void*)">
<summary>
Reads a value of type <typeparamref name="T"/> from the given location.
</summary>
<typeparam name="T">The type to read.</typeparam>
<param name="source">The location to read from.</param>
<returns>An object of type <typeparamref name="T"/> read from the given location.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.ReadUnaligned``1(System.Byte@)">
<summary>
Reads a value of type <typeparamref name="T"/> from the given location.
</summary>
<typeparam name="T">The type to read.</typeparam>
<param name="source">The location to read from.</param>
<returns>An object of type <typeparamref name="T"/> read from the given location.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Write``1(System.Void*,``0)">
<summary>
Writes a value of type <typeparamref name="T"/> to the given location.
</summary>
<typeparam name="T">The type of value to write.</typeparam>
<param name="destination">The location to write to.</param>
<param name="value">The value to write.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.WriteUnaligned``1(System.Void*,``0)">
<summary>
Writes a value of type <typeparamref name="T"/> to the given location.
</summary>
<typeparam name="T">The type of value to write.</typeparam>
<param name="destination">The location to write to.</param>
<param name="value">The value to write.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.WriteUnaligned``1(System.Byte@,``0)">
<summary>
Writes a value of type <typeparamref name="T"/> to the given location.
</summary>
<typeparam name="T">The type of value to write.</typeparam>
<param name="destination">The location to write to.</param>
<param name="value">The value to write.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Copy``1(System.Void*,``0@)">
<summary>
Copies a value of type <typeparamref name="T"/> to the given location.
</summary>
<typeparam name="T">The type of value to copy.</typeparam>
<param name="destination">The location to copy to.</param>
<param name="source">A reference to the value to copy.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Copy``1(``0@,System.Void*)">
<summary>
Copies a value of type <typeparamref name="T"/> to the given location.
</summary>
<typeparam name="T">The type of value to copy.</typeparam>
<param name="destination">The location to copy to.</param>
<param name="source">A pointer to the value to copy.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.AsPointer``1(``0@)">
<summary>
Returns a pointer to the given by-ref parameter.
</summary>
<typeparam name="T">The type of object.</typeparam>
<param name="value">The object whose pointer is obtained.</param>
<returns>A pointer to the given value.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.SizeOf``1">
<summary>
Returns the size of an object of the given type parameter.
</summary>
<typeparam name="T">The type of object whose size is retrieved.</typeparam>
<returns>The size of an object of type <typeparamref name="T"/>.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.As``1(System.Object)">
<summary>
Casts the given object to the specified type, performs no dynamic type checking.
</summary>
<typeparam name="T">The type which the object will be cast to.</typeparam>
<param name="o">The object to cast.</param>
<returns>The original object, casted to the given type.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.AsRef``1(System.Void*)">
<summary>
Reinterprets the given location as a reference to a value of type <typeparamref name="T"/>.
</summary>
<typeparam name="T">The type of the interpreted location.</typeparam>
<param name="source">The location of the value to reference.</param>
<returns>A reference to a value of type <typeparamref name="T"/>.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.AsRef``1(``0@)">
<summary>
Reinterprets the given read-only reference as a reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The read-only reference to reinterpret.</param>
<returns>A reference to a value of type <typeparamref name="T"/>.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.As``2(``0@)">
<summary>
Reinterprets the given reference as a reference to a value of type <typeparamref name="TTo"/>.
</summary>
<typeparam name="TFrom">The type of reference to reinterpret.</typeparam>
<typeparam name="TTo">The desired type of the reference.</typeparam>
<param name="source">The reference to reinterpret.</param>
<returns>A reference to a value of type <typeparamref name="TTo"/>.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Unbox``1(System.Object)">
<summary>
Returns a reference to the value type contained with the specified box object.
</summary>
<typeparam name="T">The type of the value type contained within the box.</typeparam>
<param name="box">The boxed value type.</param>
<returns>A reference to a value of type <typeparamref name="T"/> in the box object.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Add``1(``0@,System.Int32)">
<summary>
Adds an element offset to the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to add the offset to.</param>
<param name="elementOffset">The offset to add.</param>
<returns>A new reference that reflects the addition of offset to pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Add``1(System.Void*,System.Int32)">
<summary>
Adds an element offset to the given pointer.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The pointer to add the offset to.</param>
<param name="elementOffset">The offset to add.</param>
<returns>A new pointer that reflects the addition of offset to pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Add``1(``0@,System.IntPtr)">
<summary>
Adds an element offset to the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to add the offset to.</param>
<param name="elementOffset">The offset to add.</param>
<returns>A new reference that reflects the addition of offset to pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Add``1(``0@,System.UIntPtr)">
<summary>
Adds an element offset to the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to add the offset to.</param>
<param name="elementOffset">The offset to add.</param>
<returns>A new reference that reflects the addition of offset to pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.AddByteOffset``1(``0@,System.IntPtr)">
<summary>
Adds a byte offset to the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to add the offset to.</param>
<param name="byteOffset">The offset to add.</param>
<returns>A new reference that reflects the addition of byte offset to pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.AddByteOffset``1(``0@,System.UIntPtr)">
<summary>
Adds a byte offset to the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to add the offset to.</param>
<param name="byteOffset">The offset to add.</param>
<returns>A new reference that reflects the addition of byte offset to pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Subtract``1(``0@,System.Int32)">
<summary>
Subtracts an element offset from the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to subtract the offset from.</param>
<param name="elementOffset">The offset to subtract.</param>
<returns>A new reference that reflects the subraction of offset from pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Subtract``1(``0@,System.IntPtr)">
<summary>
Subtracts an element offset from the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to subtract the offset from.</param>
<param name="elementOffset">The offset to subtract.</param>
<returns>A new reference that reflects the subraction of offset from pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.Subtract``1(``0@,System.UIntPtr)">
<summary>
Subtracts an element offset from the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to subtract the offset from.</param>
<param name="elementOffset">The offset to subtract.</param>
<returns>A new reference that reflects the subraction of offset from pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.SubtractByteOffset``1(``0@,System.IntPtr)">
<summary>
Subtracts a byte offset from the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to subtract the offset from.</param>
<param name="byteOffset">The offset to subtract.</param>
<returns>A new reference that reflects the subraction of byte offset from pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.SubtractByteOffset``1(``0@,System.UIntPtr)">
<summary>
Subtracts a byte offset from the given reference.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="source">The reference to subtract the offset from.</param>
<param name="byteOffset">The offset to subtract.</param>
<returns>A new reference that reflects the subraction of byte offset from pointer.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.ByteOffset``1(``0@,``0@)">
<summary>
Determines the byte offset from origin to target from the given references.
</summary>
<typeparam name="T">The type of reference.</typeparam>
<param name="origin">The reference to origin.</param>
<param name="target">The reference to target.</param>
<returns>Byte offset from origin to target i.e. <paramref name="target"/> - <paramref name="origin"/>.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.AreSame``1(``0@,``0@)">
<summary>
Determines whether the specified references point to the same location.
</summary>
<param name="left">The first reference to compare.</param>
<param name="right">The second reference to compare.</param>
<returns><c>true</c> if <paramref name="left"/> and <paramref name="right"/> point to the same location; otherwise <c>false</c>.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.IsAddressGreaterThan``1(``0@,``0@)">
<summary>
Determines whether the memory address referenced by <paramref name="left"/> is greater than the memory address referenced by <paramref name="right"/>.
</summary>
<param name="left">The first reference to compare.</param>
<param name="right">The second reference to compare.</param>
<returns><c>true</c> if the memory address referenced by <paramref name="left"/> is greater than the memory address referenced by <paramref name="right"/>; otherwise <c>false</c>.</returns>
<remarks>
This check is conceptually similar to "(void*)(&amp;left) &gt; (void*)(&amp;right)". Both parameters must reference the same object, array, or span;
or the objects being referenced must both be pinned; or both references must represent unmanaged pointers; otherwise the result is undefined.
</remarks>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.IsAddressLessThan``1(``0@,``0@)">
<summary>
Determines whether the memory address referenced by <paramref name="left"/> is less than the memory address referenced by <paramref name="right"/>.
</summary>
<param name="left">The first reference to compare.</param>
<param name="right">The second reference to compare.</param>
<returns><c>true</c> if the memory address referenced by <paramref name="left"/> is less than the memory address referenced by <paramref name="right"/>; otherwise <c>false</c>.</returns>
<remarks>
This check is conceptually similar to "(void*)(&amp;left) &lt; (void*)(&amp;right)". Both parameters must reference the same object, array, or span;
or the objects being referenced must both be pinned; or both references must represent unmanaged pointers; otherwise the result is undefined.
</remarks>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.IsNullRef``1(``0@)">
<summary>
Returns if a given reference to a value of type <typeparamref name="T"/> is a null reference.
</summary>
<param name="source">The reference to check.</param>
<remarks>This check is conceptually similar to "(void*)(&amp;source) == nullptr".</remarks>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.NullRef``1">
<summary>
Returns a reference to a value of type <typeparamref name="T"/> that is a null reference.
</summary>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.CopyBlock(System.Void*,System.Void*,System.UInt32)">
<summary>
Copies bytes from the source address to the destination address.
</summary>
<param name="destination">The destination address to copy to.</param>
<param name="source">The source address to copy from.</param>
<param name="byteCount">The number of bytes to copy.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.CopyBlock(System.Byte@,System.Byte@,System.UInt32)">
<summary>
Copies bytes from the source address to the destination address.
</summary>
<param name="destination">The destination address to copy to.</param>
<param name="source">The source address to copy from.</param>
<param name="byteCount">The number of bytes to copy.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.CopyBlockUnaligned(System.Void*,System.Void*,System.UInt32)">
<summary>
Copies bytes from the source address to the destination address
without assuming architecture dependent alignment of the addresses.
</summary>
<param name="destination">The destination address to copy to.</param>
<param name="source">The source address to copy from.</param>
<param name="byteCount">The number of bytes to copy.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.CopyBlockUnaligned(System.Byte@,System.Byte@,System.UInt32)">
<summary>
Copies bytes from the source address to the destination address
without assuming architecture dependent alignment of the addresses.
</summary>
<param name="destination">The destination address to copy to.</param>
<param name="source">The source address to copy from.</param>
<param name="byteCount">The number of bytes to copy.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.InitBlock(System.Void*,System.Byte,System.UInt32)">
<summary>
Initializes a block of memory at the given location with a given initial value.
</summary>
<param name="startAddress">The address of the start of the memory block to initialize.</param>
<param name="value">The value to initialize the block to.</param>
<param name="byteCount">The number of bytes to initialize.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.InitBlock(System.Byte@,System.Byte,System.UInt32)">
<summary>
Initializes a block of memory at the given location with a given initial value.
</summary>
<param name="startAddress">The address of the start of the memory block to initialize.</param>
<param name="value">The value to initialize the block to.</param>
<param name="byteCount">The number of bytes to initialize.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.InitBlockUnaligned(System.Void*,System.Byte,System.UInt32)">
<summary>
Initializes a block of memory at the given location with a given initial value
without assuming architecture dependent alignment of the address.
</summary>
<param name="startAddress">The address of the start of the memory block to initialize.</param>
<param name="value">The value to initialize the block to.</param>
<param name="byteCount">The number of bytes to initialize.</param>
</member>
<member name="M:System.Runtime.CompilerServices.Unsafe.InitBlockUnaligned(System.Byte@,System.Byte,System.UInt32)">
<summary>
Initializes a block of memory at the given location with a given initial value
without assuming architecture dependent alignment of the address.
</summary>
<param name="startAddress">The address of the start of the memory block to initialize.</param>
<param name="value">The value to initialize the block to.</param>
<param name="byteCount">The number of bytes to initialize.</param>
</member>
</members>
</doc>

Binary file not shown.

View File

@@ -0,0 +1,545 @@
<?xml version="1.0"?>
<doc>
<assembly>
<name>System.Threading.Tasks.Extensions</name>
</assembly>
<members>
<member name="T:System.Runtime.CompilerServices.AsyncMethodBuilderAttribute">
<summary>
Indicates the type of the async method builder that should be used by a language compiler to
build the attributed type when used as the return type of an async method.
</summary>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncMethodBuilderAttribute.#ctor(System.Type)">
<summary>Initializes the <see cref="T:System.Runtime.CompilerServices.AsyncMethodBuilderAttribute"/>.</summary>
<param name="builderType">The <see cref="T:System.Type"/> of the associated builder.</param>
</member>
<member name="P:System.Runtime.CompilerServices.AsyncMethodBuilderAttribute.BuilderType">
<summary>Gets the <see cref="T:System.Type"/> of the associated builder.</summary>
</member>
<member name="T:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder">
<summary>Represents a builder for asynchronous methods that return a <see cref="T:System.Threading.Tasks.ValueTask"/>.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder._methodBuilder">
<summary>The <see cref="T:System.Runtime.CompilerServices.AsyncTaskMethodBuilder"/> to which most operations are delegated.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder._haveResult">
<summary>true if completed synchronously and successfully; otherwise, false.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder._useBuilder">
<summary>true if the builder should be used for setting/getting the result; otherwise, false.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder.Create">
<summary>Creates an instance of the <see cref="T:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder"/> struct.</summary>
<returns>The initialized instance.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder.Start``1(``0@)">
<summary>Begins running the builder with the associated state machine.</summary>
<typeparam name="TStateMachine">The type of the state machine.</typeparam>
<param name="stateMachine">The state machine instance, passed by reference.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder.SetStateMachine(System.Runtime.CompilerServices.IAsyncStateMachine)">
<summary>Associates the builder with the specified state machine.</summary>
<param name="stateMachine">The state machine instance to associate with the builder.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder.SetResult">
<summary>Marks the task as successfully completed.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder.SetException(System.Exception)">
<summary>Marks the task as failed and binds the specified exception to the task.</summary>
<param name="exception">The exception to bind to the task.</param>
</member>
<member name="P:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder.Task">
<summary>Gets the task for this builder.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder.AwaitOnCompleted``2(``0@,``1@)">
<summary>Schedules the state machine to proceed to the next action when the specified awaiter completes.</summary>
<typeparam name="TAwaiter">The type of the awaiter.</typeparam>
<typeparam name="TStateMachine">The type of the state machine.</typeparam>
<param name="awaiter">The awaiter.</param>
<param name="stateMachine">The state machine.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder.AwaitUnsafeOnCompleted``2(``0@,``1@)">
<summary>Schedules the state machine to proceed to the next action when the specified awaiter completes.</summary>
<typeparam name="TAwaiter">The type of the awaiter.</typeparam>
<typeparam name="TStateMachine">The type of the state machine.</typeparam>
<param name="awaiter">The awaiter.</param>
<param name="stateMachine">The state machine.</param>
</member>
<member name="T:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1">
<summary>Represents a builder for asynchronous methods that returns a <see cref="T:System.Threading.Tasks.ValueTask`1"/>.</summary>
<typeparam name="TResult">The type of the result.</typeparam>
</member>
<member name="F:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1._methodBuilder">
<summary>The <see cref="T:System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1"/> to which most operations are delegated.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1._result">
<summary>The result for this builder, if it's completed before any awaits occur.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1._haveResult">
<summary>true if <see cref="F:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1._result"/> contains the synchronous result for the async method; otherwise, false.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1._useBuilder">
<summary>true if the builder should be used for setting/getting the result; otherwise, false.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1.Create">
<summary>Creates an instance of the <see cref="T:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1"/> struct.</summary>
<returns>The initialized instance.</returns>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1.Start``1(``0@)">
<summary>Begins running the builder with the associated state machine.</summary>
<typeparam name="TStateMachine">The type of the state machine.</typeparam>
<param name="stateMachine">The state machine instance, passed by reference.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1.SetStateMachine(System.Runtime.CompilerServices.IAsyncStateMachine)">
<summary>Associates the builder with the specified state machine.</summary>
<param name="stateMachine">The state machine instance to associate with the builder.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1.SetResult(`0)">
<summary>Marks the task as successfully completed.</summary>
<param name="result">The result to use to complete the task.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1.SetException(System.Exception)">
<summary>Marks the task as failed and binds the specified exception to the task.</summary>
<param name="exception">The exception to bind to the task.</param>
</member>
<member name="P:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1.Task">
<summary>Gets the task for this builder.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1.AwaitOnCompleted``2(``0@,``1@)">
<summary>Schedules the state machine to proceed to the next action when the specified awaiter completes.</summary>
<typeparam name="TAwaiter">The type of the awaiter.</typeparam>
<typeparam name="TStateMachine">The type of the state machine.</typeparam>
<param name="awaiter">the awaiter</param>
<param name="stateMachine">The state machine.</param>
</member>
<member name="M:System.Runtime.CompilerServices.AsyncValueTaskMethodBuilder`1.AwaitUnsafeOnCompleted``2(``0@,``1@)">
<summary>Schedules the state machine to proceed to the next action when the specified awaiter completes.</summary>
<typeparam name="TAwaiter">The type of the awaiter.</typeparam>
<typeparam name="TStateMachine">The type of the state machine.</typeparam>
<param name="awaiter">the awaiter</param>
<param name="stateMachine">The state machine.</param>
</member>
<member name="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable">
<summary>Provides an awaitable type that enables configured awaits on a <see cref="T:System.Threading.Tasks.ValueTask"/>.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable._value">
<summary>The wrapped <see cref="T:System.Threading.Tasks.Task"/>.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable.#ctor(System.Threading.Tasks.ValueTask)">
<summary>Initializes the awaitable.</summary>
<param name="value">The wrapped <see cref="T:System.Threading.Tasks.ValueTask"/>.</param>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable.GetAwaiter">
<summary>Returns an awaiter for this <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable"/> instance.</summary>
</member>
<member name="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable.ConfiguredValueTaskAwaiter">
<summary>Provides an awaiter for a <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable"/>.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable.ConfiguredValueTaskAwaiter._value">
<summary>The value being awaited.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable.ConfiguredValueTaskAwaiter.#ctor(System.Threading.Tasks.ValueTask)">
<summary>Initializes the awaiter.</summary>
<param name="value">The value to be awaited.</param>
</member>
<member name="P:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable.ConfiguredValueTaskAwaiter.IsCompleted">
<summary>Gets whether the <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable"/> has completed.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable.ConfiguredValueTaskAwaiter.GetResult">
<summary>Gets the result of the ValueTask.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable.ConfiguredValueTaskAwaiter.OnCompleted(System.Action)">
<summary>Schedules the continuation action for the <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable"/>.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable.ConfiguredValueTaskAwaiter.UnsafeOnCompleted(System.Action)">
<summary>Schedules the continuation action for the <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable"/>.</summary>
</member>
<member name="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1">
<summary>Provides an awaitable type that enables configured awaits on a <see cref="T:System.Threading.Tasks.ValueTask`1"/>.</summary>
<typeparam name="TResult">The type of the result produced.</typeparam>
</member>
<member name="F:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1._value">
<summary>The wrapped <see cref="T:System.Threading.Tasks.ValueTask`1"/>.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1.#ctor(System.Threading.Tasks.ValueTask{`0})">
<summary>Initializes the awaitable.</summary>
<param name="value">The wrapped <see cref="T:System.Threading.Tasks.ValueTask`1"/>.</param>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1.GetAwaiter">
<summary>Returns an awaiter for this <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1"/> instance.</summary>
</member>
<member name="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1.ConfiguredValueTaskAwaiter">
<summary>Provides an awaiter for a <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1"/>.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1.ConfiguredValueTaskAwaiter._value">
<summary>The value being awaited.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1.ConfiguredValueTaskAwaiter.#ctor(System.Threading.Tasks.ValueTask{`0})">
<summary>Initializes the awaiter.</summary>
<param name="value">The value to be awaited.</param>
</member>
<member name="P:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1.ConfiguredValueTaskAwaiter.IsCompleted">
<summary>Gets whether the <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1"/> has completed.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1.ConfiguredValueTaskAwaiter.GetResult">
<summary>Gets the result of the ValueTask.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1.ConfiguredValueTaskAwaiter.OnCompleted(System.Action)">
<summary>Schedules the continuation action for the <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1"/>.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1.ConfiguredValueTaskAwaiter.UnsafeOnCompleted(System.Action)">
<summary>Schedules the continuation action for the <see cref="T:System.Runtime.CompilerServices.ConfiguredValueTaskAwaitable`1"/>.</summary>
</member>
<member name="T:System.Runtime.CompilerServices.ValueTaskAwaiter">
<summary>Provides an awaiter for a <see cref="T:System.Threading.Tasks.ValueTask"/>.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.ValueTaskAwaiter.s_invokeActionDelegate">
<summary>Shim used to invoke an <see cref="T:System.Action"/> passed as the state argument to a <see cref="T:System.Action`1"/>.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.ValueTaskAwaiter._value">
<summary>The value being awaited.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ValueTaskAwaiter.#ctor(System.Threading.Tasks.ValueTask)">
<summary>Initializes the awaiter.</summary>
<param name="value">The value to be awaited.</param>
</member>
<member name="P:System.Runtime.CompilerServices.ValueTaskAwaiter.IsCompleted">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask"/> has completed.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ValueTaskAwaiter.GetResult">
<summary>Gets the result of the ValueTask.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ValueTaskAwaiter.OnCompleted(System.Action)">
<summary>Schedules the continuation action for this ValueTask.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ValueTaskAwaiter.UnsafeOnCompleted(System.Action)">
<summary>Schedules the continuation action for this ValueTask.</summary>
</member>
<member name="T:System.Runtime.CompilerServices.ValueTaskAwaiter`1">
<summary>Provides an awaiter for a <see cref="T:System.Threading.Tasks.ValueTask`1"/>.</summary>
</member>
<member name="F:System.Runtime.CompilerServices.ValueTaskAwaiter`1._value">
<summary>The value being awaited.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ValueTaskAwaiter`1.#ctor(System.Threading.Tasks.ValueTask{`0})">
<summary>Initializes the awaiter.</summary>
<param name="value">The value to be awaited.</param>
</member>
<member name="P:System.Runtime.CompilerServices.ValueTaskAwaiter`1.IsCompleted">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask`1"/> has completed.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ValueTaskAwaiter`1.GetResult">
<summary>Gets the result of the ValueTask.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ValueTaskAwaiter`1.OnCompleted(System.Action)">
<summary>Schedules the continuation action for this ValueTask.</summary>
</member>
<member name="M:System.Runtime.CompilerServices.ValueTaskAwaiter`1.UnsafeOnCompleted(System.Action)">
<summary>Schedules the continuation action for this ValueTask.</summary>
</member>
<member name="T:System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags">
<summary>
Flags passed from <see cref="T:System.Threading.Tasks.ValueTask"/> and <see cref="T:System.Threading.Tasks.ValueTask`1"/> to
<see cref="M:System.Threading.Tasks.Sources.IValueTaskSource.OnCompleted(System.Action{System.Object},System.Object,System.Int16,System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags)"/> and <see cref="M:System.Threading.Tasks.Sources.IValueTaskSource`1.OnCompleted(System.Action{System.Object},System.Object,System.Int16,System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags)"/>
to control behavior.
</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags.None">
<summary>
No requirements are placed on how the continuation is invoked.
</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags.UseSchedulingContext">
<summary>
Set if OnCompleted should capture the current scheduling context (e.g. SynchronizationContext)
and use it when queueing the continuation for execution. If this is not set, the implementation
may choose to execute the continuation in an arbitrary location.
</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags.FlowExecutionContext">
<summary>
Set if OnCompleted should capture the current ExecutionContext and use it to run the continuation.
</summary>
</member>
<member name="T:System.Threading.Tasks.Sources.ValueTaskSourceStatus">
<summary>Indicates the status of an <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/> or <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ValueTaskSourceStatus.Pending">
<summary>The operation has not yet completed.</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ValueTaskSourceStatus.Succeeded">
<summary>The operation completed successfully.</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ValueTaskSourceStatus.Faulted">
<summary>The operation completed with an error.</summary>
</member>
<member name="F:System.Threading.Tasks.Sources.ValueTaskSourceStatus.Canceled">
<summary>The operation completed due to cancellation.</summary>
</member>
<member name="T:System.Threading.Tasks.Sources.IValueTaskSource">
<summary>Represents an object that can be wrapped by a <see cref="T:System.Threading.Tasks.ValueTask"/>.</summary>
</member>
<member name="M:System.Threading.Tasks.Sources.IValueTaskSource.GetStatus(System.Int16)">
<summary>Gets the status of the current operation.</summary>
<param name="token">Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask"/>'s constructor.</param>
</member>
<member name="M:System.Threading.Tasks.Sources.IValueTaskSource.OnCompleted(System.Action{System.Object},System.Object,System.Int16,System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags)">
<summary>Schedules the continuation action for this <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</summary>
<param name="continuation">The continuation to invoke when the operation has completed.</param>
<param name="state">The state object to pass to <paramref name="continuation"/> when it's invoked.</param>
<param name="token">Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask"/>'s constructor.</param>
<param name="flags">The flags describing the behavior of the continuation.</param>
</member>
<member name="M:System.Threading.Tasks.Sources.IValueTaskSource.GetResult(System.Int16)">
<summary>Gets the result of the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</summary>
<param name="token">Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask"/>'s constructor.</param>
</member>
<member name="T:System.Threading.Tasks.Sources.IValueTaskSource`1">
<summary>Represents an object that can be wrapped by a <see cref="T:System.Threading.Tasks.ValueTask`1"/>.</summary>
<typeparam name="TResult">Specifies the type of data returned from the object.</typeparam>
</member>
<member name="M:System.Threading.Tasks.Sources.IValueTaskSource`1.GetStatus(System.Int16)">
<summary>Gets the status of the current operation.</summary>
<param name="token">Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask"/>'s constructor.</param>
</member>
<member name="M:System.Threading.Tasks.Sources.IValueTaskSource`1.OnCompleted(System.Action{System.Object},System.Object,System.Int16,System.Threading.Tasks.Sources.ValueTaskSourceOnCompletedFlags)">
<summary>Schedules the continuation action for this <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/>.</summary>
<param name="continuation">The continuation to invoke when the operation has completed.</param>
<param name="state">The state object to pass to <paramref name="continuation"/> when it's invoked.</param>
<param name="token">Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask"/>'s constructor.</param>
<param name="flags">The flags describing the behavior of the continuation.</param>
</member>
<member name="M:System.Threading.Tasks.Sources.IValueTaskSource`1.GetResult(System.Int16)">
<summary>Gets the result of the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/>.</summary>
<param name="token">Opaque value that was provided to the <see cref="T:System.Threading.Tasks.ValueTask"/>'s constructor.</param>
</member>
<member name="T:System.Threading.Tasks.ValueTask">
<summary>Provides an awaitable result of an asynchronous operation.</summary>
<remarks>
<see cref="T:System.Threading.Tasks.ValueTask"/>s are meant to be directly awaited. To do more complicated operations with them, a <see cref="T:System.Threading.Tasks.Task"/>
should be extracted using <see cref="M:System.Threading.Tasks.ValueTask.AsTask"/>. Such operations might include caching an instance to be awaited later,
registering multiple continuations with a single operation, awaiting the same task multiple times, and using combinators over
multiple operations.
</remarks>
</member>
<member name="F:System.Threading.Tasks.ValueTask.s_canceledTask">
<summary>A task canceled using `new CancellationToken(true)`.</summary>
</member>
<member name="P:System.Threading.Tasks.ValueTask.CompletedTask">
<summary>A successfully completed task.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask._obj">
<summary>null if representing a successful synchronous completion, otherwise a <see cref="T:System.Threading.Tasks.Task"/> or a <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask._token">
<summary>Opaque value passed through to the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask._continueOnCapturedContext">
<summary>true to continue on the capture context; otherwise, true.</summary>
<remarks>Stored in the <see cref="T:System.Threading.Tasks.ValueTask"/> rather than in the configured awaiter to utilize otherwise padding space.</remarks>
</member>
<member name="M:System.Threading.Tasks.ValueTask.#ctor(System.Threading.Tasks.Task)">
<summary>Initialize the <see cref="T:System.Threading.Tasks.ValueTask"/> with a <see cref="T:System.Threading.Tasks.Task"/> that represents the operation.</summary>
<param name="task">The task.</param>
</member>
<member name="M:System.Threading.Tasks.ValueTask.#ctor(System.Threading.Tasks.Sources.IValueTaskSource,System.Int16)">
<summary>Initialize the <see cref="T:System.Threading.Tasks.ValueTask"/> with a <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/> object that represents the operation.</summary>
<param name="source">The source.</param>
<param name="token">Opaque value passed through to the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</param>
</member>
<member name="M:System.Threading.Tasks.ValueTask.GetHashCode">
<summary>Returns the hash code for this instance.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask.Equals(System.Object)">
<summary>Returns a value indicating whether this value is equal to a specified <see cref="T:System.Object"/>.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask.Equals(System.Threading.Tasks.ValueTask)">
<summary>Returns a value indicating whether this value is equal to a specified <see cref="T:System.Threading.Tasks.ValueTask"/> value.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask.op_Equality(System.Threading.Tasks.ValueTask,System.Threading.Tasks.ValueTask)">
<summary>Returns a value indicating whether two <see cref="T:System.Threading.Tasks.ValueTask"/> values are equal.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask.op_Inequality(System.Threading.Tasks.ValueTask,System.Threading.Tasks.ValueTask)">
<summary>Returns a value indicating whether two <see cref="T:System.Threading.Tasks.ValueTask"/> values are not equal.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask.AsTask">
<summary>
Gets a <see cref="T:System.Threading.Tasks.Task"/> object to represent this ValueTask.
</summary>
<remarks>
It will either return the wrapped task object if one exists, or it'll
manufacture a new task object to represent the result.
</remarks>
</member>
<member name="M:System.Threading.Tasks.ValueTask.Preserve">
<summary>Gets a <see cref="T:System.Threading.Tasks.ValueTask"/> that may be used at any point in the future.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask.GetTaskForValueTaskSource(System.Threading.Tasks.Sources.IValueTaskSource)">
<summary>Creates a <see cref="T:System.Threading.Tasks.Task"/> to represent the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</summary>
<remarks>
The <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/> is passed in rather than reading and casting <see cref="F:System.Threading.Tasks.ValueTask._obj"/>
so that the caller can pass in an object it's already validated.
</remarks>
</member>
<member name="T:System.Threading.Tasks.ValueTask.ValueTaskSourceAsTask">
<summary>Type used to create a <see cref="T:System.Threading.Tasks.Task"/> to represent a <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask.ValueTaskSourceAsTask._source">
<summary>The associated <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask.ValueTaskSourceAsTask._token">
<summary>The token to pass through to operations on <see cref="F:System.Threading.Tasks.ValueTask.ValueTaskSourceAsTask._source"/></summary>
</member>
<member name="P:System.Threading.Tasks.ValueTask.IsCompleted">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask"/> represents a completed operation.</summary>
</member>
<member name="P:System.Threading.Tasks.ValueTask.IsCompletedSuccessfully">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask"/> represents a successfully completed operation.</summary>
</member>
<member name="P:System.Threading.Tasks.ValueTask.IsFaulted">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask"/> represents a failed operation.</summary>
</member>
<member name="P:System.Threading.Tasks.ValueTask.IsCanceled">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask"/> represents a canceled operation.</summary>
<remarks>
If the <see cref="T:System.Threading.Tasks.ValueTask"/> is backed by a result or by a <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>,
this will always return false. If it's backed by a <see cref="T:System.Threading.Tasks.Task"/>, it'll return the
value of the task's <see cref="P:System.Threading.Tasks.Task.IsCanceled"/> property.
</remarks>
</member>
<member name="M:System.Threading.Tasks.ValueTask.ThrowIfCompletedUnsuccessfully">
<summary>Throws the exception that caused the <see cref="T:System.Threading.Tasks.ValueTask"/> to fail. If it completed successfully, nothing is thrown.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask.GetAwaiter">
<summary>Gets an awaiter for this <see cref="T:System.Threading.Tasks.ValueTask"/>.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask.ConfigureAwait(System.Boolean)">
<summary>Configures an awaiter for this <see cref="T:System.Threading.Tasks.ValueTask"/>.</summary>
<param name="continueOnCapturedContext">
true to attempt to marshal the continuation back to the captured context; otherwise, false.
</param>
</member>
<member name="T:System.Threading.Tasks.ValueTask`1">
<summary>Provides a value type that can represent a synchronously available value or a task object.</summary>
<typeparam name="TResult">Specifies the type of the result.</typeparam>
<remarks>
<see cref="T:System.Threading.Tasks.ValueTask`1"/>s are meant to be directly awaited. To do more complicated operations with them, a <see cref="T:System.Threading.Tasks.Task"/>
should be extracted using <see cref="M:System.Threading.Tasks.ValueTask`1.AsTask"/> or <see cref="M:System.Threading.Tasks.ValueTask`1.Preserve"/>. Such operations might include caching an instance to
be awaited later, registering multiple continuations with a single operation, awaiting the same task multiple times, and using
combinators over multiple operations.
</remarks>
</member>
<member name="F:System.Threading.Tasks.ValueTask`1.s_canceledTask">
<summary>A task canceled using `new CancellationToken(true)`. Lazily created only when first needed.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask`1._obj">
<summary>null if <see cref="F:System.Threading.Tasks.ValueTask`1._result"/> has the result, otherwise a <see cref="T:System.Threading.Tasks.Task`1"/> or a <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask`1._result">
<summary>The result to be used if the operation completed successfully synchronously.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask`1._token">
<summary>Opaque value passed through to the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask`1._continueOnCapturedContext">
<summary>true to continue on the captured context; otherwise, false.</summary>
<remarks>Stored in the <see cref="T:System.Threading.Tasks.ValueTask`1"/> rather than in the configured awaiter to utilize otherwise padding space.</remarks>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.#ctor(`0)">
<summary>Initialize the <see cref="T:System.Threading.Tasks.ValueTask`1"/> with a <typeparamref name="TResult"/> result value.</summary>
<param name="result">The result.</param>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.#ctor(System.Threading.Tasks.Task{`0})">
<summary>Initialize the <see cref="T:System.Threading.Tasks.ValueTask`1"/> with a <see cref="T:System.Threading.Tasks.Task`1"/> that represents the operation.</summary>
<param name="task">The task.</param>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.#ctor(System.Threading.Tasks.Sources.IValueTaskSource{`0},System.Int16)">
<summary>Initialize the <see cref="T:System.Threading.Tasks.ValueTask`1"/> with a <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/> object that represents the operation.</summary>
<param name="source">The source.</param>
<param name="token">Opaque value passed through to the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</param>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.#ctor(System.Object,`0,System.Int16,System.Boolean)">
<summary>Non-verified initialization of the struct to the specified values.</summary>
<param name="obj">The object.</param>
<param name="result">The result.</param>
<param name="token">The token.</param>
<param name="continueOnCapturedContext">true to continue on captured context; otherwise, false.</param>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.GetHashCode">
<summary>Returns the hash code for this instance.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.Equals(System.Object)">
<summary>Returns a value indicating whether this value is equal to a specified <see cref="T:System.Object"/>.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.Equals(System.Threading.Tasks.ValueTask{`0})">
<summary>Returns a value indicating whether this value is equal to a specified <see cref="T:System.Threading.Tasks.ValueTask`1"/> value.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.op_Equality(System.Threading.Tasks.ValueTask{`0},System.Threading.Tasks.ValueTask{`0})">
<summary>Returns a value indicating whether two <see cref="T:System.Threading.Tasks.ValueTask`1"/> values are equal.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.op_Inequality(System.Threading.Tasks.ValueTask{`0},System.Threading.Tasks.ValueTask{`0})">
<summary>Returns a value indicating whether two <see cref="T:System.Threading.Tasks.ValueTask`1"/> values are not equal.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.AsTask">
<summary>
Gets a <see cref="T:System.Threading.Tasks.Task`1"/> object to represent this ValueTask.
</summary>
<remarks>
It will either return the wrapped task object if one exists, or it'll
manufacture a new task object to represent the result.
</remarks>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.Preserve">
<summary>Gets a <see cref="T:System.Threading.Tasks.ValueTask`1"/> that may be used at any point in the future.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.GetTaskForValueTaskSource(System.Threading.Tasks.Sources.IValueTaskSource{`0})">
<summary>Creates a <see cref="T:System.Threading.Tasks.Task`1"/> to represent the <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/>.</summary>
<remarks>
The <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/> is passed in rather than reading and casting <see cref="F:System.Threading.Tasks.ValueTask`1._obj"/>
so that the caller can pass in an object it's already validated.
</remarks>
</member>
<member name="T:System.Threading.Tasks.ValueTask`1.ValueTaskSourceAsTask">
<summary>Type used to create a <see cref="T:System.Threading.Tasks.Task`1"/> to represent a <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask`1.ValueTaskSourceAsTask._source">
<summary>The associated <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource"/>.</summary>
</member>
<member name="F:System.Threading.Tasks.ValueTask`1.ValueTaskSourceAsTask._token">
<summary>The token to pass through to operations on <see cref="F:System.Threading.Tasks.ValueTask`1.ValueTaskSourceAsTask._source"/></summary>
</member>
<member name="P:System.Threading.Tasks.ValueTask`1.IsCompleted">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask`1"/> represents a completed operation.</summary>
</member>
<member name="P:System.Threading.Tasks.ValueTask`1.IsCompletedSuccessfully">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask`1"/> represents a successfully completed operation.</summary>
</member>
<member name="P:System.Threading.Tasks.ValueTask`1.IsFaulted">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask`1"/> represents a failed operation.</summary>
</member>
<member name="P:System.Threading.Tasks.ValueTask`1.IsCanceled">
<summary>Gets whether the <see cref="T:System.Threading.Tasks.ValueTask`1"/> represents a canceled operation.</summary>
<remarks>
If the <see cref="T:System.Threading.Tasks.ValueTask`1"/> is backed by a result or by a <see cref="T:System.Threading.Tasks.Sources.IValueTaskSource`1"/>,
this will always return false. If it's backed by a <see cref="T:System.Threading.Tasks.Task"/>, it'll return the
value of the task's <see cref="P:System.Threading.Tasks.Task.IsCanceled"/> property.
</remarks>
</member>
<member name="P:System.Threading.Tasks.ValueTask`1.Result">
<summary>Gets the result.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.GetAwaiter">
<summary>Gets an awaiter for this <see cref="T:System.Threading.Tasks.ValueTask`1"/>.</summary>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.ConfigureAwait(System.Boolean)">
<summary>Configures an awaiter for this <see cref="T:System.Threading.Tasks.ValueTask`1"/>.</summary>
<param name="continueOnCapturedContext">
true to attempt to marshal the continuation back to the captured context; otherwise, false.
</param>
</member>
<member name="M:System.Threading.Tasks.ValueTask`1.ToString">
<summary>Gets a string-representation of this <see cref="T:System.Threading.Tasks.ValueTask`1"/>.</summary>
</member>
</members>
</doc>

File diff suppressed because it is too large Load Diff

BIN
bin/Debug/cdr-tool.exe Normal file

Binary file not shown.

View File

@@ -0,0 +1,56 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup>
<supportedRuntime version="v4.8" sku=".NETFramework,Version=v4.0" />
</startup>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Net.Http" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
</dependentAssembly>
</assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Buffers" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.5.0" newVersion="4.0.5.0" />
</dependentAssembly>
</assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Memory" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.5.0" newVersion="4.0.5.0" />
</dependentAssembly>
</assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Threading.Tasks.Extensions" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.2.4.0" newVersion="4.2.4.0" />
</dependentAssembly>
</assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="Microsoft.Bcl.AsyncInterfaces" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-10.0.0.1" newVersion="10.0.0.1" />
</dependentAssembly>
</assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Formats.Asn1" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-10.0.0.1" newVersion="10.0.0.1" />
</dependentAssembly>
</assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="Microsoft.Extensions.Logging.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-10.0.0.1" newVersion="10.0.0.1" />
</dependentAssembly>
</assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Numerics.Vectors" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.6.0" newVersion="4.1.6.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>

BIN
bin/Debug/cdr-tool.pdb Normal file

Binary file not shown.

View File

@@ -0,0 +1 @@
{"installed":{"client_id":"62734798094-2bd4m03i2n3d2342g0ceh38v121og7rj.apps.googleusercontent.com","project_id":"cdrtool-424301","auth_uri":"https://accounts.google.com/o/oauth2/auth","token_uri":"https://oauth2.googleapis.com/token","auth_provider_x509_cert_url":"https://www.googleapis.com/oauth2/v1/certs","client_secret":"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","redirect_uris":["http://localhost"]}}

1
bin/Debug/license.txt Normal file
View File

@@ -0,0 +1 @@
6tgol6olSSG6jBlanyWwo9h9XtAQjD//maSc6yKcZ61sndOUjcfJRZxOVrXwfsqcHoJp9xXCK2OxJ/2s0SWDqWXDoWBpqOUFoVcxZkT9p4PD8RzPIj1k57NAYzWC46m6CLEBIPvJZziD6eJ66siK0YEbTm/3p6ndOn5y5Gd0/rwrFW+NelOCW/heRDkNMhQCY2dofK/GS4Ru7e16TX7gmxPJGl89vAmEFLsvfWyGOL8=

1493
bin/Debug/logfile.txt Normal file

File diff suppressed because it is too large Load Diff

1
bin/Debug/test.sh Executable file
View File

@@ -0,0 +1 @@
mono ./cdr-tool.exe -u sip@macintoshes.ca -p S1pP0rtal -sh 10.0.0.3 -su doug -sp D4t4Guru -sport 2222 -spath Doug/

View File

@@ -0,0 +1 @@
{"access_token":"ya29.a0Aa7pCA-NdQAOjxPOW-5G_QaWElZhIL0pPxmhpvY7Y1DTl60oOv8R4FT5jbCBzY-SX1VfpLKdrCyA2wcnFs3TW4nbqL2vID3PnzAlPXctQJd95JiIe7d_aSk2RcKZ0rfF7SApyCXQfvBq-fxedh3Z89TFx380WzUARK604bt1KlquxY3KPPXJxKFktqdGOm9tz_pn_ivWlAaCgYKAWkSARUSFQHGX2Mioduyu6YZHcGu1vXhS4WRiA0209","token_type":"Bearer","expires_in":3599,"refresh_token":"1//05VYPi-AtHwRcCgYIARAAGAUSNwF-L9IrMxitrqA-1vdPyr46Ber_YrahP3eMdgDa42RsRfAxn-m7eV_sZdn2nfCIcv5r66xB4eA","scope":"https://www.googleapis.com/auth/gmail.readonly","Issued":"2025-12-30T09:34:36.271-05:00","IssuedUtc":"2025-12-30T14:34:36.271Z"}

BIN
bin/HOL_CDRTool_1.6.0b1.zip Normal file

Binary file not shown.

BIN
bin/Release/cdr-tool.exe Executable file

Binary file not shown.

View File

@@ -0,0 +1 @@
{"installed":{"client_id":"62734798094-2bd4m03i2n3d2342g0ceh38v121og7rj.apps.googleusercontent.com","project_id":"cdrtool-424301","auth_uri":"https://accounts.google.com/o/oauth2/auth","token_uri":"https://oauth2.googleapis.com/token","auth_provider_x509_cert_url":"https://www.googleapis.com/oauth2/v1/certs","client_secret":"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","redirect_uris":["http://localhost"]}}

1
bin/Release/license.txt Normal file
View File

@@ -0,0 +1 @@
463rX1WrOTtN+zNdtJW5r9b9/i7H1UqBB4//9OS1hP0hM00Obvyt2u58GuTIH7guJ5TulA8daSKLOt3LntIGdDnhwrO7JgihXw8bnjngmQLt76R6qIrZVUQ+uWRxXJJiUR9lsbSWPYlTLby0ox1P7CFIqRZ+Irx+6BV6XK5C8dLkm8ZIdq54vyAAg+QjYDTshLFWrzNV6f77h7EEAfjr2aV0V4heWwrNTv+RdEKLCKs=

View File

@@ -0,0 +1 @@
{"access_token":"ya29.a0AXooCgvuY8xqu2wZbdg7qqK3Ag3rNMVBooPtXDvbBwmOEePfg5akS_RimyLgksQcywd6iq1jPzsQlqijx38dA0VcO-PBrfRBhPKtZjVSsrsrlmnEGkeOFr9XrgFgcTipAtKXb9TrLzpLpueYFDv0vJStZq7dpI5rVsgSjgaCgYKAUYSARESFQHGX2MiKWHBkHd63IFtGhiPffOefg0173","token_type":"Bearer","expires_in":3599,"refresh_token":"1//05VYPi-AtHwRcCgYIARAAGAUSNwF-L9IrMxitrqA-1vdPyr46Ber_YrahP3eMdgDa42RsRfAxn-m7eV_sZdn2nfCIcv5r66xB4eA","scope":"https://www.googleapis.com/auth/gmail.readonly","Issued":"2024-05-24T18:14:56.937-04:00","IssuedUtc":"2024-05-24T22:14:56.937Z"}

1
bin/lic160b1.txt Normal file
View File

@@ -0,0 +1 @@
463rX1WrOTtN+zNdtJW5r9b9/i7H1UqBB4//9OS1hP0hM00Obvyt2u58GuTIH7guJ5TulA8daSKLOt3LntIGdDnhwrO7JgihXw8bnjngmQLt76R6qIrZVUQ+uWRxXJJiUR9lsbSWPYlTLby0ox1P7CFIqRZ+Irx+6BV6XK5C8dLkm8ZIdq54vyAAg+QjYDTshLFWrzNV6f77h7EEAfjr2aV0V4heWwrNTv+RdEKLCKs=

View File

@@ -0,0 +1 @@
6tgol6olSSG6jBlanyWwo9h9XtAQjD//maSc6yKcZ61sndOUjcfJRZxOVrXwfsqcHoJp9xXCK2OxJ/2s0SWDqWXDoWBpqOUFoVcxZkT9p4PD8RzPIj1k57NAYzWC46m6CLEBIPvJZziD6eJ66siK0YEbTm/3p6ndOn5y5Gd0/rwrFW+NelOCW/heRDkNMhQCY2dofK/GS4Ru7e16TX7gmxPJGl89vAmEFLsvfWyGOL8=

View File

@@ -0,0 +1 @@
u7DnwnSwSl5JE6WecQJ5zwrlBwnkK/ZiaIy+kMbQubBPZziwllsYgoDdFI4kBAIuaHzEivFwv5TuXgcozugePwLAFwZJwojbWPTfvP2mpHsab/xkmd9kHJrfKhphC/QgVy75RoRovIlc1++bcc4RaH9V++tQEOF2kYqH7/QQfVYO9Q4ZSbzjvWDT1kIEe4AmligZ7VKo6eBJ1tT5TyxNsTd4j/Cr2FVYiNQ628Vjt5o=

156
cdrtool.csproj Normal file
View File

@@ -0,0 +1,156 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" DefaultTargets="Build">
<PropertyGroup>
<ProjectGuid>{6166EEDD-31E3-44EB-978A-5EAF9C2992F9}</ProjectGuid>
<ProjectTypeGuids>{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<OutputType>Exe</OutputType>
<RootNamespace>CDRTool</RootNamespace>
<AssemblyName>cdr-tool</AssemblyName>
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<AppDesignerFolder>Properties</AppDesignerFolder>
<ProductVersion>8.0.30703</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ReleaseVersion>1.6</ReleaseVersion>
</PropertyGroup>
<PropertyGroup Condition=" '$(Platform)' == 'AnyCPU' ">
<PlatformTarget>x86</PlatformTarget>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
<OutputPath>bin\Debug\</OutputPath>
<DebugSymbols>True</DebugSymbols>
<DebugType>Full</DebugType>
<Optimize>False</Optimize>
<CheckForOverflowUnderflow>True</CheckForOverflowUnderflow>
<DefineConstants>DEBUG;TRACE</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
<OutputPath>bin\Release\</OutputPath>
<DebugSymbols>False</DebugSymbols>
<DebugType>None</DebugType>
<Optimize>True</Optimize>
<CheckForOverflowUnderflow>False</CheckForOverflowUnderflow>
<DefineConstants>TRACE</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DefineConstants>DEBUG</DefineConstants>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.CSharp">
</Reference>
<Reference Include="System" />
<Reference Include="System.Core">
</Reference>
<Reference Include="System.Data" />
<Reference Include="System.Data.DataSetExtensions">
</Reference>
<Reference Include="System.Xml" />
<Reference Include="System.Xml.Linq">
</Reference>
<Reference Include="System.Runtime.Serialization" />
<Reference Include="mscorlib" />
<Reference Include="System.Numerics" />
<Reference Include="System.Xaml" />
<Reference Include="System.Configuration" />
<Reference Include="System.IO.Compression.FileSystem" />
<Reference Include="System.ComponentModel.Composition" />
<Reference Include="Newtonsoft.Json">
<HintPath>packages\Newtonsoft.Json.13.0.4\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="Google.Apis.Core">
<HintPath>packages\Google.Apis.Core.1.73.0\lib\net462\Google.Apis.Core.dll</HintPath>
</Reference>
<Reference Include="System.Net.Http" />
<Reference Include="Google.Apis">
<HintPath>packages\Google.Apis.1.73.0\lib\net462\Google.Apis.dll</HintPath>
</Reference>
<Reference Include="System.CodeDom">
<HintPath>packages\System.CodeDom.10.0.1\lib\net462\System.CodeDom.dll</HintPath>
</Reference>
<Reference Include="System.Management" />
<Reference Include="Google.Apis.Auth">
<HintPath>packages\Google.Apis.Auth.1.73.0\lib\net462\Google.Apis.Auth.dll</HintPath>
</Reference>
<Reference Include="Google.Apis.Gmail.v1">
<HintPath>packages\Google.Apis.Gmail.v1.1.73.0.3987\lib\net462\Google.Apis.Gmail.v1.dll</HintPath>
</Reference>
<Reference Include="BouncyCastle.Cryptography">
<HintPath>packages\BouncyCastle.Cryptography.2.6.2\lib\net461\BouncyCastle.Cryptography.dll</HintPath>
</Reference>
<Reference Include="System.Buffers">
<HintPath>packages\System.Buffers.4.6.1\lib\net462\System.Buffers.dll</HintPath>
</Reference>
<Reference Include="System.Runtime.CompilerServices.Unsafe">
<HintPath>packages\System.Runtime.CompilerServices.Unsafe.6.1.2\lib\net462\System.Runtime.CompilerServices.Unsafe.dll</HintPath>
</Reference>
<Reference Include="System.Memory">
<HintPath>packages\System.Memory.4.6.3\lib\net462\System.Memory.dll</HintPath>
</Reference>
<Reference Include="System.Threading.Tasks.Extensions">
<HintPath>packages\System.Threading.Tasks.Extensions.4.6.3\lib\net462\System.Threading.Tasks.Extensions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Bcl.AsyncInterfaces">
<HintPath>packages\Microsoft.Bcl.AsyncInterfaces.10.0.1\lib\net462\Microsoft.Bcl.AsyncInterfaces.dll</HintPath>
</Reference>
<Reference Include="System.Formats.Asn1">
<HintPath>packages\System.Formats.Asn1.10.0.1\lib\net462\System.Formats.Asn1.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.DependencyInjection.Abstractions">
<HintPath>packages\Microsoft.Extensions.DependencyInjection.Abstractions.10.0.1\lib\net462\Microsoft.Extensions.DependencyInjection.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Logging.Abstractions">
<HintPath>packages\Microsoft.Extensions.Logging.Abstractions.10.0.1\lib\net462\Microsoft.Extensions.Logging.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Renci.SshNet">
<HintPath>packages\SSH.NET.2025.1.0\lib\net462\Renci.SshNet.dll</HintPath>
</Reference>
<Reference Include="System.Numerics.Vectors">
<HintPath>packages\System.Numerics.Vectors.4.6.1\lib\net462\System.Numerics.Vectors.dll</HintPath>
</Reference>
<Reference Include="System.Diagnostics.DiagnosticSource">
<HintPath>packages\System.Diagnostics.DiagnosticSource.10.0.1\lib\net462\System.Diagnostics.DiagnosticSource.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="Arguments.cs" />
<Compile Include="Logger.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Web.cs" />
<Compile Include="WebRoutines.cs" />
<Compile Include="_Main.cs" />
<Compile Include="LicenseFile.cs" />
<Compile Include="Gmail.cs" />
<Compile Include="SSH.cs" />
</ItemGroup>
<ItemGroup>
<None Include="app.config" />
<None Include="packages.config" />
</ItemGroup>
<ItemGroup>
<Folder Include="Embedded\" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="Embedded\Google.Apis.Gmail.v1.dll" />
<EmbeddedResource Include="Embedded\Google.Apis.Auth.dll" />
<EmbeddedResource Include="Embedded\Google.Apis.dll" />
<EmbeddedResource Include="Embedded\Google.Apis.Core.dll" />
<EmbeddedResource Include="Embedded\Microsoft.Extensions.Logging.Abstractions.dll" />
<EmbeddedResource Include="Embedded\Microsoft.Extensions.DependencyInjection.Abstractions.dll" />
<EmbeddedResource Include="Embedded\System.CodeDom.dll" />
<EmbeddedResource Include="Embedded\System.Diagnostics.DiagnosticSource.dll" />
<EmbeddedResource Include="Embedded\System.Formats.Asn1.dll" />
<EmbeddedResource Include="Embedded\Microsoft.Bcl.AsyncInterfaces.dll" />
<EmbeddedResource Include="Embedded\Renci.SshNet.dll" />
<EmbeddedResource Include="Embedded\Newtonsoft.Json.dll" />
<EmbeddedResource Include="Embedded\BouncyCastle.Cryptography.dll" />
<EmbeddedResource Include="Embedded\System.Memory.dll" />
<EmbeddedResource Include="Embedded\System.Runtime.CompilerServices.Unsafe.dll" />
<EmbeddedResource Include="Embedded\System.Threading.Tasks.Extensions.dll" />
<EmbeddedResource Include="Embedded\System.Numerics.Vectors.dll" />
<EmbeddedResource Include="Embedded\System.Buffers.dll" />
<EmbeddedResource Include="Embedded\System.ValueTuple.dll" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="packages\System.ValueTuple.4.6.1\build\net471\System.ValueTuple.targets" Condition="Exists('packages\System.ValueTuple.4.6.1\build\net471\System.ValueTuple.targets')" />
</Project>

Some files were not shown because too many files have changed in this diff Show More