@extends('layouts/default') {{-- Page title --}} @section('title') Update LDAP/AD Settings @parent @stop @section('header_right') {{ trans('general.back') }} @stop {{-- Page content --}} @section('content') @if ((!function_exists('ldap_connect')) || (!function_exists('ldap_set_option')) || (!function_exists('ldap_bind')))
It doesn't look like the LDAP extension is installed or enabled on this server. :(
@else {{ Form::open(['method' => 'POST', 'files' => false, 'autocomplete' => 'false', 'class' => 'form-horizontal', 'role' => 'form' ]) }} {{csrf_field()}}

LDAP/AD

{{ Form::label('ldap_integration', trans('admin/settings/general.ldap_integration')) }}
@if (config('app.lock_passwords')===true) {{ Form::checkbox('ldap_enabled', '1', Input::old('ldap_enabled', $setting->ldap_enabled),['class' => 'minimal disabled', 'disabled' => 'disabled']) }} @else {{ Form::checkbox('ldap_enabled', '1', Input::old('ldap_enabled', $setting->ldap_enabled),array('class' => 'minimal')) }} @endcan {{ trans('admin/settings/general.ldap_enabled') }} {!! $errors->first('ldap_enabled', '') !!}
{{ Form::label('is_ad', trans('admin/settings/general.ad')) }}
@if (config('app.lock_passwords')===true) {{ Form::checkbox('is_ad', '1', Input::old('is_ad', $setting->is_ad),['class' => 'minimal disabled', 'disabled' => 'disabled']) }} @else {{ Form::checkbox('is_ad', '1', Input::old('is_ad', $setting->is_ad),array('class' => 'minimal')) }} @endif {{ trans('admin/settings/general.is_ad') }} {!! $errors->first('is_ad', '') !!}
{{ Form::label('ldap_pw_sync', trans('admin/settings/general.ldap_pw_sync')) }}
@if (config('app.lock_passwords')===true) {{ Form::checkbox('ldap_pw_sync', '1', Input::old('ldap_pw_sync', $setting->ldap_pw_sync),['class' => 'minimal disabled', 'disabled' => 'disabled']) }} @else {{ Form::checkbox('ldap_pw_sync', '1', Input::old('ldap_pw_sync', $setting->ldap_pw_sync),array('class' => 'minimal')) }} @endif {{ trans('general.yes') }}

{{ trans('admin/settings/general.ldap_pw_sync_help') }}

