mirror of
https://github.com/arx-research/libhalo.git
synced 2026-01-10 05:38:10 -05:00
Add source file headers (#85)
This commit is contained in:
committed by
GitHub
parent
81469bca10
commit
b4dfbffed7
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {Action, ArgumentError} = require("argparse");
|
||||
|
||||
class JSONParseAction extends Action {
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {ArgumentParser} = require("argparse");
|
||||
const {JSONParseAction} = require("./actions");
|
||||
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const Buffer = require('buffer/').Buffer;
|
||||
const { NFC } = require('nfc-pcsc');
|
||||
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {execCredential} = require("./credential");
|
||||
const {execWebNFC} = require("./webnfc");
|
||||
const {
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {HaloTagError, HaloLogicError, NFCOperationError, NFCMethodNotSupported} = require("../halo/exceptions");
|
||||
const {ERROR_CODES} = require("../halo/errors");
|
||||
const {arr2hex} = require("../halo/utils");
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {checkErrors, execHaloCmd} = require("./common");
|
||||
const {HaloLogicError} = require("../halo/exceptions");
|
||||
const {readNDEF} = require("./read_ndef");
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {readNDEF} = require("./read_ndef");
|
||||
const {HaloLogicError} = require("../halo/exceptions");
|
||||
const {execHaloCmd, checkErrors} = require("./common");
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const Buffer = require('buffer/').Buffer;
|
||||
const queryString = require('query-string');
|
||||
const {HaloLogicError} = require("../halo/exceptions");
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {ERROR_CODES} = require("../halo/errors");
|
||||
const {
|
||||
HaloTagError,
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const CMD_CODES = {
|
||||
// user commands, can be executed through any interface
|
||||
"SHARED_CMD_SIGN": 0x01,
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const Buffer = require('buffer/').Buffer;
|
||||
const ethers = require('ethers');
|
||||
const {HaloLogicError, HaloTagError} = require("./exceptions");
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
let ERROR_CODES = {
|
||||
0x01: ["ERROR_CODE_UNKNOWN_CMD", "Unknown command code."],
|
||||
0x02: ["ERROR_CODE_INVALID_KEY_NO", "Invalid key number."],
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
/**
|
||||
* This error is thrown when there is an error response from the tag itself.
|
||||
* The "name" property will contain the exact error name (e.g. ERROR_CODE_INVALID_KEY_NO).
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const FLAGS = {
|
||||
flagUseText: [0, 0x01],
|
||||
flagHidePk1: [0, 0x02],
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {HaloLogicError, HaloTagError} = require("../index");
|
||||
const EC = require('elliptic').ec;
|
||||
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const Buffer = require('buffer/').Buffer;
|
||||
const EC = require('elliptic').ec;
|
||||
const ethers = require('ethers');
|
||||
|
||||
6
index.js
6
index.js
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {execHaloCmdRN} = require("./drivers/nfc_manager");
|
||||
const {execHaloCmdPCSC} = require("./drivers/pcsc");
|
||||
const {
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<!--
|
||||
LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
Copyright by Arx Research, Inc., a Delaware corporation
|
||||
License: MIT
|
||||
-->
|
||||
<title>LibHaLo Demo</title>
|
||||
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<!--
|
||||
LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
Copyright by Arx Research, Inc., a Delaware corporation
|
||||
License: MIT
|
||||
-->
|
||||
<title>LibHaLo Demo</title>
|
||||
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<!--
|
||||
LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
Copyright by Arx Research, Inc., a Delaware corporation
|
||||
License: MIT
|
||||
-->
|
||||
<title>LibHaLo Demo</title>
|
||||
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<!--
|
||||
LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
Copyright by Arx Research, Inc., a Delaware corporation
|
||||
License: MIT
|
||||
-->
|
||||
<title>LibHaLo Demo</title>
|
||||
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/**
|
||||
* LibHaLo - Programmatically interact with HaLo tags from the web browser, mobile application or the desktop.
|
||||
* Copyright by Arx Research, Inc., a Delaware corporation
|
||||
* License: MIT
|
||||
*/
|
||||
|
||||
const {
|
||||
execHaloCmdWeb,
|
||||
} = require("../drivers/common");
|
||||
|
||||
Reference in New Issue
Block a user