Has anyone out there got some simple to implement calls which we can use from within Ebase to find values such as the:
Users Windows AD username
User Windows AD group
Users Windows domain
The last post on the forum regarding this appeared 7 years ago, so I presume things have moved on a bit since then?
If I try the suggested call in the old post I get what appears to be the server end info and not the client credentials.
Retrieving Windows environment variables from within Ebase
Moderators: Jon, Steve, Ian, Dave
-
- Ebase User
- Posts: 201
- Joined: Fri Dec 20, 2013 1:29 pm
- Location: Dartford Borough Council
- Contact:
-
- Ebase User
- Posts: 95
- Joined: Wed Feb 27, 2013 5:16 pm
Hi,
We had this working on a test apps a while back...I think we got everything we needed from this post.
http://forum.ebasetech.com/forum/viewtopic.php?t=689
When we had setup the single-signon we then introduced permissions based upon AD Groups etc. Someone with more experience maybe able to provide more help.
This was ultimately the command to grab the attribute values:
We had this working on a test apps a while back...I think we got everything we needed from this post.
http://forum.ebasetech.com/forum/viewtopic.php?t=689
When we had setup the single-signon we then introduced permissions based upon AD Groups etc. Someone with more experience maybe able to provide more help.
This was ultimately the command to grab the attribute values:
Code: Select all
LdapServices.getUserAttribute(system.variables.$USER , 'attributename...goeshere');
0 x
-
- Ebase User
- Posts: 331
- Joined: Mon Mar 10, 2014 8:34 am
Hi Neil, we ended up writing a simple aspx file to output AD data in json format.
We then use a JQuery ajax call and push the data into Ebase via $eb.SetFieldValue.
eg
Sorry I can't recall why we ended up going down this line but it works well.
Thanks
We then use a JQuery ajax call and push the data into Ebase via $eb.SetFieldValue.
eg
Code: Select all
<script>
$(document).ready(function() {
var TheURL = "http://&&{$ENV_DOTNETWEBSERVICE_SERVER}/CurrentUser/default.aspx";
$.ajax({
dataType:"jsonp",
contentType:"text/json",
url:TheURL,
type:"get",
crossDomain:true,
xhrFields:{withCredentials:true},
success: GetDets
});
});
function GetDets(response)
{
var UserName = '';
UserName = response.UserAccount;
var PCName = '';
PCName = response.PCHost;
var FullName = '';
FullName = response.FullName;
var EmailAddress = response.Email;
SetField("USERNAME",FullName);
SetField("USEREMAILADDRESS",EmailAddress);
};
</script>
Thanks
0 x
-
- Ebase User
- Posts: 201
- Joined: Fri Dec 20, 2013 1:29 pm
- Location: Dartford Borough Council
- Contact:
Who is online
Users browsing this forum: No registered users and 21 guests