/[cwmp]/google/trunk/bin/acs.pl
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Annotation of /google/trunk/bin/acs.pl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 180 - (hide annotations)
Sun Oct 28 21:36:30 2007 UTC (16 years, 7 months ago) by dpavlin
File MIME type: text/plain
File size: 1331 byte(s)
added --protocol-dump flag to acs which include part of protocol that we implement
1 dpavlin 28 #!/usr/bin/perl -w
2    
3     # acs.pl
4     #
5     # 06/18/07 09:19:54 CEST Dobrica Pavlinusic <dpavlin@rot13.org>
6    
7     use strict;
8    
9 dpavlin 30 use lib './lib';
10     use CWMP::Server;
11 dpavlin 57 use Getopt::Long;
12 dpavlin 28
13     my $port = 3333;
14 dpavlin 57 my $debug = 0;
15 dpavlin 164 my $store_path = './';
16     my $store_plugin = 'YAML';
17 dpavlin 180 my $protocol_dump = 0;
18 dpavlin 28
19 dpavlin 57 GetOptions(
20     'debug+' => \$debug,
21     'port=i' => \$port,
22 dpavlin 164 'store-path=s' => \$store_path,
23     'store-plugin=s' => \$store_plugin,
24 dpavlin 180 'protocol-dump!' => \$protocol_dump,
25 dpavlin 57 );
26    
27 dpavlin 180 my $queue;
28    
29     if ( $protocol_dump ) {
30    
31     warn "generating dump of xml protocol with CPE\n";
32    
33     $queue = [
34     'GetRPCMethods',
35     'GetParameterNames',
36     # [ 'GetParameterNames', 'InternetGatewayDevice.DeviceInfo.SerialNumber', 0 ],
37     # [ 'GetParameterNames', 'InternetGatewayDevice.DeviceInfo.', 1 ],
38     [ 'GetParameterValues',
39     'InternetGatewayDevice.DeviceInfo.SerialNumber',
40     'InternetGatewayDevice.DeviceInfo.VendorConfigFile.',
41     'InternetGatewayDevice.DeviceInfo.X_000E50_Country',
42     ],
43     [ 'SetParameterValues',
44     'InternetGatewayDevice.DeviceInfo.ProvisioningCode' => 'test provision',
45     # 'InternetGatewayDevice.DeviceInfo.X_000E50_Country' => 1,
46     ],
47     # 'Reboot',
48     ];
49     };
50    
51    
52 dpavlin 50 my $server = CWMP::Server->new({
53     port => $port,
54 dpavlin 150 store => {
55 dpavlin 164 module => $store_plugin,
56     path => $store_path,
57     debug => $debug,
58 dpavlin 150 },
59 dpavlin 53 debug => $debug,
60 dpavlin 180 default_queue => [ $queue ],
61 dpavlin 50 });
62 dpavlin 28 $server->run();
63    

Properties

Name Value
svn:executable *

  ViewVC Help
Powered by ViewVC 1.1.26