/usr/lib/ruby/1.8/facter/netmask.rb is in facter 1.6.5-1ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | # Fact: netmask
#
# Purpose: Returns the netmask for the main interfaces.
#
# Resolution: Uses the facter/util/netmask library routines.
#
# Caveats:
#
# netmask.rb
# Find the netmask of the primary ipaddress
# Copyright (C) 2007 David Schmitt <david@schmitt.edv-bus.at>
# Copyright (C) 2007 Mark 'phips' Phillips
#
# idea and originial source by Mark 'phips' Phillips
#
require 'facter/util/netmask'
Facter.add("netmask") do
confine :kernel => [ :sunos, :linux, :freebsd, :openbsd, :netbsd, :darwin, :"gnu/kfreebsd", :dragonfly ]
setcode do
Facter::NetMask.get_netmask
end
end
|