Can I use wildcard on info-plist for Bonjour services - wildcard

My apps using bonjour service to conversation with each other via local network.
I am facing a problem on Xcode12 with OS14 device.
A device publish a service with server type name depends on self device IP address
(example: 192.168.33.20 -> _1921683320._tcp)
B device searching a service with service type depends on A device IP address
(example: _1921683320._tcp)
According to apple document..From OS14~
https://developer.apple.com/documentation/multipeerconnectivity
Important
Apps that use the local network must provide a usage string in their Info.plist with the key NSLocalNetworkUsageDescription. Apps that use Bonjour must also declare the services they browse, using the NSBonjourServices key.
because my service type name is named by local network ip, it is changeable base on local network setting, so I am thinking about to using wildcard to define the service type name.
example: _*._tcp
but seems wildcard is not available on this definition.(I tried it)
I am also thinking about changing the naming method on A device
(example: 192.168.33.20 -> _20._tcp)
and add _1.tcp ~ _255.tcp to info-plist
But if I changed the naming method, B device could not find A device until version up.
Any idea for this problem? Please help.

I'm currently working through the same issue - Bonjour service name is dynamically created based off the iPad name to form a local mesh network. The conclusion that I have came to is com.apple.developer.networking.multicast is required for this to function without completely overhauling how all that logic is done. (More info here)
You will have to request permission from apple by filling out a form here. Let me know if this works for you!

The thing I am finding is, you "might" not be able to use a wildcard, but you can put multiple entries in the plist:
Item 0 _multicastapp0-p._tcp
Item 1 _multicastapp1-p._tcp
Item 2 _multicastapp2-p._tcp
Item 3 _multicastapp3-p._tcp
etc
Item N _multicastappN-p._tcp
So for some reason if you are trying to have multiple "Groups" of 8 or have a device have it's own "collection" i.e. be a server and have 3 devices connect to that, you can.
I haven't "fully" tested but I am going to be doing this in my apps, I did test using multiple keys tho, but not fully, no errors...

Related

Accessing Reflection for unix and openvms outside of Reflection

My place of business currently uses Reflection for Unix and OpenVMS to handle a database of customers. I access this database directly through the Reflection emulation. The only way to get data out of Reflection is to navigate to a single customer via keyboard input and print the information to a .txt.
Is there anyway I can access the VM other than through Reflection with the end goal of automating retrieval of customer information from a Java script executed outside of the Reflection environment? This is the information I can gather via the Reflection interface about what I am connecting to:
At the bottom of the Reflection interface - VT500-7 -- HOST_NAME via SECURE SHELL
Via the Connection Setup drop-down:
Host name: HOST_NAME
SSH config scheme: AutoKeyLogin
User name: username
Via the Security... button:
General tab:
Port number: 22
User Authentication: [x] Public Key
[x] Password
User Keys tab:
Use Name Type Location
[x] username1user DSA C:\Documents\PathToSSHKey\.ssh
Host Keys tab:
Host Type Fingerprint
HOST_NAME, 111.1.111.11, 22 DSA 39:14:f3:123:fds:restOfFingerprint
There is more information available if the solution is possible but I have just not provided enough to solve it, so please ask.
Given that I have the host name, port, .ssh, and host key, is it possible to connect to and read from the VM that I am otherwise connecting to normally via the Reflection emulator?
NO. Reflection (other example is PuTTY) is just a dumb-terminal emulator, here using the (secure) SSH protocol to connect to some Operating System. From the information provided we cannot even tell which OS. Maybe OpenVMS maybe some Unix. Most certainly not a 'VM', but a physical box. Maybe a Alpha, Integrity, Sun, IBM or Intel server.
IF, big if, it is OpenVMS you would possibly see something like this flash by on entry:
XXX - HP rx2600 (1.50GHz/6.0MB) OpenVMS IA64 V8.3-1H1
Last interactive login on Thursday, 7-DEC-2017 13:23:19.83
Last non-interactive login on Wednesday, 6-DEC-2017 12:35:45.80
Most likely username uses is set up to always start a (shell) script which starts a menu from which a program is activated, which knows how to access data record. IF is it OpenVMS then the actual data is likely stored in RMS (indexed) files, but it could in a proper (Oracle RDB or RDBMS) database.
If bulk access to the data is needed then you need to talk to the system/application manager for the system 'HOST_NAME' and ask them about the application and its database.
You may find that there is FTP, ODBC or JDBC or natice DB (OCI?) access to the data avaiable already, or that this can be requested. Likely tools in this space are ConnX, Attunity Connect, and such.
First you'll need to find out which OS/Platform/Version, which application (3rd party? home grown? 4GL? Cobol? Basic? and ultimately, which database/storage method.
That's not to say that some terminal emulator cannot be 'tricked' (google -
screen scraping) to be programmed to fetch a series of data on command, but that will always be error prone and laboriously for limited volumes.
You are better of trying to get proper data access.
Good luck! You'll need some.
Hein

How to Quiesce a particular domain in datapower?

I need to quiesce all the multi protocol gateway components in a particular domain ( not default ) in datapower appliance. I could see quiesce option only in each multi protocol gateway level. is there an option in domain level to quiesce all MPGW?
No, you can quiesce a whole domain or object by object.
The only other option is to create a SOMA or REST script to quiesce each object (=MPGW) by name.
As said either you can quiesce an application domain or a particular object. If you are familiar with Java and Soma templates, you can keep the list of MPGW name in a property file and iterate through and execute the Soma command for each MPGW.
Let me know if this helps.

