I hereby claim:
- I am ilgrosso on github.
- I am ilgrosso (https://keybase.io/ilgrosso) on keybase.
- I have a public key whose fingerprint is 6F62 BD06 FCE8 4D77 4248 4EBC 6B43 13ED 273D F287
To claim this, I am signing this object:
// encrypted password is in encPwd | |
GuardedString encPwd = ...; | |
final StringBuilder clearPwd = new StringBuilder(); | |
encPwd.access(new GuardedString.Accessor() { | |
@Override | |
public void access(final char[] clearChars) { | |
clearPwd.append(clearChars); |
ODataClient client = ODataClientFactory.getV3(); // or ODataClientFactory.getV4(); | |
String serviceRoot = ...; | |
URIBuilder uriBuilder = client.getURIBuilder(serviceRoot). | |
appendEntityTypeSegment("Customer").appendKeySegment(-10).expand("Info"); | |
// long version (using ATOM) | |
ODataEntityRequest req = client.getRetrieveRequestFactory().getEntityRequest(uriBuilder.build()); | |
req.setFormat(ODataPubFormat.ATOM); | |
ODataRetrieveResponse<ODataEntity> res = req.execute(); |
Edm edm = getClient().getRetrieveRequestFactory(). | |
getMetadataRequest(testStaticServiceRootURL).execute().getBody(); | |
EdmFunction func = edm.getUnboundFunction("GetPrimitiveString", null); | |
EdmEntityContainer container = edm.getSchemas().get(0).getEntityContainer(); | |
URIBuilder builder = getClient().getURIBuilder(testStaticServiceRootURL). | |
appendOperationCallSegment(URIUtils.operationImportURISegment(container, func.getName())); | |
ODataProperty property = getClient().getInvokeRequestFactory(). |
I hereby claim:
To claim this, I am signing this object:
set 04, 2015 4:14:03 PM org.apache.cxf.interceptor.LoggingOutInterceptor | |
INFORMAZIONI: Outbound Message | |
--------------------------- | |
ID: 1 | |
Address: http://localhost:9080/syncope/rest/policies | |
Http-Method: POST | |
Content-Type: application/json | |
Headers: {Content-Type=[application/json], Accept=[application/json], Authorization=[Basic YWRtaW46cGFzc3dvcmQ=]} | |
Payload: {"@class":"org.apache.syncope.common.lib.policy.AccountPolicyTO","key":0,"description":"Account Policy with custom rules","type":"ACCOUNT","propagateSuspension":false,"maxAuthenticationAttempts":0,"usedByResources":[],"usedByRealms":[],"ruleConfs":[{"@class":"net.tirasa.blog.ilgrosso.syncopecustompolicyrules.common.CustomAccountRuleConf","name":"net.tirasa.blog.ilgrosso.syncopecustompolicyrules.common.CustomAccountRuleConf","requiredSubString":"tralallallero"}],"resources":[]} | |
-------------------------------------- |
import org.apache.commons.collections4.CollectionUtils; | |
import org.apache.commons.collections4.Transformer; | |
import org.apache.commons.collections4.list.SetUniqueList; | |
// Given this user... | |
UserTO userTO = ... | |
List<String> groupKeys = SetUniqueList.setUniqueList(new ArrayList<String>()); | |
// First statically assigned groups... |
package org.apache.syncope.core.provisioning.java.pushpull; | |
import javax.script.Bindings; | |
import javax.script.Invocable; | |
import javax.script.ScriptContext; | |
import javax.script.ScriptEngine; | |
import javax.script.ScriptException; | |
import javax.script.SimpleBindings; | |
import org.apache.syncope.common.lib.patch.AnyPatch; | |
import org.apache.syncope.common.lib.to.AnyTO; |
List<PullActions> actions = new ArrayList<>(); | |
for (String className : pullTask.getActionsClassNames()) { | |
try { | |
PullActions pullActions; | |
if (className.indexOf('.') == -1) { | |
ExtensionScript script = null; // suppose to fetch it using className as key | |
ScriptEngine engine = new ScriptEngineManager().getEngineByName("nashorn"); | |
engine.eval(new InputStreamReader(script.getContent())); |
import java.lang.reflect.Method; | |
import org.hotswap.agent.annotation.Init; | |
import org.hotswap.agent.annotation.OnClassLoadEvent; | |
import org.hotswap.agent.annotation.OnResourceFileEvent; | |
import org.hotswap.agent.annotation.Plugin; | |
import org.hotswap.agent.command.Scheduler; | |
import org.hotswap.agent.javassist.CannotCompileException; | |
import org.hotswap.agent.javassist.CtClass; | |
import org.hotswap.agent.javassist.NotFoundException; | |
import org.hotswap.agent.logging.AgentLogger; |
Based on http://fabiorehm.com/blog/2014/09/11/running-gui-apps-with-docker/
Dockerfile
as follows:FROM ubuntu:18.04
RUN apt-get update && apt-get install -y firefox
# Replace 1001 with your user / group id
RUN export uid=1001 gid=1001 && \