static void Authenticate() { try { ChannelFactory <ISystemUserService> userSystemSource = new ChannelFactory <ISystemUserService>("userSystemSource"); ISystemUserService userSystemSourceService = userSystemSource.CreateChannel(); ChannelFactory <ISystemUserService> userSystemDest = new ChannelFactory <ISystemUserService>("userSystemDest"); ISystemUserService userSystemDestService = userSystemDest.CreateChannel(); try { userSystemSourceService.Authenticate("rep", "Rep123"); } catch (FaultException <SecurityException> ex) { Console.WriteLine("Error[Source Service] : {0}", ex.Detail.Reason); } try { userSystemDestService.Authenticate("rep", "Rep123"); } catch (FaultException <SecurityException> ex) { Console.WriteLine("Error [Destination Service] : {0}", ex.Detail.Reason); } } catch (Exception ex) { Console.WriteLine(ex.Message); } }
public SystemUserController(ISystemUserService systemUserService, IConfiguration configuration, IWebHostEnvironment webHostEnvironment) { _systemUserService = systemUserService; _webHostEnvironment = webHostEnvironment; }
public SystemUsersController(ICompanyService companyService, IDepartmentService departmentService, IPositionService positionService, ISystemUserService systemUserService) { this.companyService = companyService; this.departmentService = departmentService; this.positionService = positionService; this.systemUserService = systemUserService; }
public PersonController(IPermissionService permissionService, IPersonService personService, ImageService imageService, IUserContext userContext, ISystemUserService systemUserService) : base(userContext, permissionService) { m_PersonService = personService; m_ImageService = imageService; m_UserContext = userContext; m_SystemUserService = systemUserService; }
public UserInfoController(ISystemUserService _systemUserService, ILogger <UserInfoController> _logger, IMapper mapper) { this.systemUserService = _systemUserService; this.logger = _logger; this._mapper = mapper; }
public LoginForm(MainProcessForm mp) { _mp = mp; InitializeComponent(); _systemUserSvc = new SystemUserService(new eFormSqlCeContext()); _profileSvc = new ProfileInfoService(new eFormSqlCeContext()); }
public SecurityController(IUserContext workContext, IPermissionService permissionService, ISystemUserService customerService, ICacheService cacheService, IUserContext userContext) : base(userContext) { m_WorkContext = workContext; m_PermissionService = permissionService; m_CustomerService = customerService; m_CacheService = cacheService; }
public CriteriaController(ICertificateService certificateService, IProductionEquipmentService productionEquipmentService, ISystemUserService systemUserService, IUnitService unitService, IUserGroupService userGroupService, ICriterionService criterionService) { this.certificateService = certificateService; this.productionEquipmentService = productionEquipmentService; this.systemUserService = systemUserService; this.unitService = unitService; this.userGroupService = userGroupService; this.criterionService = criterionService; }
public UserController(IWebAppContext appContext , ISystemUserService userService , IPrivilegeTreeBuilder privilegeTreeBuilder , ISystemUserPermissionService systemUserPermissionService) : base(appContext) { _userService = userService; _privilegeTreeBuilder = privilegeTreeBuilder; _systemUserPermissionService = systemUserPermissionService; }
public ClaimAuthenticationService(IHttpContextAccessor httpContext , ISessionService sessionService , ISystemUserService userService , ICurrentUser currentUser ) { _httpContext = httpContext.HttpContext; _sessionService = sessionService; _userService = userService; _cachedUser = currentUser; }
public AccountController(IWebAppContext appContext , IAuthenticationService authenticationService , ISystemUserService systemUserService , IVerifyProvider verifyProvider ) : base(appContext) { _authenticationService = authenticationService; _systemUserService = systemUserService; _verifyProvider = verifyProvider; }
static void Main(string[] args) { ChannelFactory <IPersonService> personFactory = new ChannelFactory <IPersonService>(typeof(IPersonService).ToString()); ChannelFactory <ISystemUserService> userSystemFactory = new ChannelFactory <ISystemUserService>(typeof(ISystemUserService).ToString()); _userSystemService = userSystemFactory.CreateChannel(); _personService = personFactory.CreateChannel(); //MeniZaRad(); Zadatak4(); }
public SystemUserController(ISystemUserService systemUserService, IImageService imageService, IPermissionService permissionService, IPersonService personService, IStaffService staffService, ICountrySubOfficeService countrySubOfficeService, IBudgetService budgetService, IDesignationService designationService, INotificationService notificationService, IUserContext usercontext, ICacheService cacheService) : base(usercontext) { m_SystemUserService = systemUserService; m_ImageService = imageService; m_PermissionService = permissionService; m_PersonService = personService; m_StaffService = staffService; m_CountrySubOfficeService = countrySubOfficeService; m_DesignationService = designationService; m_budgetService = budgetService; m_notificationService = notificationService; m_cacheService = cacheService; }
private void CheckingRepositoriesAndServices() { _incidentXrmRepository = _repositoryNinjectFactory.IncidentXrmRepository(); if (_incidentXrmRepository == null) { throw new NullReferenceException("IncidentXrmRepository is null"); } _sqlService = _internalServiceFactory.SqlService(); if (_sqlService == null) { throw new NullReferenceException("SqlService is null"); } _incidentService = _internalServiceFactory.IncidentService(); if (_incidentService == null) { throw new NullReferenceException("IncidentService is null"); } _systemUserService = _internalServiceFactory.SystemUserService(); if (_systemUserService == null) { throw new NullReferenceException("SystemUserService is null"); } _phoneCallService = _internalServiceFactory.PhoneCallService(); if (_phoneCallService == null) { throw new NullReferenceException("PhoneCallService is null"); } _emailService = _internalServiceFactory.EmailService(); if (_emailService == null) { throw new NullReferenceException("EmailService is null"); } _annotationService = _internalServiceFactory.AnnotationService(); if (_annotationService == null) { throw new NullReferenceException("AnnotationService is null"); } }
public CustomerService(IAdminService adminService, ISystemService systemService, IAdminLookupItemsService adminLookupItemsService, IAdminEmailAddressService adminEmailAddressService, IAdminPhoneNumberService adminPhoneNumberService, IAdminUsersService adminUsersService, ISystemAddressService systemAddressService, ISystemPhoneNumberService systemPhoneNumberService, ISystemWebsiteService systemWebsiteService, ISystemPointOfContactService systemPointOfContactService, ISystemLookupItemService systemLookupItemService, ISystemUserService systemUserService, ICustomersManager customersManager, IHashingService hashingService, IConfiguration configuration, IWebHostEnvironment webHostEnvironment) : base(configuration, webHostEnvironment) { _hashingService = hashingService; _systemService = systemService; _adminService = adminService; _adminLookupItemsService = adminLookupItemsService; _adminEmailAddressService = adminEmailAddressService; _adminPhoneNumberService = adminPhoneNumberService; _adminUsersService = adminUsersService; _systemAddressService = systemAddressService; _systemPhoneNumberService = systemPhoneNumberService; _systemWebsiteService = systemWebsiteService; _systemPointOfContactService = systemPointOfContactService; _systemLookupItemService = systemLookupItemService; _systemUserService = systemUserService; _customersManager = customersManager; _configuration = configuration; _webHostEnvironment = webHostEnvironment; }
public SecurityController(IWebAppContext appContext , ISystemUserService userService , ISystemUserRolesService systemUserRolesService , IRoleService roleService , IRoleObjectAccessService roleObjectAccessService , IDataCreater dataCreater , IDataFinder dataFinder , IDataDeleter dataDeleter , IResourceOwnerService resourceOwnerService) : base(appContext) { _roleService = roleService; _userService = userService; _systemUserRolesService = systemUserRolesService; _roleObjectAccessService = roleObjectAccessService; _dataCreater = dataCreater; _dataFinder = dataFinder; _dataDeleter = dataDeleter; _resourceOwnerService = resourceOwnerService; }
/// <summary> /// Constructor /// </summary> /// <param name="systemUserService">System services.</param> /// <param name="hashingService">Hashing services.</param> /// <param name="systemEmailAddressService">System email address services.</param> /// <param name="systemPhoneNumberService">System phone number services.</param> /// <param name="systemLookupItemService">System lookup item services.</param> /// <param name="systemSubscriptionService">System subscription services.</param> /// <param name="systemDepartmentService">System department services.</param> /// <param name="systemUserManager">System database user managers.</param> /// <param name="systemManager">System database managers.</param> /// <param name="configuration">Microsoft configuration services.</param> /// <param name="webHostEnvironment">Microsoft web hosting environment services.</param> public SystemService(ISystemUserService systemUserService, IHashingService hashingService, ISystemEmailAddressService systemEmailAddressService, ISystemPhoneNumberService systemPhoneNumberService, ISystemLookupItemService systemLookupItemService, ISystemSubscriptionService systemSubscriptionService, ISystemDepartmentService systemDepartmentService, ISystemUserManager systemUserManager, ISystemManager systemManager, IConfiguration configuration, IWebHostEnvironment webHostEnvironment) : base(configuration, webHostEnvironment) { _systemUserService = systemUserService; _hashingService = hashingService; _systemEmailAddressService = systemEmailAddressService; _systemPhoneNumberService = systemPhoneNumberService; _systemLookupItemService = systemLookupItemService; _systemSubscriptionService = systemSubscriptionService; _systemDepartmentService = systemDepartmentService; _systemUsersManager = systemUserManager; _systemManager = systemManager; _configuration = configuration; _webHostEnvironment = webHostEnvironment; }
public override void OnAuthorization(AuthorizationContext filterContext) { BaseAdminController controller = filterContext.Controller as BaseAdminController; if (controller != null) { base.OnAuthorization(filterContext); ServerLogger.Info(string.Format("Authorize controller {0}", controller.GetType().ToString())); ISystemUserService systemUserService = (ISystemUserService)Bootstrapper.GetService <ISystemUserService>(); SystemUserDataInfo user = systemUserService.GetSystemUserDataInfoByID(controller.CurrentUserID); if (user == null) { filterContext.Result = new RedirectResult("/Account/AdminLogin"); } else { base.OnAuthorization(filterContext); } } else { base.OnAuthorization(filterContext); } }
public SystemUsersController(ISystemUserService Service) { SystemUserService = Service; }
public HomeController(ISystemUserService systemUserService) { _systemUserService = systemUserService; }
//private readonly string _orgUniqueName; public CustomResourceOwnerPasswordValidator(ISystemUserService systemUserService)//, IHttpContextAccessor httpContext) { _systemUserService = systemUserService; //_orgUniqueName = httpContext.HttpContext.GetRouteOrQueryString("org")?.ToString(); }
public SystemUserController() { userService = MyUnity.GetService <ISystemUserService>(); }
/// <summary> /// IOC注入 /// </summary> /// <param name="systemUserService"></param> public SystemAccountController(ISystemUserService systemUserService) { _systemUserService = systemUserService; }
public AuthManager(ISystemUserService systemUserService, ITokenHelper tokenHelper) { _systemUserService = systemUserService; _tokenHelper = tokenHelper; }
public LoginController(ISystemUserService systemUserService) { _systemUserService = systemUserService; }
public AuthenticationService(ISystemUserService systemUserService, IEncryptionService encryptionService, INotificationService notificationService) { m_SystemUserService = systemUserService; m_EncryptionService = encryptionService; m_NotificationService = notificationService; }
public LogInController(JwtSettings _jwtSettingsAccesser, ISystemUserService _systemUserService, ILogger <LogInController> _logger) { _jwtSettings = _jwtSettingsAccesser; this.systemUserService = _systemUserService; this.logger = _logger; }
/// <summary> /// ctor /// </summary> /// <param name="supplierService"></param> public SupplierController(ISupplierService supplierService, ISystemUserService systemUserService) { this._supplierService = supplierService; this._systemUserService = systemUserService; }
public RoleController(ISystemUserService systemUserService, IPermissionService permissionService, IUserContext userContext) : base(userContext) { m_SystemUserService = systemUserService; m_PermissionService = permissionService; }
public ValuesController(ISystemUserService _systemUserService, ILogger <ValuesController> _logger) { this.systemUserService = _systemUserService; this.logger = _logger; }