Sponsored Content
Full Discussion: Help needed with date
Top Forums UNIX for Dummies Questions & Answers Help needed with date Post 302180556 by chris1234 on Monday 31st of March 2008 12:48:23 PM
Old 03-31-2008
No worries i got it. Thanks for all your helo
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Help needed on Date command

Hi, I am facing one problem with date command.Actually I want to use this command to get the last month,not the current month..OK,I can do current month - 1 and give special condition for january,But this time i need last month as strings like January,februaury,march etc... There is option... (5 Replies)
Discussion started by: nikunj
5 Replies

2. Shell Programming and Scripting

help needed in date format

i need to grep date in the format year-month-day,,,,,,, actually i need to grep those dates other than current date.......... can anyone help me in this...........i need a format of date which would grep previous date except current date (1 Reply)
Discussion started by: ali560045
1 Replies

3. Shell Programming and Scripting

Help Needed in Date Condition !!

I am writing an shell script , which reads a file with contents Example :: (( This Format is yyyy-MM-DD)) 2008-05-16 2008-05-17 2008-05-18 2008-05-19 2008-05-20 2008-05-21 when i run the shell script it has to check the current date and compare it with the todays date and give me... (24 Replies)
Discussion started by: ranga27
24 Replies

4. Shell Programming and Scripting

Help needed-calculate previous date

Hi Friends, Need a command/script in unix which calculates previous date from current date. For ex: If current date= 01 Jan 2008, then output =31 Dec 2007 If current_date =01 Aug 2008 , then output= 31 July 2008 Please advice Regards, Suresh (3 Replies)
Discussion started by: sureshg_sampat
3 Replies

5. Shell Programming and Scripting

Need to zip the files date wise --urgent Help needed

Hi all, this is my first post, i need to write a script to zip the files with datewise below are the log files. -rw------- 1 root sso 85316156 May 24 22:11 core_test_smservaz_104_104_1243217459_8896 -rw------- 1 root sso 90413304 May 25 22:12 core_test_smservaz_104_104_1243303895_20912... (4 Replies)
Discussion started by: lcschandu
4 Replies

6. UNIX for Dummies Questions & Answers

date command option e Help needed please!!

Hi All, I was trying to get the date in format "Feb2" I tried option "e" giving me a padded space and getting the result as "Feb 2". Though its working fine for dates 10 to 31. Please suggest me how to get rid of this space before date. Thanks Olivia (4 Replies)
Discussion started by: Olivia
4 Replies

7. Shell Programming and Scripting

Help needed with some date arithmetic

I have a file (main.lst) containing a list of dates in DDMMYYYY format. The dates will mostly be the same but it is possible to have multiple dates and these need not be in chronological order. I have another file containing another list of dates (holidays.lst). The task is to get the latest... (5 Replies)
Discussion started by: elixir_sinari
5 Replies

8. Shell Programming and Scripting

Archiving assistance needed date to month

We have year folder say in a path /opt/informat/Archive a folder 2012. And in the same folder /opt/informat/Archive we have different folders month based, like 201210, 201211, 201212, this have data for each month, ie files. Now time to time i need to move the monthly folders to the main folder... (1 Reply)
Discussion started by: raghavraok
1 Replies

9. Shell Programming and Scripting

Needed shell script to get the latest file based on date

hi i need the shell script to get the file with latest date. for example in my input folder i have files like file_20130212.txt file_20130211.txt now my output folder should have the file with latest date i.e..file_20120212.txt i want to get the latest file .. i.e is should take... (6 Replies)
Discussion started by: hemanthsaikumar
6 Replies

10. Shell Programming and Scripting

Help needed with date compare

Hello, I have this unix script which selects rows from DB where current time is greater than expired time (column). So this will give all the records that are expired 1 day ago, 2 days ago, 3 days ago, etc.. I need help modifying in such that it should give records that are only expired 1 day... (5 Replies)
Discussion started by: jakSun8
5 Replies
SPFQUERY(1)                                             User Contributed Perl Documentation                                            SPFQUERY(1)

