Azure IoT SDK for C with WolfSSL and STM32 - gsm

I am trying to port Azure IoT SDKs for C to STM32 controller. I am using wolfSSL library for TLS version 1.2 and I am able to build the code successfully in OpenSTM32 environment.
But, after establishing successful connection with Azure server, I am unable to establish TLS handshake with the server.
I am using OpenSTM32’s example user_settings.h file from wolfSSL library to build wolfSSL library.
Do I need to make any additional changes in the WolfSSL library to use it with Azure?
OR
Is there any other TLS library, which can be used with Azure IoT SDK for C and STM32 controller?

I have managed to get it working.
There were issues with the buffer sizes and server timeouts.
Increasing the buffer size and optimizing the sending logic solved the issue.
Now, I am able to access every functionality of Azure IoT SDK for C !

Related

Can Client Blazor WebAssembly application access local serial port on client?

How should I access a serial port on a client PC from a webpage in a production environment?
Ideally coded in C# and client Blazor, but any suggestions very welcome.
Any example applications on the web?
Web Serial API and Javascript option works in Chrome if you enable the experimental option: "Experimental Web Platform features" : Enables experimental Web Platform features that are in development. – Mac, Windows, Linux, Chrome OS, Android. #enable-experimental-web-platform-features
https://bugs.chromium.org/p/chromium/issues/detail?id=884928
Being experimental precludes use in a production environment till it is formally released (experimental licence must be renewed every 6 weeks, expires in September 2020 and the functionality can be removed by Google at any time.)
So far the only solution I can think of is to create an ASP.NET Core Service application that must be installed on the client and the webpage application must connect to this local API to use the local serial port.
Any technical issues that would prevent this service approach from working? Other approaches I should consider.
The web application will be designed to interface with a central/upper arm blood pressure monitor that outputs large XML (or JSON) results after each measurement. The measurements will be saved into a "cloud" service for research and patient monitoring.
Thank you in advance for suggestions and comments.

Connection with MQClient 7.5.0 and SHA2

I have a "blackbox" application written in Java that connects to MQ. On unix server there is MQ Client installation version 7.5.0. Java application is using 1.7.0_79. I have to use SSL_RSA_WITH_AES_256_CBC_SHA256 to make the connection.
I cannot upgrade to MQ Client v8. I am not entirely sure if I can connect having MQ Client version 7.5.0 and for instance use SSL_RSA_WITH_AES_256_CBC_SHA256.
Would be that even possible to establish connection having these components ?
IBM added support for non-IBM Java cipher suite names via APAR IV66840, this was included in MQ v7.5.0.5.
What you are asking should be possible if you have the following:
Set this java system property
-Dcom.ibm.mq.cfg.useIBMCipherMappings=false
or
System.setProperty("com.ibm.mq.cfg.useIBMCipherMappings", "false")
Use cipher suite value TLS_RSA_WITH_AES_256_CBC_SHA256.
Note does not start with SSL_ for Oracle java.
Make sure the strong cryptographic provider is enable in java to support ciphersuites with AES256 encryption. It appears that if you upgrade to a higher level of java 7 (1.7.0_161 for example) this will be included and enabled by default.
Use a JKS keyStore.

Reading Heart Rate Sensor off Microsoft Band using Windows IoT Core on Raspberry Pi 2

When attempting to read Heart Rate Sensor from a Microsoft Band paired with a Raspberry Pi2 running latest Windows IoT Core (10586). I get an exception when calling:
“bandClient.SensorManager.HeartRate.RequestUserConsentAsync()”
It would seem that the IoT Core does not contain the necessary libraries to create the popup dialog that is seen on other devices when executing this method.
Are there plans to extend the Band SDK to support Windows IoT Core in this scenario?
Are there any proposed workarounds?
Thank you,
Paul
Windows 10 IoT is currently not supported by the Microsoft Band SDK. In particular, the user consent prompts run on the device that the band is paired with and in this case the required APIs for user prompts are not supported in the Windows 10 IoT Core APIs.
If you require this in a future release of the SDK please open a request at the Microsoft Health User Voice page https://microsofthealth.uservoice.com

BlueZ 5.30: D-Bus GATT API - Simply Discover and Connect to a BLE device in C

With the last release of BlueZ (5.30) the highlight was the completion of the GATT D-Bus apis. My goal is to programmatically (in C), as a BLE client:
scan for ble devices (which I can do with the hci layer)
Connect to an advertising BLE device
Get the UUIDs
Execute Read and Write to handles
The BlueZ community is strongly suggesting to use the GATT-Dbus api to accomplish this. After multiple searches and head scratching I was not successful to find a proper way or example that would perform this through GATT-DBUs api. It seems more complicate than just use directly the GATT layer. Unfortunately BlueZ removed direct access to make calls to gatt.
I'm very close to just pull the GATT source files out from Bluez, compile it as it's own independent library and directly use the GATT layer and calls to connect and execute reads/writes to ble device server. I know it is not the suggested way compared to the DBUS-GATT api but I'm out of options.
If anybody has any input on this or suggestion (with some sample code) please advise.
thank you in advance!
The best way to start with DBUS GATT API is to hace a look at the source code here: http://git.kernel.org/cgit/bluetooth/bluez.git/tree/
Under client folder you can find a full sample of how to use the DBUS GATT API. Actually that is the source of bluetoothctl tool.
Note that DBUS GATT API is still experimental but you can enable it running bluetoothd service with -E flag.
I had a similar issue which is to interact with a BLE device with a GATT C/C++ API.
In my case I had to use Bluez v4.101 - the latest Bluez version available in Ubuntu 14.04 LTS (read my story). In Bluez v4.x, there is no DBus API.
And actually, I have recently worked with Bluez v5 DBus API and I discovered if you do not use at least Bluez v5.39 (from April 2016) it is likely you will have issue with the DBus API. And as said before the DBus API is still experimental.
So to solve my Bluez v4.x dependency I had to pull the GATT source files out from Bluez and create my own library 'gattlib'. The project is Open-Source to encourage feedback and contribution.
I am using this library in my own GATT client project.
I wrote few examples to help people to start using it see the folder /examples of the project.
EDIT March 2017: I have just added DBus support to gattlib (https://github.com/labapart/gattlib/). From Bluez v5.42, gattlib automatically uses DBus API (DBus gattlib backend can also be forced when building the library to use it before v5.42).

Scaling SignalR With Windows Server Service Bus

Is it possible to scale out SignalR using Windows Server Service Bus?
I found sample of doing it with Redis, and I know there are libraries in GitHub for SQL Server (although I couldn't find a working sample for that), but I would like to implement it using the new on-premises Service Bus.
Any ideas / references?
Thanks!
In theory yes. The current stable versions support the Azure Service Bus, the latest source includes a rework of the scaleout providers such that even if it doesn't work out of the box (as the two service bus solutions are designed to have API parity) it should be straightforward to implement.
The service bus scaleout is enabled using its DependencyResolverExtensions class.

Resources