Skip to content

Instantly share code, notes, and snippets.

View hap_powsrv
Aug 28 13:47:37 vmi181373 haproxy[29054]: 127.0.0.1:59508 [28/Aug/2018:13:47:36.265] iri_front iri_pow_back/powsrv 0/0/44/861/906 200 5827 - - ---- 1/1/0/0/0 0/0 0 {#7B#22branchTransaction#22: #22BNVXXLHJLMVHCICLXKSFWVKRAXNLPKMSFWK9DYGHAVAAMMVJIIDTEGRHXVSOP9NPSPHJWGADCYCCZ9999#22, #22trunkTransaction#22: #22|} 28 "POST / HTTP/1.1" - -
Aug 28 14:06:12 vmi181373 haproxy[29054]: 127.0.0.1:34356 [28/Aug/2018:14:06:12.031] iri_front iri_pow_back/powsrv 0/0/42/-1/743 -1 5821 - - SD-- 1/1/0/0/0 0/0 0 {#7B#22branchTransaction#22:#22LSOJSAVD9DAEDIOBDNNTNWWN9VIWWBUUJJIUC9DIVOCUEDILMJM9GEGLNLMGQYOKKXTTIUWVNZFB99999#22,#22trunkTransaction#22:#22FDK|} 267 "POST http://XXX.XXX.XXX.XXX:21310/ HTTP/1.1" - -
Aug 28 14:14:24 vmi181373 haproxy[29054]: 127.0.0.1:35714 [28/Aug/2018:14:14:23.829] iri_front iri_pow_back/powsrv 0/0/33/-1/732 -1 5827 - - SD-- 1/1/0/0/0 0/0 0 {#7B#22branchTransaction#22:#22JGSLMRWJRK9SEQKUAMYZ9YFJJZNTRQUIUPINTWLHYDDNSANEJLQNAEEJ9PFN9CDQIEF9BPMFAIHSA9999#22,#22trunkTransaction#22:#22QGE|} 376 "POST h
View BinaryFormatter.Deserialize.cs
private object ByteArrayToObject(byte[] source)
{
using (var ms = new MemoryStream(source, false))
{
BinaryFormatter b = new BinaryFormatter();
return b.Deserialize(ms);
}
}
View BinaryFormatter.Serialize.cs
private byte[] ObjectToByteArray(Object obj)
{
using (var ms = new MemoryStream())
{
BinaryFormatter b = new BinaryFormatter();
b.Serialize(ms, obj);
return ms.ToArray();
}
}
@Hribek25
Hribek25 / IOTA101_07CFD43B146C.js
Last active Jan 10, 2019
Sending IOTA transaction in more granular way: API calls Prepare_transfer() and Send_transfer()
View IOTA101_07CFD43B146C.js
// The snippet is a part of the IOTA Developer Essentials project. You can reach it at https://hribek25.github.io/IOTA101/
// Complete description and story behind the snippet is available at: https://hribek25.github.io/IOTA101/Allchapters_javascript.ipynb.html#07CFD43B146C
// Requirement: IOTA Javascript Library (!npm install iota.lib.js)
var IOTA = require('../../node_modules/iota.lib.js/lib/iota');
var NodeURL = "https://nodes.thetangle.org:443";
var iota = new IOTA({
'provider': NodeURL
});
@Hribek25
Hribek25 / IOTA101_00663E550ADF.js
Last active Jan 10, 2019
Sending IOTA transaction in a single call: API call Send_transfer()
View IOTA101_00663E550ADF.js
// The snippet is a part of the IOTA Developer Essentials project. You can reach it at https://hribek25.github.io/IOTA101/
// Complete description and story behind the snippet is available at: https://hribek25.github.io/IOTA101/Allchapters_javascript.ipynb.html#00663E550ADF
// Requirement: IOTA Javascript Library (!npm install iota.lib.js)
var IOTA = require('../../node_modules/iota.lib.js/lib/iota');
var NodeURL = "https://nodes.thetangle.org:443";
var iota = new IOTA({
'provider': NodeURL
});
@Hribek25
Hribek25 / IOTA101_445C2B9485C6.js
Last active Jan 10, 2019
Preparing IOTA transactions to be broadcasted
View IOTA101_445C2B9485C6.js
// The snippet is a part of the IOTA Developer Essentials project. You can reach it at https://hribek25.github.io/IOTA101/
// Complete description and story behind the snippet is available at: https://hribek25.github.io/IOTA101/Allchapters_javascript.ipynb.html#445C2B9485C6
// Requirement: IOTA Javascript Library (!npm install iota.lib.js)
var IOTA = require('../../node_modules/iota.lib.js/lib/iota');
var NodeURL = "https://nodes.thetangle.org:443";
var iota = new IOTA({
'provider': NodeURL
});
@Hribek25
Hribek25 / IOTA101_C65223B0864A.js
Last active Jan 10, 2019
Validating IOTA address
View IOTA101_C65223B0864A.js
// The snippet is a part of the IOTA Developer Essentials project. You can reach it at https://hribek25.github.io/IOTA101/
// Complete description and story behind the snippet is available at: https://hribek25.github.io/IOTA101/Allchapters_javascript.ipynb.html#C65223B0864A
// Requirement: IOTA Javascript Library (!npm install iota.lib.js)
var IOTA = require('../../node_modules/iota.lib.js/lib/iota');
var NodeURL = "https://nodes.thetangle.org:443";
var iota = new IOTA({
'provider': NodeURL
});
@Hribek25
Hribek25 / IOTA101_39B011574CF0.js
Last active Jan 10, 2019
IOTA address and checksum
View IOTA101_39B011574CF0.js
// The snippet is a part of the IOTA Developer Essentials project. You can reach it at https://hribek25.github.io/IOTA101/
// Complete description and story behind the snippet is available at: https://hribek25.github.io/IOTA101/Allchapters_javascript.ipynb.html#39B011574CF0
// Requirement: IOTA Javascript Library (!npm install iota.lib.js)
var IOTA = require('../../node_modules/iota.lib.js/lib/iota');
var NodeURL = "https://nodes.thetangle.org:443";
var iota = new IOTA({
'provider': NodeURL
});
@Hribek25
Hribek25 / IOTA101_2508A6FF9241.js
Last active Jan 10, 2019
Generating IOTA addresses from a seed (#2)
View IOTA101_2508A6FF9241.js
// The snippet is a part of the IOTA Developer Essentials project. You can reach it at https://hribek25.github.io/IOTA101/
// Complete description and story behind the snippet is available at: https://hribek25.github.io/IOTA101/Allchapters_javascript.ipynb.html#2508A6FF9241
// Requirement: IOTA Javascript Library (!npm install iota.lib.js)
var IOTA = require('../../node_modules/iota.lib.js/lib/iota');
var NodeURL = "https://nodes.thetangle.org:443";
var MySeed = "WKQDUZTGFKSSLACUCHHLZRKZBHSDSCEBHKUPDLKFBQALEBKDMFRPUQGZRXAADPG9TSRTZGGBZOFRJCFMM";
var iota = new IOTA({
@Hribek25
Hribek25 / IOTA101_0FF479CB6C0A.js
Last active Jan 10, 2019
Generating IOTA addresses from a seed: API call Get_new_addresses()
View IOTA101_0FF479CB6C0A.js
// The snippet is a part of the IOTA Developer Essentials project. You can reach it at https://hribek25.github.io/IOTA101/
// Complete description and story behind the snippet is available at: https://hribek25.github.io/IOTA101/Allchapters_javascript.ipynb.html#0FF479CB6C0A
// Requirement: IOTA Javascript Library (!npm install iota.lib.js)
var IOTA = require('../../node_modules/iota.lib.js/lib/iota');
//For this particular task the Node URL is not important as it will not be contacted at all
//However it has to be well - formatted URI
var NodeURL = "https://nodes.thetangle.org:443";
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.