Detecting PCF version(s) - cloud-foundry

I have access to our corporate PCF, though both the Apps Manager webpage and the "cf" CLI (and thus the API).
How can I detect what version of PCF they're running? There's nothing in the website that lists it, and the best I can find is using cf api which returns:
api version: 2.98.0
How can I map that to the PCF version, or is there another way to detect it?

Usually via Ops Manager however another quick way is to click on the 'Docs' in Apps Manager it should take you to the documentation of relevant PCF version. For ex: https://docs.pivotal.io/pivotalcf/2-6/pas/intro.html means PCF 2.6
Please be advised that documentation link requires to be updated during upgrades so if someone doesn't do - it will be pointing out to older version..

I don't believe Apps Manager or the API (i.e. Cloud Controller) will report that information. Both are just single parts of the entire system, so I think you could really only expect them to publish their own version information.
If you want to see versions of what is installed, you need to look at Ops Manager. That will show you the tiles that are installed and each version.
If you don't have access to Ops Manager, you'd need to ask your platform operators.
Hope that helps!

Related

Sitecore 8.1 API Documentation Related to Users

I'm looking for API documentation on how to interact with user accounts. For example, checking if a user exists, creating a user, updating a user, getting user properties. I've been to doc.sitecore.net but I still can't seem to find any of this documented. Is it documented and where can I find it? If it is not documented, what other resources can I access?
In 6.x versions, I see that some of the functionality I need is in Sitecore.Security.Accounts. However, I don't know if this is still current or if there is a better method for 8.1 and future versions.
The 6.x guidelines are still the most current, and as of 8.2, there has not been any major changes to that API, so the Security API Cookbook is still your best bet.
https://sdn.sitecore.net/Reference/Sitecore%206/Security%20API%20Cookbook.aspx
To my knowledge, this part hasn't been changed since Sitecore 6.x, so you should be safe to use this resource.

Configuring WSO2 Identity Server as Key Manager with API Manager

I'm looking for some guidance about two specific WSO2 products, API Manager and Identity Server and for the best solution to solve the problem I'm going to explain below.
In my company, we are using ADFS 3.0 for Single Sign On support in our applications. However we are now building applications that will require OpenID Connect Specification (SPA's+Rest API's) and ADFS does not support this out of the box so we've decided to use WSO2 products for that purpose.
I already managed to install WSO2 Identity Server 5.0.0 SP1 and configured ADFS as a federated Identity Provider (the new applications will still have to authenticate users using ADFS). I also installed WSO2 API Manager 1.9.1 and configured it to use WSO2 Identity Server as the Key Manager (Configuration tutorial).
Now the problem:
Using WSO2 Identity Server 5.0.0 SP1 I couldn't get the Logout feature to work due to the issue reported here. It seems that this issue has been solved in version 5.1.0M4 so I tried to install version 5.1.0-alpha and managed to make the logout to work with ADFS (I tested it by enabling SSO for the carbon administration). However, now I'm not able to install the Key Manager feature through the carbon repositories due to incompatibilities.
As a result, with the first combination (wso2is 5.0.0 SP1/wso2am 1.9.1) I had the logout issue with ADFS and with the second combination (wso2is 5.1.0-alpha/wso2am 1.9.1), I'm not able to install the Key Manager feature in Identity Server.
Is there any way to apply a patch to solve the logout issue in the first combination? Is there a way to install the key manager feature on WSO2IS 5.1.0-alpha? Or can someone point me to another solution to solve this issue?
The issue you pointed above, marked as it type as "Patch". Usually that means WSO2 have fixed this issue for a earlier version and provided a patch to its customer. Easiest thing would be, if you are already a customer of WSO2 ask for the patch directly from their support.
If you are not a paid customer of WSO2 you are in bit of a trouble. As per this question, the source of the Service Pack also not available in public.
But luckily in your case, the component which need to have this fix not a core component. So you wouldn't be in trouble if you change the authenticator code bit. But the warning is, it would lose any fixes done for org.wso2.carbon.identity.application.authenticator.samlsso_4.2.1.jar in the service pack.
Anyway, these are the steps you should follow.
Checkout the source. Lazy path would be checkout the whole source from here. That is the most easy way which you will face less troubles when you try to build the source but the downside of that is, it would take bit of time to checkout. If you know how to build specific component from WSO2 source, you can directly checkout component it needed to changed.
Try to build the component without doing any change just to make sure there are not any issues upto this point.
Goto the class DefaultSAML2SSOManager and do the same change done in the PR.
Build the component again.
Create folder named like "patch9000" inside the <IS_HOME>/repository/components/patches/ folder.
Copy build jar (org.wso2.carbon.identity.application.authenticator.samlsso-4.2.1.jar ) in step 4 from the target folder to the <IS_HOME>/repository/components/patches/patch9000 folder.
Restart the server. If you have done everything to the point, in the server startup it would print a log like, org.wso2.carbon.server.extensions.PatchInstaller - Patch changes detected
Now retry the your flow and it would work as expected.
If you too lazy to do all above, you can wait until Identity Server Service Pack 2, which will have your fix.

Take a picture and share it with one voice command using Google Glass Mirror API

I just started using the Mirror API with a PHP web server. Is there anyway to integrate a voice command with my app that when said, Glass will take a picture and automatically share the picture with my server?
From what I read so far, it doesn't seem possible to access the camera with anything other than the default "Take picture" command. I also don't see a way to have Glass commit two actions (in this case take a picture and then share it) with one voice command. Is there any way to do the above with the Mirror API?
This isn't possible with the current features provided by the Mirror API. If this is a feature you're interested in using, file it in the official issue tracker.
However, you can implement this functionality with the GDK.

WSO2 products and Carbon version compatibility

I want to include multiple WSO2 products in 1 Carbon Management console. I started with Carbon 4.1.0. However, when installing features, not all products are listed (e.g. BRS, Identity Server etc). I understand that these will added in the future (?).
You can add additional repositories in the console, pointing to other versions of Carbon.
Now my questions are:
Will this result in a stable environment (multiple carbon versions) and products that can work together?
Is this the way to go (having 1 management console for multiple products)?
Are 4.x carbon based products compatible with 3.x carbon based products?
Is there an overview of WSO2 product versions and what Carbon version contains the features?
1) It is not recommended to install multiple features without careful analysis of them. Actually products are carefully analysed and proven features that are grouped together to solve common problems. As an example if you combine AS + ESB features yes you can have it but
it may result in poor performance in ESB since your services are hosted in the same server too. (Likewise there are many negatives). Further some of the combinations are not properly tested in an production environment and will have some unidentified issues, But released products are tested properly and used in production too.
2) Not compatible. You cannot install 3.x features in 4.x.
3) You may refer this for product overviews
http://wso2.com/products/carbon/release-matrix/
About your initial question, under carbon 4.1.0 still only AS(5.1.0) is released. Rest will be released later on (sometimes may be with carbon 4.1.x or 4.2.x).

Is there any documentation on TFS Web Services?

I am looking for any information on the Microsoft TFS Web Services. First I know accessing the Microsoft TFS Web Services directly is not supported and Microsoft provides no documentation for doing this. Therefore I am not expecting any Microsoft support or assistance here.
I know all about the .Net API available for TFS which only works on Microsoft Operating Systems. I have used these many times on Windows, however I need to do non-Windows work to access TFS, I cannot use .Net and I cannot use a Proxy (or "shim") to be installed on a Windows computer to provide Web Services for the .Net API.
I know Teamprise reversed engineered the web services and they successfully used this knowledge to make a very good cross platform Team Explorer and command line implementation in Java to access TFS. So good in fact they were purchased by Microsoft and the product rebranded and rereleased as Microsoft Visual Studio Team Explorer Everywhere.
I have also tested the .Net API against Mono on several non-windows platforms and they are not compatible. The initial NTLMv2 authentication is using calls not supported by Mono. They appear to be, understandably, making Win32 specific calls for NTLMv2 support.
Therefore before I go to the trouble of reverse engineering them for myself, and dealing with NTLMv2 to do it. I am hoping that there is some hidden or buried information on the web that someone may have documented some portion of the web services for TFS from 2005, 2008 and/or 2010.
Please no comments or posts about how this is not recommended or supported by Microsoft, that I should find a way to use the .Net API, or suggesting the Proxy/Shim is the best solution. I am fully aware of the Microsoft's official stance on this, and what the supported workarounds would be.
I'm not aware of any documentation for the TFS web services, but I can share some tips on calling them.
The NTLM authentication you mention is really a separate layer: you must authenticate to IIS before it lets you call TFS web services. I'm not aware of any Open Source software that will do NTLM auth for you, but TFS 2010 makes it easy to enable "Negotiate" authentication (SPNEGO on Wikipedia, Authentication by using Kerberos Ticket on MSDN). Negotiate supports both NTLM and Kerberos subsystems, and there may be some existing software you can use to drive it using the system's Kerberos libraries (I think curl does it). If you had to build it yourself, it would probably be easier to go the Negotiate-with-Kerberos route.
Once you're authenticated, you can start calling services. Start by pulling down the WSDL for each service (stick a "?wsdl" suffix on each endpoint URI). Hop over to where TFS is installed and explore the web application directory for endpoints. There are several versions of some endpoints for back compat with TFS 2005 and 2008, but usually new versions are not redundant (they add new stuff). You might have a favorite SOAP client library already (there are many for Java), but I can't really recommend any because we wrote our own at Teamprise.
Services like version control, build, and common structure are easy to discover via WSDL. Most the operations have obvious names, but the complex type fields are often super-abbreviated. The best way to figure which methods to call when is to watch the VS TFS client or TEE with Fiddler or Wireshark or some other HTTP inspection program. TFS VC does do things like file uploads/downloads outside the web services (watch a network trace to see the multi-part MIME upload process and be sure you're sending the right values if you implement this).
A note of caution on the work item tracking web service: this one is going to be extremely hard to master. The WIT design involves the client pre-querying the server for large amounts of schema-less metadata, which is saved on the client (but refreshed incrementally as more web service calls are made). This metadata drives all the client side behavior about work items (what fields are in a work item type, the type of a field, which values are allowed in fields, the rules that run when they change, etc.) and it will take a long time and serious study to build the client behavior to bring a work item to life. Once you have a work item, sending it to the server for update via web services is easy.
It's a lot of work, but it's possible to do incrementally, for example, if you only need some VC features. The TEE team is working on making access from other platforms easier. Please contact Martin Woodward (martin.woodward#microsoft.com) if you have any questions or suggestions in this area.
There is a Java version of the TFS SDK that will run on Linux, Mac, and Windows. It is the SDK that Teamprise uses.
http://blogs.msdn.com/b/bharry/archive/2011/05/16/announcing-a-java-sdk-for-tfs.aspx
Coding directly against the TFS webservices is not supported (even though people have done it). MSFT could break the interface without letting you know in a service pack or other hotfix. Sometimes there aren't other options, but if the Java SDK works for you, I'd try to use that first.
There is good documentation now: https://www.visualstudio.com/integrate/get-started/rest/basics