{!! $errors->first('ldap_pw_sync', '') !!}
{{ Form::label('ad_domain', trans('admin/settings/general.ad_domain')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ad_domain', Input::old('ad_domain', $setting->ad_domain), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'example.com')) }} @else {{ Form::text('ad_domain', Input::old('ad_domain', $setting->ad_domain), array('class' => 'form-control','placeholder' => 'example.com')) }} @endif

{{ trans('admin/settings/general.ad_domain_help') }}

{!! $errors->first('ad_domain', '') !!}
{{ Form::label('ldap_server', trans('admin/settings/general.ldap_server')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_server', Input::old('ldap_server', $setting->ldap_server), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'ldap://ldap.example.com')) }} @else {{ Form::text('ldap_server', Input::old('ldap_server', $setting->ldap_server), array('class' => 'form-control','placeholder' => 'ldap://ldap.example.com')) }} @endif

{{ trans('admin/settings/general.ldap_server_help') }}

{!! $errors->first('ldap_server', '') !!}
{{ Form::label('ldap_tls', trans('admin/settings/general.ldap_tls')) }}
@if (config('app.lock_passwords')===true) {{ Form::checkbox('ldap_tls', '1', Input::old('ldap_tls', $setting->ldap_tls),['class' => 'minimal disabled', 'disabled' => 'disabled']) }} @else {{ Form::checkbox('ldap_tls', '1', Input::old('ldap_tls', $setting->ldap_tls),array('class' => 'minimal')) }} @endif {{ trans('admin/settings/general.ldap_tls_help') }} {!! $errors->first('ldap_tls', '') !!}
{{ Form::label('ldap_server_cert_ignore', trans('admin/settings/general.ldap_server_cert')) }}
@if (config('app.lock_passwords')===true) {{ Form::checkbox('ldap_server_cert_ignore', '1', Input::old('ldap_server_cert_ignore', $setting->ldap_server_cert_ignore),['class' => 'minimal disabled', 'disabled' => 'disabled']) }} @else {{ Form::checkbox('ldap_server_cert_ignore', '1', Input::old('ldap_server_cert_ignore', $setting->ldap_server_cert_ignore),array('class' => 'minimal')) }} @endif {{ trans('admin/settings/general.ldap_server_cert_ignore') }} {!! $errors->first('ldap_server_cert_ignore', '') !!}

{{ trans('admin/settings/general.ldap_server_cert_help') }}

{{ Form::label('ldap_uname', trans('admin/settings/general.ldap_uname')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_uname', Input::old('ldap_uname', $setting->ldap_uname), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'binduser@example.com')) }} @else {{ Form::text('ldap_uname', Input::old('ldap_uname', $setting->ldap_uname), array('class' => 'form-control','placeholder' => 'binduser@example.com')) }} @endif {!! $errors->first('ldap_uname', '') !!}
{{ Form::label('ldap_pword', trans('admin/settings/general.ldap_pword')) }}
@if (config('app.lock_passwords')) {{ Form::password('ldap_pword', array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'binduserpassword')) }} @else {{ Form::password('ldap_pword', array('class' => 'form-control','placeholder' => 'binduserpassword')) }} @endif {!! $errors->first('ldap_pword', '') !!}
{{ Form::label('ldap_basedn', trans('admin/settings/general.ldap_basedn')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_basedn', Input::old('ldap_basedn', $setting->ldap_basedn), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'cn=users/authorized,dc=example,dc=com')) }} @else {{ Form::text('ldap_basedn', Input::old('ldap_basedn', $setting->ldap_basedn), array('class' => 'form-control','placeholder' => 'cn=users/authorized,dc=example,dc=com')) }} @endif {!! $errors->first('ldap_basedn', '') !!}
{{ Form::label('ldap_filter', trans('admin/settings/general.ldap_filter')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_filter', Input::old('ldap_filter', $setting->ldap_filter), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => '&(cn=*)')) }} @else {{ Form::text('ldap_filter', Input::old('ldap_filter', $setting->ldap_filter), array('class' => 'form-control','placeholder' => '&(cn=*)')) }} @endif {!! $errors->first('ldap_filter', '') !!}
{{ Form::label('ldap_username_field', trans('admin/settings/general.ldap_username_field')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_username_field', Input::old('ldap_username_field', $setting->ldap_username_field), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'samaccountname')) }} @else {{ Form::text('ldap_username_field', Input::old('ldap_username_field', $setting->ldap_username_field), array('class' => 'form-control','placeholder' => 'samaccountname')) }} @endif {!! $errors->first('ldap_username_field', '') !!}
{{ Form::label('ldap_lname_field', trans('admin/settings/general.ldap_lname_field')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_lname_field', Input::old('ldap_lname_field', $setting->ldap_lname_field), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'sn')) }} @else {{ Form::text('ldap_lname_field', Input::old('ldap_lname_field', $setting->ldap_lname_field), array('class' => 'form-control','placeholder' => 'sn')) }} @endif {!! $errors->first('ldap_lname_field', '') !!}
{{ Form::label('ldap_fname_field', trans('admin/settings/general.ldap_fname_field')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_fname_field', Input::old('ldap_fname_field', $setting->ldap_fname_field), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'givenname')) }} @else {{ Form::text('ldap_fname_field', Input::old('ldap_fname_field', $setting->ldap_fname_field), array('class' => 'form-control','placeholder' => 'givenname')) }} @endif {!! $errors->first('ldap_fname_field', '') !!}
{{ Form::label('ldap_auth_filter_query', trans('admin/settings/general.ldap_auth_filter_query')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_auth_filter_query', Input::old('ldap_auth_filter_query', $setting->ldap_auth_filter_query), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => '"uid="')) }} @else {{ Form::text('ldap_auth_filter_query', Input::old('ldap_auth_filter_query', $setting->ldap_auth_filter_query), array('class' => 'form-control','placeholder' => '"uid="')) }} @endif {!! $errors->first('ldap_auth_filter_query', '') !!}
{{ Form::label('ldap_version', trans('admin/settings/general.ldap_version')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_version', Input::old('ldap_version', $setting->ldap_version), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => '3')) }} @else {{ Form::text('ldap_version', Input::old('ldap_version', $setting->ldap_version), array('class' => 'form-control','placeholder' => '3')) }} @endif {!! $errors->first('ldap_version', '') !!}
{{ Form::label('ldap_active_flag', trans('admin/settings/general.ldap_active_flag')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_active_flag', Input::old('ldap_active_flag', $setting->ldap_active_flag), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => '')) }} @else {{ Form::text('ldap_active_flag', Input::old('ldap_active_flag', $setting->ldap_active_flag), array('class' => 'form-control','placeholder' => '')) }} @endif {!! $errors->first('ldap_active_flag', '') !!}
{{ Form::label('ldap_emp_num', trans('admin/settings/general.ldap_emp_num')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_emp_num', Input::old('ldap_emp_num', $setting->ldap_emp_num), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => '')) }} @else {{ Form::text('ldap_emp_num', Input::old('ldap_emp_num', $setting->ldap_emp_num), array('class' => 'form-control','placeholder' => '')) }} @endif {!! $errors->first('ldap_emp_num', '') !!}
{{ Form::label('ldap_email', trans('admin/settings/general.ldap_email')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('ldap_email', Input::old('ldap_email', $setting->ldap_email), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => '')) }} @else {{ Form::text('ldap_email', Input::old('ldap_email', $setting->ldap_email), array('class' => 'form-control','placeholder' => '')) }} @endif {!! $errors->first('ldap_email', '') !!}
@if ($setting->ldap_enabled)
{{ Form::label('test_ldap_sync', 'Test LDAP Sync') }}

{{ trans('admin/settings/general.ldap_login_sync_help') }}

{{ Form::label('test_ldap_login', 'Test LDAP Login') }}

{{ trans('admin/settings/general.ldap_login_test_help') }}

@endif
{{ Form::label('custom_forgot_pass_url', trans('admin/settings/general.custom_forgot_pass_url')) }}
@if (config('app.lock_passwords')===true) {{ Form::text('custom_forgot_pass_url', Input::old('custom_forgot_pass_url', $setting->custom_forgot_pass_url), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'https://my.ldapserver-forgotpass.com')) }} @else {{ Form::text('custom_forgot_pass_url', Input::old('custom_forgot_pass_url', $setting->custom_forgot_pass_url), array('class' => 'form-control','placeholder' => 'https://my.ldapserver-forgotpass.com')) }} @endif

{{ trans('admin/settings/general.custom_forgot_pass_url_help') }}

{!! $errors->first('custom_forgot_pass_url', '') !!}
{{Form::close()}} @endif @stop @section('moar_scripts') @stop