debian/0000755000000000000000000000000012265462527007201 5ustar debian/libsoap-wsdl-perl.docs0000644000000000000000000000001411615546121013375 0ustar TODO README debian/rules0000755000000000000000000000153211615546121010251 0ustar #!/usr/bin/make -f PACKAGE = $(shell dh_listpackages) TMP = $(CURDIR)/debian/$(PACKAGE) %: dh $@ override_dh_auto_install: dh_auto_install # strip .pl ending prename 's/\.pl//' $(TMP)/usr/bin/wsdl2perl.pl $(TMP)/usr/share/man/man1/wsdl2perl.pl.1p # just fragments $(RM) -v $(TMP)/usr/share/man/man3/SOAP::WSDL::Generator::Template::XSD::complexType.tt.3pm \ $(TMP)/usr/share/man/man3/SOAP::WSDL::Generator::Template::XSD::complexType::POD::attributeSet.tt.3pm \ $(TMP)/usr/share/man/man3/SOAP::WSDL::Generator::Template::XSD::element.tt.3pm override_dh_installexamples: dh_installexamples # change all references to wsdl2perl.pl after everything is installed find $(TMP)/usr/share/perl5/SOAP/ $(TMP)/usr/share/man/ \ $(TMP)/usr/share/doc/$(PACKAGE)/examples/ $(TMP)/usr/bin/ \ -type f | xargs sed -i -e 's/wsdl2perl\.pl/wsdl2perl/g' debian/patches/0000755000000000000000000000000012265461655010631 5ustar debian/patches/series0000644000000000000000000000021712265451647012046 0ustar pod-whatis.patch pod-spelling.patch lvalue-modification-5.18.patch load-with-Class::Load.patch prefix_from_namespace.patch use-Test::XML.patch debian/patches/prefix_from_namespace.patch0000644000000000000000000000650712265453160016206 0ustar Description: fix reversal of namespace hashes to get a prefix hash Author: Damyan Ivanov Bug: https://rt.cpan.org/Ticket/Display.html?id=74257 Bug-Debian: http://bugs.debian.org/720964 --- a/lib/SOAP/WSDL/Base.pm +++ b/lib/SOAP/WSDL/Base.pm @@ -174,6 +174,38 @@ sub schema { return $parent->schema(); } +# this is used when we have a namespaces hash, but need to find the prefix to +# some namespace +# using %prefix = reverse %namespace; can break, as %namespace may contain +# duplicate values, due to the '#default' key: +# +# '#default' => 'urn:myNamespace', +# 'tns' => 'urn:myNamespace', +# 'xml' => 'http://www.w3.org/XML/1998/namespace', +# 'wsdl' => 'http://schemas.xmlsoap.org/wsdl/', +# 'xsd' => 'http://www.w3.org/2001/XMLSchema', +# 'soap' => 'http://schemas.xmlsoap.org/wsdl/soap/' +# +# 'reverse'-ing that with Perl 5.18 gives 'urn:myNamespace' => '#default' or +# 'urn:myNamespace' => 'tns' with 50% probability due to the hash randomization +# feature. +# Using reverse causes t/003_wsdl_based_serializer.t to fail most of the time +# because the prefix for 'urn:myNamespace' is sometimes '#default' (wrong), +# sometimes 'tns' (right) + +sub prefix_from_namespace { + my ( $self, $ns ) = @_; + + my %prefix; + + while ( my ( $prefix, $ns ) = each %$ns ) { + $prefix{$ns} = $prefix + unless $prefix eq '#default' and exists $prefix{$ns}; + } + + return \%prefix; +} + 1; __END__ --- a/lib/SOAP/WSDL/XSD/Builtin.pm +++ b/lib/SOAP/WSDL/XSD/Builtin.pm @@ -19,8 +19,8 @@ sub serialize { $xml .= '<' . join ' ', $name, @{ $opt->{ attributes } }; if ( $opt->{ autotype }) { my $ns = $self->get_targetNamespace(); - my %prefix_of = reverse %{ $opt->{ namespace } }; - my $prefix = $prefix_of{ $ns } + my $prefix_of = $self->prefix_from_namespace( $opt->{ namespace } ); + my $prefix = $prefix_of->{ $ns } || die 'No prefix found for namespace '. $ns; $xml .= ' type="' . $prefix . ':' . $self->get_name() . '"'; --- a/lib/SOAP/WSDL/XSD/ComplexType.pm +++ b/lib/SOAP/WSDL/XSD/ComplexType.pm @@ -98,8 +98,8 @@ sub serialize { if ( $opt->{ autotype }) { my $ns = $self->get_targetNamespace(); # reverse namespace by prefix hash - my %prefix_of = reverse %{ $opt->{ namespace } }; - my $prefix = $prefix_of{ $ns } + my $prefix_of = $self->prefix_from_namespace( $opt->{ namespace } ); + my $prefix = $prefix_of->{ $ns } || die 'No prefix found for namespace '. $ns; $xml .= join q{}, " type=\"$prefix:", $self->get_name(), '" ' if ($self->get_name() ); --- a/lib/SOAP/WSDL/XSD/SimpleType.pm +++ b/lib/SOAP/WSDL/XSD/SimpleType.pm @@ -100,9 +100,9 @@ sub _serialize_single { $xml .= '<' . join ' ', $name, @{ $opt->{ attributes } }; if ( $opt->{ autotype }) { # reverse namespace by prefix hash - my %prefix_of = reverse %{ $opt->{ namespace } }; + my $prefix_of = $self->prefix_from_namespace( $opt->{namespace} ); my $ns = $self->get_targetNamespace(); - my $prefix = $prefix_of{ $ns } + my $prefix = $prefix_of->{ $ns } || die 'No prefix found for namespace '. $ns; $xml .= ' type="' . $prefix . ':' . $self->get_name() .'"'; } debian/patches/use-Test::XML.patch0000644000000000000000000000150212265453571014124 0ustar Description: use Test::XML for comparing XML instead of 'eq' 'eq' works most of the time, until you have XML structures which have more than one attribute. Their serialization is non-deterministic since the order of the attributes is not predictable. Author: Damyan Ivanov Bug: https://rt.cpan.org/Ticket/Display.html?id=74257 Bug-Debian: http://bugs.debian.org/720964 --- a/t/SOAP/WSDL/05_simpleType-list.t +++ b/t/SOAP/WSDL/05_simpleType-list.t @@ -36,7 +36,11 @@ ok $xml = $soap->call('test', testAll => #5 ok ( $xml2 = $soap->call('test', testAll => "1 2" ) , 'Serialized scalar call' ); #6 -ok( $xml eq $xml2, 'Got expected result'); +SKIP: { + skip "Test::XML needed for comparing XML", 1 + unless eval { require Text::XML }; + is_xml( $xml, $xml2, 'Got expected result'); +} #7 TODO: { debian/patches/pod-whatis.patch0000644000000000000000000000220411615546121013715 0ustar Description: fix whatis entries Origin: vendor Forwarded: no Author: gregor herrmann Last-Update: 2010-12-21 --- a/lib/SOAP/WSDL/Manual/CodeFirst.pod +++ b/lib/SOAP/WSDL/Manual/CodeFirst.pod @@ -1,6 +1,8 @@ =pod -=head1 Writing Code-First Web Services with SOAP::WSDL +=head1 NAME + +CodeFirst - Writing Code-First Web Services with SOAP::WSDL B. --- a/lib/SOAP/WSDL/Manual/Deserializer.pod +++ b/lib/SOAP/WSDL/Manual/Deserializer.pod @@ -2,7 +2,7 @@ =head1 NAME -SOAP::WSDL::Manual::Deserializer +SOAP::WSDL::Manual::Deserializer - Deserializer classes =head1 DESERIALIZER CLASSES @@ -46,4 +46,4 @@ Martin Kutter Emartin.kutter fen-net.deE =cut - \ No newline at end of file + --- a/lib/SOAP/WSDL/Manual/Serializer.pod +++ b/lib/SOAP/WSDL/Manual/Serializer.pod @@ -2,7 +2,7 @@ =head1 NAME -SOAP::WSDL::Manual::Serializer +SOAP::WSDL::Manual::Serializer - Serializer classes =head1 SERIALIZER CLASSES @@ -27,4 +27,4 @@ Martin Kutter Emartin.kutter fen-net.deE =cut - \ No newline at end of file + debian/patches/pod-spelling.patch0000644000000000000000000001323012265461655014246 0ustar Description: spelling fixes Origin: vendor Forwarded: no Author: gregor herrmann Last-Update: 2010-12-21 --- a/lib/SOAP/WSDL.pm +++ b/lib/SOAP/WSDL.pm @@ -660,7 +660,7 @@ such interfaces. =head2 Debugging / Tracing While SOAP::Lite features a global tracing facility, SOAP::WSDL -allows to switch tracing on/of on a per-object base. +allows one to switch tracing on/of on a per-object base. This has to be done in the SOAP client used by SOAP::WSDL - see L for an example and L for @@ -784,7 +784,7 @@ L for de =head2 Skipping unwanted items -Sometimes there's unneccessary information transported in SOAP messages. +Sometimes there's unnecessary information transported in SOAP messages. To skip XML nodes (including all child nodes), just edit the type map for the message, set the type map entry to '__SKIP__', and comment out all --- a/lib/SOAP/WSDL/Manual/CodeFirst.pod +++ b/lib/SOAP/WSDL/Manual/CodeFirst.pod @@ -71,7 +71,7 @@ This would result in the following XML S Perl does not have the concept of interfaces. However, Moose provides Roles, which can be used for defining interfaces. -However, it's not really necessary to define a interface Interface (in the sense of a Jave interface) - +However, it's not really necessary to define a interface Interface (in the sense of a Java interface) - a interface class is sufficient. Subroutine attributes could be used for providing additional information - attributes in perl are much like --- a/lib/SOAP/WSDL/Manual/Cookbook.pod +++ b/lib/SOAP/WSDL/Manual/Cookbook.pod @@ -101,7 +101,7 @@ you should see at least two lines contai If you're talking to a Server using NTLMv2 exclusively, you will only the first line in the debug output, and then an error. -To explicitely enable NTLMv2, do the following in your client: +To explicitly enable NTLMv2, do the following in your client: use Authen::NTLM; ntlmv2(1); @@ -156,7 +156,7 @@ Instead, it requires this: How do I do this using SOAP::WSDL? -A: The following steps are neccessary to achieve this result: +A: The following steps are necessary to achieve this result: First, you would need to write a new serializer, which is quite easy, as it just creates the envelope and calls ->serialize_qualified() on $header and @@ -214,7 +214,7 @@ Example: The generated SOAP client is as =head2 Disabling strict XML processing in a CGI based server -You have to set the deserializer in the transport class explicitely to +You have to set the deserializer in the transport class explicitly to a L object with the C option set to 0. --- a/lib/SOAP/WSDL/Manual/FAQ.pod +++ b/lib/SOAP/WSDL/Manual/FAQ.pod @@ -64,7 +64,7 @@ and emits SOAP messages with namespace i Its SOAP message parser however, is not namespace sensitive but uses the pre-shared information from the WSDL for looking up what each XML node means. -SOAP::WSDL can parse SOAP messages including namespace informations up to the +SOAP::WSDL can parse SOAP messages including namespace information up to the point where equally named elements from different namespaces may appear at the same position. --- a/lib/SOAP/WSDL/Manual/Parser.pod +++ b/lib/SOAP/WSDL/Manual/Parser.pod @@ -75,7 +75,7 @@ A class resolver package might look like =head3 Skipping unwanted items -Sometimes there's unneccessary information transported in SOAP messages. +Sometimes there's unnecessary information transported in SOAP messages. To skip XML nodes (including all child nodes), just edit the type map for the message and set the type map entry to '__SKIP__'. --- a/lib/SOAP/WSDL/Manual/XSD.pod +++ b/lib/SOAP/WSDL/Manual/XSD.pod @@ -424,7 +424,7 @@ effect yet. =item * fractionDigits -=item * lenght +=item * length =item * maxExclusive --- a/lib/SOAP/WSDL/Manual/Glossary.pod +++ b/lib/SOAP/WSDL/Manual/Glossary.pod @@ -16,7 +16,7 @@ for Simple Object Access Protocol. SOAP is a W3C recommendation. The latest version of the SOAP specification may be found at L. -SOAP defines a protocoll for message exchange between applications. +SOAP defines a protocol for message exchange between applications. The most popular usage is to use SOAP for remote procedure calls (RPC). While one of the constituting aspects of a web service is its --- a/lib/SOAP/WSDL/Server/Simple.pm +++ b/lib/SOAP/WSDL/Server/Simple.pm @@ -129,7 +129,7 @@ See the generated server class on detail =head1 DESCRIPTION Lightweight SOAP server for use with HTTP::Server::Simple, mainly designed -for testing purposes. It allows to set up a simple SOAP server without having +for testing purposes. It allows one to set up a simple SOAP server without having to configure CGI or mod_perl stuff. SOAP::WSDL::Server::Simple is not recommended for production use. debian/patches/lvalue-modification-5.18.patch0000644000000000000000000000230212265452756016175 0ustar Description: fix invalid lvalue assignments with perl 5.18 also fixes a missing ->[0] after get_port() Author: Lee Johnson Bug: https://rt.cpan.org/Ticket/Display.html?id=74257 Bug-Debian: http://bugs.debian.org/720964 --- a/lib/SOAP/WSDL.pm +++ b/lib/SOAP/WSDL.pm @@ -166,7 +166,7 @@ sub _wsdl_get_service :PRIVATE { my $wsdl = $definitions_of{ $ident }; return $service_of{ $ident } = $servicename_of{ $ident } ? $wsdl->find_service( $wsdl->get_targetNamespace() , $servicename_of{ $ident } ) - : $service_of{ $ident } = $wsdl->get_service()->[ 0 ]; + : $wsdl->get_service()->[ 0 ]; } ## end sub _wsdl_get_service sub _wsdl_get_port :PRIVATE { @@ -174,8 +174,8 @@ sub _wsdl_get_port :PRIVATE { my $wsdl = $definitions_of{ $ident }; my $ns = $wsdl->get_targetNamespace(); return $port_of{ $ident } = $portname_of{ $ident } - ? $service_of{ $ident }->get_port( $ns, $portname_of{ $ident } ) - : $port_of{ $ident } = $service_of{ $ident }->get_port()->[ 0 ]; + ? $service_of{ $ident }->get_port( $ns, $portname_of{ $ident } )->[0] + : $service_of{ $ident }->get_port()->[ 0 ]; } sub _wsdl_get_binding :PRIVATE { debian/patches/load-with-Class::Load.patch0000644000000000000000000000257512265452455015600 0ustar Description: fix class loading with Perl 5.18 In Perl 5.18 everything is an object, so $type->isa('UNIVERSAL') succeeds even when $type is a plain string representng a class that was never loaded. . Deferring the check and the actual class loading to Class::Load fixes the issue. Author: Damyan Ivanov Bug: https://rt.cpan.org/Ticket/Display.html?id=74257 Bug-Debian: http://bugs.debian.org/720964 --- a/lib/SOAP/WSDL/XSD/Typelib/ComplexType.pm +++ b/lib/SOAP/WSDL/XSD/Typelib/ComplexType.pm @@ -7,6 +7,7 @@ use SOAP::WSDL::XSD::Typelib::Builtin; use Scalar::Util qw(blessed); use Data::Dumper; require Class::Std::Fast::Storable; +use Class::Load (); use base qw(SOAP::WSDL::XSD::Typelib::Builtin::anyType); @@ -155,9 +156,8 @@ sub _factory { my $type = $CLASSES_OF{ $class }->{ $name } or croak "No class given for $name"; - # require all types here - $type->isa('UNIVERSAL') - or eval "require $type" + Class::Load::is_class_loaded($type) + or eval { Class::Load::load_class $type } or croak $@; # check now, so we don't need to do it later. --- a/META.yml +++ b/META.yml @@ -8,6 +8,7 @@ license: artistic resources: license: http://opensource.org/licenses/artistic-license.php requires: + Class::Load: 0 Class::Std::Fast: 0.0.5 Data::Dumper: 0 Date::Format: 0 debian/copyright0000644000000000000000000000205512265462366011137 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: SOAP-WSDL Upstream-Contact: Martin Kutter Source: https://metacpan.org/release/SOAP-WSDL Files: * Copyright: 2004-2009, Martin Kutter License: Artistic or GPL-1+ Files: debian/* Copyright: 2010, gregor herrmann License: Artistic or GPL-1+ License: Artistic This program is free software; you can redistribute it and/or modify it under the terms of the Artistic License, which comes with Perl. . On Debian systems, the complete text of the Artistic License can be found in `/usr/share/common-licenses/Artistic'. License: GPL-1+ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version. . On Debian systems, the complete text of version 1 of the GNU General Public License can be found in `/usr/share/common-licenses/GPL-1'. debian/watch0000644000000000000000000000015712265462376010237 0ustar version=3 https://metacpan.org/release/SOAP-WSDL .*/SOAP-WSDL-v?(\d[\d.-]+)\.(?:tar(?:\.gz|\.bz2)?|tgz|zip)$ debian/libsoap-wsdl-perl.examples0000644000000000000000000000001211615546121014261 0ustar example/* debian/source/0000755000000000000000000000000011615546121010470 5ustar debian/source/format0000644000000000000000000000001411615546121011676 0ustar 3.0 (quilt) debian/control0000644000000000000000000000242512265462352010603 0ustar Source: libsoap-wsdl-perl Section: perl Priority: optional Build-Depends: debhelper (>= 8) Build-Depends-Indep: libclass-std-fast-perl, libtemplate-perl, libterm-readkey-perl, libtimedate-perl, liburi-perl, libwww-perl, libxml-parser-perl, libtest-pod-perl, libsoap-lite-perl, libtest-mockobject-perl, libio-stringy-perl, perl, libtest-xml-perl, libclass-load-perl Maintainer: Debian Perl Group Uploaders: gregor herrmann Standards-Version: 3.9.5 Homepage: https://metacpan.org/release/SOAP-WSDL Vcs-Git: git://anonscm.debian.org/pkg-perl/packages/libsoap-wsdl-perl.git Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-perl/packages/libsoap-wsdl-perl.git Package: libsoap-wsdl-perl Architecture: all Depends: ${misc:Depends}, ${perl:Depends}, libclass-std-fast-perl, libtemplate-perl, libterm-readkey-perl, libtimedate-perl, liburi-perl, libwww-perl, libxml-parser-perl, libclass-load-perl Recommends: libsoap-lite-perl Description: Perl module for SOAP with WSDL support SOAP::WSDL provides easy access to Web Services with WSDL descriptions. . The WSDL is parsed and stored in memory. Your data is serialized according to the rules in the WSDL. The only transport mechanisms currently supported are http and https. debian/compat0000644000000000000000000000000211615546121010366 0ustar 8 debian/changelog0000644000000000000000000000213312265462527011052 0ustar libsoap-wsdl-perl (2.00.10-2) unstable; urgency=low * Team upload [ Ansgar Burchardt ] * debian/control: Convert Vcs-* fields to Git. [ Salvatore Bonaccorso ] * debian/copyright: Replace DEP5 Format-Specification URL from svn.debian.org to anonscm.debian.org URL. * Change Vcs-Git to canonical URI (git://anonscm.debian.org) * Change search.cpan.org based URIs to metacpan.org based URIs [ Axel Beckert ] * debian/copyright: migrate pre-1.0 format to 1.0 using "cme fix dpkg- copyright" [ Damyan Ivanov ] * add libtest-xml-perl to build-dependencies enabling additional tests * add patches fixing invalid lvalue assignments and hash randomization issues with perl 5.18. Closes: #720964 * update pod-spelling.patch with two occurences of "allows to" * declare conformance with Policy 3.9.5 * remove trailing shash from metacpan URLs -- Damyan Ivanov Wed, 15 Jan 2014 12:39:08 +0200 libsoap-wsdl-perl (2.00.10-1) unstable; urgency=low * Initial release (closes: #607712). -- gregor herrmann Tue, 21 Dec 2010 20:03:05 +0100