Connect. Communicate. Collaborate. Securely.

Home » Kerio User Forums » Kerio Control » how to configure Kerio Control UTM by Command Line with ssh? (how to configure Kerio Control UTM by Command Line with ssh?)
  •  
ali.sajedi

Messages: 6
Karma: 0
Send a private message to this user
how to configure Kerio Control UTM by Command Line with ssh?

for example i want add ipAddressGroup by Command Line or etc...

  •  
ICT and Me

Messages: 935

Karma: 53
Send a private message to this user
Officially that isn't possible. Best is to do this in Control Console.

ICT and Me
Carlo Turk
The Netherlands
www.ictandme.nl
  •  
Brian Carmichael (Kerio)

Messages: 639
Karma: 65
Send a private message to this user

Brian Carmichael
Senior Technical Marketing Engineer | Kerio
Stay Connected Anytime, Anywhere. Discover Kerio Cloud!
  •  
ali.sajedi

Messages: 6
Karma: 0
Send a private message to this user
thanks for your reply.

but i want add a ipaddressgroup by this api and the documentiation and example no complete.

please help me to add ipaddressgroup by api.

i can add ipaddressgroup in winroute.cfg and execute 60winroute restart command but this command restart winroute service and expired all user session.


please help me

[Updated on: Sat, 30 May 2015 11:56]

  •  
ali.sajedi

Messages: 6
Karma: 0
Send a private message to this user
hello

i write this code to add ipaddressgroup. the kerio not return any errors. but not add ip address group to list. why????????

try {
	$session = $api->login($hostname, $username, $password);
		
	$params=array( 
		'groupIds' => array(''),
		'details' => array( 
		'groupId' => 'bm8tZmlsdGVy', 
		'description' => 'descsdfgdghddgd', 
		'type' => 'Host', 
		'enabled' => '1', 
		'status'=>'StoreStatusClean',
		'host' => 'dddddddddddddddd.com'
		) 
	);
	$output1=$api->sendRequest('IpAddressGroups.set', $params);
	
	$api->sendRequest('IpAddressGroups.apply');
		
}
catch (KerioApiException $error) {

	/* Catch possible errors */
	$html->printError($error->getMessage());
}

[Updated on: Sun, 31 May 2015 11:11]

  •  
ali.sajedi

Messages: 6
Karma: 0
Send a private message to this user
Who does not know the answer to my question ???!!!!!!!
  •  
Brian Carmichael (Kerio)

Messages: 639
Karma: 65
Send a private message to this user
Hi Ali, there is a separate forum for the API. You should post your question there. From the developer zone http://www.kerio.com/learn-community/developer-zone go to the "Get involved" tab and apply to join the forum.

Brian Carmichael
Senior Technical Marketing Engineer | Kerio
Stay Connected Anytime, Anywhere. Discover Kerio Cloud!
  •  
ali.sajedi

Messages: 6
Karma: 0
Send a private message to this user
I went to the link and complete the registration form, but ...

I do not think my question is difficult to answer.
  •  
ali.sajedi

Messages: 6
Karma: 0
Send a private message to this user
i use this code to add ipGroupAddress. and this code correctly add addresses. But changes disappears after 30 seconds. why????????????????????

try {
	$session = $api->login($hostname, $username, $password);
	$params= array( 
			'groups' => array(array( 
			'groupName' => 'group-1', 
			'description' => '-------------', 
			'type' => 'Host', 
			'enabled' => '1', 
			'status' => 'StoreStatusClean', 
			'host' => '-------------------'
			)) 
			);
			
	$output1=$api->sendRequest('IpAddressGroups.create', $params);
	
	$api->sendRequest('IpAddressGroups.apply');
	
}
catch (KerioApiException $error) {

	/* Catch possible errors */
	$html->printError($error->getMessage());
}

/* Logout */
if (isset($session)) {
	$api->logout();
}


If I refresh the kerio control admin page before 30 secondes, stored changes.
and display alert about confirmed and saved changes.

how to programically confirmed last changes?

i use this code for confimed changes. the code successfully run and no error. but no save last changes.

$u=$api->sendRequest('Session.getConfigTimestamp');
	printf ($u['clientTimestampList']['0']['name']);
	printf ($u['clientTimestampList']['0']['timestamp']);
	
	$p = array( 
	'clientTimestampList' => array(
	'name'=>$u['clientTimestampList']['0']['name'],
	'timestamp'=>$u['clientTimestampList']['0']['timestamp']
	)
	);
	
	$output2=$api->sendRequest('Session.confirmConfig',$p);
	
	print 'confirmed=';
	printf ($output2['confirmed']);

[Updated on: Tue, 09 June 2015 15:29]

Previous Topic: Suggestion for Control host connections exceeded
Next Topic: Statistic without NAT
Goto Forum:
  


Disclaimer:
Kerio discussion forums are intended for open communication between forum members and may contain information and material posted by members which may be useful in learning about Kerio products. The discussion forums are not intended to provide technical support for any specific product. Any information implied or expressed in the discussion forums is that of the posting member. Kerio is in no way responsible for the information posted in the forums, or its accuracy. Kerio employees may participate in the discussions, but their postings do not represent an offical position of the company on any issues raised or discussed. Kerio reserves the right to monitor and maintain the forums to promote free and accurate exchange of information.

Current Time: Sun Apr 23 23:32:05 CEST 2017

Total time taken to generate the page: 0.01518 seconds
.:: Contact :: Home ::.
Powered by: FUDforum 3.0.4.