Hot answers tagged

182

Both Swarm and Whisper are complementary technologies contributing to the vision of Ethereum as a "world computer". When imagining Ethereum as a metaphor for a shared computer, it should be noted that computation alone is not enough. For a computer to be fully useful, it also needs storage to "remember" things and bandwidth to "communicate" them. This could ...


41

Whisper is a part of the Ethereum P2P protocol suite that allows for messaging between users via the same network that the blockchain runs on. There are many uses, some of which are listed on the wiki The protocol is seperate from the blockchain, so smart contracts do not have access. Whisper has existed in a sort of alpha, working-prototype state for ...


24

So it is only possible to send HEX data in the data field. This will not be a standard transaction but will require you to use geth, MyCrypto advanced settings on the send page, or another client that allows you to access and edit the data field. Google and visit an ascii->hex site and type your message. Copy the hexadecimal output, and remove all the ...


18

I'm glad you asked because this was the main thing we are testing in Status - the viability of Whisper. There's many factors that come into play here. Firstly, let me describe how Whisper roughly works, how Status tries to compensate and what might be happening here. Whisper is an identity based encrypted messaging protocol that has dark routing, to learn ...


11

whisper is part both the go and c++ clients. It is a fully functional implementation. swarm is being actively developed by the go-team. See the Devcon1 talk for the big picture. See the issues labeled 'swarm' on github. POC1 will be public and integration to Mist will start after some more serious network integration testing. Work towards using IPFS as ...


9

By sending a message, I assume you mean you want to send some form of a text based message to another user... You can send a message as part of the data field in a transaction. For the user to know you actually sent them a message, you could use the web3.js api to listen and extract messages from a transaction. You'd then have to decode it to ascii to make ...


9

You can't make an Ethereum contract start with plaintext and meaningfully encrypt a message, because all contract execution has to be verifiable by all the nodes in the network, so as you say everybody would also have to be able to see your plaintext. If you want to send a message from one user of a contract to another user of the contract, the obvious ...


8

Dixit Guillaume Ballet whisper v6 is still work in progress, it's not compatible with v5 and the EIP 627 is the only spec right now. Documentation will be updated when v6 is ready [V6 improves] parity compatibility and scalability


7

Check out the Use Cases section in the Ethereum Whisper protocol at https://github.com/ethereum/wiki/wiki/Whisper-Overview : shh.post({ "topic": t, "payload": p }); No signature, no encryption: Anonymous broadcast; a bit like an anonymous subject-filtered twitter feed. shh.post({ "from": myIdentity, "topic": t, "payload": p }); Open signature, no encryption:...


7

At this point it's difficult to give a very accurate answer to your questions as Whisper is still very much in its infancy stage, however I'll attempt to answer your question with the implemenation that's currently in operation. The amount of whisper topics that you may use for your messages and filters are theoretical infinite. Please note that whisper ...


7

Whisper is not receiving funding from the Ethereum Foundation but is still being developed on by developers in their spare time. A new version 5 is reaching its final stage soon. If you're interested you can talk to developers on Gitter in the Whisper channel: https://gitter.im/ethereum/whisper. Swarm still is being developed and you can read more ...


6

Here's how you would do it with the web3 api. const Utils = require('web3-utils'); let txTransfer = {}; txTransfer.from = from.address; txTransfer.to = to.address; txTransfer.gas = GasLimit; txTransfer.value = amount; txTransfer.data = Utils.toHex('free text data'); web3.eth.sendTransaction(txTransfer); I have a working example on the blockchain at this ...


6

You will have to start geth with the --shh parameter. user@Kumquat:~$ geth help | grep shh --shh Enable Whisper Without the --shh parameter: user@Kumquat:/tmp$ geth --datadir test console ... > var shh = web3.shh; undefined > var appName = "My silly app!"; undefined > var myName = "Gav Would"; undefined > var myIdentity = shh....


5

The two are related in name, and perhaps in their goals. Whisper.sh was released in 2012 and is operated and controlled by a single entity. Ethereum's Whisper protocol is peer to peer and is not controlled by a single entity. Here is a link to a YouTube presentation by Dr Gavin Wood about Ethereum's Whisper.


5

For temporary messages, I'd use Events. They can be used to send individual instructions to the devices. For persistent data like the current temperature, you can use storage variables. For example, this could turn the LED on if the temperature raises above 60 degrees. contract IOT { uint public temperature; address sensor; address led; ...


5

