Compare commits
3 commits
c101616e62
...
09a78164d3
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
09a78164d3 | ||
|
|
a9cffbe482 | ||
|
|
f9b51f107d |
4 changed files with 9 additions and 14 deletions
|
|
@ -2,6 +2,6 @@
|
|||
|
||||
The aim is to create a trustworthy Stellar transaction signer (and, by necessity, a pretty printer) using only Glasgow Haskell compiler code and Haskell Core libraries, reducing the possible supply chain attack surface.
|
||||
|
||||
To build and run it, install `cabal-install` and use `cabal run`.
|
||||
To build and run it, install `cabal-install` and use `cabal run`. The program expects your transaction coming from the standard input, and your private (S...) key residing in `$HOME/~/.stellar-veritas-key`. It will produce the decoded transaction description afterwards, with simple descriptions of the most popular operations. When it is ran from an interactive terminal, it will ask for a confirmation before signing the transaction.
|
||||
|
||||
The project contains the code of trimmed-down non-core dependencies, mainly cryptographic libraries. To avoid using bundled libraries (to build against the current Hackage), do the same in the `src` directory. To further reduce the amount of code under audit, weeder can be used, although the utility is dubious.
|
||||
|
|
|
|||
|
|
@ -4,11 +4,9 @@ module Main where
|
|||
|
||||
import Control.Monad
|
||||
import qualified Data.ByteString as B
|
||||
import Data.ByteString.Base32 (decodeBase32, encodeBase32)
|
||||
import Data.ByteString.Base32 (encodeBase32)
|
||||
import qualified Data.ByteString.Base64 as B64
|
||||
import qualified Data.ByteString.Char8 as BC8
|
||||
import Data.Coerce
|
||||
import Data.Char
|
||||
import Data.List
|
||||
import Data.Maybe
|
||||
import qualified Data.Text as T
|
||||
|
|
@ -31,7 +29,7 @@ main = do
|
|||
let parsedTransaction = case xdrDeserialize transaction :: Either String TransactionEnvelope of
|
||||
Left err -> error err
|
||||
Right x -> x
|
||||
T.putStrLn $ pretty parsedTransaction
|
||||
T.hPutStrLn stderr $ pretty parsedTransaction
|
||||
proceed <- confirm
|
||||
when proceed $ do
|
||||
key <- getPrivateKey
|
||||
|
|
|
|||
|
|
@ -2,22 +2,19 @@ cabal-version: 3.0
|
|||
name: stellar-veritas
|
||||
-- semver
|
||||
version: 0
|
||||
synopsis: Stellar transaction signer and pretty-printer
|
||||
-- description:
|
||||
synopsis: Stellar transaction signer and pretty-printer
|
||||
description: The aim is to create a trustworthy Stellar transaction signer (and, by necessity, a pretty printer) using only Glasgow Haskell compiler code and Haskell Core libraries, reducing the possible supply chain attack surface.
|
||||
license: AGPL-3.0-only
|
||||
license-file: LICENSE
|
||||
-- author:
|
||||
-- maintainer:
|
||||
-- copyright:
|
||||
license-file: COPYING
|
||||
author: La Ancapo
|
||||
category: Network, Stellar
|
||||
build-type: Simple
|
||||
tested-with: GHC == 9.12.3
|
||||
|
||||
executable stellar-veritas
|
||||
main-is: Main.hs
|
||||
ghc-options: -W -Wcompat -fno-warn-tabs -g
|
||||
ghc-options: -W -Wcompat -fno-warn-tabs -rtsopts=ignoreAll -optl-Wl,-s
|
||||
other-modules:
|
||||
-- other-extensions:
|
||||
build-depends: base >= 4.9 && < 5,
|
||||
text >= 1.2.4.1 && < 2.2,
|
||||
bytestring ^>= 0.12,
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ tested-with: GHC == 9.12.3
|
|||
|
||||
executable stellar-veritas
|
||||
main-is: Main.hs
|
||||
ghc-options: -W -Wcompat -fno-warn-tabs -g
|
||||
ghc-options: -W -Wcompat -fno-warn-tabs -rtsopts=ignoreAll -optl-Wl,-s
|
||||
other-modules:
|
||||
build-depends: base >= 4.9 && < 5,
|
||||
text >= 1.2.4.1 && < 2.2,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue