Comments (9)
It looks like there was a mistake in some of the code. The prefix is based on the identity of the adapter, which should be one of two versions based on SuppressIPAddress
configuration variable:
"_" + server + "_" + port
example:_localhost_7878
"_" + sha1digest("_" + server + "_" + port)[0..10]
The other option is to specify it directly using AdapterIdentity
.
The reason was a security concern raised by some companies that didn't want the IP addresses of the adapter exposed. It was supposed to be optional and have effect all the way down. I'll add a fix in version 2.2.0.15 with the MQTT source changes.
from cppagent.
from cppagent.
Awesome.
I actually remember seeing that issue and the resolution about security, but i guess my keyword searching wasnt strong enough today.
AdapterIdentity
is fine for me, just didnt know it existed.
ETA: i said i was going to close this, but ill keep it open and add more to the readme in my PR. these issues can close when the PR goes.
from cppagent.
It looks like there was a mistake in some of the code. The prefix is based on the identity of the adapter, which should be one of two versions based on
SuppressIPAddress
configuration variable:1. `"_" + server + "_" + port` example: `_localhost_7878` 2. `"_" + sha1digest("_" + server + "_" + port)[0..10]`
The other option is to specify it directly using
AdapterIdentity
.The reason was a security concern raised by some companies that didn't want the IP addresses of the adapter exposed. It was supposed to be optional and have effect all the way down. I'll add a fix in version 2.2.0.15 with the MQTT source changes.
Added to my PR : #367
from cppagent.
Maybe AdapterIdentity
can be used to generate MqttClientId
?
from cppagent.
from cppagent.
I still have a task to verify if a random client id is being generated if not specified. If it is not generated, why not. And what mqtt_cpp is using as its generator. I thought it used the machine ip and port (unique). I’ll get back once I investigate the code a bit more.
...oh? turns out, host:port for both my sink and source are the same (localhost:1883) !, so they are the same client id? go figure.
I suppose a remote broker is the same issue - host:port is the same for both sink and adapter
from cppagent.
AdapterIdentity: in Mqtt it creates like serverIp:MqttPort or serverIp:1883.
MqttClientId: you can declare in config file or Generates unique id.
from cppagent.
We need a better way of creating the ID. Unless we have one client per process (which we could do) we need to make each instance unique.
from cppagent.
Related Issues (20)
- [`v2.2.0.16 Docker ARM`] - SHDR in `Connector::reader: End of file: End of file` HOT 6
- Is FilterDuplicates ignored in config? HOT 1
- MQTT Ingress testing results HOT 2
- mqtt2 MTConnect/Probe/ topic name for agent HOT 8
- docker tag `2.2.0.16` is actually agent v2.2.0.15 HOT 5
- AGENT Device Observationrate stops reporting HOT 12
- Question | Sync with buffer using REST API? HOT 2
- Dataitems in <Interfaces> element break the response doc HOT 11
- UUID Adapter Configuration Item HOT 4
- Pass environment variable to AgentDeviceUUID HOT 1
- Blank observation for open text events like program have spaces in output
- PERIODS in tag names (MQTT Egress) HOT 7
- Change the schema version for the stylesheets to match the version of the schema being used for the agent.
- Make 'sender' configurable to support docker HOT 2
- Add * uuid: to the README and make sure all the other adapter commands are documented HOT 5
- `device` REST param does not work HOT 9
- Unclear logging at startup when using Docker HOT 1
- Ubuntu 20.04: Error building test package HOT 25
- * uuid command handling in agent not as expected HOT 19
- AgentConfiguration::monitorThread message reports wrong number of seconds
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cppagent.