There is something specifically for this purpose, which is called Whisper In a nutshell whisper is a communication protocol for DApps to communicate each other. Example Usage var shh = web3.shh; var appName = "My silly app!"; var myName = "Gav Would"; var myIdentity = shh.newIdentity(); shh.post({ "from": myIdentity, "topic": [ web3.fromAscii(...


4

Possible answer: It is not entirely clear where Swarm and Whisper fit into the development roadmap and when or if they will be delivered by the same developers that developed the EVM... Source


3

To enable whisper just run Geth with the --shh Enable Whisper flag i.e. geth --shh To enable SWARM you need to Build Geth & Bzzd (Swarm Daemon) from source: go get -d github.com/ethereum/go-ethereum go install github.com/ethereum/go-ethereum/cmd/geth go install github.com/ethereum/go-ethereum/cmd/bzzd Then run $GOPATH/bin/bzzd. Note you need to ...


3

No. Of course it's possible what you suggesting, but no, because you have a major mixup in terminology. For a peer 2 peer communication layer, have a look at devp2p. Here is the specification. For actual data/file transfer have a look at swarm, the peer 2 peer file hosting protocol. (See also.) Whisper is a peer 2 peer encrypted messanging protocol, ...


3

| OSI Layer | Ethereum Protocols | ------------------------------------- | Application | Kademlia, RPC, IPC | | Presentation | AES, ECDSA | | Session | | | Transport | | | Network | | | Data Link | | | Physical | | Please note ...


3

"I am not clear how the private key is generated at the receiver side to decrypt the message. I found that no additional inputs are given to decrypt other than the sealed envelope." There are two cases: If you're sending a message to a specific recipient; If you're sending a multicast message. Specific recipient If the message is for a specific ...


3

Communication between parties on the Ethereum network, if the messages are temporarily and shouldn't be stored for ever, can be done over the Whisper protocol. If you want to give this a whirl and are using geth make sure to start your nodes with the --shh flag. This will enable whisper. You can find more information about the Whisper API here. A working ...


3

Yes, this is possible and quite simple, but not necessarily advisable. Some things to keep in mind: All messages need to be encrypted off-chain. Otherwise anyone can read all of your communication Storage is expensive. It's not incredibly cost-prohibitive, but users would need to buy ether and keep their accounts funded. Costs can be reduced by using Events ...


3

When I tested a couple of weeks ago, whisper works inside the geth client, in that messages can be sent, and that messages can be received using filters. When I tried using the web3 client, which makes rpc calls to geth for similar functions, I found that sending messages worked, but creating filters failed (so I could not receive messages). No replies ...


3

Theoretically, yes, code execution time is limited by the block time. But on a practical level, gas costs and the block gas limit are what limit code execution time. Try writing a contract that takes many milliseconds and you will probably find that you have exceeded the block gas limit. FYI the average block time is 15 seconds. Whisper is the messaging ...


3

web3js v1.x.x const txParams = { nonce: nonce, gasPrice: gasPrice, gasLimit: gasLimit, to: to, value: value, data : web3.utils.toHex('rockstar blockchain developer'), // EIP 155 chainId - mainnet: 1, ropsten: 3 chainId: 4 } const tx = new ethereumTx(txParams); tx.sign(privateKey); const serializedTx = '0x'+tx.serialize().toString('hex') ...


3

Based on the Whisper V5 RPC API documentation, I was finally able to construct a working example with private/public keys. I have tested this in a private network with geth 1.7.2 console. In mainnet, whisper will most probably not work, since the majority of nodes will not have this protocol enabled. On the receiver node: 1/ create a new keypair var kId =...


3

I would recommended to use this documentation : https://github.com/ethereum/go-ethereum/wiki/Whisper Whisper usage your posted links are outdated and moreover are for Whisper v 2.0 Answer: It's possible 1:N message if you provide identical symKey for all recipients. P.S. My posted links are for Whisper 5.0 , current version of Whisper is 6.0 but ...


3

Solution using Web3.py: I have followed following ssh-mode code. receiver.py that runs on node-1: from os.path import expanduser from web3 import HTTPProvider, Web3 import asyncio import time def handle_event(event): print(f"recipientPublicKey={event['recipientPublicKey'].hex()}") print(event["payload"].decode("utf-8")) async def log_loop(...


3

Whisper First of all, Whisper is kind of a database to spread announcements to the Ethereum network - or more precisely, to all geth nodes who have enabled Whisper. By default, Whisper is hidden behind a flag. Whisper can be used to send messages. Sending messages will have the following properties: Receiver anonymity: no one knows who the actual receiver ...


Only top voted, non community-wiki answers of a minimum length are eligible