From 9f0e83ede8b1cb684dbd3601cce59c48a060a3a1 Mon Sep 17 00:00:00 2001 From: Peter Harpending Date: Sun, 27 Aug 2023 16:04:30 -0600 Subject: [PATCH] cleanup awcp package, version bump to 0.2.3 --- libs/awcp/README.md | 17 +++++++++++++++-- libs/awcp/jex.eterms | 2 +- libs/awcp/src/awcp.ts | 11 ++++++----- 3 files changed, 22 insertions(+), 8 deletions(-) diff --git a/libs/awcp/README.md b/libs/awcp/README.md index 9c53409..dcd2b56 100644 --- a/libs/awcp/README.md +++ b/libs/awcp/README.md @@ -1,3 +1,16 @@ -# awcp (package documentation) +# awcp: Aepp-Waellet Communication Protocol. -Please click the word "Documentation" in the sidebar +Mostly an internal package. + +Page scripts (aepps) and wallet browser extensions (waellets) need to talk to +each other. This package contains + +1. type definitions of the messages +2. a list of error codes + +[src/awcp.ts](./src/awcp.ts) contains a detailed explanation of how the +protocol is structured. + +[Sidekick](../../sidekick/) exhibits how to use this from the perspective of +the page script (aepp), and [Jack Russell](../../jrx) exhibits how to use this +from the perspective of the waellet. diff --git a/libs/awcp/jex.eterms b/libs/awcp/jex.eterms index 79587b0..f0ea95a 100644 --- a/libs/awcp/jex.eterms +++ b/libs/awcp/jex.eterms @@ -1,5 +1,5 @@ {type, library}. {realm, local}. {name, awcp}. -{version, "0.2.2"}. +{version, "0.2.3"}. {deps, []}. diff --git a/libs/awcp/src/awcp.ts b/libs/awcp/src/awcp.ts index 5c24b6f..cc79260 100644 --- a/libs/awcp/src/awcp.ts +++ b/libs/awcp/src/awcp.ts @@ -15,11 +15,12 @@ * this. * * Keep in mind that these messages are not secret. Any browser extension or - * foreign page script can intercept these messages. Imagine as an (imperfect) - * analogy that you work in an office. Everyone's mail is dumped on the floor - * in the middle of the office, and you are responsible for picking out which - * letters are addressed to you. Anyone else can pick up letters addressed to - * you, and read them. + * foreign page script can intercept these messages, and inject messages of + * their own. Imagine as an (imperfect) analogy that you work in an office. + * Everyone's mail is dumped on the floor in the middle of the office. You are + * responsible for picking out which letters are addressed to you. Anyone else + * can pick up letters addressed to you, and read them. Anyone else can also + * place their own letters in the pile. * * This module defines the shape of the messages that are sent. There are several * layers to the onion, each corresponding to natural branch points in the