NAME
spfquery - (Mail::SPF) - Checks if a given set of e-mail parameters matches a domain's SPF policy VERSION
2.501 SYNOPSIS
Preferred usage: spfquery [--versions|-v 1|2|1,2] [--scope|-s helo|mfrom|pra] --identity|--id identity --ip-address|--ip ip-address [--helo-identity|--helo-id helo-identity] [OPTIONS] spfquery [--versions|-v 1|2|1,2] [--scope|-s helo|mfrom|pra] --file|-f filename|- [OPTIONS] Legacy usage: spfquery --helo helo-identity --ip-address|--ip ip-address [OPTIONS] spfquery --mfrom mfrom-identity --ip-address|--ip ip-address [--helo helo-identity] [OPTIONS] spfquery --pra pra-identity --ip-address|--ip ip-address [OPTIONS] Other usage: spfquery --version|-V spfquery --help DESCRIPTION
spfquery checks if a given set of e-mail parameters (e.g., the SMTP sender's IP address) matches the responsible domain's Sender Policy Framework (SPF) policy. For more information on SPF see <http://www.openspf.org>. Preferred Usage The following usage forms are preferred over the legacy forms used by older spfquery versions: The --identity form checks if the given ip-address is an authorized SMTP sender for the given "helo" hostname, "mfrom" envelope sender e-mail address, or "pra" (so-called purported resonsible address) e-mail address, depending on the value of the --scope option (which defaults to mfrom if omitted). The --file form reads "ip-address identity [helo-identity]" tuples from the file with the specified filename, or from standard input if filename is -, and checks them against the specified scope (mfrom by default). Both forms support an optional --versions option, which specifies a comma-separated list of the SPF version numbers of SPF records that may be used. 1 means that "v=spf1" records should be used. 2 means that "spf2.0" records should be used. Defaults to 1,2, i.e., uses any SPF records that are available. Records of a higher version are preferred. Legacy Usage spfquery versions before 2.500 featured the following usage forms, which are discouraged but still supported for backwards compatibility: The --helo form checks if the given ip-address is an authorized SMTP sender for the "HELO" hostname given as the identity (so-called "HELO" check). The --mfrom form checks if the given ip-address is an authorized SMTP sender for the envelope sender email-address (or domain) given as the identity (so-called "MAIL FROM" check). If a domain is given instead of an e-mail address, "postmaster" will be substituted for the localpart. The --pra form checks if the given ip-address is an authorized SMTP sender for the PRA (Purported Responsible Address) e-mail address given as the identity. Other Usage The --version form prints version information of spfquery. The --help form prints usage information for spfquery. OPTIONS
Standard Options The preferred and legacy forms optionally take any of the following OPTIONS: --default-explanation string --def-exp string Use the specified string as the default explanation if the authority domain does not specify an explanation string of its own. --hostname hostname Use hostname as the host name of the local system instead of auto-detecting it. --keep-comments --no-keep-comments Do (not) print any comments found when reading from a file or from standard input. --sanitize (currently ignored) --no-sanitize (currently ignored) Do (not) sanitize the output by condensing consecutive white-space into a single space and replacing non-printable characters with question marks. Enabled by default. --debug (currently ignored) Print out debug information. Black Magic Options Several options that were supported by earlier versions of spfquery are considered black magic (i.e. potentially dangerous for the innocent user) and are thus disabled by default. If the Mail::SPF::BlackMagic Perl module is installed, they may be enabled by specifying --enable-black-magic. --max-dns-interactive-terms n Evaluate a maximum of n DNS-interactive mechanisms and modifiers per SPF check. Defaults to 10. Do not override the default unless you know what you are doing! --max-name-lookups-per-term n Perform a maximum of n DNS name look-ups per mechanism or modifier. Defaults to 10. Do not override the default unless you know what you are doing! --authorize-mxes-for email-address|domain,... Consider all the MXes of the comma-separated list of email-addresses and domains as inherently authorized. --tfwl Perform "trusted-forwarder.org" accreditation checking. --guess spf-terms Use spf-terms as a default record if no SPF record is found. --local spf-terms Process spf-terms as local policy before resorting to a default result (the implicit or explicit "all" mechanism at the end of the domain's SPF record). For example, this could be used for white-listing one's secondary MXes: "mx:mydomain.example.org". --override domain=spf-record --fallback domain=spf-record Set overrides and fallbacks. Each option can be specified multiple times. For example: --override example.org='v=spf1 -all' --override '*.example.net'='v=spf1 a mx -all' --fallback example.com='v=spf1 -all' RESULT CODES
pass The specified IP address is an authorized SMTP sender for the identity. fail The specified IP address is not an authorized SMTP sender for the identity. softfail The specified IP address is not an authorized SMTP sender for the identity, however the authority domain is still testing out its SPF policy. neutral The identity's authority domain makes no assertion about the status of the IP address. permerror A permanent error occurred while evaluating the authority domain's policy (e.g., a syntax error in the SPF record). Manual intervention is required from the authority domain. temperror A temporary error occurred while evaluating the authority domain's policy (e.g., a DNS error). Try again later. none There is no applicable SPF policy for the identity domain. EXIT CODES
Result | Exit code -----------+----------- pass | 0 fail | 1 softfail | 2 neutral | 3 permerror | 4 temperror | 5 none | 6 EXAMPLES
spfquery --scope mfrom --id user@example.com --ip 1.2.3.4 spfquery --file test_data echo "127.0.0.1 user@example.com helohost.example.com" | spfquery -f - COMPATIBILITY
spfquery has undergone the following interface changes compared to earlier versions: 2.500 o A new preferred usage style for performing individual SPF checks has been introduced. The new style accepts a unified --identity option and an optional --scope option that specifies the type (scope) of the identity. In contrast, the legacy usage style requires a separate usage form for every supported scope. See "Preferred usage" and "Legacy usage" for details. o The former "unknown" and "error" result codes have been renamed to "permerror" and "temperror", respectively, in order to comply with RFC 4408 terminology. o SPF checks with an empty identity are no longer supported. In the case of an empty "MAIL FROM" SMTP transaction parameter, perform a check with the "helo" scope directly. o The --debug and --(no-)sanitize options are currently ignored by this version of spfquery. They will again be supported in the future. o Several features that were supported by earlier versions of spfquery are considered black magic and thus are now disabled by default. See "Black Magic Options". o Several option names have been deprecated. This is a list of them and their preferred synonyms: Deprecated options | Preferred options ---------------------+----------------------------- --sender, -s | --mfrom --ipv4, -i | --ip-address, --ip --name | --hostname --max-lookup-count, | --max-dns-interactive-terms --max-lookup | --rcpt-to, -r | --authorize-mxes-for --trusted | --tfwl SEE ALSO
Mail::SPF, spfd(8) <http://www.ietf.org/rfc/rfc4408.txt> AUTHORS
This version of spfquery is a complete rewrite by Julian Mehnle <julian@mehnle.net>, based on an earlier version written by Meng Weng Wong <mengwong+spf@pobox.com> and Wayne Schlitt <wayne@schlitt.net>. perl v5.12.1 2010-07-05 SPFQUERY(1)
All times are GMT -4. The time now is 09:54 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy