I added a new user attribute to my LDAP schema, and configured user-mgt.xml to support the new custom ObjectClass.
Then I used the Claim Management UI, and managed to succesfully set the new attribute to be displayed and Supported by default.
Now it all works: I checked that the new claim is correctly setup in the registry db, and whenever I edit a user profile I can view and edit the new custom attribute.
The question is: Can I set this straight up from some xml configuration file?
My problem is that even I edit claim-config.xml and change the parameters to the corresponding claim in the http://wso2.org/claims dialect to be Supported, and give it a DisplayOrder, it has no effect.
I would like not to depend much on the GUI and registry status, but rather rely on configuration files.
Thanks
You can not edit claim-config.xml file add new claims, if the server has been started once. Only 1st startup, it would populate all claims in to the database (you can delete the database and edit the file and start, then also it would populate). Then you can only edit or add them through management console UI. However, if you know about Identity Server, all these UI functions have been exposed via web service API. If you does not like UI, you can do it using automating web service call... Basically SOAPUI can be used for this purpose.
Related
Where does WSO2 Greg store custom RXTs that are created? They can be edited/added through admin console. I can see the default RXTs under wso2 greg home/repository/resources/rxts but do not see here the custom RXTs
Also let me know
How does WSo2 Greg generate reg_UUID for the resources added? I want to implement the UUID generation script outside so that i can add the resource entries in the respective tables directly from DB?
If you create it using mgt console it will be only stored in DB. However, users can add soft copies of rxt to <GREG_HOME>/repository/resources/rxts/ location. This is a one-time addition and will not reflect any changes that we do to the rxt softcopy afterward. Please find last words of this article.
UUID is created in registry PUT operation and please find the sample code here which we used to generate UUIDs for Swaggers. As per your fix you need to create a registry handler for your assets and remove any existing handler then link your UUID creation logic. Please find this article on how to create a custom handler.
I need to add new user in Wso2 CEP (3.1.0) and I know that is possible by "clicking" few steps in console (example from documentation). I wonder if it possible to add new user without login into console, but connect to H2 database and insert user there?
I know that new user is save into "UM_USER" table.
Maybe someone knows what class write user into H2, how passowrd is enrcypted and what is "UM_SALT_VALUE" and why I need it?
If all you want is to manage users programmatically, a better way rather than trying to modify H2 DB is to do it through the relevant admin service. This way you don't have to bother about the underlying user-store or the salt values used for hashing passwords etc.
In Carbon-based products, most of the configurations done through the web console can be done programmatically by calling the relevant admin web service, such as user management, adding/managing deployment artifacts etc.
So for you use case, you can use the User Management admin service at:
https://localhost:9443/services/UserAdmin?wsdl
Note that in order to access this wsdl, you should make these admin service wsdl's visible by editing <CEP>/repository/conf/carbon.xml and restart the server.
<HideAdminServiceWSDLs>false</HideAdminServiceWSDLs>
Does the WSO2 dashboard allow for User information recovery? I am looking at it currently, and documentation shows that it allows for users to log in and manage their account. Does the Dashboard also support User Information Recovery, (i.e. resetting the password or finding a forgotten username). And if it does, what values in the configuration file do I need to modify?
Yes it does. Sort of. Here is a sample app that, I'm guessing, the WSO2 folks created.
http://cgchamath.blogspot.com/2013/12/password-recovery-with-wso2-identity.html
The example at the bottom has a readme with how to configure the server. What i did was to add a button to the dashboard login page that loaded the configured sample app, then rebranded the sample to make it look more like the dashboard page.
When I go to "My Identity -> My Profiles", it does not give me the option to Add New Profile (as seen on the documentation for User Profile Management), but I can only edit the default profile.
I am using an external MySQL server as the JDBC user store, and creation and editing of users works fine.
I did not find any parameter in the xml files to enable this multiple profile feature. How should I proceed?
Thanks.
Yes. I also find the same. Adding multiple profile for user has been removed from UI. But with JDBC user store, I guess, we can add this using the web service API. Following is the API
https://{ip}:{port}/services/UserProfileMgtService?wsdl
I use Liferay 6.1.1-ce-ga2 bundled with Tomcat server and Oracle 10g database.
My goal is to insert some content, as Journal Article, and display them in an Asset Publisher (with a structure and template, already working).
I used JournalArticleServiceSoap.addArticle(...) with the right fields (groupid, structureid, templateid, ...). The contents are "correctly" inserted in the database and I can see them inside web contents from administrator content panel. The contents have also "Approved" as status. This is done by setting:
serviceContext.setWorkflowAction(WorkflowConstants.ACTION_PUBLISH)
However, I can't see the inserted contents displayed with the other contents in the Asset Publisher, until I open it again for edition and click on publish button (even without changing nothing). Then the content is published as expected. The problem is the number of contents. It is about 600 so I can't to this action for each one.
I do not understand what is the matter and how to figure it out? In other words, what do I have to do to make the web-content inserted by web service display automatically in Asset Publisher?
Or, what does the "Publish" do exactly so I can try to reproduce programmatically with SOAP service (or SQL after insertion)?
Thank you in advance for your help.
I've also posted the same question in Liferay' forum: Problem to display JournalArticle inserted by SOAP web service
you can try to log the database accessing from Liferay and see what will be changed after you save article manualy. Herefor set the logging level of hibernate to info or debug.
are you setting serviceContext like this?
ServiceContext serviceContext = new ServiceContext();
serviceContext.setAddGuestPermissions(true);
serviceContext.setAddGroupPermissions(true);
serviceContext.setScopeGroupId(groupId);
serviceContext.setWorkflowAction(WorkflowConstants.ACTION_PUBLISH);
You must setting serviceContext Like This:
ServiceContext serviceContext = new ServiceContext();
//serviceContext.setAddGuestPermissions(true);
//serviceContext.setAddGroupPermissions(true);
serviceContext.setScopeGroupId(groupId);
serviceContext.setWorkflowAction(1);
serviceContext.setIndexingEnabled(true);
serviceContext.setIndexingEnabled(true); is Very Important.
The following code is not must requeired.
serviceContext.setAddGuestPermissions(true);
serviceContext.setAddGroupPermissions(true);