How to migrate Wordpress between Compute Engine instances

I have recently created a very small Google Compute Engine instance, naively thinking it's one of those easily scalable things Google people keep raving about.
I used the quick deployment feature of Wordpress and it all installed itself nicely, so I started configuring and adding data etc.
However, I then found out that I can't scale an existing instance (i.e. it won't allow me to change the instance type to a bigger one. I don't get why not, but there you go.), so it looks like I need to find a way to migrate my Wordpress installation to a new instance.
Will I simply be able to create a new instance and point it at the persistent disk my small instance currently uses, et voila, Bob's your uncle?
Or do I need to manually get the files and MySql data off the first instance and re-import into an empty new instance?
What's the easiest way?
Any advise or helpful links would be appreciated.
Thanks.
P.S.: Btw, should I try to use the Google Cloud SQL store instead of a local MySql installation?
In order to upgrade your VM:
access the VM's settings in the Developers Console (your project -> Compute -> Compute Engine -> VM instances -> click on the VM's name)
Scroll down to the "Disks" section, and un-check "Delete boot disk when instance is deleted"
Delete the VM in question. Take note that the disk, named after the instance, will remain.
Create a new VM, selecting "Existing disk" under Boot disk - Boot source. In the next box down, select the disk from point 3 above, as well as a bigger machine type.
The resulting new instance will use the existing disk from the old one, with improved hardware / performance.
As for using Cloud SQL in lieu of a VM-installed database, it's perfectly feasible, and allows to adjust the Cloud SQL instance to match your actual use. A few consideration when setting up this kind of instance:
limit the IPs allowed to connect to your Cloud SQL instance to your frontend's IP, and perhaps the workstation's IP or subnet from which you maintain the database out of.
configure Cloud SQL to use SSL certificates.
Sammy's answer covers the important stuff I just wanted to clarify how your files are arranged on the two disks that are attached to your instance:
The data disk contains /var/www/ which is all of the wordpress files. It's mounted on the instance at /wordpress
The boot disk contains everything else, including the MySQL database that was created for the Wordpress installation.

Can 2 Apps Access the 1 Sterling NoSQL Database?

I'm currently working with SterlingDB (not the phone 7 version) and would like to be able to access the same Sterling Database from 2 different applications (and therefore different AppDomains).
I have ascertained that even when you pass a FileSystemDriver to the RegisterDatabase method:
engine.SterlingDatabase.RegisterDatabase<PodcastDatabase>(new FileSystemDriver("MyTestApp/"));
you end up with 2 different databases:
I:\Users\Dave\AppData\Local\Sterling Database\TestMeGo\1123790033 and
I:\Users\Dave\AppData\Local\Sterling Database\TestMeGo\1728918701
This is presumably because the apps are contained in separate AppDomains and the IsolatedStorage which is used by Sterling is compartmentalised accordingly.
Is there a way to have just one Sterling database which more than 1 app can access?
Thanks
It should be possible, as you can read here. You either let the storage be based on the XAP url, or on the source domain. If you can get both apps to be from the same source domain, and use the GetUserStoreForSite method, you should be able to get it to work.

Windows Mobile: "My network card connects to" registry settings

Can anybody please tell me the registry setting(s) that are affected in Windows Mobile 6.1 when a user selects Start -> Settings -> Connections -> Wi-Fi and then changes the value of the "My network card connects to" drop down list on the "Network Adapters" tab?
I have a device that seems to default this to "The Internet" when in fact the Wi-Fi connects to the corporate network and I would like to be able to change this programatically rather than expecting 250+ users to have to do it manually every time they reboot their devices.
Thanks.
I'm not certain that it is a registry change, but if it is, it's easy to determine.
Use the remote registry editor and attach to the device
Save the entire registry to a file
Change the network settings
Save the registry again
Use your favorite diff program to compare the two files
I think you should be able to change this setting using provisioning xml, either via DMProcessConfigXML api, or by making a setup cpf with the xml in it and running it on the device. This post details how to build the xml into a cpf.
The CSP you would be interested in is the Wifi CSP
The 'Work Network' and 'The Internet' are metanetworks that are specified in the xml by guid, usually in the DestId parm. My answer to this question details the xml you can use to pass to DMProcessConfigXML to read the settings on the device to see what they are. Then you can build some xml to just set the right setting. I suspect that you would just need to set the DestId parm of the appropriate wifi entry to the 'Work Network' guid.
According to my registry comparison on WM5 (HTC Touch HD), corroborated by values in http://msdn.microsoft.com/en-us/library/bb737539%28v=MSDN.10%29.aspx, this setting is specified in the registry key:
HKEY_LOCAL_MACHINE\ControlPanel\WiFi\Ethernet\DestID.
"{436EF144-B4FB-4863-A041-8F905A62C572}" (default) The Internet
"{A1182988-0D73-439e-87AD-2A5B369F808B}" Work
I also tried a CE2003 device (Motorola MC50), but couldn’t detect any registry changes. The key above does not exist in the registry on this device.

Resources