Git Product home page Git Product logo

Comments (7)

erossignon avatar erossignon commented on May 23, 2024

Hey, Thank you for your interest,
The project is pretty much at its early stage. At this time, a client can only connect to a server ,sending the HEL message and receiving the ACK message.
The next steps are to implement GetEndPoints and OpenSecureChannel/CloseSecureChannel.

Please feel free to suggest pull request or contribute, The task is quite enormous and as GitHub moto says : let's "Build Better software, Together").

from node-opcua.

 avatar commented on May 23, 2024

Hey, right now I'm still trying to get it to work, it will not install via NPM on my Windows machine since the x509 module cannot be installed, haven't tried on my Linux machine, it gives the following error:

317 error [email protected] install: node-gyp rebuild
317 error Exit status 1
318 error Failed at the [email protected] install script.
318 error This is most likely a problem with the x509 package,
318 error not with npm itself.
318 error Tell the author that this fails on your system:
318 error node-gyp rebuild
318 error You can get their info via:
318 error npm owner ls x509
318 error There is likely additional logging output above.
319 error System Windows_NT 6.2.9200
320 error command "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js" "install" "node-opcua" "--python"
321 error cwd C:\Users\JT\Documents\Projects\Node-OPC
322 error node -v v0.10.24
323 error npm -v 1.3.21
324 error code ELIFECYCLE
325 verbose exit [ 1, true ]

Why does it need to the x509 module? What certificates are needed to parse?

I tried simply downloading the repo, placing it in the node_modules folder and calling:

var opcua = require('node-opcua');

from the top-level, without success:

ERROR: Cannot find module "node-opcua"

Is it being exported as a standard Nodejs module or are the exports not set up yet?

Thanks in advance

from node-opcua.

 avatar commented on May 23, 2024

Update: Added exports file to make it incudeable from top-level using:

var opcua = require('node-opcua');

Only includes the lib\nodeopcua.js script at the moment:

https://github.com/terndrup/node-opcua/commit/1550d2c5ac3bdc94ad57706421a5da6f65615ae0

from node-opcua.

erossignon avatar erossignon commented on May 23, 2024

It looks like the x509 npm module seems broken and not supported on windows.
I have removed dependencies to the x509 module and replaced it with ursa and rsa-stream.

from node-opcua.

erossignon avatar erossignon commented on May 23, 2024

Hi Jeppe,
I have incorporated your fix to make it work as a npm package.
I have also now provided an example in the README and in this little project node-opcua-sample
Let me know how it goes on your side...

from node-opcua.

johnyesberg avatar johnyesberg commented on May 23, 2024

Hi Etienne,
Thanks for all your great work on node-opcua. I'm just starting to experiment with it. I'd like to connect to a server that requires a username and password.

I see opcua-client.js (line 523) has OPCUAClient.prototype._activateSession() that creates a new AnonymousIdentityToken. I was wondering where the best place might be to modify this code. Options I came up with include:

  • Not modifying your code at all. In the myfirstclient.js, I could replace _activateSession() with a new one that creates a different IdentityToken. But I didn't think that public code should be modifying functions starting with _
  • I could leave your code alone, and replace the createSession() function with one that doesn't call _activateSession(). But that seems to be making too much work for myself.
  • I could modify your code so that _activateSession() doesn't always create a new AnonymousIdentityToken. Instead, it could have a userIdentityToken field which is initialized as an AnonymousIdentityToken, but my user code could overwrite that field.
  • Having a prototype.CreateUserIdentityToken() function that could be replaced by user code.
  • Various others.

Do you have a preference?

from node-opcua.

erossignon avatar erossignon commented on May 23, 2024

Hi John,
I have modified createSession so we can now pass an optional userIdentityToken ,
see abfbee6 and https://github.com/erossignon/node-opcua/blob/master/test/test_opcua_ClientServer_UserNameIdentityToken.js#L54

from node-opcua.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.