2020-09-19 21:01:22 +00:00
|
|
|
|
using System;
|
|
|
|
|
using System.Text;
|
2020-09-20 21:13:46 +00:00
|
|
|
|
using System.IO;
|
|
|
|
|
using System.Collections.Generic;
|
2020-09-19 21:01:22 +00:00
|
|
|
|
|
|
|
|
|
using onionrpow;
|
|
|
|
|
|
|
|
|
|
namespace onionrpow_cli
|
|
|
|
|
{
|
|
|
|
|
class Program
|
|
|
|
|
{
|
|
|
|
|
static void Main(string[] args)
|
|
|
|
|
{
|
2020-09-20 21:13:46 +00:00
|
|
|
|
|
|
|
|
|
using (Stream stdin = Console.OpenStandardInput())
|
|
|
|
|
{
|
|
|
|
|
var data = new List<byte>();
|
|
|
|
|
byte[] buffer = new byte[60000];
|
|
|
|
|
int bytes;
|
|
|
|
|
while ((bytes = stdin.Read(buffer, 0, buffer.Length)) > 0) {
|
|
|
|
|
//stdout.Write(buffer, 0, bytes);
|
|
|
|
|
data.AddRange(buffer);
|
|
|
|
|
}
|
|
|
|
|
onionrpow.OnionrPow.compute(data.ToArray(), 3);
|
|
|
|
|
}
|
2020-09-19 21:01:22 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|