Skip to content

stdweird/p5-net-freeipa

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

84 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

p5-net-freeipa

Perl5 NET::FreeIPA (FreeIPA 4.2+ JSON API)

Example usage

ipa user-find equivalent using API call and basic result postprocessing. The connection in this example will (try to) use kerberos authentication. (See Net::FreeIPA::RPC::new_client for authentication details.)

use Net::FreeIPA;

my $fi = Net::FreeIPA->new("host.example.com");
die("Failed to initialise the rest client") if ! $fi->{rc};
if ($fi->api_user_find("")) {
    print "Found ", scalar @{$fi->{result}}, " users\n";
} else {
    print "Something went wrong\n";
}

IPA API

All API commands are retrieve using gen_api.pl script from the JSON API.

Tests

Run tests with prove -Ilib -r t (or prove -Ilib -t/name_of_test.t for single unittest)

References

License

Apache 2.0 (license is added to the release via Dist-Zilla).

About

Perl5 NET::FreeIPA (FreeIPA 4.2+ JSON API)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages